From 33edab63c852ce6346c34df55210c167c14811ba Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Mon, 10 Feb 2025 16:26:03 +0300 Subject: [PATCH 01/16] refactor: update gitignore --- .gitignore | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index d94fc81d..e3ba8b52 100644 --- a/.gitignore +++ b/.gitignore @@ -4,6 +4,11 @@ *.dll *.so *.dylib +*.dot +*.log +*.ign + +.DS_Store # IDE Config files .idea/ @@ -29,4 +34,4 @@ .devcontainer # ignore build dir -build \ No newline at end of file +build From fec8719f07b000f59008067d3f904706e9442ac1 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Mon, 10 Feb 2025 16:26:47 +0300 Subject: [PATCH 02/16] refactor: remove unnecessary precommit config --- .pre-commit-config.yaml | 24 ------------------------ 1 file changed, 24 deletions(-) delete mode 100644 .pre-commit-config.yaml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml deleted file mode 100644 index 7f75d270..00000000 --- a/.pre-commit-config.yaml +++ /dev/null @@ -1,24 +0,0 @@ -repos: - - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.4.0 - hooks: - - id: check-yaml - - id: end-of-file-fixer - - id: trailing-whitespace - - id: check-json - - id: pretty-format-json - args: [--autofix, --indent=2, --no-sort-keys] - - repo: https://github.com/hadolint/hadolint - rev: v2.12.1-beta - hooks: - - id: hadolint - - repo: https://github.com/golangci/golangci-lint - rev: v1.50.1 - hooks: - - id: golangci-lint - - repo: https://github.com/dnephin/pre-commit-golang - rev: v0.5.1 - hooks: - - id: go-unit-tests - - id: go-build - - id: go-mod-tidy From 9e432e06ce5697c0ddffb3af42d04d744697bae9 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Mon, 10 Feb 2025 16:27:26 +0300 Subject: [PATCH 03/16] feat: upgrade go.mod for cosmos-sdk v0.50 and ibc8 --- go.mod | 419 +++++++++++-------- go.sum | 1267 ++++++++++++++++++++++++++------------------------------ 2 files changed, 826 insertions(+), 860 deletions(-) diff --git a/go.mod b/go.mod index 6bad7b8c..3fec5595 100644 --- a/go.mod +++ b/go.mod @@ -1,153 +1,194 @@ module github.com/sge-network/sge -go 1.23 +go 1.23.1 + +toolchain go1.23.5 require ( - cosmossdk.io/api v0.3.1 + cosmossdk.io/api v0.7.6 + cosmossdk.io/client/v2 v2.0.0-beta.5 + cosmossdk.io/collections v0.4.0 + cosmossdk.io/core v0.11.1 + cosmossdk.io/depinject v1.1.0 cosmossdk.io/errors v1.0.1 - cosmossdk.io/math v1.3.0 - cosmossdk.io/simapp v0.0.0-20230831152633-2e9e5d6eea24 - github.com/CosmWasm/wasmd v0.45.0 - github.com/cometbft/cometbft v0.37.5 - github.com/cometbft/cometbft-db v0.8.0 + cosmossdk.io/log v1.5.0 + cosmossdk.io/math v1.5.0 + cosmossdk.io/store v1.1.1 + cosmossdk.io/tools/confix v0.1.2 + cosmossdk.io/x/circuit v0.1.1 + cosmossdk.io/x/evidence v0.1.1 + cosmossdk.io/x/feegrant v0.1.1 + cosmossdk.io/x/nft v0.1.1 + cosmossdk.io/x/upgrade v0.1.4 + github.com/CosmWasm/wasmd v0.53.0 + github.com/bufbuild/buf v1.34.0 + github.com/cometbft/cometbft v0.38.15 + github.com/cosmos/cosmos-db v1.1.1 github.com/cosmos/cosmos-proto v1.0.0-beta.5 - github.com/cosmos/cosmos-sdk v0.47.14 + github.com/cosmos/cosmos-sdk v0.50.11 github.com/cosmos/gogoproto v1.7.0 - github.com/cosmos/ibc-apps/modules/ibc-hooks/v7 v7.0.0-20240502201956-e9b46e4bf0ad - github.com/cosmos/ibc-go/modules/light-clients/08-wasm v0.1.1-ibc-go-v7.3-wasmvm-v1.5 - github.com/cosmos/ibc-go/v7 v7.4.0 - github.com/golang-jwt/jwt v3.2.2+incompatible + github.com/cosmos/ibc-go/modules/capability v1.0.1 + github.com/cosmos/ibc-go/v8 v8.5.3 github.com/golang-jwt/jwt/v4 v4.5.1 + github.com/golang/mock v1.6.0 github.com/golang/protobuf v1.5.4 - github.com/golangci/golangci-lint v1.61.0 + github.com/golangci/golangci-lint v1.63.0 github.com/google/uuid v1.6.0 github.com/gorilla/mux v1.8.1 github.com/grpc-ecosystem/grpc-gateway v1.16.0 - github.com/grpc-ecosystem/grpc-gateway/v2 v2.23.0 + github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1 github.com/mrz1836/go-sanitize v1.3.3 - github.com/prometheus/client_golang v1.16.0 - github.com/rakyll/statik v0.1.7 - github.com/spf13/cast v1.7.0 + github.com/spf13/cast v1.7.1 github.com/spf13/cobra v1.8.1 - github.com/stretchr/testify v1.9.0 - google.golang.org/genproto/googleapis/api v0.0.0-20241021214115-324edc3d5d38 - google.golang.org/grpc v1.67.1 + github.com/spf13/pflag v1.0.6 + github.com/spf13/viper v1.19.0 + github.com/stretchr/testify v1.10.0 + golang.org/x/tools v0.29.0 + google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489 + google.golang.org/grpc v1.70.0 + google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.5.1 + google.golang.org/protobuf v1.36.5 gopkg.in/yaml.v2 v2.4.0 + gotest.tools/v3 v3.5.2 mvdan.cc/gofumpt v0.7.0 ) require ( - github.com/Abirdcfly/dupword v0.1.1 // indirect + github.com/Abirdcfly/dupword v0.1.3 // indirect github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24 // indirect github.com/alingse/asasalint v0.0.11 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect - github.com/cosmos/iavl v0.20.1 // indirect - github.com/creachadair/taskgroup v0.4.2 // indirect - github.com/curioswitch/go-reassign v0.2.0 // indirect + github.com/cosmos/iavl v1.2.4 // indirect + github.com/curioswitch/go-reassign v0.3.0 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect - github.com/google/btree v1.1.2 // indirect + github.com/google/btree v1.1.3 // indirect github.com/kkHAIKE/contextcheck v1.1.5 // indirect github.com/maratori/testableexamples v1.0.0 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/sashamelentyev/interfacebloat v1.1.0 // indirect - github.com/sashamelentyev/usestdlibvars v1.27.0 // indirect - github.com/spf13/pflag v1.0.5 // indirect - github.com/spf13/viper v1.18.2 // indirect - github.com/timonwong/loggercheck v0.9.4 // indirect - go.uber.org/atomic v1.10.0 // indirect - go.uber.org/multierr v1.9.0 // indirect - go.uber.org/zap v1.24.0 // indirect + github.com/sashamelentyev/usestdlibvars v1.28.0 // indirect + github.com/timonwong/loggercheck v0.10.1 // indirect + go.uber.org/multierr v1.11.0 // indirect + go.uber.org/zap v1.27.0 // indirect ) require ( 4d63.com/gocheckcompilerdirectives v1.2.1 // indirect 4d63.com/gochecknoglobals v0.2.1 // indirect + buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.3-20241127180247-a33202765966.1 // indirect + buf.build/gen/go/bufbuild/registry/connectrpc/go v1.18.1-20250106231242-56271afbd6ce.1 // indirect + buf.build/gen/go/bufbuild/registry/protocolbuffers/go v1.36.3-20250106231242-56271afbd6ce.1 // indirect + cel.dev/expr v0.19.1 // indirect cloud.google.com/go v0.115.1 // indirect - cloud.google.com/go/auth v0.9.3 // indirect + cloud.google.com/go/auth v0.9.4 // indirect cloud.google.com/go/auth/oauth2adapt v0.2.4 // indirect - cloud.google.com/go/compute/metadata v0.5.0 // indirect + cloud.google.com/go/compute/metadata v0.5.2 // indirect cloud.google.com/go/iam v1.2.0 // indirect cloud.google.com/go/storage v1.43.0 // indirect - cosmossdk.io/core v0.6.1 // indirect - cosmossdk.io/depinject v1.0.0-alpha.4 // indirect - cosmossdk.io/log v1.4.1 // indirect - cosmossdk.io/tools/rosetta v0.2.1 // indirect - filippo.io/edwards25519 v1.0.0 // indirect - github.com/4meepo/tagalign v1.3.4 // indirect + connectrpc.com/connect v1.18.1 // indirect + connectrpc.com/otelconnect v0.7.1 // indirect + cosmossdk.io/x/tx v0.13.7 // indirect + filippo.io/edwards25519 v1.1.0 // indirect + github.com/4meepo/tagalign v1.4.1 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect github.com/99designs/keyring v1.2.2 // indirect - github.com/Antonboom/errname v0.1.13 // indirect - github.com/Antonboom/nilnil v0.1.9 // indirect - github.com/Antonboom/testifylint v1.4.3 // indirect + github.com/Antonboom/errname v1.0.0 // indirect + github.com/Antonboom/nilnil v1.0.1 // indirect + github.com/Antonboom/testifylint v1.5.2 // indirect + github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c // indirect github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c // indirect - github.com/ChainSafe/go-schnorrkel v1.0.0 // indirect - github.com/CosmWasm/wasmvm v1.5.5 // indirect - github.com/Crocmagnon/fatcontext v0.5.2 // indirect + github.com/CosmWasm/wasmvm/v2 v2.2.1 // indirect + github.com/Crocmagnon/fatcontext v0.5.3 // indirect + github.com/DataDog/datadog-go v4.8.3+incompatible // indirect + github.com/DataDog/zstd v1.5.5 // indirect github.com/GaijinEntertainment/go-exhaustruct/v3 v3.3.0 // indirect - github.com/Masterminds/semver/v3 v3.3.0 // indirect + github.com/Masterminds/semver/v3 v3.3.1 // indirect + github.com/Microsoft/go-winio v0.6.2 // indirect github.com/OpenPeeDeeP/depguard/v2 v2.2.0 // indirect - github.com/alecthomas/go-check-sumtype v0.1.4 // indirect - github.com/alexkohler/nakedret/v2 v2.0.4 // indirect + github.com/alecthomas/go-check-sumtype v0.3.1 // indirect + github.com/alexkohler/nakedret/v2 v2.0.5 // indirect github.com/alexkohler/prealloc v1.0.0 // indirect - github.com/armon/go-metrics v0.4.1 // indirect + github.com/alingse/nilnesserr v0.1.1 // indirect + github.com/antlr4-go/antlr/v4 v4.13.1 // indirect github.com/ashanbrown/forbidigo v1.6.0 // indirect - github.com/ashanbrown/makezero v1.1.1 // indirect - github.com/aws/aws-sdk-go v1.44.203 // indirect - github.com/benbjohnson/clock v1.3.0 // indirect + github.com/ashanbrown/makezero v1.2.0 // indirect + github.com/aws/aws-sdk-go v1.44.224 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect - github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect - github.com/bkielbasa/cyclop v1.2.1 // indirect + github.com/bgentry/speakeasy v0.2.0 // indirect + github.com/bits-and-blooms/bitset v1.8.0 // indirect + github.com/bkielbasa/cyclop v1.2.3 // indirect github.com/blizzy78/varnamelen v0.8.0 // indirect - github.com/bombsimon/wsl/v4 v4.4.1 // indirect - github.com/breml/bidichk v0.2.7 // indirect - github.com/breml/errchkjson v0.3.6 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect - github.com/butuzov/ireturn v0.3.0 // indirect - github.com/butuzov/mirror v1.2.0 // indirect + github.com/bombsimon/wsl/v4 v4.5.0 // indirect + github.com/breml/bidichk v0.3.2 // indirect + github.com/breml/errchkjson v0.4.0 // indirect + github.com/bufbuild/protocompile v0.14.1 // indirect + github.com/bufbuild/protoplugin v0.0.0-20250106231243-3a819552c9d9 // indirect + github.com/bufbuild/protovalidate-go v0.8.2 // indirect + github.com/bufbuild/protoyaml-go v0.1.9 // indirect + github.com/butuzov/ireturn v0.3.1 // indirect + github.com/butuzov/mirror v1.3.0 // indirect + github.com/bytedance/sonic v1.12.3 // indirect + github.com/bytedance/sonic/loader v0.2.0 // indirect github.com/catenacyber/perfsprint v0.7.1 // indirect github.com/ccojocar/zxcvbn-go v1.0.2 // indirect - github.com/cenkalti/backoff/v4 v4.1.3 // indirect - github.com/cespare/xxhash v1.1.0 // indirect + github.com/cenkalti/backoff/v4 v4.3.0 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/charithe/durationcheck v0.0.10 // indirect github.com/chavacava/garif v0.1.0 // indirect github.com/chzyer/readline v1.5.1 // indirect - github.com/ckaznocha/intrange v0.2.0 // indirect + github.com/ckaznocha/intrange v0.3.0 // indirect + github.com/cloudwego/base64x v0.1.4 // indirect + github.com/cloudwego/iasm v0.2.0 // indirect github.com/cockroachdb/apd/v2 v2.0.2 // indirect - github.com/cockroachdb/errors v1.10.0 // indirect + github.com/cockroachdb/apd/v3 v3.2.1 // indirect + github.com/cockroachdb/errors v1.11.3 // indirect + github.com/cockroachdb/fifo v0.0.0-20240616162244-4768e80dfb9a // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect + github.com/cockroachdb/pebble v1.1.2 // indirect github.com/cockroachdb/redact v1.1.5 // indirect - github.com/coinbase/rosetta-sdk-go v0.7.9 // indirect - github.com/confio/ics23/go v0.9.0 // indirect + github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect + github.com/cometbft/cometbft-db v0.14.1 // indirect + github.com/containerd/continuity v0.4.5 // indirect + github.com/containerd/stargz-snapshotter/estargz v0.16.3 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect - github.com/cosmos/ics23/go v0.10.0 // indirect - github.com/cosmos/ledger-cosmos-go v0.12.4 // indirect - github.com/cosmos/rosetta-sdk-go v0.10.0 // indirect + github.com/cosmos/ics23/go v0.11.0 // indirect + github.com/cosmos/ledger-cosmos-go v0.13.3 // indirect + github.com/cpuguy83/go-md2man/v2 v2.0.6 // indirect + github.com/creachadair/atomicfile v0.3.1 // indirect + github.com/creachadair/tomledit v0.0.24 // indirect github.com/daixiang0/gci v0.13.5 // indirect - github.com/danieljoos/wincred v1.1.2 // indirect + github.com/danieljoos/wincred v1.2.1 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 // indirect github.com/denis-tingaikin/go-header v0.5.0 // indirect - github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect - github.com/dgraph-io/badger/v2 v2.2007.4 // indirect - github.com/dgraph-io/ristretto v0.1.1 // indirect - github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect - github.com/docker/distribution v2.8.2+incompatible // indirect + github.com/desertbit/timer v1.0.1 // indirect + github.com/dgraph-io/badger/v4 v4.2.0 // indirect + github.com/dgraph-io/ristretto v0.1.2-0.20240116140435-c67e07994f91 // indirect + github.com/distribution/reference v0.6.0 // indirect + github.com/docker/cli v27.5.0+incompatible // indirect + github.com/docker/distribution v2.8.3+incompatible // indirect + github.com/docker/docker v27.5.0+incompatible // indirect + github.com/docker/docker-credential-helpers v0.8.2 // indirect + github.com/docker/go-connections v0.5.0 // indirect + github.com/docker/go-units v0.5.0 // indirect github.com/dustin/go-humanize v1.0.1 // indirect - github.com/dvsekhvalnov/jose2go v1.6.0 // indirect + github.com/dvsekhvalnov/jose2go v1.7.0 // indirect + github.com/emicklei/dot v1.6.2 // indirect github.com/ettle/strcase v0.2.0 // indirect - github.com/fatih/color v1.17.0 // indirect + github.com/fatih/color v1.18.0 // indirect github.com/fatih/structtag v1.2.0 // indirect + github.com/felixge/fgprof v0.9.5 // indirect github.com/firefart/nonamedreturns v1.0.5 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/fzipp/gocyclo v0.6.0 // indirect - github.com/getsentry/sentry-go v0.23.0 // indirect + github.com/getsentry/sentry-go v0.28.1 // indirect github.com/ghodss/yaml v1.0.0 // indirect - github.com/ghostiam/protogetter v0.3.6 // indirect - github.com/go-critic/go-critic v0.11.4 // indirect - github.com/go-kit/kit v0.12.0 // indirect + github.com/ghostiam/protogetter v0.3.8 // indirect + github.com/go-chi/chi/v5 v5.2.0 // indirect + github.com/go-critic/go-critic v0.11.5 // indirect + github.com/go-kit/kit v0.13.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect github.com/go-logr/logr v1.4.2 // indirect @@ -159,76 +200,89 @@ require ( github.com/go-toolsmith/astp v1.1.0 // indirect github.com/go-toolsmith/strparse v1.1.0 // indirect github.com/go-toolsmith/typep v1.1.0 // indirect - github.com/go-viper/mapstructure/v2 v2.1.0 // indirect - github.com/go-xmlfmt/xmlfmt v1.1.2 // indirect + github.com/go-viper/mapstructure/v2 v2.2.1 // indirect + github.com/go-xmlfmt/xmlfmt v1.1.3 // indirect github.com/gobwas/glob v0.2.3 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gofrs/flock v0.12.1 // indirect + github.com/gofrs/uuid/v5 v5.2.0 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/glog v1.2.2 // indirect - github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect - github.com/golang/mock v1.6.0 // indirect + github.com/golang/glog v1.2.3 // indirect + github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect github.com/golang/snappy v0.0.4 // indirect github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a // indirect - github.com/golangci/gofmt v0.0.0-20240816233607-d8596aa466a9 // indirect + github.com/golangci/go-printf-func-name v0.1.0 // indirect + github.com/golangci/gofmt v0.0.0-20241223200906-057b0627d9b9 // indirect github.com/golangci/misspell v0.6.0 // indirect - github.com/golangci/modinfo v0.3.4 // indirect + github.com/golangci/modinfo v0.3.3 // indirect github.com/golangci/plugin-module-register v0.1.1 // indirect github.com/golangci/revgrep v0.5.3 // indirect github.com/golangci/unconvert v0.0.0-20240309020433-c5143eacb3ed // indirect + github.com/google/cel-go v0.22.1 // indirect + github.com/google/flatbuffers v24.3.25+incompatible // indirect github.com/google/go-cmp v0.6.0 // indirect + github.com/google/go-containerregistry v0.20.2 // indirect github.com/google/gofuzz v1.2.0 // indirect github.com/google/orderedcode v0.0.1 // indirect + github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad // indirect github.com/google/s2a-go v0.1.8 // indirect - github.com/googleapis/enterprise-certificate-proxy v0.3.3 // indirect + github.com/googleapis/enterprise-certificate-proxy v0.3.4 // indirect github.com/googleapis/gax-go/v2 v2.13.0 // indirect github.com/gordonklaus/ineffassign v0.1.0 // indirect - github.com/gorilla/handlers v1.5.1 // indirect - github.com/gorilla/websocket v1.5.0 // indirect + github.com/gorilla/handlers v1.5.2 // indirect + github.com/gorilla/websocket v1.5.3 // indirect github.com/gostaticanalysis/analysisutil v0.7.1 // indirect github.com/gostaticanalysis/comment v1.4.2 // indirect github.com/gostaticanalysis/forcetypeassert v0.1.0 // indirect github.com/gostaticanalysis/nilerr v0.1.1 // indirect - github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 // indirect + github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 // indirect github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c // indirect - github.com/gtank/merlin v0.1.1 // indirect - github.com/gtank/ristretto255 v0.1.2 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/hashicorp/go-getter v1.7.5 // indirect + github.com/hashicorp/go-hclog v1.6.3 // indirect github.com/hashicorp/go-immutable-radix v1.3.1 // indirect + github.com/hashicorp/go-immutable-radix/v2 v2.1.0 // indirect + github.com/hashicorp/go-metrics v0.5.3 // indirect + github.com/hashicorp/go-plugin v1.6.1 // indirect github.com/hashicorp/go-safetemp v1.0.0 // indirect github.com/hashicorp/go-version v1.7.0 // indirect - github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect + github.com/hashicorp/golang-lru v1.0.2 // indirect + github.com/hashicorp/golang-lru/v2 v2.0.7 // indirect github.com/hashicorp/hcl v1.0.0 // indirect - github.com/hdevalence/ed25519consensus v0.1.0 // indirect + github.com/hashicorp/yamux v0.1.1 // indirect + github.com/hdevalence/ed25519consensus v0.2.0 // indirect github.com/hexops/gotextdiff v1.0.3 // indirect github.com/huandu/skiplist v1.2.0 // indirect + github.com/iancoleman/strcase v0.3.0 // indirect github.com/improbable-eng/grpc-web v0.15.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect + github.com/jdx/go-netrc v1.0.0 // indirect github.com/jgautheron/goconst v1.7.1 // indirect github.com/jingyugao/rowserrcheck v1.1.1 // indirect - github.com/jirfag/go-printf-func-name v0.0.0-20200119135958-7558a9eaa5af // indirect - github.com/jjti/go-spancheck v0.6.2 // indirect + github.com/jjti/go-spancheck v0.6.4 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect - github.com/julz/importas v0.1.0 // indirect + github.com/julz/importas v0.2.0 // indirect github.com/karamaru-alpha/copyloopvar v1.1.0 // indirect - github.com/kisielk/errcheck v1.7.0 // indirect - github.com/klauspost/compress v1.17.0 // indirect + github.com/kisielk/errcheck v1.8.0 // indirect + github.com/klauspost/compress v1.17.11 // indirect + github.com/klauspost/cpuid/v2 v2.0.9 // indirect + github.com/klauspost/pgzip v1.2.6 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect github.com/kulti/thelper v0.6.3 // indirect github.com/kunwardeep/paralleltest v1.0.10 // indirect github.com/kyoh86/exportloopref v0.1.11 // indirect - github.com/lasiar/canonicalheader v1.1.1 // indirect - github.com/ldez/gomoddirectives v0.2.4 // indirect - github.com/ldez/tagliatelle v0.5.0 // indirect + github.com/lasiar/canonicalheader v1.1.2 // indirect + github.com/ldez/exptostd v0.3.0 // indirect + github.com/ldez/gomoddirectives v0.6.0 // indirect + github.com/ldez/grignotin v0.7.0 // indirect + github.com/ldez/tagliatelle v0.7.1 // indirect + github.com/ldez/usetesting v0.4.1 // indirect github.com/leonklingele/grouper v1.1.2 // indirect github.com/lib/pq v1.10.9 // indirect - github.com/libp2p/go-buffer-pool v0.1.0 // indirect - github.com/linxGnu/grocksdb v1.7.16 // indirect - github.com/lufeee/execinquery v1.2.1 // indirect + github.com/linxGnu/grocksdb v1.9.3 // indirect github.com/macabu/inamedparam v0.1.3 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/manifoldco/promptui v0.9.0 // indirect @@ -236,71 +290,89 @@ require ( github.com/matoous/godox v0.0.0-20230222163458-006bad1f9d26 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect - github.com/mattn/go-runewidth v0.0.10 // indirect - github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect - github.com/mgechev/revive v1.3.9 // indirect - github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 // indirect - github.com/minio/highwayhash v1.0.2 // indirect + github.com/mattn/go-runewidth v0.0.16 // indirect + github.com/mgechev/revive v1.5.1 // indirect + github.com/minio/highwayhash v1.0.3 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect + github.com/moby/docker-image-spec v1.3.1 // indirect + github.com/moby/term v0.5.2 // indirect github.com/moricho/tparallel v0.3.2 // indirect + github.com/morikuni/aec v1.0.0 // indirect github.com/mtibben/percent v0.2.1 // indirect + github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/nakabonne/nestif v0.3.1 // indirect github.com/nishanths/exhaustive v0.12.0 // indirect github.com/nishanths/predeclared v0.2.2 // indirect - github.com/nunnatsa/ginkgolinter v0.16.2 // indirect + github.com/nunnatsa/ginkgolinter v0.18.4 // indirect + github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a // indirect + github.com/oklog/run v1.1.0 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect + github.com/onsi/ginkgo/v2 v2.22.2 // indirect + github.com/onsi/gomega v1.36.2 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect + github.com/opencontainers/image-spec v1.1.0 // indirect + github.com/opencontainers/runc v1.1.14 // indirect github.com/pelletier/go-toml/v2 v2.2.3 // indirect - github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect + github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 // indirect + github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c // indirect + github.com/pkg/profile v1.7.0 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect - github.com/polyfloyd/go-errorlint v1.6.0 // indirect - github.com/prometheus/client_model v0.3.0 // indirect - github.com/prometheus/common v0.42.0 // indirect - github.com/prometheus/procfs v0.10.1 // indirect + github.com/polyfloyd/go-errorlint v1.7.0 // indirect + github.com/prometheus/client_golang v1.20.5 // indirect + github.com/prometheus/client_model v0.6.1 // indirect + github.com/prometheus/common v0.61.0 // indirect + github.com/prometheus/procfs v0.15.1 // indirect github.com/quasilyte/go-ruleguard v0.4.3-0.20240823090925-0fe6f58b47b1 // indirect github.com/quasilyte/go-ruleguard/dsl v0.3.22 // indirect github.com/quasilyte/gogrep v0.5.0 // indirect github.com/quasilyte/regex/syntax v0.0.0-20210819130434-b3f0c404a727 // indirect github.com/quasilyte/stdinfo v0.0.0-20220114132959-f7386bf02567 // indirect + github.com/raeperd/recvcheck v0.2.0 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect - github.com/rivo/uniseg v0.2.0 // indirect - github.com/rogpeppe/go-internal v1.12.0 // indirect - github.com/rs/cors v1.8.3 // indirect + github.com/rivo/uniseg v0.4.7 // indirect + github.com/rogpeppe/go-internal v1.13.1 // indirect + github.com/rs/cors v1.11.1 // indirect github.com/rs/zerolog v1.33.0 // indirect + github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/ryancurrah/gomodguard v1.3.5 // indirect github.com/ryanrolds/sqlclosecheck v0.5.1 // indirect - github.com/sagikazarmark/locafero v0.4.0 // indirect + github.com/sagikazarmark/locafero v0.6.0 // indirect github.com/sagikazarmark/slog-shim v0.1.0 // indirect - github.com/sanposhiho/wastedassign/v2 v2.0.7 // indirect - github.com/santhosh-tekuri/jsonschema/v5 v5.3.1 // indirect - github.com/sasha-s/go-deadlock v0.3.1 // indirect - github.com/securego/gosec/v2 v2.21.2 // indirect + github.com/sanposhiho/wastedassign/v2 v2.1.0 // indirect + github.com/santhosh-tekuri/jsonschema/v6 v6.0.1 // indirect + github.com/sasha-s/go-deadlock v0.3.5 // indirect + github.com/securego/gosec/v2 v2.21.4 // indirect + github.com/shamaton/msgpack/v2 v2.2.0 // indirect github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/sivchari/containedctx v1.0.3 // indirect - github.com/sivchari/tenv v1.10.0 // indirect - github.com/sonatard/noctx v0.0.2 // indirect + github.com/sivchari/tenv v1.12.1 // indirect + github.com/sonatard/noctx v0.1.0 // indirect github.com/sourcegraph/conc v0.3.0 // indirect github.com/sourcegraph/go-diff v0.7.0 // indirect github.com/spf13/afero v1.11.0 // indirect github.com/ssgreg/nlreturn/v2 v2.2.1 // indirect - github.com/stbenjam/no-sprintf-host-port v0.1.1 // indirect + github.com/stbenjam/no-sprintf-host-port v0.2.0 // indirect + github.com/stoewer/go-strcase v1.3.0 // indirect github.com/stretchr/objx v0.5.2 // indirect github.com/subosito/gotenv v1.6.0 // indirect github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect - github.com/tdakkota/asciicheck v0.2.0 // indirect + github.com/tdakkota/asciicheck v0.3.0 // indirect github.com/tendermint/go-amino v0.16.0 // indirect - github.com/tetafro/godot v1.4.17 // indirect - github.com/tidwall/btree v1.6.0 // indirect - github.com/timakin/bodyclose v0.0.0-20230421092635-574207250966 // indirect - github.com/tomarrell/wrapcheck/v2 v2.9.0 // indirect + github.com/tetafro/godot v1.4.20 // indirect + github.com/tidwall/btree v1.7.0 // indirect + github.com/timakin/bodyclose v0.0.0-20241017074812-ed6a65f985e3 // indirect + github.com/tomarrell/wrapcheck/v2 v2.10.0 // indirect github.com/tommy-muehle/go-mnd/v2 v2.5.1 // indirect + github.com/twitchyliquid64/golang-asm v0.15.1 // indirect github.com/ulikunitz/xz v0.5.11 // indirect - github.com/ultraware/funlen v0.1.0 // indirect - github.com/ultraware/whitespace v0.1.1 // indirect - github.com/uudashr/gocognit v1.1.3 // indirect + github.com/ultraware/funlen v0.2.0 // indirect + github.com/ultraware/whitespace v0.2.0 // indirect + github.com/uudashr/gocognit v1.2.0 // indirect + github.com/uudashr/iface v1.3.0 // indirect + github.com/vbatts/tar-split v0.11.6 // indirect github.com/xen0n/gosmopolitan v1.2.2 // indirect github.com/yagipy/maintidx v1.0.0 // indirect github.com/yeya24/promlinter v0.3.0 // indirect @@ -308,63 +380,50 @@ require ( github.com/zondax/hid v0.9.2 // indirect github.com/zondax/ledger-go v0.14.3 // indirect gitlab.com/bosi/decorder v0.4.2 // indirect - go-simpler.org/musttag v0.12.2 // indirect + go-simpler.org/musttag v0.13.0 // indirect go-simpler.org/sloglint v0.7.2 // indirect - go.etcd.io/bbolt v1.3.7 // indirect + go.etcd.io/bbolt v1.4.0-alpha.1 // indirect go.opencensus.io v0.24.0 // indirect + go.opentelemetry.io/auto/sdk v1.1.0 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.54.0 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.54.0 // indirect - go.opentelemetry.io/otel v1.29.0 // indirect - go.opentelemetry.io/otel/metric v1.29.0 // indirect - go.opentelemetry.io/otel/trace v1.29.0 // indirect - go.uber.org/automaxprocs v1.5.3 // indirect - golang.org/x/crypto v0.27.0 // indirect - golang.org/x/exp v0.0.0-20240904232852-e7e105dedf7e // indirect - golang.org/x/exp/typeparams v0.0.0-20240314144324-c7f7c6466f7f // indirect - golang.org/x/mod v0.21.0 // indirect - golang.org/x/net v0.28.0 // indirect - golang.org/x/oauth2 v0.23.0 // indirect - golang.org/x/sync v0.8.0 // indirect - golang.org/x/sys v0.25.0 // indirect - golang.org/x/term v0.24.0 // indirect - golang.org/x/text v0.19.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.58.0 // indirect + go.opentelemetry.io/otel v1.33.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.33.0 // indirect + go.opentelemetry.io/otel/sdk v1.32.0 // indirect + go.opentelemetry.io/otel/trace v1.33.0 // indirect + go.uber.org/atomic v1.11.0 // indirect + go.uber.org/automaxprocs v1.6.0 // indirect + golang.org/x/arch v0.0.0-20210923205945-b76863e36670 // indirect + golang.org/x/crypto v0.32.0 // indirect + golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 // indirect + golang.org/x/exp/typeparams v0.0.0-20241108190413-2d47ceb2692f // indirect + golang.org/x/mod v0.22.0 // indirect + golang.org/x/net v0.34.0 // indirect + golang.org/x/oauth2 v0.26.0 // indirect + golang.org/x/sync v0.11.0 // indirect + golang.org/x/sys v0.29.0 // indirect + golang.org/x/term v0.28.0 // indirect + golang.org/x/text v0.22.0 // indirect golang.org/x/time v0.6.0 // indirect - golang.org/x/tools v0.24.0 // indirect - google.golang.org/api v0.196.0 // indirect + google.golang.org/api v0.198.0 // indirect google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20241021214115-324edc3d5d38 // indirect - google.golang.org/protobuf v1.35.1 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20250204164813-702378808489 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect honnef.co/go/tools v0.5.1 // indirect mvdan.cc/unparam v0.0.0-20240528143540-8a5130ca722f // indirect - nhooyr.io/websocket v1.8.7 // indirect + nhooyr.io/websocket v1.8.11 // indirect pgregory.net/rapid v1.1.0 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) replace ( - // cosmos keyring - github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 - - github.com/CosmWasm/wasmd => github.com/sge-network/wasmd v0.0.0-20241104103744-57e9fdbaa27f - - github.com/cosmos/cosmos-sdk => github.com/sge-network/cosmos-sdk v0.47.9-0.20250130125213-8f7baf6f5b95 - - // support concurrency for iavl - github.com/cosmos/iavl => github.com/cosmos/iavl v0.20.1 - // dgrijalva/jwt-go is deprecated and doesn't receive security updates. // TODO: remove it: https://github.com/cosmos/cosmos-sdk/issues/13134 github.com/dgrijalva/jwt-go => github.com/golang-jwt/jwt/v4 v4.4.2 - - // Fix upstream GHSA-h395-qcrw-5vmq vulnerability. - // TODO Remove it: https://github.com/cosmos/cosmos-sdk/issues/10409 - github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.9.0 - - // https://github.com/cosmos/cosmos-sdk/issues/14949 - // pin the version of goleveldb to v1.0.1-0.20210819022825-2ae1ddf74ef7 required by SDK v47 upgrade guide. + // fix upstream GHSA-h395-qcrw-5vmq vulnerability. + github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.7.0 + // replace broken goleveldb github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 - - golang.org/x/exp => golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb ) diff --git a/go.sum b/go.sum index ee8e8323..c978caae 100644 --- a/go.sum +++ b/go.sum @@ -2,16 +2,22 @@ 4d63.com/gocheckcompilerdirectives v1.2.1/go.mod h1:yjDJSxmDTtIHHCqX0ufRYZDL6vQtMG7tJdKVeWwsqvs= 4d63.com/gochecknoglobals v0.2.1 h1:1eiorGsgHOFOuoOiJDy2psSrQbRdIHrlge0IJIkUgDc= 4d63.com/gochecknoglobals v0.2.1/go.mod h1:KRE8wtJB3CXCsb1xy421JfTHIIbmT3U5ruxw2Qu8fSU= +buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.3-20241127180247-a33202765966.1 h1:cQZXKoQ+eB0kykzfJe80RP3nc+3PWbbBrUBm8XNYAQY= +buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.3-20241127180247-a33202765966.1/go.mod h1:6VPKM8zbmgf9qsmkmKeH49a36Vtmidw3rG53B5mTenc= +buf.build/gen/go/bufbuild/registry/connectrpc/go v1.18.1-20250106231242-56271afbd6ce.1 h1:4bJ5Sh3FovNqit+k1rYn03YpckFkgpBjeZe52eoiuUY= +buf.build/gen/go/bufbuild/registry/connectrpc/go v1.18.1-20250106231242-56271afbd6ce.1/go.mod h1:GI0Fv/enMZ/dJPfDwU5zamn8P3LUEEl2L/1yg0qw4ZQ= +buf.build/gen/go/bufbuild/registry/protocolbuffers/go v1.36.3-20250106231242-56271afbd6ce.1 h1:yPzRLpc0SqVzph6J9NcNux3B7vx4hNy8svO36F+mogc= +buf.build/gen/go/bufbuild/registry/protocolbuffers/go v1.36.3-20250106231242-56271afbd6ce.1/go.mod h1:UOdD+CmwdvN3oRHXeZ+WDeIthKVXKo7Dm+2E/233xd0= +cel.dev/expr v0.19.1 h1:NciYrtDRIR0lNCnH1LFJegdjspNx9fI59O7TWcua/W4= +cel.dev/expr v0.19.1/go.mod h1:MrpN08Q+lEBs+bGYdLxxHkZoUSsCp0nSKTs0nTymJgw= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= -cloud.google.com/go v0.43.0/go.mod h1:BOSR3VbTLkk6FDC/TcffxP4NF/FFBGA5ku+jvKOP7pg= cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To= -cloud.google.com/go v0.51.0/go.mod h1:hWtGJ6gnXH+KgDv+V0zFGDvpi07n3z8ZNj3T1RW0Gcw= cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4= cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M= cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc= @@ -52,8 +58,8 @@ cloud.google.com/go/asset v1.8.0/go.mod h1:mUNGKhiqIdbr8X7KNayoYvyc4HbbFO9URsjby cloud.google.com/go/assuredworkloads v1.5.0/go.mod h1:n8HOZ6pff6re5KYfBXcFvSViQjDwxFkAkmUFffJRbbY= cloud.google.com/go/assuredworkloads v1.6.0/go.mod h1:yo2YOk37Yc89Rsd5QMVECvjaMKymF9OP+QXWlKXUkXw= cloud.google.com/go/assuredworkloads v1.7.0/go.mod h1:z/736/oNmtGAyU47reJgGN+KVoYoxeLBoj4XkKYscNI= -cloud.google.com/go/auth v0.9.3 h1:VOEUIAADkkLtyfr3BLa3R8Ed/j6w1jTBmARx+wb5w5U= -cloud.google.com/go/auth v0.9.3/go.mod h1:7z6VY+7h3KUdRov5F1i8NDP5ZzWKYmEPO842BgCsmTk= +cloud.google.com/go/auth v0.9.4 h1:DxF7imbEbiFu9+zdKC6cKBko1e8XeJnipNqIbWZ+kDI= +cloud.google.com/go/auth v0.9.4/go.mod h1:SHia8n6//Ya940F1rLimhJCjjx7KE17t0ctFEci3HkA= cloud.google.com/go/auth/oauth2adapt v0.2.4 h1:0GWE/FUsXhf6C+jAkWgYm7X9tK8cuEIfy19DBn6B6bY= cloud.google.com/go/auth/oauth2adapt v0.2.4/go.mod h1:jC/jOpwFP6JBxhB3P5Rr0a9HLMC/Pe3eaL4NmdvqPtc= cloud.google.com/go/automl v1.5.0/go.mod h1:34EjfoFGMZ5sgJ9EoLsRtdPSNZLcfflJR39VbVNS2M0= @@ -65,7 +71,6 @@ cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUM cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= cloud.google.com/go/bigquery v1.42.0/go.mod h1:8dRTJxhtG+vwBKzE5OseQn/hiydoQN3EedCaOdYmxRA= -cloud.google.com/go/bigtable v1.2.0/go.mod h1:JcVAOl45lrTmQfLj7T6TxyMzIN/3FGGcFm+2xVAli2o= cloud.google.com/go/billing v1.4.0/go.mod h1:g9IdKBEFlItS8bTtlrZdVLWSSdSyFUZKXNS02zKMOZY= cloud.google.com/go/billing v1.5.0/go.mod h1:mztb1tBc3QekhjSgmpf/CV4LzWXLzCArwpLmP2Gm88s= cloud.google.com/go/binaryauthorization v1.1.0/go.mod h1:xwnoWu3Y84jbuHa0zd526MJYmtnVXn0syOjaJgy4+dM= @@ -79,8 +84,8 @@ cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= -cloud.google.com/go/compute/metadata v0.5.0 h1:Zr0eK8JbFv6+Wi4ilXAR8FJ3wyNdpxHKJNPos6LTZOY= -cloud.google.com/go/compute/metadata v0.5.0/go.mod h1:aHnloV2TPI38yx4s9+wAZhHykWvVCfu7hQbF+9CWoiY= +cloud.google.com/go/compute/metadata v0.5.2 h1:UxK4uu/Tn+I3p2dYWTfiX4wva7aYlKixAHn3fyqngqo= +cloud.google.com/go/compute/metadata v0.5.2/go.mod h1:C66sj2AluDcIqakBq/M8lw8/ybHgOZqin2obFxa/E5k= cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= cloud.google.com/go/containeranalysis v0.6.0/go.mod h1:HEJoiEIu+lEXM+k7+qLCci0h33lX3ZqoYFdmPcoO7s4= cloud.google.com/go/datacatalog v1.3.0/go.mod h1:g9svFY6tuR+j+hrTw3J2dNcmI0dzmSiyOzm8kpLq0a0= @@ -195,135 +200,136 @@ cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xX cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= -collectd.org v0.3.0/go.mod h1:A/8DzQBkF6abtvrT2j/AU/4tiBgJWYyh0y/oB/4MlWE= -cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= -cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= -cosmossdk.io/core v0.6.1 h1:OBy7TI2W+/gyn2z40vVvruK3di+cAluinA6cybFbE7s= -cosmossdk.io/core v0.6.1/go.mod h1:g3MMBCBXtxbDWBURDVnJE7XML4BG5qENhs0gzkcpuFA= -cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= -cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= +connectrpc.com/connect v1.18.1 h1:PAg7CjSAGvscaf6YZKUefjoih5Z/qYkyaTrBW8xvYPw= +connectrpc.com/connect v1.18.1/go.mod h1:0292hj1rnx8oFrStN7cB4jjVBeqs+Yx5yDIC2prWDO8= +connectrpc.com/otelconnect v0.7.1 h1:scO5pOb0i4yUE66CnNrHeK1x51yq0bE0ehPg6WvzXJY= +connectrpc.com/otelconnect v0.7.1/go.mod h1:dh3bFgHBTb2bkqGCeVVOtHJreSns7uu9wwL2Tbz17ms= +cosmossdk.io/api v0.7.6 h1:PC20PcXy1xYKH2KU4RMurVoFjjKkCgYRbVAD4PdqUuY= +cosmossdk.io/api v0.7.6/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= +cosmossdk.io/client/v2 v2.0.0-beta.5 h1:0LVv3nEByn//hFDIrYLs2WvsEU3HodOelh4SDHnA/1I= +cosmossdk.io/client/v2 v2.0.0-beta.5/go.mod h1:4p0P6o0ro+FizakJUYS9SeM94RNbv0thLmkHRw5o5as= +cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= +cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= +cosmossdk.io/core v0.11.1 h1:h9WfBey7NAiFfIcUhDVNS503I2P2HdZLebJlUIs8LPA= +cosmossdk.io/core v0.11.1/go.mod h1:OJzxcdC+RPrgGF8NJZR2uoQr56tc7gfBKhiKeDO7hH0= +cosmossdk.io/depinject v1.1.0 h1:wLan7LG35VM7Yo6ov0jId3RHWCGRhe8E8bsuARorl5E= +cosmossdk.io/depinject v1.1.0/go.mod h1:kkI5H9jCGHeKeYWXTqYdruogYrEeWvBQCw1Pj4/eCFI= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= -cosmossdk.io/log v1.4.1 h1:wKdjfDRbDyZRuWa8M+9nuvpVYxrEOwbD/CA8hvhU8QM= -cosmossdk.io/log v1.4.1/go.mod h1:k08v0Pyq+gCP6phvdI6RCGhLf/r425UT6Rk/m+o74rU= -cosmossdk.io/math v1.3.0 h1:RC+jryuKeytIiictDslBP9i1fhkVm6ZDmZEoNP316zE= -cosmossdk.io/math v1.3.0/go.mod h1:vnRTxewy+M7BtXBNFybkuhSH4WfedVAAnERHgVFhp3k= -cosmossdk.io/simapp v0.0.0-20230831152633-2e9e5d6eea24 h1:A+LHM41uss8WNJ+qZCdvCjtiG6UiIN7ZqmPZz6R25wc= -cosmossdk.io/simapp v0.0.0-20230831152633-2e9e5d6eea24/go.mod h1:1kVkzonF2p6SYsSMXXURz/kx50QWArqazCk1Myulu8g= -cosmossdk.io/tools/rosetta v0.2.1 h1:ddOMatOH+pbxWbrGJKRAawdBkPYLfKXutK9IETnjYxw= -cosmossdk.io/tools/rosetta v0.2.1/go.mod h1:Pqdc1FdvkNV3LcNIkYWt2RQY6IP1ge6YWZk8MhhO9Hw= -filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= -filippo.io/edwards25519 v1.0.0 h1:0wAIcmJUqRdI8IJ/3eGi5/HwXZWPujYXXlkrQogz0Ek= -filippo.io/edwards25519 v1.0.0/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= -git.sr.ht/~sircmpwn/getopt v0.0.0-20191230200459-23622cc906b3/go.mod h1:wMEGFFFNuPos7vHmWXfszqImLppbc0wEhh6JBfJIUgw= -git.sr.ht/~sircmpwn/go-bare v0.0.0-20210406120253-ab86bc2846d9/go.mod h1:BVJwbDfVjCjoFiKrhkei6NdGcZYpkDkdyCdg1ukytRA= -github.com/4meepo/tagalign v1.3.4 h1:P51VcvBnf04YkHzjfclN6BbsopfJR5rxs1n+5zHt+w8= -github.com/4meepo/tagalign v1.3.4/go.mod h1:M+pnkHH2vG8+qhE5bVc/zeP7HS/j910Fwa9TUSyZVI0= +cosmossdk.io/log v1.5.0 h1:dVdzPJW9kMrnAYyMf1duqacoidB9uZIl+7c6z0mnq0g= +cosmossdk.io/log v1.5.0/go.mod h1:Tr46PUJjiUthlwQ+hxYtUtPn4D/oCZXAkYevBeh5+FI= +cosmossdk.io/math v1.5.0 h1:sbOASxee9Zxdjd6OkzogvBZ25/hP929vdcYcBJQbkLc= +cosmossdk.io/math v1.5.0/go.mod h1:AAwwBmUhqtk2nlku174JwSll+/DepUXW3rWIXN5q+Nw= +cosmossdk.io/store v1.1.1 h1:NA3PioJtWDVU7cHHeyvdva5J/ggyLDkyH0hGHl2804Y= +cosmossdk.io/store v1.1.1/go.mod h1:8DwVTz83/2PSI366FERGbWSH7hL6sB7HbYp8bqksNwM= +cosmossdk.io/tools/confix v0.1.2 h1:2hoM1oFCNisd0ltSAAZw2i4ponARPmlhuNu3yy0VwI4= +cosmossdk.io/tools/confix v0.1.2/go.mod h1:7XfcbK9sC/KNgVGxgLM0BrFbVcR/+6Dg7MFfpx7duYo= +cosmossdk.io/x/circuit v0.1.1 h1:KPJCnLChWrxD4jLwUiuQaf5mFD/1m7Omyo7oooefBVQ= +cosmossdk.io/x/circuit v0.1.1/go.mod h1:B6f/urRuQH8gjt4eLIXfZJucrbreuYrKh5CSjaOxr+Q= +cosmossdk.io/x/evidence v0.1.1 h1:Ks+BLTa3uftFpElLTDp9L76t2b58htjVbSZ86aoK/E4= +cosmossdk.io/x/evidence v0.1.1/go.mod h1:OoDsWlbtuyqS70LY51aX8FBTvguQqvFrt78qL7UzeNc= +cosmossdk.io/x/feegrant v0.1.1 h1:EKFWOeo/pup0yF0svDisWWKAA9Zags6Zd0P3nRvVvw8= +cosmossdk.io/x/feegrant v0.1.1/go.mod h1:2GjVVxX6G2fta8LWj7pC/ytHjryA6MHAJroBWHFNiEQ= +cosmossdk.io/x/nft v0.1.1 h1:pslAVS8P5NkW080+LWOamInjDcq+v2GSCo+BjN9sxZ8= +cosmossdk.io/x/nft v0.1.1/go.mod h1:Kac6F6y2gsKvoxU+fy8uvxRTi4BIhLOor2zgCNQwVgY= +cosmossdk.io/x/tx v0.13.7 h1:8WSk6B/OHJLYjiZeMKhq7DK7lHDMyK0UfDbBMxVmeOI= +cosmossdk.io/x/tx v0.13.7/go.mod h1:V6DImnwJMTq5qFjeGWpXNiT/fjgE4HtmclRmTqRVM3w= +cosmossdk.io/x/upgrade v0.1.4 h1:/BWJim24QHoXde8Bc64/2BSEB6W4eTydq0X/2f8+g38= +cosmossdk.io/x/upgrade v0.1.4/go.mod h1:9v0Aj+fs97O+Ztw+tG3/tp5JSlrmT7IcFhAebQHmOPo= +dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= +filippo.io/edwards25519 v1.1.0 h1:FNf4tywRC1HmFuKW5xopWpigGjJKiJSV0Cqo0cJWDaA= +filippo.io/edwards25519 v1.1.0/go.mod h1:BxyFTGdWcka3PhytdK4V28tE5sGfRvvvRV7EaN4VDT4= +github.com/4meepo/tagalign v1.4.1 h1:GYTu2FaPGOGb/xJalcqHeD4il5BiCywyEYZOA55P6J4= +github.com/4meepo/tagalign v1.4.1/go.mod h1:2H9Yu6sZ67hmuraFgfZkNcg5Py9Ch/Om9l2K/2W1qS4= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 h1:/vQbFIOMbk2FiG/kXiLl8BRyzTWDw7gX/Hz7Dd5eDMs= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4/go.mod h1:hN7oaIRCjzsZ2dE+yG5k+rsdt3qcwykqK6HVGcKwsw4= -github.com/Abirdcfly/dupword v0.1.1 h1:Bsxe0fIw6OwBtXMIncaTxCLHYO5BB+3mcsR5E8VXloY= -github.com/Abirdcfly/dupword v0.1.1/go.mod h1:B49AcJdTYYkpd4HjgAcutNGG9HZ2JWwKunH9Y2BA6sM= -github.com/Antonboom/errname v0.1.13 h1:JHICqsewj/fNckzrfVSe+T33svwQxmjC+1ntDsHOVvM= -github.com/Antonboom/errname v0.1.13/go.mod h1:uWyefRYRN54lBg6HseYCFhs6Qjcy41Y3Jl/dVhA87Ns= -github.com/Antonboom/nilnil v0.1.9 h1:eKFMejSxPSA9eLSensFmjW2XTgTwJMjZ8hUHtV4s/SQ= -github.com/Antonboom/nilnil v0.1.9/go.mod h1:iGe2rYwCq5/Me1khrysB4nwI7swQvjclR8/YRPl5ihQ= -github.com/Antonboom/testifylint v1.4.3 h1:ohMt6AHuHgttaQ1xb6SSnxCeK4/rnK7KKzbvs7DmEck= -github.com/Antonboom/testifylint v1.4.3/go.mod h1:+8Q9+AOLsz5ZiQiiYujJKs9mNz398+M6UgslP4qgJLA= -github.com/Azure/azure-sdk-for-go/sdk/azcore v0.21.1/go.mod h1:fBF9PQNqB8scdgpZ3ufzaLntG0AG7C1WjPMsiFOmfHM= -github.com/Azure/azure-sdk-for-go/sdk/internal v0.8.3/go.mod h1:KLF4gFr6DcKFZwSuH8w8yEK6DpFl3LP5rhdvAb7Yz5I= -github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0/go.mod h1:tPaiy8S5bQ+S5sOiDlINkp7+Ef339+Nz5L5XO+cnOHo= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 h1:UQHMgLO+TxOElx5B5HZ4hJQsoJ/PvUvKRhJHDQXO8P8= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= +github.com/99designs/keyring v1.2.2 h1:pZd3neh/EmUzWONb35LxQfvuY7kiSXAq3HQd97+XBn0= +github.com/99designs/keyring v1.2.2/go.mod h1:wes/FrByc8j7lFOAGLGSNEg8f/PaI3cgTBqhFkHUrPk= +github.com/Abirdcfly/dupword v0.1.3 h1:9Pa1NuAsZvpFPi9Pqkd93I7LIYRURj+A//dFd5tgBeE= +github.com/Abirdcfly/dupword v0.1.3/go.mod h1:8VbB2t7e10KRNdwTVoxdBaxla6avbhGzb8sCTygUMhw= +github.com/Antonboom/errname v1.0.0 h1:oJOOWR07vS1kRusl6YRSlat7HFnb3mSfMl6sDMRoTBA= +github.com/Antonboom/errname v1.0.0/go.mod h1:gMOBFzK/vrTiXN9Oh+HFs+e6Ndl0eTFbtsRTSRdXyGI= +github.com/Antonboom/nilnil v1.0.1 h1:C3Tkm0KUxgfO4Duk3PM+ztPncTFlOf0b2qadmS0s4xs= +github.com/Antonboom/nilnil v1.0.1/go.mod h1:CH7pW2JsRNFgEh8B2UaPZTEPhCMuFowP/e8Udp9Nnb0= +github.com/Antonboom/testifylint v1.5.2 h1:4s3Xhuv5AvdIgbd8wOOEeo0uZG7PbDKQyKY5lGoQazk= +github.com/Antonboom/testifylint v1.5.2/go.mod h1:vxy8VJ0bc6NavlYqjZfmp6EfqXMtBgQ4+mhCojwC1P8= +github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c h1:udKWzYgxTojEKWjV8V+WSxDXJ4NFATAsZjh8iIbsQIg= +github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c h1:pxW6RcqyfI9/kWtOwnv/G+AzdKuy2ZrqINhenH4HyNs= github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho= -github.com/ChainSafe/go-schnorrkel v1.0.0 h1:3aDA67lAykLaG1y3AOjs88dMxC88PgUuHRrLeDnvGIM= -github.com/ChainSafe/go-schnorrkel v1.0.0/go.mod h1:dpzHYVxLZcp8pjlV+O+UR8K0Hp/z7vcchBSbMBEhCw4= -github.com/CosmWasm/wasmvm v1.5.5 h1:XlZI3xO5iUhiBqMiyzsrWEfUtk5gcBMNYIdHnsTB+NI= -github.com/CosmWasm/wasmvm v1.5.5/go.mod h1:Q0bSEtlktzh7W2hhEaifrFp1Erx11ckQZmjq8FLCyys= -github.com/Crocmagnon/fatcontext v0.5.2 h1:vhSEg8Gqng8awhPju2w7MKHqMlg4/NI+gSDHtR3xgwA= -github.com/Crocmagnon/fatcontext v0.5.2/go.mod h1:87XhRMaInHP44Q7Tlc7jkgKKB7kZAOPiDkFMdKCC+74= -github.com/DATA-DOG/go-sqlmock v1.3.3/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= +github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= +github.com/CosmWasm/wasmd v0.53.0 h1:kdaoAi20bIb4VCsxw9pRaT2g5PpIp82Wqrr9DRVN9ao= +github.com/CosmWasm/wasmd v0.53.0/go.mod h1:FJl/aWjdpGof3usAMFQpDe07Rkx77PUzp0cygFMOvtw= +github.com/CosmWasm/wasmvm/v2 v2.2.1 h1:cmOnM+TDfUl2VRugeo1eJBw4U/Lw0WLviuQHKSo9DVQ= +github.com/CosmWasm/wasmvm/v2 v2.2.1/go.mod h1:bMhLQL4Yp9CzJi9A83aR7VO9wockOsSlZbT4ztOl6bg= +github.com/Crocmagnon/fatcontext v0.5.3 h1:zCh/wjc9oyeF+Gmp+V60wetm8ph2tlsxocgg/J0hOps= +github.com/Crocmagnon/fatcontext v0.5.3/go.mod h1:XoCQYY1J+XTfyv74qLXvNw4xFunr3L1wkopIIKG7wGM= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= -github.com/DataDog/zstd v1.5.0/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= +github.com/DataDog/datadog-go v4.8.3+incompatible h1:fNGaYSuObuQb5nzeTQqowRAd9bpDIRRV4/gUtIBjh8Q= +github.com/DataDog/datadog-go v4.8.3+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= +github.com/DataDog/zstd v1.5.5 h1:oWf5W7GtOLgp6bciQYDmhHHjdhYkALu6S/5Ni9ZgSvQ= +github.com/DataDog/zstd v1.5.5/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24 h1:sHglBQTwgx+rWPdisA5ynNEsoARbiCBOyGcJM4/OzsM= github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24/go.mod h1:4UJr5HIiMZrwgkSPdsjy2uOQExX/WEILpIrO9UPGuXs= github.com/GaijinEntertainment/go-exhaustruct/v3 v3.3.0 h1:/fTUt5vmbkAcMBt4YQiuC23cV0kEsN1MVMNqeOW43cU= github.com/GaijinEntertainment/go-exhaustruct/v3 v3.3.0/go.mod h1:ONJg5sxcbsdQQ4pOW8TGdTidT2TMAUy/2Xhr8mrYaao= github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= -github.com/Masterminds/semver/v3 v3.3.0 h1:B8LGeaivUe71a5qox1ICM/JLl0NqZSW5CHyL+hmvYS0= -github.com/Masterminds/semver/v3 v3.3.0/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM= -github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= -github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= +github.com/Masterminds/semver/v3 v3.3.1 h1:QtNSWtVZ3nBfk8mAOu/B6v7FMJ+NHTIgUPi7rj+4nv4= +github.com/Masterminds/semver/v3 v3.3.1/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM= +github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY= +github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 h1:TngWCqHvy9oXAN6lEVMRuU21PR1EtLVZJmdB18Gu3Rw= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5/go.mod h1:lmUJ/7eu/Q8D7ML55dXQrVaamCz2vxCfdQBasLZfHKk= -github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/OpenPeeDeeP/depguard/v2 v2.2.0 h1:vDfG60vDtIuf0MEOhmLlLLSzqaRM8EMcgJPdp74zmpA= github.com/OpenPeeDeeP/depguard/v2 v2.2.0/go.mod h1:CIzddKRvLBC4Au5aYP/i3nyaWQ+ClszLIuVocRiCYFQ= github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= -github.com/StackExchange/wmi v0.0.0-20180116203802-5d049714c4a6/go.mod h1:3eOhrUMpNV+6aFIbp5/iudMxNCF27Vw2OZgy4xEx0Fg= -github.com/VictoriaMetrics/fastcache v1.6.0/go.mod h1:0qHz5QP0GMX4pfmMA/zt5RgfNuXJrTP0zS7DqpHGGTw= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= -github.com/Zilliqa/gozilliqa-sdk v1.2.1-0.20201201074141-dd0ecada1be6/go.mod h1:eSYp2T6f0apnuW8TzhV3f6Aff2SE8Dwio++U4ha4yEM= -github.com/adlio/schema v1.3.3 h1:oBJn8I02PyTB466pZO1UZEn1TV5XLlifBSyMrmHl/1I= -github.com/adlio/schema v1.3.3/go.mod h1:1EsRssiv9/Ce2CMzq5DoL7RiMshhuigQxrR4DMV9fHg= -github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= +github.com/adlio/schema v1.3.6 h1:k1/zc2jNfeiZBA5aFTRy37jlBIuCkXCm0XmvpzCKI9I= +github.com/adlio/schema v1.3.6/go.mod h1:qkxwLgPBd1FgLRHYVCmQT/rrBr3JH38J9LjmVzWNudg= github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= -github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= -github.com/alecthomas/assert/v2 v2.2.2 h1:Z/iVC0xZfWTaFNE6bA3z07T86hd45Xe2eLt6WVy2bbk= -github.com/alecthomas/assert/v2 v2.2.2/go.mod h1:pXcQ2Asjp247dahGEmsZ6ru0UVwnkhktn7S0bBDLxvQ= -github.com/alecthomas/go-check-sumtype v0.1.4 h1:WCvlB3l5Vq5dZQTFmodqL2g68uHiSwwlWcT5a2FGK0c= -github.com/alecthomas/go-check-sumtype v0.1.4/go.mod h1:WyYPfhfkdhyrdaligV6svFopZV8Lqdzn5pyVBaV6jhQ= -github.com/alecthomas/repr v0.2.0 h1:HAzS41CIzNW5syS8Mf9UwXhNH1J9aix/BvDRf1Ml2Yk= -github.com/alecthomas/repr v0.2.0/go.mod h1:Fr0507jx4eOXV7AlPV6AVZLYrLIuIeSOWtW57eE/O/4= +github.com/alecthomas/assert/v2 v2.11.0 h1:2Q9r3ki8+JYXvGsDyBXwH3LcJ+WK5D0gc5E8vS6K3D0= +github.com/alecthomas/assert/v2 v2.11.0/go.mod h1:Bze95FyfUr7x34QZrjL+XP+0qgp/zg8yS+TtBj1WA3k= +github.com/alecthomas/go-check-sumtype v0.3.1 h1:u9aUvbGINJxLVXiFvHUlPEaD7VDULsrxJb4Aq31NLkU= +github.com/alecthomas/go-check-sumtype v0.3.1/go.mod h1:A8TSiN3UPRw3laIgWEUOHHLPa6/r9MtoigdlP5h3K/E= +github.com/alecthomas/repr v0.4.0 h1:GhI2A8MACjfegCPVq9f1FLvIBS+DrQ2KQBFZP1iFzXc= +github.com/alecthomas/repr v0.4.0/go.mod h1:Fr0507jx4eOXV7AlPV6AVZLYrLIuIeSOWtW57eE/O/4= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= -github.com/alexkohler/nakedret/v2 v2.0.4 h1:yZuKmjqGi0pSmjGpOC016LtPJysIL0WEUiaXW5SUnNg= -github.com/alexkohler/nakedret/v2 v2.0.4/go.mod h1:bF5i0zF2Wo2o4X4USt9ntUWve6JbFv02Ff4vlkmS/VU= +github.com/alexkohler/nakedret/v2 v2.0.5 h1:fP5qLgtwbx9EJE8dGEERT02YwS8En4r9nnZ71RK+EVU= +github.com/alexkohler/nakedret/v2 v2.0.5/go.mod h1:bF5i0zF2Wo2o4X4USt9ntUWve6JbFv02Ff4vlkmS/VU= github.com/alexkohler/prealloc v1.0.0 h1:Hbq0/3fJPQhNkN0dR95AVrr6R7tou91y0uHG5pOcUuw= github.com/alexkohler/prealloc v1.0.0/go.mod h1:VetnK3dIgFBBKmg0YnD9F9x6Icjd+9cvfHR56wJVlKE= github.com/alingse/asasalint v0.0.11 h1:SFwnQXJ49Kx/1GghOFz1XGqHYKp21Kq1nHad/0WQRnw= github.com/alingse/asasalint v0.0.11/go.mod h1:nCaoMhw7a9kSJObvQyVzNTPBDbNpdocqrSP7t/cW5+I= -github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= -github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo29Kk6CurOXKm700vrz8f0KW0JNfpkRJY/8= +github.com/alingse/nilnesserr v0.1.1 h1:7cYuJewpy9jFNMEA72Q1+3Nm3zKHzg+Q28D5f2bBFUA= +github.com/alingse/nilnesserr v0.1.1/go.mod h1:1xJPrXonEtX7wyTq8Dytns5P2hNzoWymVUIaKm4HNFg= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= -github.com/apache/arrow/go/arrow v0.0.0-20191024131854-af6fa24be0db/go.mod h1:VTxUBvSJ3s3eHAg65PNgrsn5BtqCRPdmyXh6rAfdxN0= +github.com/antlr4-go/antlr/v4 v4.13.1 h1:SqQKkuVZ+zWkMMNkjy5FZe5mr5WURWnlpmOuzYWrPrQ= +github.com/antlr4-go/antlr/v4 v4.13.1/go.mod h1:GKmUxMtwp6ZgGwZSva4eWPC5mS6vUAmOABFgjdkM7Nw= github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= -github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= -github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a/go.mod h1:DAHtR1m6lCRdSC2Tm3DSWRPvIPr6xNKyeHdqDQSQT+A= github.com/ashanbrown/forbidigo v1.6.0 h1:D3aewfM37Yb3pxHujIPSpTf6oQk9sc9WZi8gerOIVIY= github.com/ashanbrown/forbidigo v1.6.0/go.mod h1:Y8j9jy9ZYAEHXdu723cUlraTqbzjKF1MUyfOKL+AjcU= -github.com/ashanbrown/makezero v1.1.1 h1:iCQ87C0V0vSyO+M9E/FZYbu65auqH0lnsOkf5FcB28s= -github.com/ashanbrown/makezero v1.1.1/go.mod h1:i1bJLCRSCHOcOa9Y6MyF2FTfMZMFdHvxKHxgO5Z1axI= +github.com/ashanbrown/makezero v1.2.0 h1:/2Lp1bypdmK9wDIq7uWBlDF1iMUpIIS4A+pF6C9IEUU= +github.com/ashanbrown/makezero v1.2.0/go.mod h1:dxlPhHbDMC6N6xICzFBSK+4njQDdK8euNO0qjQMtGY4= github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQwij/eHl5CU= github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.44.122/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo= -github.com/aws/aws-sdk-go v1.44.203 h1:pcsP805b9acL3wUqa4JR2vg1k2wnItkDYNvfmcy6F+U= -github.com/aws/aws-sdk-go v1.44.203/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI= +github.com/aws/aws-sdk-go v1.44.224 h1:09CiaaF35nRmxrzWZ2uRq5v6Ghg/d2RiPjZnSgtt+RQ= +github.com/aws/aws-sdk-go v1.44.224/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI= github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= -github.com/aws/aws-sdk-go-v2 v1.2.0/go.mod h1:zEQs02YRBw1DjK0PoJv3ygDYOFTre1ejlJWl8FwAuQo= -github.com/aws/aws-sdk-go-v2/config v1.1.1/go.mod h1:0XsVy9lBI/BCXm+2Tuvt39YmdHwS5unDQmxZOYe8F5Y= -github.com/aws/aws-sdk-go-v2/credentials v1.1.1/go.mod h1:mM2iIjwl7LULWtS6JCACyInboHirisUUdkBPoTHMOUo= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.0.2/go.mod h1:3hGg3PpiEjHnrkrlasTfxFqUsZ2GCk/fMUn4CbKgSkM= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.0.2/go.mod h1:45MfaXZ0cNbeuT0KQ1XJylq8A6+OpVV2E5kvY/Kq+u8= -github.com/aws/aws-sdk-go-v2/service/route53 v1.1.1/go.mod h1:rLiOUrPLW/Er5kRcQ7NkwbjlijluLsrIbu/iyl35RO4= -github.com/aws/aws-sdk-go-v2/service/sso v1.1.1/go.mod h1:SuZJxklHxLAXgLTc1iFXbEWkXs7QRTQpCLGaKIprQW0= -github.com/aws/aws-sdk-go-v2/service/sts v1.1.1/go.mod h1:Wi0EBZwiz/K44YliU0EKxqTCJGUfYTWXrrBwkq736bM= -github.com/aws/smithy-go v1.1.0/go.mod h1:EzMw8dbp/YJL4A5/sbhGddag+NPT7q084agLbB9LgIw= -github.com/benbjohnson/clock v1.3.0 h1:ip6w0uFQkncKQ979AypyG0ER7mqUSBdKLOgAle/AT8A= -github.com/benbjohnson/clock v1.3.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= +github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -331,56 +337,43 @@ github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6r github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= -github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bkielbasa/cyclop v1.2.1 h1:AeF71HZDob1P2/pRm1so9cd1alZnrpyc4q2uP2l0gJY= -github.com/bkielbasa/cyclop v1.2.1/go.mod h1:K/dT/M0FPAiYjBgQGau7tz+3TMh4FWAEqlMhzFWCrgM= +github.com/bgentry/speakeasy v0.2.0 h1:tgObeVOf8WAvtuAX6DhJ4xks4CFNwPDZiqzGqIHE51E= +github.com/bgentry/speakeasy v0.2.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= +github.com/bits-and-blooms/bitset v1.8.0 h1:FD+XqgOZDUxxZ8hzoBFuV9+cGWY9CslN6d5MS5JVb4c= +github.com/bits-and-blooms/bitset v1.8.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= +github.com/bkielbasa/cyclop v1.2.3 h1:faIVMIGDIANuGPWH031CZJTi2ymOQBULs9H21HSMa5w= +github.com/bkielbasa/cyclop v1.2.3/go.mod h1:kHTwA9Q0uZqOADdupvcFJQtp/ksSnytRMe8ztxG8Fuo= github.com/blizzy78/varnamelen v0.8.0 h1:oqSblyuQvFsW1hbBHh1zfwrKe3kcSj0rnXkKzsQ089M= github.com/blizzy78/varnamelen v0.8.0/go.mod h1:V9TzQZ4fLJ1DSrjVDfl89H7aMnTvKkApdHeyESmyR7k= -github.com/bmizerany/pat v0.0.0-20170815010413-6226ea591a40/go.mod h1:8rLXio+WjiTceGBHIoTvn60HIbs7Hm7bcHjyrSqYB9c= -github.com/boltdb/bolt v1.3.1/go.mod h1:clJnj/oiGkjum5o1McbSZDSLxVThjynRyGBgiAx27Ps= -github.com/bombsimon/wsl/v4 v4.4.1 h1:jfUaCkN+aUpobrMO24zwyAMwMAV5eSziCkOKEauOLdw= -github.com/bombsimon/wsl/v4 v4.4.1/go.mod h1:Xu/kDxGZTofQcDGCtQe9KCzhHphIe0fDuyWTxER9Feo= -github.com/breml/bidichk v0.2.7 h1:dAkKQPLl/Qrk7hnP6P+E0xOodrq8Us7+U0o4UBOAlQY= -github.com/breml/bidichk v0.2.7/go.mod h1:YodjipAGI9fGcYM7II6wFvGhdMYsC5pHDlGzqvEW3tQ= -github.com/breml/errchkjson v0.3.6 h1:VLhVkqSBH96AvXEyclMR37rZslRrY2kcyq+31HCsVrA= -github.com/breml/errchkjson v0.3.6/go.mod h1:jhSDoFheAF2RSDOlCfhHO9KqhZgAYLyvHe7bRCX8f/U= -github.com/btcsuite/btcd v0.0.0-20190315201642-aa6e0f35703c/go.mod h1:DrZx5ec/dmnfpw9KyYoQyYo7d0KEvTkk/5M/vbZjAr8= -github.com/btcsuite/btcd v0.20.1-beta/go.mod h1:wVuoA8VJLEcwgqHBwHmzLRazpKxTv13Px/pDuV7OomQ= -github.com/btcsuite/btcd v0.21.0-beta.0.20201114000516-e9c7a5ac6401/go.mod h1:Sv4JPQ3/M+teHz9Bo5jBpkNcP0x6r7rdihlNL/7tTAs= -github.com/btcsuite/btcd v0.22.1 h1:CnwP9LM/M9xuRrGSCGeMVs9iv09uMqwsVX7EeIpgV2c= -github.com/btcsuite/btcd v0.22.1/go.mod h1:wqgTSL29+50LRkmOVknEdmt8ZojIzhuWvgu/iptuN7Y= -github.com/btcsuite/btcd/btcec/v2 v2.1.2/go.mod h1:ctjw4H1kknNJmRN4iP1R7bTQ+v3GJkZBd6mui8ZsAZE= -github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= -github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= -github.com/btcsuite/btcd/btcutil v1.1.2 h1:XLMbX8JQEiwMcYft2EGi8zPUkoa0abKIU6/BJSRsjzQ= -github.com/btcsuite/btcd/btcutil v1.1.2/go.mod h1:UR7dsSJzJUfMmFiiLlIrMq1lS9jh9EdCV7FStZSnpi0= -github.com/btcsuite/btcd/chaincfg/chainhash v1.0.0/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= -github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= -github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= -github.com/btcsuite/btclog v0.0.0-20170628155309-84c8d2346e9f/go.mod h1:TdznJufoqS23FtqVCzL0ZqgP5MqXbb4fg/WgDys70nA= -github.com/btcsuite/btcutil v0.0.0-20190207003914-4c204d697803/go.mod h1:+5NJ2+qvTyV9exUAL/rxXi3DcLg2Ts+ymUAY5y4NvMg= -github.com/btcsuite/btcutil v0.0.0-20190425235716-9e5f4b9a998d/go.mod h1:+5NJ2+qvTyV9exUAL/rxXi3DcLg2Ts+ymUAY5y4NvMg= -github.com/btcsuite/btcutil v1.0.2/go.mod h1:j9HUFwoQRsZL3V4n+qG+CUnEGHOarIxfC3Le2Yhbcts= -github.com/btcsuite/btcutil v1.0.3-0.20201208143702-a53e38424cce/go.mod h1:0DVlHczLPewLcPGEIeUEzfOJhqGPQ0mJJRDBtD307+o= -github.com/btcsuite/go-socks v0.0.0-20170105172521-4720035b7bfd/go.mod h1:HHNXQzUsZCxOoE+CPiyCTO6x34Zs86zZUiwtpXoGdtg= -github.com/btcsuite/goleveldb v0.0.0-20160330041536-7834afc9e8cd/go.mod h1:F+uVaaLLH7j4eDXPRvw78tMflu7Ie2bzYOH4Y8rRKBY= -github.com/btcsuite/goleveldb v1.0.0/go.mod h1:QiK9vBlgftBg6rWQIj6wFzbPfRjiykIEhBH4obrXJ/I= -github.com/btcsuite/snappy-go v0.0.0-20151229074030-0bdef8d06723/go.mod h1:8woku9dyThutzjeg+3xrA5iCpBRH8XEEg3lh6TiUghc= -github.com/btcsuite/snappy-go v1.0.0/go.mod h1:8woku9dyThutzjeg+3xrA5iCpBRH8XEEg3lh6TiUghc= -github.com/btcsuite/websocket v0.0.0-20150119174127-31079b680792/go.mod h1:ghJtEyQwv5/p4Mg4C0fgbePVuGr935/5ddU9Z3TmDRY= -github.com/btcsuite/winsvc v1.0.0/go.mod h1:jsenWakMcC0zFBFurPLEAyrnc/teJEM1O46fmI40EZs= -github.com/bufbuild/protocompile v0.4.0 h1:LbFKd2XowZvQ/kajzguUp2DC9UEIQhIq77fZZlaQsNA= -github.com/bufbuild/protocompile v0.4.0/go.mod h1:3v93+mbWn/v3xzN+31nwkJfrEpAUwp+BagBSZWx+TP8= -github.com/butuzov/ireturn v0.3.0 h1:hTjMqWw3y5JC3kpnC5vXmFJAWI/m31jaCYQqzkS6PL0= -github.com/butuzov/ireturn v0.3.0/go.mod h1:A09nIiwiqzN/IoVo9ogpa0Hzi9fex1kd9PSD6edP5ZA= -github.com/butuzov/mirror v1.2.0 h1:9YVK1qIjNspaqWutSv8gsge2e/Xpq1eqEkslEUHy5cs= -github.com/butuzov/mirror v1.2.0/go.mod h1:DqZZDtzm42wIAIyHXeN8W/qb1EPlb9Qn/if9icBOpdQ= -github.com/bwesterb/go-ristretto v1.2.0/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0= -github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1O2AihPM= -github.com/bytedance/sonic v1.8.0 h1:ea0Xadu+sHlu7x5O3gKhRpQ1IKiMrSiHttPF0ybECuA= -github.com/bytedance/sonic v1.8.0/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= -github.com/c-bata/go-prompt v0.2.2/go.mod h1:VzqtzE2ksDBcdln8G7mk2RX9QyGjH+OVqOCSiVIqS34= +github.com/bombsimon/wsl/v4 v4.5.0 h1:iZRsEvDdyhd2La0FVi5k6tYehpOR/R7qIUjmKk7N74A= +github.com/bombsimon/wsl/v4 v4.5.0/go.mod h1:NOQ3aLF4nD7N5YPXMruR6ZXDOAqLoM0GEpLwTdvmOSc= +github.com/breml/bidichk v0.3.2 h1:xV4flJ9V5xWTqxL+/PMFF6dtJPvZLPsyixAoPe8BGJs= +github.com/breml/bidichk v0.3.2/go.mod h1:VzFLBxuYtT23z5+iVkamXO386OB+/sVwZOpIj6zXGos= +github.com/breml/errchkjson v0.4.0 h1:gftf6uWZMtIa/Is3XJgibewBm2ksAQSY/kABDNFTAdk= +github.com/breml/errchkjson v0.4.0/go.mod h1:AuBOSTHyLSaaAFlWsRSuRBIroCh3eh7ZHh5YeelDIk8= +github.com/btcsuite/btcd/btcec/v2 v2.3.4 h1:3EJjcN70HCu/mwqlUsGK8GcNVyLVxFDlWurTXGPFfiQ= +github.com/btcsuite/btcd/btcec/v2 v2.3.4/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= +github.com/btcsuite/btcd/btcutil v1.1.6 h1:zFL2+c3Lb9gEgqKNzowKUPQNb8jV7v5Oaodi/AYFd6c= +github.com/btcsuite/btcd/btcutil v1.1.6/go.mod h1:9dFymx8HpuLqBnsPELrImQeTQfKBQqzqGbbV3jK55aE= +github.com/bufbuild/buf v1.34.0 h1:rZSVfYS5SakOe6ds9PDjbHVwOc+vBGVWNW9Ei+Rg/+c= +github.com/bufbuild/buf v1.34.0/go.mod h1:Fj+KBmY2ODYD2Ld02w4LH9Y3WiRH2203IjGJbKYK5Hc= +github.com/bufbuild/protocompile v0.14.1 h1:iA73zAf/fyljNjQKwYzUHD6AD4R8KMasmwa/FBatYVw= +github.com/bufbuild/protocompile v0.14.1/go.mod h1:ppVdAIhbr2H8asPk6k4pY7t9zB1OU5DoEw9xY/FUi1c= +github.com/bufbuild/protoplugin v0.0.0-20250106231243-3a819552c9d9 h1:kAWER21DzhzU7ys8LL1WkSfbGkwXv+tM30hyEsYrW2k= +github.com/bufbuild/protoplugin v0.0.0-20250106231243-3a819552c9d9/go.mod h1:c5D8gWRIZ2HLWO3gXYTtUfw/hbJyD8xikv2ooPxnklQ= +github.com/bufbuild/protovalidate-go v0.8.2 h1:sgzXHkHYP6HnAsL2Rd3I1JxkYUyEQUv9awU1PduMxbM= +github.com/bufbuild/protovalidate-go v0.8.2/go.mod h1:K6w8iPNAXBoIivVueSELbUeUl+MmeTQfCDSug85pn3M= +github.com/bufbuild/protoyaml-go v0.1.9 h1:anV5UtF1Mlvkkgp4NWA6U/zOnJFng8Orq4Vf3ZUQHBU= +github.com/bufbuild/protoyaml-go v0.1.9/go.mod h1:KCBItkvZOK/zwGueLdH1Wx1RLyFn5rCH7YjQrdty2Wc= +github.com/butuzov/ireturn v0.3.1 h1:mFgbEI6m+9W8oP/oDdfA34dLisRFCj2G6o/yiI1yZrY= +github.com/butuzov/ireturn v0.3.1/go.mod h1:ZfRp+E7eJLC0NQmk1Nrm1LOrn/gQlOykv+cVPdiXH5M= +github.com/butuzov/mirror v1.3.0 h1:HdWCXzmwlQHdVhwvsfBb2Au0r3HyINry3bDWLYXiKoc= +github.com/butuzov/mirror v1.3.0/go.mod h1:AEij0Z8YMALaq4yQj9CPPVYOyJQyiexpQEQgihajRfI= +github.com/bytedance/sonic v1.12.3 h1:W2MGa7RCU1QTeYRTPE3+88mVC0yXmsRQRChiyVocVjU= +github.com/bytedance/sonic v1.12.3/go.mod h1:B8Gt/XvtZ3Fqj+iSKMypzymZxw/FVwgIGKzMzT9r/rk= +github.com/bytedance/sonic/loader v0.1.1/go.mod h1:ncP89zfokxS5LZrJxl5z0UJcsk4M4yY2JpfqGeCtNLU= +github.com/bytedance/sonic/loader v0.2.0 h1:zNprn+lsIP06C/IqCHs3gPQIvnvpKbbxyXQP1iU4kWM= +github.com/bytedance/sonic/loader v0.2.0/go.mod h1:ncP89zfokxS5LZrJxl5z0UJcsk4M4yY2JpfqGeCtNLU= github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= github.com/catenacyber/perfsprint v0.7.1 h1:PGW5G/Kxn+YrN04cRAZKC+ZuvlVwolYMrIyyTJ/rMmc= github.com/catenacyber/perfsprint v0.7.1/go.mod h1:/wclWYompEyjUD2FuIIDVKNkqz7IgBIWXIH3V0Zol50= @@ -389,11 +382,9 @@ github.com/ccojocar/zxcvbn-go v1.0.2/go.mod h1:g1qkXtUSvHP8lhHp5GrSmTz6uWALGRMQd github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= -github.com/cenkalti/backoff/v4 v4.1.3 h1:cFAlzYUlVYDysBEH2T5hyJZMh3+5+WCBvSnK6Q8UtC4= -github.com/cenkalti/backoff/v4 v4.1.3/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= +github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8= +github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/cespare/cp v0.1.0/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= -github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= @@ -403,9 +394,9 @@ github.com/charithe/durationcheck v0.0.10/go.mod h1:bCWXb7gYRysD1CU3C+u4ceO49LoG github.com/chavacava/garif v0.1.0 h1:2JHa3hbYf5D9dsgseMKAmc/MZ109otzgNFk5s87H9Pc= github.com/chavacava/garif v0.1.0/go.mod h1:XMyYCkEL58DF0oyW4qDjjnPWONs2HBqYKI+UIPD+Gww= github.com/cheggaaa/pb v1.0.27/go.mod h1:pQciLPpbU0oxA0h+VJYYLxO+XeDQb5pZijXscXHm81s= -github.com/chenzhuoyu/base64x v0.0.0-20211019084208-fb5309c8db06/go.mod h1:DH46F32mSOjUmXrMHnKwZdA8wcEefY7UVqBKYGjpdQY= -github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 h1:qSGYFH7+jGhDF8vLC+iwCD4WpbV1EBDSzWkJODFLams= -github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311/go.mod h1:b583jCggY9gE99b6G5LEC39OIiVsWj+R97kbl5odCEk= +github.com/chromedp/cdproto v0.0.0-20230802225258-3cf4e6d46a89/go.mod h1:GKljq0VrfU4D5yc+2qA6OVr8pmO/MBbPEWqWQ/oqGEs= +github.com/chromedp/chromedp v0.9.2/go.mod h1:LkSXJKONWTCHAfQasKFUZI+mxqS4tZqhmtGzzhLsnLs= +github.com/chromedp/sysutil v1.0.0/go.mod h1:kgWmDdq8fTzXYcKIBqIYvRRTnYb9aNS9moAV0xufSww= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/logex v1.2.1 h1:XHDu3E6q+gdHgsdTPH6ImJMIp436vR6MPtH8gP05QzM= github.com/chzyer/logex v1.2.1/go.mod h1:JLbx6lG2kDbNRFnfkgvh4eRJRPX1QCoOIWomwysCBrQ= @@ -417,11 +408,14 @@ github.com/chzyer/test v1.0.0 h1:p3BQDXSxOhOG0P9z6/hGnII4LGiEPOYBhs8asl/fC04= github.com/chzyer/test v1.0.0/go.mod h1:2JlltgoNkt4TW/z9V/IzDdFaMTM2JPIi26O1pF38GC8= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= -github.com/ckaznocha/intrange v0.2.0 h1:FykcZuJ8BD7oX93YbO1UY9oZtkRbp+1/kJcDjkefYLs= -github.com/ckaznocha/intrange v0.2.0/go.mod h1:r5I7nUlAAG56xmkOpw4XVr16BXhwYTUdcuRFeevn1oE= +github.com/ckaznocha/intrange v0.3.0 h1:VqnxtK32pxgkhJgYQEeOArVidIPg+ahLP7WBOXZd5ZY= +github.com/ckaznocha/intrange v0.3.0/go.mod h1:+I/o2d2A1FBHgGELbGxzIcyd3/9l9DuwjM8FsbSS3Lo= github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cloudflare/cloudflare-go v0.14.0/go.mod h1:EnwdgGMaFOruiPZRFSgn+TsQ3hQ7C/YWzIGLeu5c304= +github.com/cloudwego/base64x v0.1.4 h1:jwCgWpFanWmN8xoIUHa2rtzmkd5J2plF/dnLS6Xd/0Y= +github.com/cloudwego/base64x v0.1.4/go.mod h1:0zlkT4Wn5C6NdauXdJRhSKRlJvmclQ1hhJgA0rcu/8w= +github.com/cloudwego/iasm v0.2.0 h1:1KNIy1I1H9hNNFEEH3DVnI4UujN+1zjpuk6gwHLTssg= +github.com/cloudwego/iasm v0.2.0/go.mod h1:8rXZaNYT2n95jn+zTI1sDr+IgcD2GVs0nlbbQPiEFhY= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -433,40 +427,46 @@ github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWH github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cockroachdb/apd/v2 v2.0.2 h1:weh8u7Cneje73dDh+2tEVLUvyBc89iwepWCD8b8034E= github.com/cockroachdb/apd/v2 v2.0.2/go.mod h1:DDxRlzC2lo3/vSlmSoS7JkqbbrARPuFOGr0B9pvN3Gw= +github.com/cockroachdb/apd/v3 v3.2.1 h1:U+8j7t0axsIgvQUqthuNm82HIrYXodOV2iWLWtEaIwg= +github.com/cockroachdb/apd/v3 v3.2.1/go.mod h1:klXJcjp+FffLTHlhIG69tezTDvdP065naDsHzKhYSqc= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= -github.com/cockroachdb/errors v1.10.0 h1:lfxS8zZz1+OjtV4MtNWgboi/W5tyLEB6VQZBXN+0VUU= -github.com/cockroachdb/errors v1.10.0/go.mod h1:lknhIsEVQ9Ss/qKDBQS/UqFSvPQjOwNq2qyKAxtHRqE= +github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f h1:otljaYPt5hWxV3MUfO5dFPFiOXg9CyG5/kCfayTqsJ4= +github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= +github.com/cockroachdb/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= +github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= +github.com/cockroachdb/fifo v0.0.0-20240616162244-4768e80dfb9a h1:f52TdbU4D5nozMAhO9TvTJ2ZMCXtN4VIAmfrrZ0JXQ4= +github.com/cockroachdb/fifo v0.0.0-20240616162244-4768e80dfb9a/go.mod h1:9/y3cnZ5GKakj/H4y9r9GTjCvAFta7KLgSHPJJYc52M= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/pebble v1.1.2 h1:CUh2IPtR4swHlEj48Rhfzw6l/d0qA31fItcIszQVIsA= +github.com/cockroachdb/pebble v1.1.2/go.mod h1:4exszw1r40423ZsmkG/09AFEG83I0uDgfujJdbL6kYU= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= +github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= +github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/coinbase/kryptology v1.8.0/go.mod h1:RYXOAPdzOGUe3qlSFkMGn58i3xUA8hmxYHksuq+8ciI= -github.com/coinbase/rosetta-sdk-go v0.7.9 h1:lqllBjMnazTjIqYrOGv8h8jxjg9+hJazIGZr9ZvoCcA= -github.com/coinbase/rosetta-sdk-go v0.7.9/go.mod h1:0/knutI7XGVqXmmH4OQD8OckFrbQ8yMsUZTG7FXCR2M= -github.com/cometbft/cometbft v0.37.5 h1:/U/TlgMh4NdnXNo+YU9T2NMCWyhXNDF34Mx582jlvq0= -github.com/cometbft/cometbft v0.37.5/go.mod h1:QC+mU0lBhKn8r9qvmnq53Dmf3DWBt4VtkcKw2C81wxY= -github.com/cometbft/cometbft-db v0.8.0 h1:vUMDaH3ApkX8m0KZvOFFy9b5DZHBAjsnEuo9AKVZpjo= -github.com/cometbft/cometbft-db v0.8.0/go.mod h1:6ASCP4pfhmrCBpfk01/9E1SI29nD3HfVHrY4PG8x5c0= -github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= -github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= -github.com/consensys/bavard v0.1.8-0.20210406032232-f3452dc9b572/go.mod h1:Bpd0/3mZuaj6Sj+PqrmIquiOKy397AKGThQPaGzNXAQ= -github.com/consensys/bavard v0.1.8-0.20210915155054-088da2f7f54a/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= -github.com/consensys/gnark-crypto v0.4.1-0.20210426202927-39ac3d4b3f1f/go.mod h1:815PAHg3wvysy0SyIqanF8gZ0Y1wjk/hrDHD/iT88+Q= -github.com/consensys/gnark-crypto v0.5.3/go.mod h1:hOdPlWQV1gDLp7faZVeg8Y0iEPFaOUnCc4XeCCk96p0= -github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= -github.com/containerd/continuity v0.3.0/go.mod h1:wJEAIwKOm/pBZuBd0JmeTvnLquTB1Ag8espWhkykbPM= -github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= +github.com/cometbft/cometbft v0.38.15 h1:5veFd8k1uXM27PBg9sMO3hAfRJ3vbh4OmmLf6cVrqXg= +github.com/cometbft/cometbft v0.38.15/go.mod h1:+wh6ap6xctVG+JOHwbl8pPKZ0GeqdPYqISu7F4b43cQ= +github.com/cometbft/cometbft-db v0.14.1 h1:SxoamPghqICBAIcGpleHbmoPqy+crij/++eZz3DlerQ= +github.com/cometbft/cometbft-db v0.14.1/go.mod h1:KHP1YghilyGV/xjD5DP3+2hyigWx0WTp9X+0Gnx0RxQ= +github.com/containerd/continuity v0.4.5 h1:ZRoN1sXq9u7V6QoHMcVWGhOwDFqZ4B9i5H6un1Wh0x4= +github.com/containerd/continuity v0.4.5/go.mod h1:/lNJvtJKUQStBzpVQ1+rasXO1LAWtUQssk28EZvJ3nE= +github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= +github.com/containerd/log v0.1.0/go.mod h1:VRRf09a7mHDIRezVKTRCrOq78v577GXq3bSa3EhrzVo= +github.com/containerd/stargz-snapshotter/estargz v0.16.3 h1:7evrXtoh1mSbGj/pfRccTampEyKpjpOnS3CyiV1Ebr8= +github.com/containerd/stargz-snapshotter/estargz v0.16.3/go.mod h1:uyr4BfYfOj3G9WBVE8cOlQmXAbPN9VEQpBBeJIuOipU= github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= +github.com/cosmos/cosmos-db v1.1.1 h1:FezFSU37AlBC8S98NlSagL76oqBRWq/prTPvFcEJNCM= +github.com/cosmos/cosmos-db v1.1.1/go.mod h1:AghjcIPqdhSLP/2Z0yha5xPH3nLnskz81pBx3tcVSAw= github.com/cosmos/cosmos-proto v1.0.0-beta.5 h1:eNcayDLpip+zVLRLYafhzLvQlSmyab+RC5W7ZfmxJLA= github.com/cosmos/cosmos-proto v1.0.0-beta.5/go.mod h1:hQGLpiIUloJBMdQMMWb/4wRApmI9hjHH05nefC0Ojec= -github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= +github.com/cosmos/cosmos-sdk v0.50.11 h1:LxR1aAc8kixdrs3itO+3a44sFoc+vjxVAOyPFx22yjk= +github.com/cosmos/cosmos-sdk v0.50.11/go.mod h1:gt14Meok2IDCjbDtjwkbUcgVNEpUBDN/4hg9cCUtLgw= github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY= github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw= github.com/cosmos/gogogateway v1.2.0 h1:Ae/OivNhp8DqBi/sh2A8a1D0y638GpL3tkmLQAiKxTE= @@ -474,89 +474,82 @@ github.com/cosmos/gogogateway v1.2.0/go.mod h1:iQpLkGWxYcnCdz5iAdLcRBSw3h7NXeOkZ github.com/cosmos/gogoproto v1.4.2/go.mod h1:cLxOsn1ljAHSV527CHOtaIP91kK6cCrZETRBrkzItWU= github.com/cosmos/gogoproto v1.7.0 h1:79USr0oyXAbxg3rspGh/m4SWNyoz/GLaAh0QlCe2fro= github.com/cosmos/gogoproto v1.7.0/go.mod h1:yWChEv5IUEYURQasfyBW5ffkMHR/90hiHgbNgrtp4j0= -github.com/cosmos/iavl v0.20.1 h1:rM1kqeG3/HBT85vsZdoSNsehciqUQPWrR4BYmqE2+zg= -github.com/cosmos/iavl v0.20.1/go.mod h1:WO7FyvaZJoH65+HFOsDir7xU9FWk2w9cHXNW1XHcl7A= -github.com/cosmos/ibc-apps/modules/ibc-hooks/v7 v7.0.0-20240502201956-e9b46e4bf0ad h1:ozJyL/gd3hXYQodS7EESUQgu+1CeJ9nvb9sfHufmsjI= -github.com/cosmos/ibc-apps/modules/ibc-hooks/v7 v7.0.0-20240502201956-e9b46e4bf0ad/go.mod h1:JwHFbo1oX/ht4fPpnPvmhZr+dCkYK1Vihw+vZE9umR4= -github.com/cosmos/ibc-go/modules/light-clients/08-wasm v0.1.1-ibc-go-v7.3-wasmvm-v1.5 h1:sMoHjep+KInjMrppNCEutMVm1p8nI9WhKCuMQ+EcUHw= -github.com/cosmos/ibc-go/modules/light-clients/08-wasm v0.1.1-ibc-go-v7.3-wasmvm-v1.5/go.mod h1:VR2Hg2i/X1bafbmmNsV2Khwsg0PzNeuWoVKmSN5dAwo= -github.com/cosmos/ibc-go/v7 v7.4.0 h1:8FqYMptvksgMvlbN4UW9jFxTXzsPyfAzEZurujXac8M= -github.com/cosmos/ibc-go/v7 v7.4.0/go.mod h1:L/KaEhzV5TGUCTfGysVgMBQtl5Dm7hHitfpk+GIeoAo= -github.com/cosmos/ics23/go v0.10.0 h1:iXqLLgp2Lp+EdpIuwXTYIQU+AiHj9mOC2X9ab++bZDM= -github.com/cosmos/ics23/go v0.10.0/go.mod h1:ZfJSmng/TBNTBkFemHHHj5YY7VAU/MBU980F4VU1NG0= -github.com/cosmos/keyring v1.2.0 h1:8C1lBP9xhImmIabyXW4c3vFjjLiBdGCmfLUfeZlV1Yo= -github.com/cosmos/keyring v1.2.0/go.mod h1:fc+wB5KTk9wQ9sDx0kFXB3A0MaeGHM9AwRStKOQ5vOA= -github.com/cosmos/ledger-cosmos-go v0.12.4 h1:drvWt+GJP7Aiw550yeb3ON/zsrgW0jgh5saFCr7pDnw= -github.com/cosmos/ledger-cosmos-go v0.12.4/go.mod h1:fjfVWRf++Xkygt9wzCsjEBdjcf7wiiY35fv3ctT+k4M= -github.com/cosmos/rosetta-sdk-go v0.10.0 h1:E5RhTruuoA7KTIXUcMicL76cffyeoyvNybzUGSKFTcM= -github.com/cosmos/rosetta-sdk-go v0.10.0/go.mod h1:SImAZkb96YbwvoRkzSMQB6noNJXFgWl/ENIznEoYQI4= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= +github.com/cosmos/iavl v1.2.4 h1:IHUrG8dkyueKEY72y92jajrizbkZKPZbMmG14QzsEkw= +github.com/cosmos/iavl v1.2.4/go.mod h1:GiM43q0pB+uG53mLxLDzimxM9l/5N9UuSY3/D0huuVw= +github.com/cosmos/ibc-go/modules/apps/callbacks v0.2.1-0.20231113120333-342c00b0f8bd h1:Lx+/5dZ/nN6qPXP2Ofog6u1fmlkCFA1ElcOconnofEM= +github.com/cosmos/ibc-go/modules/apps/callbacks v0.2.1-0.20231113120333-342c00b0f8bd/go.mod h1:JWfpWVKJKiKtd53/KbRoKfxWl8FsT2GPcNezTOk0o5Q= +github.com/cosmos/ibc-go/modules/capability v1.0.1 h1:ibwhrpJ3SftEEZRxCRkH0fQZ9svjthrX2+oXdZvzgGI= +github.com/cosmos/ibc-go/modules/capability v1.0.1/go.mod h1:rquyOV262nGJplkumH+/LeYs04P3eV8oB7ZM4Ygqk4E= +github.com/cosmos/ibc-go/v8 v8.5.3 h1:VF1Vq3/zZB40eeFvx4wI4WmlJGGF74o+/MxcPxQ2mWY= +github.com/cosmos/ibc-go/v8 v8.5.3/go.mod h1:P5hkAvq0Qbg0h18uLxDVA9q1kOJ0l36htMsskiNwXbo= +github.com/cosmos/ics23/go v0.11.0 h1:jk5skjT0TqX5e5QJbEnwXIS2yI2vnmLOgpQPeM5RtnU= +github.com/cosmos/ics23/go v0.11.0/go.mod h1:A8OjxPE67hHST4Icw94hOxxFEJMBG031xIGF/JHNIY0= +github.com/cosmos/ledger-cosmos-go v0.13.3 h1:7ehuBGuyIytsXbd4MP43mLeoN2LTOEnk5nvue4rK+yM= +github.com/cosmos/ledger-cosmos-go v0.13.3/go.mod h1:HENcEP+VtahZFw38HZ3+LS3Iv5XV6svsnkk9vdJtLr8= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creachadair/taskgroup v0.4.2 h1:jsBLdAJE42asreGss2xZGZ8fJra7WtwnHWeJFxv2Li8= -github.com/creachadair/taskgroup v0.4.2/go.mod h1:qiXUOSrbwAY3u0JPGTzObbE3yf9hcXHDKBZ2ZjpCbgM= +github.com/cpuguy83/go-md2man/v2 v2.0.6 h1:XJtiaUW6dEEqVuZiMTn1ldk455QWwEIsMIJlo5vtkx0= +github.com/cpuguy83/go-md2man/v2 v2.0.6/go.mod h1:oOW0eioCTA6cOiMLiUPZOpcVxMig6NIQQ7OS05n1F4g= +github.com/creachadair/atomicfile v0.3.1 h1:yQORkHjSYySh/tv5th1dkKcn02NEW5JleB84sjt+W4Q= +github.com/creachadair/atomicfile v0.3.1/go.mod h1:mwfrkRxFKwpNAflYZzytbSwxvbK6fdGRRlp0KEQc0qU= +github.com/creachadair/tomledit v0.0.24 h1:5Xjr25R2esu1rKCbQEmjZYlrhFkDspoAbAKb6QKQDhQ= +github.com/creachadair/tomledit v0.0.24/go.mod h1:9qHbShRWQzSCcn617cMzg4eab1vbLCOjOshAWSzWr8U= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/curioswitch/go-reassign v0.2.0 h1:G9UZyOcpk/d7Gd6mqYgd8XYWFMw/znxwGDUstnC9DIo= -github.com/curioswitch/go-reassign v0.2.0/go.mod h1:x6OpXuWvgfQaMGks2BZybTngWjT84hqJfKoO8Tt/Roc= -github.com/cyberdelia/templates v0.0.0-20141128023046-ca7fffd4298c/go.mod h1:GyV+0YP4qX0UQ7r2MoYZ+AvYDp12OF5yg4q8rGnyNh4= +github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= +github.com/creack/pty v1.1.18/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= +github.com/curioswitch/go-reassign v0.3.0 h1:dh3kpQHuADL3cobV/sSGETA8DOv457dwl+fbBAhrQPs= +github.com/curioswitch/go-reassign v0.3.0/go.mod h1:nApPCCTtqLJN/s8HfItCcKV0jIPwluBOvZP+dsJGA88= github.com/daixiang0/gci v0.13.5 h1:kThgmH1yBmZSBCh1EJVxQ7JsHpm5Oms0AMed/0LaH4c= github.com/daixiang0/gci v0.13.5/go.mod h1:12etP2OniiIdP4q+kjUGrC/rUagga7ODbqsom5Eo5Yk= -github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= -github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= -github.com/dave/jennifer v1.2.0/go.mod h1:fIb+770HOpJ2fmN9EPPKOqm1vMGhB+TwXKMZhrIygKg= -github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/danieljoos/wincred v1.2.1 h1:dl9cBrupW8+r5250DYkYxocLeZ1Y4vB1kxgtjxw8GQs= +github.com/danieljoos/wincred v1.2.1/go.mod h1:uGaFL9fDn3OLTvzCGulzE+SzjEe5NGlh5FdCcyfPwps= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/deckarep/golang-set v1.8.0/go.mod h1:5nI87KwE7wgsBU1F4GKAw2Qod7p5kyS383rP6+o6qqo= -github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= -github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 h1:HbphB4TFFXpv7MNrT52FGrrgVXF1owhMVTHFZIlnvd4= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0/go.mod h1:DZGJHZMqrU4JJqFAWUS2UO1+lbSKsdiOoYi9Zzey7Fc= -github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= -github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= -github.com/deepmap/oapi-codegen v1.8.2/go.mod h1:YLgSKSDv/bZQB7N4ws6luhozi3cEdRktEqrX88CvjIw= +github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5ilcvdfma9wOH6Y= +github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/denis-tingaikin/go-header v0.5.0 h1:SRdnP5ZKvcO9KKRP1KJrhFR3RrlGuD+42t4429eC9k8= github.com/denis-tingaikin/go-header v0.5.0/go.mod h1:mMenU5bWrok6Wl2UsZjy+1okegmwQ3UgWl4V1D8gjlY= -github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= -github.com/dgraph-io/badger/v2 v2.2007.4 h1:TRWBQg8UrlUhaFdco01nO2uXwzKS7zd+HVdwV/GHc4o= -github.com/dgraph-io/badger/v2 v2.2007.4/go.mod h1:vSw/ax2qojzbN6eXHIx6KPKtCSHJN/Uz0X0VPruTIhk= -github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= -github.com/dgraph-io/ristretto v0.0.3/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= -github.com/dgraph-io/ristretto v0.1.1 h1:6CWw5tJNgpegArSHpNHJKldNeq03FQCwYvfMVWajOK8= -github.com/dgraph-io/ristretto v0.1.1/go.mod h1:S1GPSBCYCIhmVNfcth17y2zZtQT6wzkzgwUve0VDWWA= -github.com/dgryski/go-bitstream v0.0.0-20180413035011-3522498ce2c8/go.mod h1:VMaSuZ+SZcx/wljOQKvp5srsbCiKDEb6K2wC4+PiBmQ= -github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= +github.com/desertbit/timer v1.0.1 h1:yRpYNn5Vaaj6QXecdLMPMJsW81JLiI1eokUft5nBmeo= +github.com/desertbit/timer v1.0.1/go.mod h1:htRrYeY5V/t4iu1xCJ5XsQvp4xve8QulXXctAzxqcwE= +github.com/dgraph-io/badger/v4 v4.2.0 h1:kJrlajbXXL9DFTNuhhu9yCx7JJa4qpYWxtE8BzuWsEs= +github.com/dgraph-io/badger/v4 v4.2.0/go.mod h1:qfCqhPoWDFJRx1gp5QwwyGo8xk1lbHUxvK9nK0OGAak= +github.com/dgraph-io/ristretto v0.1.2-0.20240116140435-c67e07994f91 h1:Pux6+xANi0I7RRo5E1gflI4EZ2yx3BGZ75JkAIvGEOA= +github.com/dgraph-io/ristretto v0.1.2-0.20240116140435-c67e07994f91/go.mod h1:swkazRqnUf1N62d0Nutz7KIj2UKqsm/H8tD0nBJAXqM= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= -github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= -github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc= -github.com/dnaeon/go-vcr v1.1.0/go.mod h1:M7tiix8f0r6mKKJ3Yq/kqU1OYf3MnfmBWVbPx/yU9ko= -github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= -github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= -github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v1.4.2-0.20180625184442-8e610b2b55bf/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= -github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= -github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= +github.com/distribution/reference v0.6.0 h1:0IXCQ5g4/QMHHkarYzh5l+u8T3t73zM5QvfrDyIgxBk= +github.com/distribution/reference v0.6.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= +github.com/dlclark/regexp2 v1.11.0 h1:G/nrcoOa7ZXlpoa/91N3X7mM3r8eIlMBBJZvsz/mxKI= +github.com/dlclark/regexp2 v1.11.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= +github.com/docker/cli v27.5.0+incompatible h1:aMphQkcGtpHixwwhAXJT1rrK/detk2JIvDaFkLctbGM= +github.com/docker/cli v27.5.0+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= +github.com/docker/distribution v2.8.3+incompatible h1:AtKxIZ36LoNK51+Z6RpzLpddBirtxJnzDrHLEKxTAYk= +github.com/docker/distribution v2.8.3+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= +github.com/docker/docker v27.5.0+incompatible h1:um++2NcQtGRTz5eEgO6aJimo6/JxrTXC941hd05JO6U= +github.com/docker/docker v27.5.0+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker-credential-helpers v0.8.2 h1:bX3YxiGzFP5sOXWc3bTPEXdEaZSeVMrFgOr3T+zrFAo= +github.com/docker/docker-credential-helpers v0.8.2/go.mod h1:P3ci7E3lwkZg6XiHdRKft1KckHiO9a2rNtyFbZ/ry9M= +github.com/docker/go-connections v0.5.0 h1:USnMq7hx7gwdVZq1L49hLXaFtUdTADjXGp+uj1Br63c= +github.com/docker/go-connections v0.5.0/go.mod h1:ov60Kzw0kKElRwhNs9UlUHAE/F9Fe6GLaXnqyDdmEXc= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= -github.com/dop251/goja v0.0.0-20211011172007-d99e4b8cbf48/go.mod h1:R9ET47fwRVRPZnOGvHxxhuZcbrMCuiqOz3Rlrh4KSnk= -github.com/dop251/goja_nodejs v0.0.0-20210225215109-d91c329300e7/go.mod h1:hn7BA7c8pLvoGndExHudxTDKZ84Pyvv+90pbBjbTz0Y= github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= -github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= -github.com/dvsekhvalnov/jose2go v1.6.0 h1:Y9gnSnP4qEI0+/uQkHvFXeD2PLPJeXEL+ySMEA2EjTY= -github.com/dvsekhvalnov/jose2go v1.6.0/go.mod h1:QsHjhyTlD/lAVqn/NSbVZmSCGeDehTB/mPZadG+mhXU= +github.com/dvsekhvalnov/jose2go v1.7.0 h1:bnQc8+GMnidJZA8zc6lLEAb4xNrIqHwO+9TzqvtQZPo= +github.com/dvsekhvalnov/jose2go v1.7.0/go.mod h1:QsHjhyTlD/lAVqn/NSbVZmSCGeDehTB/mPZadG+mhXU= github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs= github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU= github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I= -github.com/eclipse/paho.mqtt.golang v1.2.0/go.mod h1:H9keYFcgq3Qr5OUJm/JZI/i6U7joQ8SYLhZwfeOo6Ts= github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M= +github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A= +github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= github.com/envoyproxy/go-control-plane v0.6.9/go.mod h1:SBwIajubJHhxtWwsL9s8ss4safvEdbitLhGGK48rN6g= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= @@ -568,22 +561,23 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.m github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0= github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/ethereum/go-ethereum v1.10.17/go.mod h1:Lt5WzjM07XlXc95YzrhosmR4J9Ahd6X2wyEV2SvGhk0= +github.com/envoyproxy/protoc-gen-validate v1.1.0 h1:tntQDh69XqOCOZsDz0lVJQez/2L6Uu2PdjCQwWCJ3bM= +github.com/envoyproxy/protoc-gen-validate v1.1.0/go.mod h1:sXRDRVmzEbkM7CVcM06s9shE/m23dg3wzjl0UWqJ2q4= github.com/ettle/strcase v0.2.0 h1:fGNiVF21fHXpX1niBgk0aROov1LagYsOwV/xqKDKR/Q= github.com/ettle/strcase v0.2.0/go.mod h1:DajmHElDSaX76ITe3/VHVyMin4LWSJN5Z909Wp+ED1A= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= -github.com/fatih/color v1.17.0 h1:GlRw1BRJxkpqUCBKzKOw098ed57fEsKeNjpTe3cSjK4= -github.com/fatih/color v1.17.0/go.mod h1:YZ7TlrGPkiz6ku9fK3TLD/pl3CpsiFyu8N92HLgmosI= +github.com/fatih/color v1.18.0 h1:S8gINlzdQ840/4pfAwic/ZE0djQEH3wM94VfqLTZcOM= +github.com/fatih/color v1.18.0/go.mod h1:4FelSpRwEGDpQ12mAdzqdOukCy4u8WUtOY6lkT/6HfU= github.com/fatih/structtag v1.2.0 h1:/OdNE99OxoI/PqaW/SuSK9uxxT3f/tcSZgon/ssNSx4= github.com/fatih/structtag v1.2.0/go.mod h1:mBJUNpUnHmRKrKlQQlmCrh5PuhftFbNv8Ys4/aAZl94= -github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/felixge/fgprof v0.9.3/go.mod h1:RdbpDgzqYVh/T9fPELJyV7EYJuHB55UTEULNun8eiPw= +github.com/felixge/fgprof v0.9.5 h1:8+vR6yu2vvSKn08urWyEuxx75NWPEvybbkBirEpsbVY= +github.com/felixge/fgprof v0.9.5/go.mod h1:yKl+ERSa++RYOs32d8K6WEXCB4uXdLls4ZaZPpayhMM= github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/firefart/nonamedreturns v1.0.5 h1:tM+Me2ZaXs8tfdDw3X6DOX++wMCOqzYUho6tUTYIdRA= github.com/firefart/nonamedreturns v1.0.5/go.mod h1:gHJjDqhGM4WyPt639SOZs+G89Ko7QKH5R5BhnO6xJhw= -github.com/fjl/memsize v0.0.0-20190710130421-bcb5799ab5e5/go.mod h1:VvhXpOYNQvB+uIk2RvXzuaQtkQJzzIx6lSBe1xv7hi0= -github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g= github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4= @@ -596,31 +590,29 @@ github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nos github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/fzipp/gocyclo v0.6.0 h1:lsblElZG7d3ALtGMx9fmxeTKZaLLpU8mET09yN4BBLo= github.com/fzipp/gocyclo v0.6.0/go.mod h1:rXPyn8fnlpa0R2csP/31uerbiVBugk5whMdlyaLkLoA= -github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff/go.mod h1:x7DCsMOv1taUwEWCzT4cmDeAkigA5/QCwUodaVOe8Ww= -github.com/getkin/kin-openapi v0.53.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= -github.com/getkin/kin-openapi v0.61.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= -github.com/getsentry/sentry-go v0.23.0 h1:dn+QRCeJv4pPt9OjVXiMcGIBIefaTJPw/h0bZWO05nE= -github.com/getsentry/sentry-go v0.23.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= +github.com/getsentry/sentry-go v0.28.1 h1:zzaSm/vHmGllRM6Tpx1492r0YDzauArdBfkJRtY6P5k= +github.com/getsentry/sentry-go v0.28.1/go.mod h1:1fQZ+7l7eeJ3wYi82q5Hg8GqAPgefRq+FP/QhafYVgg= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/ghostiam/protogetter v0.3.6 h1:R7qEWaSgFCsy20yYHNIJsU9ZOb8TziSRRxuAOTVKeOk= -github.com/ghostiam/protogetter v0.3.6/go.mod h1:7lpeDnEJ1ZjL/YtyoN99ljO4z0pd3H0d18/t2dPBxHw= -github.com/gin-contrib/sse v0.1.0 h1:Y/yl/+YNO8GZSjAhjMsSuLt29uWRFHdHYUb5lYOV9qE= +github.com/ghostiam/protogetter v0.3.8 h1:LYcXbYvybUyTIxN2Mj9h6rHrDZBDwZloPoKctWrFyJY= +github.com/ghostiam/protogetter v0.3.8/go.mod h1:WZ0nw9pfzsgxuRsPOFQomgDVSWtDLJRfQJEhsGbmQMA= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= -github.com/gin-gonic/gin v1.9.0 h1:OjyFBKICoexlu99ctXNR2gg+c5pKrKMuyjgARg9qeY8= -github.com/gin-gonic/gin v1.9.0/go.mod h1:W1Me9+hsUSyj3CePGrd1/QrKJMSJ1Tu/0hFEH89961k= -github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE= -github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24= -github.com/go-chi/chi/v5 v5.0.0/go.mod h1:BBug9lr0cqtdAhsu6R4AAdvufI0/XBzAQSsUqJpoZOs= -github.com/go-critic/go-critic v0.11.4 h1:O7kGOCx0NDIni4czrkRIXTnit0mkyKOCePh3My6OyEU= -github.com/go-critic/go-critic v0.11.4/go.mod h1:2QAdo4iuLik5S9YG0rT4wcZ8QxwHYkrr6/2MWAiv/vc= +github.com/gin-gonic/gin v1.7.0/go.mod h1:jD2toBW3GZUr5UMcdrwQA10I7RuaFOl/SGeDjXkfUtY= +github.com/go-chi/chi/v5 v5.2.0 h1:Aj1EtB0qR2Rdo2dG4O94RIU35w2lvQSj6BRA4+qwFL0= +github.com/go-chi/chi/v5 v5.2.0/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= +github.com/go-critic/go-critic v0.11.5 h1:TkDTOn5v7EEngMxu8KbuFqFR43USaaH8XRJLz1jhVYA= +github.com/go-critic/go-critic v0.11.5/go.mod h1:wu6U7ny9PiaHaZHcvMDmdysMqvDem162Rh3zWTrqk8M= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= +github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= +github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= +github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgOZ7o= -github.com/go-kit/kit v0.12.0 h1:e4o3o3IsBfAKQh5Qbbiqyfu97Ku7jrO/JbohvztANh4= -github.com/go-kit/kit v0.12.0/go.mod h1:lHd+EkCZPIwYItmGDDRdhinkzX2A1sj+M9biaEaizzs= +github.com/go-kit/kit v0.13.0 h1:OoneCcHKHQ03LfBpoQCUfCluwd2Vt3ohz+kvbJneZAU= +github.com/go-kit/kit v0.13.0/go.mod h1:phqEHMMUbyrCFCTgH48JueqrM3md2HcAZ8N3XE4FKDg= +github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= @@ -633,21 +625,13 @@ github.com/go-logr/logr v1.4.2 h1:6pFjapn8bFcIbiKo3XT4j/BhANplGihG6tvd+8rYgrY= github.com/go-logr/logr v1.4.2/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= -github.com/go-ole/go-ole v1.2.1/go.mod h1:7FAglXiTm7HKlQRDeOQ6ZNUHidzCWXuZWq/1dTyBNF8= -github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= -github.com/go-playground/assert/v2 v2.2.0/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= -github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= -github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= -github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY= -github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY= -github.com/go-playground/validator/v10 v10.11.2 h1:q3SHpufmypg+erIExEKUmsgmhDTyhcJ38oeKGACXohU= -github.com/go-playground/validator/v10 v10.11.2/go.mod h1:NieE624vt4SCTJtD87arVLvdmjPAeV8BQlHtMnw9D7s= +github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= +github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= +github.com/go-playground/universal-translator v0.17.0/go.mod h1:UkSxE5sNxxRwHyU+Scu5vgOQjsIJAF8j9muTVoKLVtA= +github.com/go-playground/validator/v10 v10.4.1/go.mod h1:nlOn6nFhuKACm19sB/8EGNn9GlaMV7XkbRSipzJ0Ii4= github.com/go-quicktest/qt v1.101.0 h1:O1K29Txy5P2OK0dGo59b7b0LR6wKfIhttaAhHUyn7eI= github.com/go-quicktest/qt v1.101.0/go.mod h1:14Bz/f7NwaXPtdYEgzsx46kqSxVwTbzVZsDC26tQJow= -github.com/go-sourcemap/sourcemap v2.1.3+incompatible/go.mod h1:F8jJfvm2KbVjc5NqelyYJmf/v5J0dwNLS2mL4sNA1Jg= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= -github.com/go-sql-driver/mysql v1.4.1/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= @@ -670,26 +654,25 @@ github.com/go-toolsmith/strparse v1.1.0 h1:GAioeZUK9TGxnLS+qfdqNbA4z0SSm5zVNtCQi github.com/go-toolsmith/strparse v1.1.0/go.mod h1:7ksGy58fsaQkGQlY8WVoBFNyEPMGuJin1rfoPS4lBSQ= github.com/go-toolsmith/typep v1.1.0 h1:fIRYDyF+JywLfqzyhdiHzRop/GQDxxNhLGQ6gFUNHus= github.com/go-toolsmith/typep v1.1.0/go.mod h1:fVIw+7zjdsMxDA3ITWnH1yOiw1rnTQKCsF/sk2H/qig= -github.com/go-viper/mapstructure/v2 v2.1.0 h1:gHnMa2Y/pIxElCH2GlZZ1lZSsn6XMtufpGyP1XxdC/w= -github.com/go-viper/mapstructure/v2 v2.1.0/go.mod h1:oJDH3BJKyqBA2TXFhDsKDGDTlndYOZ6rGS0BRZIxGhM= -github.com/go-xmlfmt/xmlfmt v1.1.2 h1:Nea7b4icn8s57fTx1M5AI4qQT5HEM3rVUO8MuE6g80U= -github.com/go-xmlfmt/xmlfmt v1.1.2/go.mod h1:aUCEOzzezBEjDBbFBoSiya/gduyIiWYRP6CnSFIV8AM= +github.com/go-viper/mapstructure/v2 v2.2.1 h1:ZAaOCxANMuZx5RCeg0mBdEZk7DZasvvZIxtHqx8aGss= +github.com/go-viper/mapstructure/v2 v2.2.1/go.mod h1:oJDH3BJKyqBA2TXFhDsKDGDTlndYOZ6rGS0BRZIxGhM= +github.com/go-xmlfmt/xmlfmt v1.1.3 h1:t8Ey3Uy7jDSEisW2K3somuMKIpzktkWptA0iFCnRUWY= +github.com/go-xmlfmt/xmlfmt v1.1.3/go.mod h1:aUCEOzzezBEjDBbFBoSiya/gduyIiWYRP6CnSFIV8AM= github.com/gobwas/glob v0.2.3 h1:A4xDbljILXROh+kObIiy5kIaPYD8e96x1tgBhUI5J+Y= github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= -github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= -github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8= +github.com/gobwas/httphead v0.1.0/go.mod h1:O/RXo79gxV8G+RqlR/otEwx4Q36zl9rqC5u12GKvMCM= github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= -github.com/gobwas/ws v1.0.2 h1:CoAavW/wd/kulfZmSIBt6p24n4j7tHgNVCjsfHVNUbo= +github.com/gobwas/pool v0.2.1/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= -github.com/goccy/go-json v0.10.0 h1:mXKd9Qw4NuzShiRlOXKews24ufknHO7gx30lsDyokKA= -github.com/goccy/go-json v0.10.0/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= +github.com/gobwas/ws v1.2.1/go.mod h1:hRKAFb8wOxFROYNsT1bqfWnhX+b5MFeJM9r2ZSwg/KY= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gofrs/flock v0.12.1 h1:MTLVXXHf8ekldpJk3AKicLij9MdwOWkZ+a/jHHZby9E= github.com/gofrs/flock v0.12.1/go.mod h1:9zxTsyu5xtJ9DK+1tFZyibEV7y3uwDxPPfbxeeHCoD0= -github.com/gofrs/uuid v3.3.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= +github.com/gofrs/uuid/v5 v5.2.0 h1:qw1GMx6/y8vhVsx626ImfKMuS5CvJmhIKKtuyvfajMM= +github.com/gofrs/uuid/v5 v5.2.0/go.mod h1:CDOjlDMVAtN56jqyRUZh58JT31Tiw7/oQyEXZV+9bD8= github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.1-0.20201022092350-68b0159b7869/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= github.com/gogo/googleapis v1.4.1 h1:1Yx4Myt7BxzvUr5ldGSbwYiZG6t9wGBZ+8/fX3Wvtq0= @@ -700,23 +683,19 @@ github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zV github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/golang-jwt/jwt v3.2.2+incompatible h1:IfV12K8xAKAnZqdXVzCZ+TOjboZ2keLg81eXfW3O+oY= -github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= -github.com/golang-jwt/jwt/v4 v4.3.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= github.com/golang-jwt/jwt/v4 v4.4.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang-jwt/jwt/v4 v4.5.1 h1:JdqV9zKUdtaa9gdPlywC3aeoEsR681PlKC+4F5gQgeo= github.com/golang-jwt/jwt/v4 v4.5.1/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= -github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= -github.com/golang/geo v0.0.0-20190916061304-5b978397cfec/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/glog v1.2.2 h1:1+mZ9upx1Dh6FmUTFR1naJ77miKiXgALjWOZ3NVFPmY= -github.com/golang/glog v1.2.2/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= +github.com/golang/glog v1.2.3 h1:oDTdz9f5VGVVNGu/Q7UXKWYsD0873HXLHdJUNBsSEKM= +github.com/golang/glog v1.2.3/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= +github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 h1:f+oWsMOmNPc8JmEHVZIycC7hBoQxHH9pNKQORJNozsQ= +github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8/go.mod h1:wcDNUvekVysuuOpQKo3191zZyTpiI6se1N1ULghS0sw= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= @@ -753,15 +732,16 @@ github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a h1:w8hkcTqaFpzKqonE9uMCefW1WDie15eSP/4MssdenaM= github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a/go.mod h1:ryS0uhF+x9jgbj/N71xsEqODy9BN81/GonCZiOzirOk= -github.com/golangci/gofmt v0.0.0-20240816233607-d8596aa466a9 h1:/1322Qns6BtQxUZDTAT4SdcoxknUki7IAoK4SAXr8ME= -github.com/golangci/gofmt v0.0.0-20240816233607-d8596aa466a9/go.mod h1:Oesb/0uFAyWoaw1U1qS5zyjCg5NP9C9iwjnI4tIsXEE= -github.com/golangci/golangci-lint v1.61.0 h1:VvbOLaRVWmyxCnUIMTbf1kDsaJbTzH20FAMXTAlQGu8= -github.com/golangci/golangci-lint v1.61.0/go.mod h1:e4lztIrJJgLPhWvFPDkhiMwEFRrWlmFbrZea3FsJyN8= -github.com/golangci/lint-1 v0.0.0-20181222135242-d2cdd8c08219/go.mod h1:/X8TswGSh1pIozq4ZwCfxS0WA5JGXguxk94ar/4c87Y= +github.com/golangci/go-printf-func-name v0.1.0 h1:dVokQP+NMTO7jwO4bwsRwLWeudOVUPPyAKJuzv8pEJU= +github.com/golangci/go-printf-func-name v0.1.0/go.mod h1:wqhWFH5mUdJQhweRnldEywnR5021wTdZSNgwYceV14s= +github.com/golangci/gofmt v0.0.0-20241223200906-057b0627d9b9 h1:t5wybL6RtO83VwoMOb7U/Peqe3gGKQlPIC66wXmnkvM= +github.com/golangci/gofmt v0.0.0-20241223200906-057b0627d9b9/go.mod h1:Ag3L7sh7E28qAp/5xnpMMTuGYqxLZoSaEHZDkZB1RgU= +github.com/golangci/golangci-lint v1.63.0 h1:4HZnKnU9nA08TQpzpl5Ngrr79B/tEvv0UJVZ92K0k1k= +github.com/golangci/golangci-lint v1.63.0/go.mod h1:yZsr57ibOW/1CAtgo/R4+H0QqDmLZtRSCOvyc8QBHf8= github.com/golangci/misspell v0.6.0 h1:JCle2HUTNWirNlDIAUO44hUsKhOFqGPoC4LZxlaSXDs= github.com/golangci/misspell v0.6.0/go.mod h1:keMNyY6R9isGaSAu+4Q8NMBwMPkh15Gtc8UCVoDtAWo= -github.com/golangci/modinfo v0.3.4 h1:oU5huX3fbxqQXdfspamej74DFX0kyGLkw1ppvXoJ8GA= -github.com/golangci/modinfo v0.3.4/go.mod h1:wytF1M5xl9u0ij8YSvhkEVPP3M5Mc7XLl1pxH3B2aUM= +github.com/golangci/modinfo v0.3.3 h1:YBQDZpDMJpe5mtd0klUFYL8tSVkmF3cmm0fZ48sc7+s= +github.com/golangci/modinfo v0.3.3/go.mod h1:wytF1M5xl9u0ij8YSvhkEVPP3M5Mc7XLl1pxH3B2aUM= github.com/golangci/plugin-module-register v0.1.1 h1:TCmesur25LnyJkpsVrupv1Cdzo+2f7zX0H6Jkw1Ol6c= github.com/golangci/plugin-module-register v0.1.1/go.mod h1:TTpqoB6KkwOJMV8u7+NyXMrkwwESJLOkfl9TxR1DGFc= github.com/golangci/revgrep v0.5.3 h1:3tL7c1XBMtWHHqVpS5ChmiAAoe4PF/d5+ULzV9sLAzs= @@ -770,9 +750,12 @@ github.com/golangci/unconvert v0.0.0-20240309020433-c5143eacb3ed h1:IURFTjxeTfNF github.com/golangci/unconvert v0.0.0-20240309020433-c5143eacb3ed/go.mod h1:XLXN8bNw4CGRPaqgl3bv/lhz7bsGPh4/xSaMTbo2vkQ= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= -github.com/google/btree v1.1.2 h1:xf4v41cLI2Z6FxbKm+8Bu+m8ifhj15JuZ9sa0jZCMUU= -github.com/google/btree v1.1.2/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= -github.com/google/flatbuffers v1.11.0/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= +github.com/google/btree v1.1.3 h1:CVpQJjYgC4VbzxeGVHfvZrv1ctoYCAI8vbl07Fcxlyg= +github.com/google/btree v1.1.3/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= +github.com/google/cel-go v0.22.1 h1:AfVXx3chM2qwoSbM7Da8g8hX8OVSkBFwX+rz2+PcK40= +github.com/google/cel-go v0.22.1/go.mod h1:BuznPXXfQDpXKWQ9sPW3TzlAJN5zzFe+i9tIs0yC4s8= +github.com/google/flatbuffers v24.3.25+incompatible h1:CX395cjN9Kke9mmalRoL3d81AtFUxJM+yDthflgJGkI= +github.com/google/flatbuffers v24.3.25+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= @@ -790,9 +773,10 @@ github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeN github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-containerregistry v0.20.2 h1:B1wPJ1SN/S7pB+ZAimcciVD+r+yV/l/DSArMxlbwseo= +github.com/google/go-containerregistry v0.20.2/go.mod h1:z38EKdKh4h7IP2gSfUUqEvalZBqs6AoLeWfUy34nQC8= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/gofuzz v1.1.1-0.20200604201612-c04b05f3adfa/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= @@ -818,23 +802,23 @@ github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5 h1:5iH8iuqE5apketRbSFBy+X1V0o+l+8NF1avt4HWl7cA= -github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= +github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg= +github.com/google/pprof v0.0.0-20240227163752-401108e1b7e7/go.mod h1:czg5+yv1E0ZGTi6S6vVK1mke0fV+FaUhNGcd6VRS9Ik= +github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad h1:a6HEuzUHeKH6hwfN/ZoQgRgVIWFJljSWa/zetS2WTvg= +github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.8 h1:zZDs9gcbt9ZPLV0ndSyQk6Kacx2g/X+SKYovpnz3SMM= github.com/google/s2a-go v0.1.8/go.mod h1:6iNWHTpQ+nfNRN5E00MSdfDwVesa8hhS32PhPO8deJA= github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/enterprise-certificate-proxy v0.0.0-20220520183353-fd19c99a87aa/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= github.com/googleapis/enterprise-certificate-proxy v0.2.0/go.mod h1:8C0jb7/mgJe/9KK8Lm7X9ctZC2t60YyIpYEI16jx0Qg= -github.com/googleapis/enterprise-certificate-proxy v0.3.3 h1:QRje2j5GZimBzlbhGA2V2QlGNgL8G6e+wGo/+/2bWI0= -github.com/googleapis/enterprise-certificate-proxy v0.3.3/go.mod h1:YKe7cfqYXjKGpGvmSg28/fFvhNzinZQm8DGnaburhGA= +github.com/googleapis/enterprise-certificate-proxy v0.3.4 h1:XYIDZApgAnrN1c855gTgghdIA6Stxb52D5RnLI1SLyw= +github.com/googleapis/enterprise-certificate-proxy v0.3.4/go.mod h1:YKe7cfqYXjKGpGvmSg28/fFvhNzinZQm8DGnaburhGA= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= @@ -851,18 +835,16 @@ github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORR github.com/gordonklaus/ineffassign v0.1.0 h1:y2Gd/9I7MdY1oEIt+n+rowjBNDcLQq3RsH5hwJd0f9s= github.com/gordonklaus/ineffassign v0.1.0/go.mod h1:Qcp2HIAYhR7mNUVSIxZww3Guk4it82ghYcEXIAk+QT0= github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= -github.com/gorilla/handlers v1.5.1 h1:9lRY6j8DEeeBT10CvO9hGW0gmky0BprnvDI5vfhUHH4= -github.com/gorilla/handlers v1.5.1/go.mod h1:t8XrUpc4KVXb7HGyJ4/cEnwQiaxrX/hz1Zv/4g96P1Q= +github.com/gorilla/handlers v1.5.2 h1:cLTUSsNkgcwhgRqvCNmdbRWG0A3N4F+M2nWKdScwyEE= +github.com/gorilla/handlers v1.5.2/go.mod h1:dX+xVpaxdSw+q0Qek8SSsl3dfMk3jNddUkMzo0GtH0w= github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= -github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY= github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ= github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= -github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +github.com/gorilla/websocket v1.5.3 h1:saDtZ6Pbx/0u+bgYQ3q96pZgCzfhKXGPqt7kZ72aNNg= +github.com/gorilla/websocket v1.5.3/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gostaticanalysis/analysisutil v0.7.1 h1:ZMCjoue3DtDWQ5WyU16YbjbQEQ3VuzwxALrpYd+HeKk= github.com/gostaticanalysis/analysisutil v0.7.1/go.mod h1:v21E3hY37WKMGSnbsw2S/ojApNWb6C1//mXO48CXbVc= github.com/gostaticanalysis/comment v1.4.1/go.mod h1:ih6ZxzTHLdadaiSnF5WY3dxUoXfXAlTaRzuaNDlSado= @@ -873,41 +855,42 @@ github.com/gostaticanalysis/forcetypeassert v0.1.0/go.mod h1:qZEedyP/sY1lTGV1uJ3 github.com/gostaticanalysis/nilerr v0.1.1 h1:ThE+hJP0fEp4zWLkWHWcRyI2Od0p7DlgYG3Uqrmrcpk= github.com/gostaticanalysis/nilerr v0.1.1/go.mod h1:wZYb6YI5YAxxq0i1+VJbY0s2YONW0HU0GPE3+5PWN4A= github.com/gostaticanalysis/testutil v0.3.1-0.20210208050101-bfb5c8eec0e4/go.mod h1:D+FIZ+7OahH3ePw/izIEeH5I06eKs1IKI4Xr64/Am3M= -github.com/gostaticanalysis/testutil v0.4.0 h1:nhdCmubdmDF6VEatUNjgUZBJKWRqugoISdUv3PPQgHY= -github.com/gostaticanalysis/testutil v0.4.0/go.mod h1:bLIoPefWXrRi/ssLFWX1dx7Repi5x3CuviD3dgAZaBU= -github.com/graph-gophers/graphql-go v1.3.0/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= +github.com/gostaticanalysis/testutil v0.5.0 h1:Dq4wT1DdTwTGCQQv3rl3IvD5Ld0E6HiY+3Zh0sUGqw8= +github.com/gostaticanalysis/testutil v0.5.0/go.mod h1:OLQSbuM6zw2EvCcXTz1lVq5unyoNft372msDY0nY5Hs= github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.2.2/go.mod h1:EaizFBKfUKtMIF5iaDEhniwNedqGo9FuLFzppDr3uwI= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= +github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 h1:UH//fgunKIs4JdUbpDl1VZCDaL56wXCB/5+wF6uHfaI= +github.com/grpc-ecosystem/go-grpc-middleware v1.4.0/go.mod h1:g5qyo/la0ALbONm6Vbp88Yd8NsDy6rZz+RcrMPxvld8= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.23.0 h1:ad0vkEBuk23VJzZR9nkLVG0YAoN9coASF1GusYX6AlU= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.23.0/go.mod h1:igFoXX2ELCW06bol23DWPB5BEWfZISOzSP5K2sbLea0= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1 h1:e9Rjr40Z98/clHv5Yg79Is0NtosR5LXRvdr7o/6NwbA= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1/go.mod h1:tIxuGz/9mpox++sgp9fJjHO0+q1X9/UOWd798aAm22M= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c h1:6rhixN/i8ZofjG1Y75iExal34USq5p+wiN1tpie8IrU= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c/go.mod h1:NMPJylDgVpX0MLRlPy15sqSwOFv/U1GZ2m21JhFfek0= -github.com/gtank/merlin v0.1.1-0.20191105220539-8318aed1a79f/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= -github.com/gtank/merlin v0.1.1 h1:eQ90iG7K9pOhtereWsmyRJ6RAwcP4tHTDBHXNg+u5is= -github.com/gtank/merlin v0.1.1/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= -github.com/gtank/ristretto255 v0.1.2 h1:JEqUCPA1NvLq5DwYtuzigd7ss8fwbYay9fi4/5uMzcc= -github.com/gtank/ristretto255 v0.1.2/go.mod h1:Ph5OpO6c7xKUGROZfWVLiJf9icMDwUeIvY4OmlYW69o= github.com/hashicorp/consul/api v1.3.0/go.mod h1:MmDNSzIMUjNpY/mQ398R4bk2FnqQLoPndWW5VkKPlCE= github.com/hashicorp/consul/sdk v0.3.0/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= -github.com/hashicorp/go-bexpr v0.1.10/go.mod h1:oxlubA2vC/gFVfX1A6JGp7ls7uCDlfJn732ehYYg+g0= github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= github.com/hashicorp/go-getter v1.7.5 h1:dT58k9hQ/vbxNMwoI5+xFYAJuv6152UNvdHokfI5wE4= github.com/hashicorp/go-getter v1.7.5/go.mod h1:W7TalhMmbPmsSMdNjD0ZskARur/9GJ17cfHTRtXV744= +github.com/hashicorp/go-hclog v1.6.3 h1:Qr2kF+eVWjTiYmU7Y31tYlP1h0q/X3Nl3tPGdaB11/k= +github.com/hashicorp/go-hclog v1.6.3/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= +github.com/hashicorp/go-immutable-radix/v2 v2.1.0 h1:CUW5RYIcysz+D3B+l1mDeXrQ7fUvGGCwJfdASSzbrfo= +github.com/hashicorp/go-immutable-radix/v2 v2.1.0/go.mod h1:hgdqLXA4f6NIjRVisM1TJ9aOJVNRqKZj+xDGF6m7PBw= +github.com/hashicorp/go-metrics v0.5.3 h1:M5uADWMOGCTUNU1YuC4hfknOeHNaX54LDm4oYSucoNE= +github.com/hashicorp/go-metrics v0.5.3/go.mod h1:KEjodfebIOuBYSAe/bHTm+HChmKSxAOXPBieMLYozDE= github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= +github.com/hashicorp/go-plugin v1.6.1 h1:P7MR2UP6gNKGPp+y7EZw2kOiq4IR9WiqLvp0XOsVdwI= +github.com/hashicorp/go-plugin v1.6.1/go.mod h1:XPHFku2tFo3o3QKFgSYo+cghcUhw1NA1hZyMK0PWAw0= github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU= github.com/hashicorp/go-safetemp v1.0.0 h1:2HR189eFNrjHQyENnQMMpCiBAsRxzbTMIgBhEyExpmo= @@ -915,8 +898,9 @@ github.com/hashicorp/go-safetemp v1.0.0/go.mod h1:oaerMy3BhqiTbVye6QuFhFtIceqFoD github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-uuid v1.0.1 h1:fv1ep09latC32wFoVwnqcnKJGnMSdBanPczbHAYm1BE= github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= +github.com/hashicorp/go-uuid v1.0.3 h1:2gKiV6YVmrJ1i2CKKa9obLvRieoRGviZFL26PcT/Co8= +github.com/hashicorp/go-uuid v1.0.3/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go-version v1.2.1/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go-version v1.6.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= @@ -925,61 +909,50 @@ github.com/hashicorp/go-version v1.7.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09 github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d h1:dg1dEPuWpEqDnvIw251EVy4zlP8gWbsGj4BsUKCRpYs= -github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= +github.com/hashicorp/golang-lru v1.0.2 h1:dV3g9Z/unq5DpblPpw+Oqcv4dU/1omnb4Ok8iPY6p1c= +github.com/hashicorp/golang-lru v1.0.2/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= +github.com/hashicorp/golang-lru/v2 v2.0.7 h1:a+bsQ5rvGLjzHuww6tVxozPZFVghXaHOwFs4luLUK2k= +github.com/hashicorp/golang-lru/v2 v2.0.7/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM= github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= -github.com/hdevalence/ed25519consensus v0.1.0 h1:jtBwzzcHuTmFrQN6xQZn6CQEO/V9f7HsjsjeEZ6auqU= -github.com/hdevalence/ed25519consensus v0.1.0/go.mod h1:w3BHWjwJbFU29IRHL1Iqkw3sus+7FctEyM4RqDxYNzo= +github.com/hashicorp/yamux v0.1.1 h1:yrQxtgseBDrq9Y652vSRDvsKCJKOUD+GzTS4Y0Y8pvE= +github.com/hashicorp/yamux v0.1.1/go.mod h1:CtWFDAQgb7dxtzFs4tWbplKIe2jSi3+5vKbgIO0SLnQ= +github.com/hdevalence/ed25519consensus v0.2.0 h1:37ICyZqdyj0lAZ8P4D1d1id3HqbbG1N3iBb1Tb4rdcU= +github.com/hdevalence/ed25519consensus v0.2.0/go.mod h1:w3BHWjwJbFU29IRHL1Iqkw3sus+7FctEyM4RqDxYNzo= github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUqJM= github.com/hexops/gotextdiff v1.0.3/go.mod h1:pSWU5MAI3yDq+fZBTazCSJysOMbxWL1BSow5/V2vxeg= -github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iURXE7ZOP9L9hSkA= -github.com/holiman/uint256 v1.2.0/go.mod h1:y4ga/t+u+Xwd7CpDgZESaRcWy0I7XMlTMA25ApIH5Jw= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huandu/go-assert v1.1.5 h1:fjemmA7sSfYHJD7CUqs9qTwwfdNAx7/j2/ZlHXzNB3c= github.com/huandu/go-assert v1.1.5/go.mod h1:yOLvuqZwmcHIC5rIzrBhT7D3Q9c3GFnd0JrPVhn/06U= github.com/huandu/skiplist v1.2.0 h1:gox56QD77HzSC0w+Ws3MH3iie755GBJU1OER3h5VsYw= github.com/huandu/skiplist v1.2.0/go.mod h1:7v3iFjLcSAzO4fN5B8dvebvo/qsfumiLiDXMrPiHF9w= github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmKTg= -github.com/huin/goupnp v1.0.3-0.20220313090229-ca81a64b4204/go.mod h1:ZxNlw5WqJj6wSsRK5+YfflQGXYfccj5VgQsMNixHM7Y= -github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3iZrZfqZzyLl6l7F3c6L1oWn7OICBi6o= +github.com/iancoleman/strcase v0.3.0 h1:nTXanmYxhfFAMjZL34Ov6gkzEsSJZ5DbhxWjvSASxEI= +github.com/iancoleman/strcase v0.3.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= +github.com/ianlancetaylor/demangle v0.0.0-20210905161508-09a460cdf81d/go.mod h1:aYm2/VgdVmcIU8iMfdMvDMsRAQjcfZSKFby6HOFvi/w= +github.com/ianlancetaylor/demangle v0.0.0-20230524184225-eabc099b10ab/go.mod h1:gx7rwoVhcfuVKG5uya9Hs3Sxj7EIvldVofAWIUtGouw= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= github.com/improbable-eng/grpc-web v0.15.0/go.mod h1:1sy9HKV4Jt9aEs9JSnkWlRJPuPtwNr0l57L4f878wP8= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= -github.com/influxdata/flux v0.65.1/go.mod h1:J754/zds0vvpfwuq7Gc2wRdVwEodfpCFM7mYlOw2LqY= -github.com/influxdata/influxdb v1.8.3/go.mod h1:JugdFhsvvI8gadxOI6noqNeeBHvWNTbfYGtiAn+2jhI= -github.com/influxdata/influxdb-client-go/v2 v2.4.0/go.mod h1:vLNHdxTJkIf2mSLvGrpj8TCcISApPoXkaxP8g9uRlW8= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/influxdata/influxql v1.1.1-0.20200828144457-65d3ef77d385/go.mod h1:gHp9y86a/pxhjJ+zMjNXiQAA197Xk9wLxaz+fGG+kWk= -github.com/influxdata/line-protocol v0.0.0-20180522152040-32c6aa80de5e/go.mod h1:4kt73NQhadE3daL3WhR5EJ/J2ocX0PZzwxQ0gXJ7oFE= -github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/influxdata/line-protocol v0.0.0-20210311194329-9aa0e372d097/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/influxdata/promql/v2 v2.12.0/go.mod h1:fxOPu+DY0bqCTCECchSRtWfc+0X19ybifQhZoQNF5D8= -github.com/influxdata/roaring v0.4.13-0.20180809181101-fc520f41fab6/go.mod h1:bSgUQ7q5ZLSO+bKBGqJiCBGAl+9DxyW63zLTujjUlOE= -github.com/influxdata/tdigest v0.0.0-20181121200506-bf2b5ad3c0a9/go.mod h1:Js0mqiSBE6Ffsg94weZZ2c+v/ciT8QRHFOap7EKDrR0= -github.com/influxdata/usage-client v0.0.0-20160829180054-6d3895376368/go.mod h1:Wbbw6tYNvwa5dlB6304Sd+82Z3f7PmVZHVKU637d4po= -github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc= -github.com/jedisct1/go-minisign v0.0.0-20190909160543-45766022959e/go.mod h1:G1CVv03EnqU1wYL2dFwXxW2An0az9JTl/ZsqXQeBlkU= -github.com/jessevdk/go-flags v0.0.0-20141203071132-1679536dcc89/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= +github.com/jdx/go-netrc v1.0.0 h1:QbLMLyCZGj0NA8glAhxUpf1zDg6cxnWgMBbjq40W0gQ= +github.com/jdx/go-netrc v1.0.0/go.mod h1:Gh9eFQJnoTNIRHXl2j5bJXA1u84hQWJWgGh569zF3v8= github.com/jgautheron/goconst v1.7.1 h1:VpdAG7Ca7yvvJk5n8dMwQhfEZJh95kl/Hl9S1OI5Jkk= github.com/jgautheron/goconst v1.7.1/go.mod h1:aAosetZ5zaeC/2EfMeRswtxUFBpe2Hr7HzkgX4fanO4= -github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= -github.com/jhump/protoreflect v1.15.1/go.mod h1:jD/2GMKKE6OqX8qTjhADU1e6DShO+gavG9e0Q693nKo= +github.com/jhump/protoreflect v1.16.0 h1:54fZg+49widqXYQ0b+usAFHbMkBGR4PpXrsHc8+TBDg= +github.com/jhump/protoreflect v1.16.0/go.mod h1:oYPd7nPvcBw/5wlDfm/AVmU9zH9BgqGCI469pGxfj/8= github.com/jingyugao/rowserrcheck v1.1.1 h1:zibz55j/MJtLsjP1OF4bSdgXxwL1b+Vn7Tjzq7gFzUs= github.com/jingyugao/rowserrcheck v1.1.1/go.mod h1:4yvlZSDb3IyDTUZJUmpZfm2Hwok+Dtp+nu2qOq+er9c= -github.com/jirfag/go-printf-func-name v0.0.0-20200119135958-7558a9eaa5af h1:KA9BjwUk7KlCh6S9EAGWBt1oExIUv9WyNCiRz5amv48= -github.com/jirfag/go-printf-func-name v0.0.0-20200119135958-7558a9eaa5af/go.mod h1:HEWGJkRDzjJY2sqdDwxccsGicWEf9BQOZsq2tV+xzM0= -github.com/jjti/go-spancheck v0.6.2 h1:iYtoxqPMzHUPp7St+5yA8+cONdyXD3ug6KK15n7Pklk= -github.com/jjti/go-spancheck v0.6.2/go.mod h1:+X7lvIrR5ZdUTkxFYqzJ0abr8Sb5LOo80uOhWNqIrYA= +github.com/jjti/go-spancheck v0.6.4 h1:Tl7gQpYf4/TMU7AT84MN83/6PutY21Nb9fuQjFTpRRc= +github.com/jjti/go-spancheck v0.6.4/go.mod h1:yAEYdKJ2lRkDA8g7X+oKUHXOWVAXSBJRv04OhF+QUjk= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= @@ -988,56 +961,44 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= +github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= -github.com/jrick/logrotate v1.0.0/go.mod h1:LNinyqDIJnpAur+b8yyulnQw/wDuN1+BYKlTRt3OuAQ= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.8/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= -github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= -github.com/jsternberg/zap-logfmt v1.0.0/go.mod h1:uvPs/4X51zdkcm5jXl5SYoN+4RK21K8mysFmDaM/h+o= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -github.com/julz/importas v0.1.0 h1:F78HnrsjY3cR7j0etXy5+TU1Zuy7Xt08X/1aJnH5xXY= -github.com/julz/importas v0.1.0/go.mod h1:oSFU2R4XK/P7kNBrnL/FEQlDGN1/6WoxXEjSSXO0DV0= -github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= -github.com/jwilder/encoding v0.0.0-20170811194829-b4e1701a28ef/go.mod h1:Ct9fl0F6iIOGgxJ5npU/IUOhOhqlVrGjyIZc8/MagT0= -github.com/karalabe/usb v0.0.2/go.mod h1:Od972xHfMJowv7NGVDiWVxk2zxnWgjLlJzE+F4F7AGU= +github.com/julz/importas v0.2.0 h1:y+MJN/UdL63QbFJHws9BVC5RpA2iq0kpjrFajTGivjQ= +github.com/julz/importas v0.2.0/go.mod h1:pThlt589EnCYtMnmhmRYY/qn9lCf/frPOK+WMx3xiJY= github.com/karamaru-alpha/copyloopvar v1.1.0 h1:x7gNyKcC2vRBO1H2Mks5u1VxQtYvFiym7fCjIP8RPos= github.com/karamaru-alpha/copyloopvar v1.1.0/go.mod h1:u7CIfztblY0jZLOQZgH3oYsJzpC2A7S6u/lfgSXHy0k= github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= -github.com/kisielk/errcheck v1.7.0 h1:+SbscKmWJ5mOK/bO1zS60F5I9WwZDWOfRsC4RwfwRV0= -github.com/kisielk/errcheck v1.7.0/go.mod h1:1kLL+jV4e+CFfueBmI1dSK2ADDyQnlrnrY/FqKluHJQ= +github.com/kisielk/errcheck v1.8.0 h1:ZX/URYa7ilESY19ik/vBmCn6zdGQLxACwjAcWbHlYlg= +github.com/kisielk/errcheck v1.8.0/go.mod h1:1kLL+jV4e+CFfueBmI1dSK2ADDyQnlrnrY/FqKluHJQ= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kkHAIKE/contextcheck v1.1.5 h1:CdnJh63tcDe53vG+RebdpdXJTc9atMgGqdx8LXxiilg= github.com/kkHAIKE/contextcheck v1.1.5/go.mod h1:O930cpht4xb1YQpK+1+AgoM3mFsvxr7uyFptcnWTYUA= -github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= -github.com/klauspost/compress v1.4.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= -github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= -github.com/klauspost/compress v1.17.0 h1:Rnbp4K9EjcDuVuHtd0dgA4qNuv9yKDYKK1ulpJwgrqM= -github.com/klauspost/compress v1.17.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/klauspost/cpuid v0.0.0-20170728055534-ae7887de9fa5 h1:2U0HzY8BJ8hVwDKIzp7y4voR9CX/nvcfymLmg2UiOio= -github.com/klauspost/cpuid v0.0.0-20170728055534-ae7887de9fa5/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= +github.com/klauspost/compress v1.17.11 h1:In6xLpyWOi1+C7tXUUWv2ot1QvBjxevKAaI6IXrJmUc= +github.com/klauspost/compress v1.17.11/go.mod h1:pMDklpSncoRMuLFrf1W9Ss9KT+0rH90U12bZKk7uwG0= github.com/klauspost/cpuid/v2 v2.0.9 h1:lgaqFMSdTdQYdZ04uHyN2d/eKdOMyi2YLSvlQIBFYa4= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= -github.com/klauspost/crc32 v0.0.0-20161016154125-cb6bfca970f6/go.mod h1:+ZoRqAPRLkC4NPOvfYeR5KNOrY6TD+/sAC3HXPZgDYg= -github.com/klauspost/pgzip v1.0.2-0.20170402124221-0bf5dcad4ada/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs= +github.com/klauspost/pgzip v1.2.6 h1:8RXeL5crjEUFnR2/Sn6GJNWtSQ3Dk8pq4CL3jvdDyjU= +github.com/klauspost/pgzip v1.2.6/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs= +github.com/knz/go-libedit v1.10.1/go.mod h1:MZTVkCWyz0oBc7JOWP3wNAzd002ZbM/5hgShxwh4x8M= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= -github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= @@ -1048,42 +1009,38 @@ github.com/kulti/thelper v0.6.3 h1:ElhKf+AlItIu+xGnI990no4cE2+XaSu1ULymV2Yulxs= github.com/kulti/thelper v0.6.3/go.mod h1:DsqKShOvP40epevkFrvIwkCMNYxMeTNjdWL4dqWHZ6I= github.com/kunwardeep/paralleltest v1.0.10 h1:wrodoaKYzS2mdNVnc4/w31YaXFtsc21PCTdvWJ/lDDs= github.com/kunwardeep/paralleltest v1.0.10/go.mod h1:2C7s65hONVqY7Q5Efj5aLzRCNLjw2h4eMc9EcypGjcY= +github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/kyoh86/exportloopref v0.1.11 h1:1Z0bcmTypkL3Q4k+IDHMWTcnCliEZcaPiIe0/ymEyhQ= github.com/kyoh86/exportloopref v0.1.11/go.mod h1:qkV4UF1zGl6EkF1ox8L5t9SwyeBAZ3qLMd6up458uqA= -github.com/labstack/echo/v4 v4.2.1/go.mod h1:AA49e0DZ8kk5jTOOCKNuPR6oTnBS0dYiM4FW1e6jwpg= -github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= -github.com/lasiar/canonicalheader v1.1.1 h1:wC+dY9ZfiqiPwAexUApFush/csSPXeIi4QqyxXmng8I= -github.com/lasiar/canonicalheader v1.1.1/go.mod h1:cXkb3Dlk6XXy+8MVQnF23CYKWlyA7kfQhSw2CcZtZb0= -github.com/ldez/gomoddirectives v0.2.4 h1:j3YjBIjEBbqZ0NKtBNzr8rtMHTOrLPeiwTkfUJZ3alg= -github.com/ldez/gomoddirectives v0.2.4/go.mod h1:oWu9i62VcQDYp9EQ0ONTfqLNh+mDLWWDO+SO0qSQw5g= -github.com/ldez/tagliatelle v0.5.0 h1:epgfuYt9v0CG3fms0pEgIMNPuFf/LpPIfjk4kyqSioo= -github.com/ldez/tagliatelle v0.5.0/go.mod h1:rj1HmWiL1MiKQuOONhd09iySTEkUuE/8+5jtPYz9xa4= -github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= -github.com/leodido/go-urn v1.2.1 h1:BqpAaACuzVSgi/VLzGZIobT2z4v53pjosyNd9Yv6n/w= -github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= +github.com/lasiar/canonicalheader v1.1.2 h1:vZ5uqwvDbyJCnMhmFYimgMZnJMjwljN5VGY0VKbMXb4= +github.com/lasiar/canonicalheader v1.1.2/go.mod h1:qJCeLFS0G/QlLQ506T+Fk/fWMa2VmBUiEI2cuMK4djI= +github.com/ldez/exptostd v0.3.0 h1:iKdMtUedzov89jDvuwmo0qpo+ARpZJg9hMp3428WwNg= +github.com/ldez/exptostd v0.3.0/go.mod h1:iZBRYaUmcW5jwCR3KROEZ1KivQQp6PHXbDPk9hqJKCQ= +github.com/ldez/gomoddirectives v0.6.0 h1:Jyf1ZdTeiIB4dd+2n4qw+g4aI9IJ6JyfOZ8BityWvnA= +github.com/ldez/gomoddirectives v0.6.0/go.mod h1:TuwOGYoPAoENDWQpe8DMqEm5nIfjrxZXmxX/CExWyZ4= +github.com/ldez/grignotin v0.7.0 h1:vh0dI32WhHaq6LLPZ38g7WxXuZ1+RzyrJ7iPG9JMa8c= +github.com/ldez/grignotin v0.7.0/go.mod h1:uaVTr0SoZ1KBii33c47O1M8Jp3OP3YDwhZCmzT9GHEk= +github.com/ldez/tagliatelle v0.7.1 h1:bTgKjjc2sQcsgPiT902+aadvMjCeMHrY7ly2XKFORIk= +github.com/ldez/tagliatelle v0.7.1/go.mod h1:3zjxUpsNB2aEZScWiZTHrAXOl1x25t3cRmzfK1mlo2I= +github.com/ldez/usetesting v0.4.1 h1:T/4Bk3YDX6XUBtdNDDFymlr5GBekKA4j7HUtrv1YaaI= +github.com/ldez/usetesting v0.4.1/go.mod h1:eEs46T3PpQ+9RgN9VjpY6qWdiw2/QmfiDeWmdZdrjIQ= +github.com/ledongthuc/pdf v0.0.0-20220302134840-0c2507a12d80/go.mod h1:imJHygn/1yfhB7XSJJKlFZKl/J+dCPAknuiaGOshXAs= +github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= github.com/leonklingele/grouper v1.1.2 h1:o1ARBDLOmmasUaNDesWqWCIFH3u7hoFlM84YrjT3mIY= github.com/leonklingele/grouper v1.1.2/go.mod h1:6D0M/HVkhs2yRKRFZUoGjeDy7EZTfFBE9gl4kjmIGkA= -github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw= github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= -github.com/libp2p/go-buffer-pool v0.1.0 h1:oK4mSFcQz7cTQIfqbe4MIj9gLW+mnanjyFtc6cdF0Y8= -github.com/libp2p/go-buffer-pool v0.1.0/go.mod h1:N+vh8gMqimBzdKkSMVuydVDq+UV5QTWy5HSiZacSbPg= github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= -github.com/linxGnu/grocksdb v1.7.16 h1:Q2co1xrpdkr5Hx3Fp+f+f7fRGhQFQhvi/+226dtLmA8= -github.com/linxGnu/grocksdb v1.7.16/go.mod h1:JkS7pl5qWpGpuVb3bPqTz8nC12X3YtPZT+Xq7+QfQo4= -github.com/lucasjones/reggen v0.0.0-20180717132126-cdb49ff09d77/go.mod h1:5ELEyG+X8f+meRWHuqUOewBOhvHkl7M76pdGEansxW4= -github.com/lufeee/execinquery v1.2.1 h1:hf0Ems4SHcUGBxpGN7Jz78z1ppVkP/837ZlETPCEtOM= -github.com/lufeee/execinquery v1.2.1/go.mod h1:EC7DrEKView09ocscGHC+apXMIaorh4xqSxS/dy8SbM= +github.com/linxGnu/grocksdb v1.9.3 h1:s1cbPcOd0cU2SKXRG1nEqCOWYAELQjdqg3RVI2MH9ik= +github.com/linxGnu/grocksdb v1.9.3/go.mod h1:QYiYypR2d4v63Wj1adOOfzglnoII0gLj3PNh4fZkcFA= github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ= github.com/macabu/inamedparam v0.1.3 h1:2tk/phHkMlEL/1GNe/Yf6kkR/hkcUdAEY3L0hjYV1Mk= github.com/macabu/inamedparam v0.1.3/go.mod h1:93FLICAIk/quk7eaPPQvbzihUdn/QkGDwIZEoLtpH6I= -github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= -github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/manifoldco/promptui v0.9.0 h1:3V4HzJk1TtXW1MTZMP7mdlwbBpIinw3HztaIlYthEiA= github.com/manifoldco/promptui v0.9.0/go.mod h1:ka04sppxSGFAtxX0qhlYQjISsg9mR4GWtQEhdbn6Pgg= github.com/maratori/testableexamples v1.0.0 h1:dU5alXRrD8WKSjOUnmJZuzdxWOEQ57+7s93SLMxb2vI= @@ -1094,44 +1051,30 @@ github.com/matoous/godox v0.0.0-20230222163458-006bad1f9d26 h1:gWg6ZQ4JhDfJPqlo2 github.com/matoous/godox v0.0.0-20230222163458-006bad1f9d26/go.mod h1:1BELzlh859Sh1c6+90blK8lbYy0kwQf1bYlBhBysy1s= github.com/matryer/is v1.4.0 h1:sosSmIWwkYITGrxZ25ULNDeKiMNzFSr4V/eqBQP0PeE= github.com/matryer/is v1.4.0/go.mod h1:8I/i5uYgLzgsgEloJE1U6xx5HkBQpAZvepWuujKwMRU= -github.com/matryer/moq v0.0.0-20190312154309-6cfb0558e1bd/go.mod h1:9ELz6aaclSIGnZBoaSLZ3NAl1VTufbOrXBPvtcy6WiQ= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.7/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= -github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= +github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= -github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/mattn/go-isatty v0.0.19/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= -github.com/mattn/go-runewidth v0.0.3/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.4/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -github.com/mattn/go-runewidth v0.0.10 h1:CoZ3S2P7pvtP45xOtBw+/mDL2z0RKI576gSkzRRpdGg= -github.com/mattn/go-runewidth v0.0.10/go.mod h1:RAqKPSqVFrSLVXbA8x7dzmKdmGzieGRCM46jaSJTDAk= -github.com/mattn/go-sqlite3 v1.11.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= -github.com/mattn/go-tty v0.0.0-20180907095812-13ff1204f104/go.mod h1:XPvLUNfbS4fJH25nqRHfWLMa1ONC8Amw+mIA639KxkE= +github.com/mattn/go-runewidth v0.0.16 h1:E5ScNMtiwvlvB5paMFdw9p4kSQzbXFikJ5SQO6TULQc= +github.com/mattn/go-runewidth v0.0.16/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zkfA9PSy5pEvNWRP0ET0TIVo= -github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/mgechev/revive v1.3.9 h1:18Y3R4a2USSBF+QZKFQwVkBROUda7uoBlkEuBD+YD1A= -github.com/mgechev/revive v1.3.9/go.mod h1:+uxEIr5UH0TjXWHTno3xh4u7eg6jDpXKzQccA9UGhHU= +github.com/mgechev/revive v1.5.1 h1:hE+QPeq0/wIzJwOphdVyUJ82njdd8Khp4fUIHGZHW3M= +github.com/mgechev/revive v1.5.1/go.mod h1:lC9AhkJIBs5zwx8wkudyHrU+IJkrEKmpCmGMnIJPk4o= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= -github.com/mimoo/StrobeGo v0.0.0-20181016162300-f8f6d4d2b643/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= -github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 h1:QRUSJEgZn2Snx0EmT/QLXibWjSUDjKWvXIT19NBVp94= -github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= -github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= -github.com/minio/highwayhash v1.0.2/go.mod h1:BQskDq+xkJ12lmlUUi7U0M5Swg3EWR+dLTk+kldvVxY= +github.com/minio/highwayhash v1.0.3 h1:kbnuUMoHYyVl7szWjSxJnxw11k2U709jqFPPmIUyD6Q= +github.com/minio/highwayhash v1.0.3/go.mod h1:GGYsuwP/fPD6Y9hMiXuapVvlIUEhFhMTh0rxU3ik1LQ= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= @@ -1143,34 +1086,32 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4 github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8ohIXc3tViBH44KcwB2g4= +github.com/moby/docker-image-spec v1.3.1 h1:jMKff3w6PgbfSa69GfNg+zN/XLhfXJGnEx3Nl2EsFP0= +github.com/moby/docker-image-spec v1.3.1/go.mod h1:eKmb5VW8vQEh/BAr2yvVNvuiJuY6UIocYsFu/DxxRpo= +github.com/moby/term v0.5.2 h1:6qk3FJAFDs6i/q3W/pQ97SX192qKfZgGjCQqfCJkgzQ= +github.com/moby/term v0.5.2/go.mod h1:d3djjFCrjnB+fl8NJux+EJzu0msscUP+f8it8hPkFLc= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= -github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/modocache/gover v0.0.0-20171022184752-b58185e213c5/go.mod h1:caMODM3PzxT8aQXRPkAt8xlV/e7d7w8GM5g0fa5F0D8= github.com/moricho/tparallel v0.3.2 h1:odr8aZVFA3NZrNybggMkYO3rgPRcqjeQUlBBFVxKHTI= github.com/moricho/tparallel v0.3.2/go.mod h1:OQ+K3b4Ln3l2TZveGCywybl68glfLEwFGqvnjok8b+U= +github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= +github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= github.com/mrz1836/go-sanitize v1.3.3 h1:MfWVBN25tuXSoXa6FgC+OiLFn0D37K9qkF3kslLhVQQ= github.com/mrz1836/go-sanitize v1.3.3/go.mod h1:wvRS2ALFDxOCK3ORQPwKUxl7HTIBUV8S3U34Hwn96r4= -github.com/mschoch/smat v0.0.0-20160514031455-90eadee771ae/go.mod h1:qAyveg+e4CE+eKJXWVjKXM4ck2QobLqTDytGJbLLhJg= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/grpc-proxy v0.0.0-20181017164139-0f1106ef9c76/go.mod h1:x5OoJHDHqxHS801UIuhqGl6QdSAEJvtausosHSdazIo= github.com/nakabonne/nestif v0.3.1 h1:wm28nZjhQY5HyYPx+weN3Q65k6ilSBxDb8v5S81B81U= github.com/nakabonne/nestif v0.3.1/go.mod h1:9EtoZochLn5iUprVDmDjqGKPofoUEBL8U4Ngq6aY7OE= -github.com/naoina/go-stringutil v0.1.0/go.mod h1:XJ2SJL9jCtBh+P9q5btrd/Ylo8XwT/h1USek5+NqSA0= -github.com/naoina/toml v0.1.2-0.20170918210437-9fafd6967416/go.mod h1:NBIhNtsFMo3G2szEBne+bO4gS192HuIYRqfvOWb4i1E= github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= github.com/nats-io/jwt v0.3.2/go.mod h1:/euKqTS1ZD+zzjYrY7pseZrTtWQSjujC7xjPc8wL6eU= github.com/nats-io/nats-server/v2 v2.1.2/go.mod h1:Afk+wRZqkMQs/p45uXdrVLuab3gwv3Z8C4HTBu8GD/k= @@ -1178,20 +1119,22 @@ github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzE github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nkeys v0.1.3/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= -github.com/neilotoole/errgroup v0.1.6/go.mod h1:Q2nLGf+594h0CLBs/Mbg6qOr7GtqDK7C2S41udRnToE= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nishanths/exhaustive v0.12.0 h1:vIY9sALmw6T/yxiASewa4TQcFsVYZQQRUQJhKRf3Swg= github.com/nishanths/exhaustive v0.12.0/go.mod h1:mEZ95wPIZW+x8kC4TgC+9YCUgiST7ecevsVDTgc2obs= github.com/nishanths/predeclared v0.2.2 h1:V2EPdZPliZymNAn79T8RkNApBjMmVKh5XRpLm/w98Vk= github.com/nishanths/predeclared v0.2.2/go.mod h1:RROzoN6TnGQupbC+lqggsOlcgysk3LMK/HI84Mp280c= -github.com/nunnatsa/ginkgolinter v0.16.2 h1:8iLqHIZvN4fTLDC0Ke9tbSZVcyVHoBs0HIbnVSxfHJk= -github.com/nunnatsa/ginkgolinter v0.16.2/go.mod h1:4tWRinDN1FeJgU+iJANW/kz7xKN5nYRAOfJDQUS9dOQ= +github.com/nunnatsa/ginkgolinter v0.18.4 h1:zmX4KUR+6fk/vhUFt8DOP6KwznekhkmVSzzVJve2vyM= +github.com/nunnatsa/ginkgolinter v0.18.4/go.mod h1:AMEane4QQ6JwFz5GgjI5xLUM9S/CylO+UyM97fN2iBI= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= -github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= -github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= +github.com/nxadm/tail v1.4.11 h1:8feyoE3OzPrcshW5/MJ4sGESc5cqmGkGCWlco4l0bqY= +github.com/nxadm/tail v1.4.11/go.mod h1:OTaG3NK980DZzxbRq6lEuzgU+mug70nY11sMd4JXXHc= +github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a h1:dlRvE5fWabOchtH7znfiFCcOvmIYgOeAS5ifBXBlh9Q= +github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a/go.mod h1:hVoHR2EVESiICEMbg137etN/Lx+lSrHPTD39Z/uE+2s= github.com/oklog/oklog v0.3.2/go.mod h1:FCV+B7mhrz4o+ueLpx+KqkyXRGMWOYEvfiXtdGtbWGs= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= -github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= +github.com/oklog/run v1.1.0 h1:GEenZ1cK0+q0+wsJew9qUg/DyD8k3JzYsZAi5gYi2mA= +github.com/oklog/run v1.1.0/go.mod h1:sVPdnTZT1zYwAJeCMu2Th4T21pA3FPOQRfWjQlk7DVU= github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo= github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= @@ -1201,30 +1144,29 @@ github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108 github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= -github.com/onsi/ginkgo/v2 v2.20.2 h1:7NVCeyIWROIAheY21RLS+3j2bb52W0W82tkberYytp4= -github.com/onsi/ginkgo/v2 v2.20.2/go.mod h1:K9gyxPIlb+aIvnZ8bd9Ak+YP18w3APlR+5coaZoE2ag= -github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= +github.com/onsi/ginkgo/v2 v2.22.2 h1:/3X8Panh8/WwhU/3Ssa6rCKqPLuAkVY2I0RoyDLySlU= +github.com/onsi/ginkgo/v2 v2.22.2/go.mod h1:oeMosUL+8LtarXBHu/c0bx2D/K9zyQ6uX3cTyztHwsk= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= -github.com/onsi/gomega v1.34.2 h1:pNCwDkzrsv7MS9kpaQvVb1aVLahQXyJ/Tv5oAZMI3i8= -github.com/onsi/gomega v1.34.2/go.mod h1:v1xfxRgk0KIsG+QOdm7p8UosrOzPYRo60fd3B/1Dukc= +github.com/onsi/gomega v1.36.2 h1:koNYke6TVk6ZmnyHrCXba/T/MoLBXFjeC1PtvYgw0A8= +github.com/onsi/gomega v1.36.2/go.mod h1:DdwyADRjrc825LhMEkD76cHR5+pUnjhUN8GlHlRPHzY= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= -github.com/opencontainers/image-spec v1.1.0-rc2 h1:2zx/Stx4Wc5pIPDvIxHXvXtQFW/7XWJGmnM7r3wg034= -github.com/opencontainers/image-spec v1.1.0-rc2/go.mod h1:3OVijpioIKYWTqjiG0zfF6wvoJ4fAXGbjdZuI2NgsRQ= -github.com/opencontainers/runc v1.1.3 h1:vIXrkId+0/J2Ymu2m7VjGvbSlAId9XNRPhn2p4b+d8w= -github.com/opencontainers/runc v1.1.3/go.mod h1:1J5XiS+vdZ3wCyZybsuxXZWGrgSr8fFJHLXuG2PsnNg= +github.com/opencontainers/image-spec v1.1.0 h1:8SG7/vwALn54lVB/0yZ/MMwhFrPYtpEHQb2IpWsCzug= +github.com/opencontainers/image-spec v1.1.0/go.mod h1:W4s4sFTMaBeK1BQLXbG4AdM2szdn85PY75RI83NrTrM= +github.com/opencontainers/runc v1.1.14 h1:rgSuzbmgz5DUJjeSnw337TxDbRuqjs6iqQck/2weR6w= +github.com/opencontainers/runc v1.1.14/go.mod h1:E4C2z+7BxR7GHXp0hAY53mek+x49X1LjPNeMTfRGvOA= github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492/go.mod h1:Ngi6UdF0k5OKD5t5wlmGhe/EDKPoUM3BXZSSfIuJbis= github.com/opentracing/basictracer-go v1.0.0/go.mod h1:QfBfYuafItcjQuMwinw9GhYKwFXS9KnPs5lxoYwgW74= github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= -github.com/opentracing/opentracing-go v1.0.3-0.20180606204148-bd9c31933947/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/openzipkin-contrib/zipkin-go-opentracing v0.4.5/go.mod h1:/wsWhb9smxSfWAKL3wpBW7V8scJMt8N8gnaMCS9E/cA= github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw= github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= +github.com/orisano/pixelmatch v0.0.0-20220722002657-fb0b55479cde/go.mod h1:nZgzbfBr3hhjoZnS66nKrHmduYNpc34ny7RK4z5/HM0= github.com/ory/dockertest v3.3.5+incompatible h1:iLLK6SQwIhcbrG783Dghaaa3WPzGc+4Emza6EbVUUGA= github.com/ory/dockertest v3.3.5+incompatible/go.mod h1:1vX4m9wsvi00u5bseYwXaSnhNrne+V0E6LAcBILJdPs= github.com/otiai10/copy v1.2.0/go.mod h1:rrF5dJ5F0t/EWSYODDu4j9/vEeYHMkc8jt0zJChqQWw= @@ -1238,35 +1180,31 @@ github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIw github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= -github.com/paulbellamy/ratecounter v0.2.0/go.mod h1:Hfx1hDpSGoqxkVVpBi/IlYD7kChlfo5C6hzIHwPqfFE= github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= -github.com/pelletier/go-toml/v2 v2.0.6/go.mod h1:eumQOmlWiOPt5WriQQqoM5y18pDHwha2N+QD+EUNTek= github.com/pelletier/go-toml/v2 v2.2.3 h1:YmeHyLY8mFWbdkNWwpr+qIL2bEqT0o95WSdkNHvL12M= github.com/pelletier/go-toml/v2 v2.2.3/go.mod h1:MfCQTFTvCcUyyvvwm1+G6H/jORL20Xlb6rzQu9GuUkc= github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= -github.com/peterh/liner v1.0.1-0.20180619022028-8c1271fcf47f/go.mod h1:xIteQHvHuaLYG9IFj6mSxM0fCKrs34IrEQUhOYuGPHc= -github.com/peterh/liner v1.1.1-0.20190123174540-a2c9a5303de7/go.mod h1:CRroGNssyjTd/qIG2FyxByd2S8JEAZXBl4qUrZf8GS0= -github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= -github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 h1:hDSdbBuw3Lefr6R18ax0tZ2BJeNB3NehB3trOwYBsdU= -github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= -github.com/philhofer/fwd v1.0.0/go.mod h1:gk3iGcWd9+svBvR0sR+KPcfE+RNWozjowpeBVG3ZVNU= +github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 h1:Dx7Ovyv/SFnMFw3fD4oEoeorXc6saIiQ23LrGLth0Gw= +github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc= github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= +github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c h1:+mdjkGKdHQG3305AYmdv1U2eRNDiU2ErMBj1gwrq8eQ= +github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c/go.mod h1:7rwL4CYBLnjLxUqIJNnCWiEdr3bn6IUYi15bNlnbCCU= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/profile v1.2.1/go.mod h1:hJw3o1OdXxsrSjjVksARp5W95eeEaEfptyVZyv6JUPA= -github.com/pkg/term v0.0.0-20180730021639-bffc007b7fd5/go.mod h1:eCbImbZ95eXtAUIbLAuAVnBnwf83mjf6QIVH8SHYwqQ= +github.com/pkg/profile v1.7.0 h1:hnbDkaNWPCLMO9wGLdBFTIZvzDrDfBM2072E1S9gJkA= +github.com/pkg/profile v1.7.0/go.mod h1:8Uer0jas47ZQMJ7VD+OHknK4YDY07LPUC6dEvqDjvNo= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/polyfloyd/go-errorlint v1.6.0 h1:tftWV9DE7txiFzPpztTAwyoRLKNj9gpVm2cg8/OwcYY= -github.com/polyfloyd/go-errorlint v1.6.0/go.mod h1:HR7u8wuP1kb1NeN1zqTd1ZMlqUKPPHF+Id4vIPvDqVw= +github.com/polyfloyd/go-errorlint v1.7.0 h1:Zp6lzCK4hpBDj8y8a237YK4EPrMXQWvOe3nGoH4pFrU= +github.com/polyfloyd/go-errorlint v1.7.0/go.mod h1:dGWKu85mGHnegQ2SWpEybFityCg3j7ZbwsVUxAOk9gY= github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= github.com/prashantv/gostub v1.1.0 h1:BTyx3RfQjRHnUWaGF9oQos79AlQ5k8WNktv7VGvVH4g= github.com/prashantv/gostub v1.1.0/go.mod h1:A5zLQHz7ieHGG7is6LLXLz7I8+3LZzsrV0P1IAHhP5U= @@ -1276,35 +1214,32 @@ github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5Fsn github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og= github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= -github.com/prometheus/client_golang v1.16.0 h1:yk/hx9hDbrGHovbci4BY+pRMfSuuat626eFsHb7tmT8= -github.com/prometheus/client_golang v1.16.0/go.mod h1:Zsulrv/L9oM40tJ7T815tM89lFEugiJ9HzIqaAx4LKc= +github.com/prometheus/client_golang v1.20.5 h1:cxppBPuYhUnsO6yo/aoRol4L7q7UFfdm+bR9r+8l63Y= +github.com/prometheus/client_golang v1.20.5/go.mod h1:PIEt8X02hGcP8JWbeHyeZ53Y/jReSnHgO035n//V5WE= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.1.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.3.0 h1:UBgGFHqYdG/TPFD1B1ogZywDqEkwp3fBMvqdiQ7Xew4= -github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= -github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= +github.com/prometheus/client_model v0.6.1 h1:ZKSh/rekM+n3CeS952MLRAdFwIKqeY8b62p8ais2e9E= +github.com/prometheus/client_model v0.6.1/go.mod h1:OrxVMOVHjw3lKMa8+x6HeMGkHMQyHDk9E3jmP2AmGiY= github.com/prometheus/common v0.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc= github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt26CguLLsqA= github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.15.0/go.mod h1:U+gB1OBLb1lF3O42bTCL+FK18tX9Oar16Clt/msog/s= -github.com/prometheus/common v0.42.0 h1:EKsfXEYo4JpWMHH5cg+KOUWeuJSov1Id8zGR8eeI1YM= -github.com/prometheus/common v0.42.0/go.mod h1:xBwqVerjNdUDjgODMpudtOMwlOwf2SaTr1yjz4b7Zbc= +github.com/prometheus/common v0.61.0 h1:3gv/GThfX0cV2lpO7gkTUwZru38mxevy90Bj8YFSRQQ= +github.com/prometheus/common v0.61.0/go.mod h1:zr29OCN/2BsJRaFwG8QOBr41D6kkchKbpeNH7pAjb/s= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.3.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.10.1 h1:kYK1Va/YMlutzCGazswoHKo//tZVlFpKYh+PymziUAg= -github.com/prometheus/procfs v0.10.1/go.mod h1:nwNm2aOCAYw8uTR/9bWRREkZFxAUcWzPHWJq+XBB/FM= -github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= +github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc= +github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk= github.com/quasilyte/go-ruleguard v0.4.3-0.20240823090925-0fe6f58b47b1 h1:+Wl/0aFp0hpuHM3H//KMft64WQ1yX9LdJY64Qm/gFCo= github.com/quasilyte/go-ruleguard v0.4.3-0.20240823090925-0fe6f58b47b1/go.mod h1:GJLgqsLeo4qgavUoL8JeGFNS7qcisx3awV/w9eWTmNI= github.com/quasilyte/go-ruleguard/dsl v0.3.22 h1:wd8zkOhSNr+I+8Qeciml08ivDt1pSXe60+5DqOpCjPE= @@ -1315,67 +1250,56 @@ github.com/quasilyte/regex/syntax v0.0.0-20210819130434-b3f0c404a727 h1:TCg2WBOl github.com/quasilyte/regex/syntax v0.0.0-20210819130434-b3f0c404a727/go.mod h1:rlzQ04UMyJXu/aOvhd8qT+hvDrFpiwqp8MRXDY9szc0= github.com/quasilyte/stdinfo v0.0.0-20220114132959-f7386bf02567 h1:M8mH9eK4OUR4lu7Gd+PU1fV2/qnDNfzT635KRSObncs= github.com/quasilyte/stdinfo v0.0.0-20220114132959-f7386bf02567/go.mod h1:DWNGW8A4Y+GyBgPuaQJuWiy0XYftx4Xm/y5Jqk9I6VQ= -github.com/rakyll/statik v0.1.7 h1:OF3QCZUuyPxuGEP7B4ypUa7sB/iHtqOTDYZXGM8KOdQ= -github.com/rakyll/statik v0.1.7/go.mod h1:AlZONWzMtEnMs7W4e/1LURLiI49pIMmp6V9Unghqrcc= +github.com/raeperd/recvcheck v0.2.0 h1:GnU+NsbiCqdC2XX5+vMZzP+jAJC5fht7rcVTAhX74UI= +github.com/raeperd/recvcheck v0.2.0/go.mod h1:n04eYkwIR0JbgD73wT8wL4JjPC3wm0nFtzBnWNocnYU= github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= -github.com/retailnext/hllpp v1.0.1-0.20180308014038-101a6d2f8b52/go.mod h1:RDpi1RftBQPUCDRw6SmxeaREsAaRKnOclghuzp/WRzc= -github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= -github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= -github.com/rjeczalik/notify v0.9.1/go.mod h1:rKwnCoCGeuQnwBtTSPL9Dad03Vh2n40ePRrjvIXnJho= +github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ= +github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= -github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= -github.com/rogpeppe/go-internal v1.8.0/go.mod h1:WmiCO8CzOY8rg0OYDC4/i/2WRWAB6poM+XZ2dLUbcbE= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= -github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= -github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= +github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII= +github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o= github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= -github.com/rs/cors v1.8.3 h1:O+qNyWn7Z+F9M0ILBHgMVPuB1xTOucVd5gtaYyXBpRo= -github.com/rs/cors v1.8.3/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= +github.com/rs/cors v1.11.1 h1:eU3gRzXLRK57F5rKMGMZURNdIG4EoAmX8k94r9wXWHA= +github.com/rs/cors v1.11.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.33.0 h1:1cU2KZkvPxNyfgEmhHAz/1A9Bz+llsdYzklWFzgp0r8= github.com/rs/zerolog v1.33.0/go.mod h1:/7mN4D5sKwJLZQ2b/znpjC3/GQWY/xaDXUM0kKWRHss= -github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryancurrah/gomodguard v1.3.5 h1:cShyguSwUEeC0jS7ylOiG/idnd1TpJ1LfHGpV3oJmPU= github.com/ryancurrah/gomodguard v1.3.5/go.mod h1:MXlEPQRxgfPQa62O8wzK3Ozbkv9Rkqr+wKjSxTdsNJE= github.com/ryanrolds/sqlclosecheck v0.5.1 h1:dibWW826u0P8jNLsLN+En7+RqWWTYrjCB9fJfSfdyCU= github.com/ryanrolds/sqlclosecheck v0.5.1/go.mod h1:2g3dUjoS6AL4huFdv6wn55WpLIDjY7ZgUR4J8HOO/XQ= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/sagikazarmark/locafero v0.4.0 h1:HApY1R9zGo4DBgr7dqsTH/JJxLTTsOt7u6keLGt6kNQ= -github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgYEpgQ3O5fPuL3H4= +github.com/sagikazarmark/locafero v0.6.0 h1:ON7AQg37yzcRPU69mt7gwhFEBwxI6P9T4Qu3N51bwOk= +github.com/sagikazarmark/locafero v0.6.0/go.mod h1:77OmuIc6VTraTXKXIs/uvUxKGUXjE1GbemJYHqdNjX0= github.com/sagikazarmark/slog-shim v0.1.0 h1:diDBnUNK9N/354PgrxMywXnAwEr1QZcOr6gto+ugjYE= github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= -github.com/sanposhiho/wastedassign/v2 v2.0.7 h1:J+6nrY4VW+gC9xFzUc+XjPD3g3wF3je/NsJFwFK7Uxc= -github.com/sanposhiho/wastedassign/v2 v2.0.7/go.mod h1:KyZ0MWTwxxBmfwn33zh3k1dmsbF2ud9pAAGfoLfjhtI= -github.com/santhosh-tekuri/jsonschema/v5 v5.3.1 h1:lZUw3E0/J3roVtGQ+SCrUrg3ON6NgVqpn3+iol9aGu4= -github.com/santhosh-tekuri/jsonschema/v5 v5.3.1/go.mod h1:uToXkOrWAZ6/Oc07xWQrPOhJotwFIyu2bBVN41fcDUY= -github.com/sasha-s/go-deadlock v0.3.1 h1:sqv7fDNShgjcaxkO0JNcOAlr8B9+cV5Ey/OB71efZx0= -github.com/sasha-s/go-deadlock v0.3.1/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= +github.com/sanposhiho/wastedassign/v2 v2.1.0 h1:crurBF7fJKIORrV85u9UUpePDYGWnwvv3+A96WvwXT0= +github.com/sanposhiho/wastedassign/v2 v2.1.0/go.mod h1:+oSmSC+9bQ+VUAxA66nBb0Z7N8CK7mscKTDYC6aIek4= +github.com/santhosh-tekuri/jsonschema/v6 v6.0.1 h1:PKK9DyHxif4LZo+uQSgXNqs0jj5+xZwwfKHgph2lxBw= +github.com/santhosh-tekuri/jsonschema/v6 v6.0.1/go.mod h1:JXeL+ps8p7/KNMjDQk3TCwPpBy0wYklyWTfbkIzdIFU= +github.com/sasha-s/go-deadlock v0.3.5 h1:tNCOEEDG6tBqrNDOX35j/7hL5FcFViG6awUGROb2NsU= +github.com/sasha-s/go-deadlock v0.3.5/go.mod h1:bugP6EGbdGYObIlx7pUZtWqlvo8k9H6vCBBsiChJQ5U= github.com/sashamelentyev/interfacebloat v1.1.0 h1:xdRdJp0irL086OyW1H/RTZTr1h/tMEOsumirXcOJqAw= github.com/sashamelentyev/interfacebloat v1.1.0/go.mod h1:+Y9yU5YdTkrNvoX0xHc84dxiN1iBi9+G8zZIhPVoNjQ= -github.com/sashamelentyev/usestdlibvars v1.27.0 h1:t/3jZpSXtRPRf2xr0m63i32ZrusyurIGT9E5wAvXQnI= -github.com/sashamelentyev/usestdlibvars v1.27.0/go.mod h1:9nl0jgOfHKWNFS43Ojw0i7aRoS4j6EBye3YBhmAIRF8= +github.com/sashamelentyev/usestdlibvars v1.28.0 h1:jZnudE2zKCtYlGzLVreNp5pmCdOxXUzwsMDBkR21cyQ= +github.com/sashamelentyev/usestdlibvars v1.28.0/go.mod h1:9nl0jgOfHKWNFS43Ojw0i7aRoS4j6EBye3YBhmAIRF8= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/securego/gosec/v2 v2.21.2 h1:deZp5zmYf3TWwU7A7cR2+SolbTpZ3HQiwFqnzQyEl3M= -github.com/securego/gosec/v2 v2.21.2/go.mod h1:au33kg78rNseF5PwPnTWhuYBFf534bvJRvOrgZ/bFzU= -github.com/segmentio/fasthash v1.0.3/go.mod h1:waKX8l2N8yckOgmSsXJi7x1ZfdKZ4x7KRMzBtS3oedY= -github.com/segmentio/kafka-go v0.1.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo= -github.com/segmentio/kafka-go v0.2.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo= -github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= -github.com/sge-network/cosmos-sdk v0.47.9-0.20250130125213-8f7baf6f5b95 h1:54GyVRNK0pK3bHXsUhkohkH6oElUDr96PTyskkWtp64= -github.com/sge-network/cosmos-sdk v0.47.9-0.20250130125213-8f7baf6f5b95/go.mod h1:GrDj/zd9Tiuy8ZpG9PbUbhghCVU7lwyH0GS7CpxHpyM= -github.com/sge-network/wasmd v0.0.0-20241104103744-57e9fdbaa27f h1:1pJSGSfHSw1iTddTAApXM6FRPmyKdd81/peKvdtjPa0= -github.com/sge-network/wasmd v0.0.0-20241104103744-57e9fdbaa27f/go.mod h1:aZ5a8YdvErEpedfub+coENfZR21VwOL4HkI8F2dg0Cw= +github.com/securego/gosec/v2 v2.21.4 h1:Le8MSj0PDmOnHJgUATjD96PaXRvCpKC+DGJvwyy0Mlk= +github.com/securego/gosec/v2 v2.21.4/go.mod h1:Jtb/MwRQfRxCXyCm1rfM1BEiiiTfUOdyzzAhlr6lUTA= +github.com/shamaton/msgpack/v2 v2.2.0 h1:IP1m01pHwCrMa6ZccP9B3bqxEMKMSmMVAVKk54g3L/Y= +github.com/shamaton/msgpack/v2 v2.2.0/go.mod h1:6khjYnkx73f7VQU7wjcFS9DFjs+59naVWJv1TB7qdOI= github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c h1:W65qqJCIOVP4jpqPQ0YvHYKwcMEMVWIzWC5iNQQfBTU= github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c/go.mod h1:/PevMnwAxekIXwN8qQyfc5gl2NlkB3CQlkizAbOkeBs= -github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk= github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ= github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= @@ -1387,44 +1311,38 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/sivchari/containedctx v1.0.3 h1:x+etemjbsh2fB5ewm5FeLNi5bUjK0V8n0RB+Wwfd0XE= github.com/sivchari/containedctx v1.0.3/go.mod h1:c1RDvCbnJLtH4lLcYD/GqwiBSSf4F5Qk0xld2rBqzJ4= -github.com/sivchari/tenv v1.10.0 h1:g/hzMA+dBCKqGXgW8AV/1xIWhAvDrx0zFKNR48NFMg0= -github.com/sivchari/tenv v1.10.0/go.mod h1:tdY24masnVoZFxYrHv/nD6Tc8FbkEtAQEEziXpyMgqY= +github.com/sivchari/tenv v1.12.1 h1:+E0QzjktdnExv/wwsnnyk4oqZBUfuh89YMQT1cyuvSY= +github.com/sivchari/tenv v1.12.1/go.mod h1:1LjSOUCc25snIr5n3DtGGrENhX3LuWefcplwVGC24mw= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= -github.com/sonatard/noctx v0.0.2 h1:L7Dz4De2zDQhW8S0t+KUjY0MAQJd6SgVwhzNIc4ok00= -github.com/sonatard/noctx v0.0.2/go.mod h1:kzFz+CzWSjQ2OzIm46uJZoXuBpa2+0y3T36U18dWqIo= +github.com/sonatard/noctx v0.1.0 h1:JjqOc2WN16ISWAjAk8M5ej0RfExEXtkEyExl2hLW+OM= +github.com/sonatard/noctx v0.1.0/go.mod h1:0RvBxqY8D4j9cTTTWE8ylt2vqj2EPI8fHmrxHdsaZ2c= github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY= github.com/sourcegraph/conc v0.3.0 h1:OQTbbt6P72L20UqAkXXuLOj79LfEanQ+YQFNpLA9ySo= github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0= github.com/sourcegraph/go-diff v0.7.0 h1:9uLlrd5T46OXs5qpp8L/MTltk0zikUGi0sNNyCpA8G0= github.com/sourcegraph/go-diff v0.7.0/go.mod h1:iBszgVvyxdc8SFZ7gm69go2KDdt3ag071iBaWPF6cjs= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= -github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/afero v1.11.0 h1:WJQKhtpdm3v2IzqG8VMqrr6Rf3UYpEF239Jy9wNepM8= github.com/spf13/afero v1.11.0/go.mod h1:GH9Y3pIexgf1MTIWtNGyogA5MwRIDXGUr+hbWNoBjkY= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cast v1.7.0 h1:ntdiHjuueXFgm5nzDRdOS4yfT43P5Fnud6DH50rz/7w= -github.com/spf13/cast v1.7.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= +github.com/spf13/cast v1.7.1 h1:cuNEagBQEHWN1FnbGEjCXL2szYEXqfJPbP2HNUaca9Y= +github.com/spf13/cast v1.7.1/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= github.com/spf13/cobra v1.8.1 h1:e5/vxKd/rZsfSJMUX1agtjeTDf+qv1/JdBF8gg5k9ZM= github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3kD9Y= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= -github.com/spf13/viper v1.18.2 h1:LUXCnvUvSM6FXAsj6nnfc8Q2tp1dIgUfY9Kc8GsSOiQ= -github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= +github.com/spf13/pflag v1.0.6 h1:jFzHGLGAlb3ruxLB8MhbI6A8+AQX/2eW4qeyNZXNp2o= +github.com/spf13/pflag v1.0.6/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/spf13/viper v1.19.0 h1:RWq5SEjt8o25SROyN3z2OrDB9l7RPd3lwTWU8EcEdcI= +github.com/spf13/viper v1.19.0/go.mod h1:GQUN9bilAbhU/jgc1bKs99f/suXKeUMct8Adx5+Ntkg= github.com/ssgreg/nlreturn/v2 v2.2.1 h1:X4XDI7jstt3ySqGU86YGAURbxw3oTDPK9sPEi6YEwQ0= github.com/ssgreg/nlreturn/v2 v2.2.1/go.mod h1:E/iiPB78hV7Szg2YfRgyIrk1AD6JVMTRkkxBiELzh2I= -github.com/status-im/keycard-go v0.0.0-20190316090335-8537d3370df4/go.mod h1:RZLeN1LMWmRsyYjvAu+I6Dm9QmlDaIIt+Y+4Kd7Tp+Q= -github.com/stbenjam/no-sprintf-host-port v0.1.1 h1:tYugd/yrm1O0dV+ThCbaKZh195Dfm07ysF0U6JQXczc= -github.com/stbenjam/no-sprintf-host-port v0.1.1/go.mod h1:TLhvtIvONRzdmkFiio4O8LHsN9N74I+PhRquPsxpL0I= +github.com/stbenjam/no-sprintf-host-port v0.2.0 h1:i8pxvGrt1+4G0czLr/WnmyH7zbZ8Bg8etvARQ1rpyl4= +github.com/stbenjam/no-sprintf-host-port v0.2.0/go.mod h1:eL0bQ9PasS0hsyTyfTjjG+E80QIyPnBVQbYZyv20Jfk= +github.com/stoewer/go-strcase v1.3.0 h1:g0eASXYtp+yvN9fK8sH94oCIk0fau9uV1/ZdJ0AVEzs= +github.com/stoewer/go-strcase v1.3.0/go.mod h1:fAH5hQ5pehh+j3nZfvwdk2RgEgQjAoM8wodgtPmh1xo= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= @@ -1434,7 +1352,6 @@ github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSS github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/objx v0.5.2 h1:xuMeJ0Sdp5ZMRXx/aWO6RZxdr3beISkG5/G/aIRr3pY= github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= -github.com/stretchr/testify v1.2.0/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= @@ -1442,78 +1359,62 @@ github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5 github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= -github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= +github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tdakkota/asciicheck v0.2.0 h1:o8jvnUANo0qXtnslk2d3nMKTFNlOnJjRrNcj0j9qkHM= -github.com/tdakkota/asciicheck v0.2.0/go.mod h1:Qb7Y9EgjCLJGup51gDHFzbI08/gbGhL/UVhYIPWG2rg= +github.com/tdakkota/asciicheck v0.3.0 h1:LqDGgZdholxZMaJgpM6b0U9CFIjDCbFdUF00bDnBKOQ= +github.com/tdakkota/asciicheck v0.3.0/go.mod h1:KoJKXuX/Z/lt6XzLo8WMBfQGzak0SrAKZlvRr4tg8Ac= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tenntenn/modver v1.0.1 h1:2klLppGhDgzJrScMpkj9Ujy3rXPUspSjAcev9tSEBgA= github.com/tenntenn/modver v1.0.1/go.mod h1:bePIyQPb7UeioSRkw3Q0XeMhYZSMx9B8ePqg6SAMGH0= github.com/tenntenn/text/transform v0.0.0-20200319021203-7eef512accb3 h1:f+jULpRQGxTSkNYKJ51yaw6ChIqO+Je8UqsTKN/cDag= github.com/tenntenn/text/transform v0.0.0-20200319021203-7eef512accb3/go.mod h1:ON8b8w4BN/kE1EOhwT0o+d62W65a6aPw1nouo9LMgyY= -github.com/tetafro/godot v1.4.17 h1:pGzu+Ye7ZUEFx7LHU0dAKmCOXWsPjl7qA6iMGndsjPs= -github.com/tetafro/godot v1.4.17/go.mod h1:2oVxTBSftRTh4+MVfUaUXR6bn2GDXCaMcOG4Dk3rfio= -github.com/tidwall/btree v1.6.0 h1:LDZfKfQIBHGHWSwckhXI0RPSXzlo+KYdjK7FWSqOzzg= -github.com/tidwall/btree v1.6.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= -github.com/tidwall/gjson v1.12.1/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= -github.com/tidwall/gjson v1.14.0/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= -github.com/tidwall/match v1.1.1/go.mod h1:eRSPERbgtNPcGhD8UCthc6PmLEQXEWd3PRB5JTxsfmM= -github.com/tidwall/pretty v1.2.0/go.mod h1:ITEVvHYasfjBbM0u2Pg8T2nJnzm8xPwvNhhsoaGGjNU= -github.com/tidwall/sjson v1.2.4/go.mod h1:098SZ494YoMWPmMO6ct4dcFnqxwj9r/gF0Etp19pSNM= -github.com/timakin/bodyclose v0.0.0-20230421092635-574207250966 h1:quvGphlmUVU+nhpFa4gg4yJyTRJ13reZMDHrKwYw53M= -github.com/timakin/bodyclose v0.0.0-20230421092635-574207250966/go.mod h1:27bSVNWSBOHm+qRp1T9qzaIpsWEP6TbUnei/43HK+PQ= -github.com/timonwong/loggercheck v0.9.4 h1:HKKhqrjcVj8sxL7K77beXh0adEm6DLjV/QOGeMXEVi4= -github.com/timonwong/loggercheck v0.9.4/go.mod h1:caz4zlPcgvpEkXgVnAJGowHAMW2NwHaNlpS8xDbVhTg= -github.com/tinylib/msgp v1.0.2/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDWklFE= -github.com/tklauser/go-sysconf v0.3.5/go.mod h1:MkWzOF4RMCshBAMXuhXJs64Rte09mITnppBXY/rYEFI= -github.com/tklauser/numcpus v0.2.2/go.mod h1:x3qojaO3uyYt0i56EW/VUYs7uBvdl2fkfZFu0T9wgjM= +github.com/tetafro/godot v1.4.20 h1:z/p8Ek55UdNvzt4TFn2zx2KscpW4rWqcnUrdmvWJj7E= +github.com/tetafro/godot v1.4.20/go.mod h1:2oVxTBSftRTh4+MVfUaUXR6bn2GDXCaMcOG4Dk3rfio= +github.com/tidwall/btree v1.7.0 h1:L1fkJH/AuEh5zBnnBbmTwQ5Lt+bRJ5A8EWecslvo9iI= +github.com/tidwall/btree v1.7.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= +github.com/timakin/bodyclose v0.0.0-20241017074812-ed6a65f985e3 h1:y4mJRFlM6fUyPhoXuFg/Yu02fg/nIPFMOY8tOqppoFg= +github.com/timakin/bodyclose v0.0.0-20241017074812-ed6a65f985e3/go.mod h1:mkjARE7Yr8qU23YcGMSALbIxTQ9r9QBVahQOBRfU460= +github.com/timonwong/loggercheck v0.10.1 h1:uVZYClxQFpw55eh+PIoqM7uAOHMrhVcDoWDery9R8Lg= +github.com/timonwong/loggercheck v0.10.1/go.mod h1:HEAWU8djynujaAVX7QI65Myb8qgfcZ1uKbdpg3ZzKl8= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/tomarrell/wrapcheck/v2 v2.9.0 h1:801U2YCAjLhdN8zhZ/7tdjB3EnAoRlJHt/s+9hijLQ4= -github.com/tomarrell/wrapcheck/v2 v2.9.0/go.mod h1:g9vNIyhb5/9TQgumxQyOEqDHsmGYcGsVMOx/xGkqdMo= +github.com/tomarrell/wrapcheck/v2 v2.10.0 h1:SzRCryzy4IrAH7bVGG4cK40tNUhmVmMDuJujy4XwYDg= +github.com/tomarrell/wrapcheck/v2 v2.10.0/go.mod h1:g9vNIyhb5/9TQgumxQyOEqDHsmGYcGsVMOx/xGkqdMo= github.com/tommy-muehle/go-mnd/v2 v2.5.1 h1:NowYhSdyE/1zwK9QCLeRb6USWdoif80Ie+v+yU8u1Zw= github.com/tommy-muehle/go-mnd/v2 v2.5.1/go.mod h1:WsUAkMJMYww6l/ufffCD3m+P7LEvr8TnZn9lwVDlgzw= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS4MhqMhdFk5YI= github.com/twitchyliquid64/golang-asm v0.15.1/go.mod h1:a1lVb/DtPvCB8fslRZhAngC2+aY1QWCk3Cedj/Gdt08= -github.com/tyler-smith/go-bip39 v1.0.1-0.20181017060643-dbb3b84ba2ef/go.mod h1:sJ5fKU0s6JVwZjjcUEX2zFOnvq0ASQ2K9Zr6cf67kNs= -github.com/tyler-smith/go-bip39 v1.0.2/go.mod h1:sJ5fKU0s6JVwZjjcUEX2zFOnvq0ASQ2K9Zr6cf67kNs= -github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= -github.com/ugorji/go/codec v1.2.9 h1:rmenucSohSTiyL09Y+l2OCk+FrMxGMzho2+tjr5ticU= -github.com/ugorji/go/codec v1.2.9/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= +github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= +github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= github.com/ulikunitz/xz v0.5.10/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/ulikunitz/xz v0.5.11 h1:kpFauv27b6ynzBNT/Xy+1k+fK4WswhN/6PN5WhFAGw8= github.com/ulikunitz/xz v0.5.11/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= -github.com/ultraware/funlen v0.1.0 h1:BuqclbkY6pO+cvxoq7OsktIXZpgBSkYTQtmwhAK81vI= -github.com/ultraware/funlen v0.1.0/go.mod h1:XJqmOQja6DpxarLj6Jj1U7JuoS8PvL4nEqDaQhy22p4= -github.com/ultraware/whitespace v0.1.1 h1:bTPOGejYFulW3PkcrqkeQwOd6NKOOXvmGD9bo/Gk8VQ= -github.com/ultraware/whitespace v0.1.1/go.mod h1:XcP1RLD81eV4BW8UhQlpaR+SDc2givTvyI8a586WjW8= +github.com/ultraware/funlen v0.2.0 h1:gCHmCn+d2/1SemTdYMiKLAHFYxTYz7z9VIDRaTGyLkI= +github.com/ultraware/funlen v0.2.0/go.mod h1:ZE0q4TsJ8T1SQcjmkhN/w+MceuatI6pBFSxxyteHIJA= +github.com/ultraware/whitespace v0.2.0 h1:TYowo2m9Nfj1baEQBjuHzvMRbp19i+RCcRYrSWoFa+g= +github.com/ultraware/whitespace v0.2.0/go.mod h1:XcP1RLD81eV4BW8UhQlpaR+SDc2givTvyI8a586WjW8= github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= -github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/XcUArI= -github.com/uudashr/gocognit v1.1.3 h1:l+a111VcDbKfynh+airAy/DJQKaXh2m9vkoysMPSZyM= -github.com/uudashr/gocognit v1.1.3/go.mod h1:aKH8/e8xbTRBwjbCkwZ8qt4l2EpKXl31KMHgSS+lZ2U= -github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= -github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -github.com/vmihailenco/msgpack/v5 v5.3.5/go.mod h1:7xyJ9e+0+9SaZT0Wt1RGleJXzli6Q/V5KbhBonMG9jc= -github.com/vmihailenco/tagparser/v2 v2.0.0/go.mod h1:Wri+At7QHww0WTrCBeu4J6bNtoV6mEfg5OIWRZA9qds= -github.com/willf/bitset v1.1.3/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4= +github.com/uudashr/gocognit v1.2.0 h1:3BU9aMr1xbhPlvJLSydKwdLN3tEUUrzPSSM8S4hDYRA= +github.com/uudashr/gocognit v1.2.0/go.mod h1:k/DdKPI6XBZO1q7HgoV2juESI2/Ofj9AcHPZhBBdrTU= +github.com/uudashr/iface v1.3.0 h1:zwPch0fs9tdh9BmL5kcgSpvnObV+yHjO4JjVBl8IA10= +github.com/uudashr/iface v1.3.0/go.mod h1:4QvspiRd3JLPAEXBQ9AiZpLbJlrWWgRChOKDJEuQTdg= +github.com/vbatts/tar-split v0.11.6 h1:4SjTW5+PU11n6fZenf2IPoV8/tz3AaYHMWjf23envGs= +github.com/vbatts/tar-split v0.11.6/go.mod h1:dqKNtesIOr2j2Qv3W/cHjnvk9I8+G7oAkFDFN6TCBEI= github.com/xen0n/gosmopolitan v1.2.2 h1:/p2KTnMzwRexIW8GlKawsTWOxn7UHA+jCMF/V8HHtvU= github.com/xen0n/gosmopolitan v1.2.2/go.mod h1:7XX7Mj61uLYrj0qmeN0zi7XDon9JRAEhYQqAPLVNTeg= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= -github.com/xlab/treeprint v0.0.0-20180616005107-d6fb6747feb6/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= github.com/yagipy/maintidx v1.0.0 h1:h5NvIsCz+nRDapQ0exNv4aJ0yXSI0420omVANTv3GJM= github.com/yagipy/maintidx v1.0.0/go.mod h1:0qNf/I/CCZXSMhsRsrEPDZ+DkekpKLXAJfsTACwgXLk= -github.com/ybbus/jsonrpc v2.1.2+incompatible/go.mod h1:XJrh1eMSzdIYFbM08flv0wp5G35eRniyeGut1z+LSiE= github.com/yeya24/promlinter v0.3.0 h1:JVDbMp08lVCP7Y6NP3qHroGAO6z2yGKQtS5JsjqtoFs= github.com/yeya24/promlinter v0.3.0/go.mod h1:cDfJQQYv9uYciW60QT0eeHlFodotkYZlL+YcPQN+mW4= github.com/ykadowak/zerologlint v0.1.5 h1:Gy/fMz1dFQN9JZTPjv1hxEk+sRWm05row04Yoolgdiw= @@ -1533,13 +1434,13 @@ gitlab.com/bosi/decorder v0.4.2 h1:qbQaV3zgwnBZ4zPMhGLW4KZe7A7NwxEhJx39R3shffo= gitlab.com/bosi/decorder v0.4.2/go.mod h1:muuhHoaJkA9QLcYHq4Mj8FJUwDZ+EirSHRiaTcTf6T8= go-simpler.org/assert v0.9.0 h1:PfpmcSvL7yAnWyChSjOz6Sp6m9j5lyK8Ok9pEL31YkQ= go-simpler.org/assert v0.9.0/go.mod h1:74Eqh5eI6vCK6Y5l3PI8ZYFXG4Sa+tkr70OIPJAUr28= -go-simpler.org/musttag v0.12.2 h1:J7lRc2ysXOq7eM8rwaTYnNrHd5JwjppzB6mScysB2Cs= -go-simpler.org/musttag v0.12.2/go.mod h1:uN1DVIasMTQKk6XSik7yrJoEysGtR2GRqvWnI9S7TYM= +go-simpler.org/musttag v0.13.0 h1:Q/YAW0AHvaoaIbsPj3bvEI5/QFP7w696IMUpnKXQfCE= +go-simpler.org/musttag v0.13.0/go.mod h1:FTzIGeK6OkKlUDVpj0iQUXZLUO1Js9+mvykDQy9C5yM= go-simpler.org/sloglint v0.7.2 h1:Wc9Em/Zeuu7JYpl+oKoYOsQSy2X560aVueCW/m6IijY= go-simpler.org/sloglint v0.7.2/go.mod h1:US+9C80ppl7VsThQclkM7BkCHQAzuz8kHLsW3ppuluo= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/bbolt v1.3.7 h1:j+zJOnnEjF/kyHlDDgGnVL/AIqIJPq8UoB2GSNfkUfQ= -go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= +go.etcd.io/bbolt v1.4.0-alpha.1 h1:3yrqQzbRRPFPdOMWS/QQIVxVnzSkAZQYeWlZFv1kbj4= +go.etcd.io/bbolt v1.4.0-alpha.1/go.mod h1:S/Z/Nm3iuOnyO1W4XuFfPci51Gj6F1Hv0z8hisyYYOw= go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg= go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= go.opencensus.io v0.20.2/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= @@ -1552,72 +1453,86 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= +go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= +go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.54.0 h1:r6I7RJCN86bpD/FQwedZ0vSixDpwuWREjW9oRMsmqDc= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.54.0/go.mod h1:B9yO6b04uB80CzjedvewuqDhxJxi11s7/GtiGa8bAjI= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.54.0 h1:TT4fX+nBOA/+LUkobKGW1ydGcn+G3vRw9+g5HwCphpk= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.54.0/go.mod h1:L7UH0GbB0p47T4Rri3uHjbpCFYrVrwc1I25QhNPiGK8= -go.opentelemetry.io/otel v1.29.0 h1:PdomN/Al4q/lN6iBJEN3AwPvUiHPMlt93c8bqTG5Llw= -go.opentelemetry.io/otel v1.29.0/go.mod h1:N/WtXPs1CNCUEx+Agz5uouwCba+i+bJGFicT8SR4NP8= -go.opentelemetry.io/otel/metric v1.29.0 h1:vPf/HFWTNkPu1aYeIsc98l4ktOQaL6LeSoeV2g+8YLc= -go.opentelemetry.io/otel/metric v1.29.0/go.mod h1:auu/QWieFVWx+DmQOUMgj0F8LHWdgalxXqvp7BII/W8= -go.opentelemetry.io/otel/sdk v1.28.0 h1:b9d7hIry8yZsgtbmM0DKyPWMMUMlK9NEKuIG4aBqWyE= -go.opentelemetry.io/otel/sdk v1.28.0/go.mod h1:oYj7ClPUA7Iw3m+r7GeEjz0qckQRJK2B8zjcZEfu7Pg= -go.opentelemetry.io/otel/trace v1.29.0 h1:J/8ZNK4XgR7a21DZUAsbF8pZ5Jcw1VhACmnYt39JTi4= -go.opentelemetry.io/otel/trace v1.29.0/go.mod h1:eHl3w0sp3paPkYstJOmAimxhiFXPg+MMTlEh3nsQgWQ= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.58.0 h1:yd02MEjBdJkG3uabWP9apV+OuWRIXGDuJEUJbOHmCFU= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.58.0/go.mod h1:umTcuxiv1n/s/S6/c2AT/g2CQ7u5C59sHDNmfSwgz7Q= +go.opentelemetry.io/otel v1.33.0 h1:/FerN9bax5LoK51X/sI0SVYrjSE0/yUL7DpxW4K3FWw= +go.opentelemetry.io/otel v1.33.0/go.mod h1:SUUkR6csvUQl+yjReHu5uM3EtVV7MBm5FHKRlNx4I8I= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.19.0 h1:Mne5On7VWdx7omSrSSZvM4Kw7cS7NQkOOmLcgscI51U= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.19.0/go.mod h1:IPtUMKL4O3tH5y+iXVyAXqpAwMuzC1IrxVS81rummfE= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.24.0 h1:Xw8U6u2f8DK2XAkGRFV7BBLENgnTGX9i4rQRxJf+/vs= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.24.0/go.mod h1:6KW1Fm6R/s6Z3PGXwSJN2K4eT6wQB3vXX6CVnYX9NmM= +go.opentelemetry.io/otel/metric v1.33.0 h1:r+JOocAyeRVXD8lZpjdQjzMadVZp2M4WmQ+5WtEnklQ= +go.opentelemetry.io/otel/metric v1.33.0/go.mod h1:L9+Fyctbp6HFTddIxClbQkjtubW6O9QS3Ann/M82u6M= +go.opentelemetry.io/otel/sdk v1.32.0 h1:RNxepc9vK59A8XsgZQouW8ue8Gkb4jpWtJm9ge5lEG4= +go.opentelemetry.io/otel/sdk v1.32.0/go.mod h1:LqgegDBjKMmb2GC6/PrTnteJG39I8/vJCAP9LlJXEjU= +go.opentelemetry.io/otel/sdk/metric v1.32.0 h1:rZvFnvmvawYb0alrYkjraqJq0Z4ZUJAiyYCU9snn1CU= +go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= +go.opentelemetry.io/otel/trace v1.33.0 h1:cCJuF7LRjUFso9LPnEAHJDB2pqzp+hbO8eu1qqW2d/s= +go.opentelemetry.io/otel/trace v1.33.0/go.mod h1:uIcdVUZMpTAmz0tI1z04GoVSezK37CbGV4fr1f2nBck= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= +go.opentelemetry.io/proto/otlp v1.3.1 h1:TrMUixzpM0yuc/znrFTP9MMRh8trP93mkCiDVeXrui0= +go.opentelemetry.io/proto/otlp v1.3.1/go.mod h1:0X1WI4de4ZsLrrJNLAQbFeLCm3T7yBkR0XqQ7niQU+8= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= -go.uber.org/atomic v1.10.0 h1:9qC72Qh0+3MqyJbAn8YU5xVq1frD8bn3JtD2oXtafVQ= -go.uber.org/atomic v1.10.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= -go.uber.org/automaxprocs v1.5.3 h1:kWazyxZUrS3Gs4qUpbwo5kEIMGe/DAvi5Z4tl2NW4j8= -go.uber.org/automaxprocs v1.5.3/go.mod h1:eRbA25aqJrxAbsLO0xy5jVwPt7FQnRgjW+efnwa1WM0= -go.uber.org/goleak v1.1.11 h1:wy28qYRKZgnJTxGxvye5/wgWr1EKjmUDGYox5mGlRlI= -go.uber.org/goleak v1.1.11/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ= +go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= +go.uber.org/atomic v1.11.0 h1:ZvwS0R+56ePWxUNi+Atn9dWONBPp/AUETXlHW0DxSjE= +go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= +go.uber.org/automaxprocs v1.6.0 h1:O3y2/QNTOdbF+e/dpXNNW7Rx2hZ4sTIPyybbxyNqTUs= +go.uber.org/automaxprocs v1.6.0/go.mod h1:ifeIMSnPZuznNm6jmdzmU3/bfk01Fe2fotchwEFJ8r8= +go.uber.org/goleak v1.1.10/go.mod h1:8a7PlsEVH3e/a/GLqe5IIrQx6GzcnRmZEufDUTk4A7A= +go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= +go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4= -go.uber.org/multierr v1.9.0 h1:7fIwc/ZtS0q++VgcfqFDxSBZVv/Xo49/SYnDFupUwlI= -go.uber.org/multierr v1.9.0/go.mod h1:X2jQV1h+kxSjClGpnseKVIxpmcjrj7MNnI0bnlfKTVQ= +go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU= +go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= +go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= -go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= -go.uber.org/zap v1.24.0 h1:FiJd5l1UOLj0wCgbSE0rwwXHzEdAZS6hiiSnxJN/D60= -go.uber.org/zap v1.24.0/go.mod h1:2kMP+WWQ8aoFoedH3T2sq6iJ2yDWpHbP0f6MQbS9Gkg= +go.uber.org/zap v1.18.1/go.mod h1:xg/QME4nWcxGxrpdeYfq7UvYrLh66cuVKdrbD1XF/NI= +go.uber.org/zap v1.27.0 h1:aJMhYGrd5QSmlpLMr2MftRKl7t8J8PTZPA732ud/XR8= +go.uber.org/zap v1.27.0/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E= golang.org/x/arch v0.0.0-20210923205945-b76863e36670 h1:18EFjUmQOcUvxNYSkA6jO9VAiXCnxFY6NyDX0bHDmkU= golang.org/x/arch v0.0.0-20210923205945-b76863e36670/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= -golang.org/x/crypto v0.0.0-20170930174604-9419663f5a44/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20190426145343-a29dc8fdc734/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190909091759-094676da4a83/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200115085410-6d4e4cb37c7d/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= -golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.1.0/go.mod h1:RecgLatLF4+eUMCP1PoPZQb+cVrJcOPbHkTkbkB9sbw= -golang.org/x/crypto v0.5.0/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU= -golang.org/x/crypto v0.27.0 h1:GXm2NjJrPaiv/h1tb2UH8QfgC/hOf/+z0p6PT8o1w7A= -golang.org/x/crypto v0.27.0/go.mod h1:1Xngt8kV6Dvbssa53Ziq6Eqn0HqbZi5Z6R0ZpwQzt70= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb h1:xIApU0ow1zwMa2uL1VDNeQlNVFTWMQxZUZCMDy0Q4Us= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc= +golang.org/x/crypto v0.13.0/go.mod h1:y6Z2r+Rw4iayiXXAIxJIDAJ1zMW4yaTpebo8fPOliYc= +golang.org/x/crypto v0.14.0/go.mod h1:MVFd36DqK4CsrnJYDkBA3VC4m2GkXAM0PvzMCn4JQf4= +golang.org/x/crypto v0.32.0 h1:euUpcYgM8WcP71gNpTqQCn6rC2t6ULUPiOzfWaXVVfc= +golang.org/x/crypto v0.32.0/go.mod h1:ZnnJkOaASj8g0AjIduWNlq2NRxL0PlBrbKVyZ6V/Ugc= +golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= +golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= +golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= +golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= +golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= +golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= +golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= +golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= +golang.org/x/exp v0.0.0-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= +golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 h1:yqrTHse8TCMW1M1ZCP+VAR/l0kKxwaAIqN/il7x4voA= +golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8/go.mod h1:tujkw807nyEEAamNbDrEGzRav+ilXA7PCRAd6xsmwiU= golang.org/x/exp/typeparams v0.0.0-20220428152302-39d4317da171/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= golang.org/x/exp/typeparams v0.0.0-20230203172020-98cc5a0785f9/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= -golang.org/x/exp/typeparams v0.0.0-20240314144324-c7f7c6466f7f h1:phY1HzDcf18Aq9A8KkmRtY9WvOFIxN8wgfvy6Zm1DV8= -golang.org/x/exp/typeparams v0.0.0-20240314144324-c7f7c6466f7f/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= -golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= +golang.org/x/exp/typeparams v0.0.0-20241108190413-2d47ceb2692f h1:WTyX8eCCyfdqiPYkRGm0MqElSfYFH3yR1+rl/mct9sA= +golang.org/x/exp/typeparams v0.0.0-20241108190413-2d47ceb2692f/go.mod h1:AbB0pIl9nAr9wVwH+Z2ZpaocVmF5I4GyWCDIsVjR0bk= +golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= +golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -1630,23 +1545,26 @@ golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPI golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= +golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= +golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= +golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= +golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.6.0/go.mod h1:4mET923SAdbXp2ki8ey+zGs1SLqsuM2Y0uvdZR/fUNI= golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.11.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.21.0 h1:vvrHzRwRfVKSiLrG+d4FMl/Qi4ukBCE6kZlTUkDYRT0= -golang.org/x/mod v0.21.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= -golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/mod v0.9.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +golang.org/x/mod v0.13.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= +golang.org/x/mod v0.22.0 h1:D4nJWe9zXqHOmWqj4VMOJhvzj7bEZg4wEYa759z1pH4= +golang.org/x/mod v0.22.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1684,18 +1602,15 @@ golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81R golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.0.0-20201010224723-4f7140c49acb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210220033124-5f55cee0dc0d/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20210610132358-84b48f89b13b/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= @@ -1713,9 +1628,12 @@ golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY= golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= -golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= -golang.org/x/net v0.28.0 h1:a9JDOJc5GMUJ0+UDqmLT86WiEy7iWyIhz8gz8E4e5hE= -golang.org/x/net v0.28.0/go.mod h1:yqtgsTWOOnlGLG9GFRrK3++bGOUEkNBoHZc8MEDWPNg= +golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= +golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= +golang.org/x/net v0.15.0/go.mod h1:idbUs1IY1+zTqbi8yxTbhexhEEk5ur9LInksu6HrEpk= +golang.org/x/net v0.16.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= +golang.org/x/net v0.34.0 h1:Mb7Mrk043xzHgnRM88suvJFwzVrRfHEHJEl5/71CKw0= +golang.org/x/net v0.34.0/go.mod h1:di0qlW3YNM5oh6GqDGQr92MyTozJPmybPK4Ev/Gm31k= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -1741,8 +1659,8 @@ golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri golang.org/x/oauth2 v0.0.0-20220909003341-f21342109be1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.1.0/go.mod h1:G9FE4dLTsbXUu90h/Pf85g4w1D+SSAgR+q46nJZ8M4A= -golang.org/x/oauth2 v0.23.0 h1:PbgcYx2W7i4LvjJWEbf0ngHV6qJYr86PkAV3bXdLEbs= -golang.org/x/oauth2 v0.23.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= +golang.org/x/oauth2 v0.26.0 h1:afQXWNNaeC4nvZ0Ed9XvCCzXM6UHJG7iCg0W4fPqSBE= +golang.org/x/oauth2 v0.26.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1758,8 +1676,10 @@ golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ= -golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.11.0 h1:GGz8+XQP4FvTTrjZPzNKTMFtSXH80RAzG+5ghFPgK9w= +golang.org/x/sync v0.11.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1768,21 +1688,18 @@ golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190130150945-aca44879d564/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1790,7 +1707,6 @@ golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20191220142924-d4481acd189f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200107162124-548cf772de50/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1810,7 +1726,6 @@ golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200826173525-f9321e4c35a6/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1821,11 +1736,8 @@ golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210316164454-77fc1eacc6aa/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210324051608-47abb6519492/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210420205809-ac73e9fd8988/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1835,11 +1747,12 @@ golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210819135213-f52c844e1c1c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211105183446-c75c47738b0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1861,24 +1774,29 @@ golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34= -golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= +golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.29.0 h1:TPYlXGxvx1MGTn2GiZDhnjPA9wZzZeGKHHmKhHYvgaU= +golang.org/x/sys v0.29.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc= golang.org/x/term v0.4.0/go.mod h1:9P2UbLfCdcvo3p/nzKvsmas4TnlujnuoV9hGgYzW1lQ= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= -golang.org/x/term v0.24.0 h1:Mh5cbb+Zk2hqqXNO7S1iTjEphVL+jb8ZWaqh/g+JWkM= -golang.org/x/term v0.24.0/go.mod h1:lOBK/LVxemqiMij05LGJ0tzNr8xlmwBRJ81PX6wVLH8= +golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= +golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= +golang.org/x/term v0.12.0/go.mod h1:owVbMEjm3cBLCHdkQu9b1opXd4ETQWc3BhuQGKgXgvU= +golang.org/x/term v0.13.0/go.mod h1:LTmsnFJwVN6bCy1rVCoS+qHT1HhALEFxKncY3WNNh4U= +golang.org/x/term v0.28.0 h1:/Ts8HFuMR2E6IP/jlo7QVLZHggjKQbhu/7H0LJFr3Gg= +golang.org/x/term v0.28.0/go.mod h1:Sw/lC2IAUZ92udQNf3WodGtn4k/XoLyZoh8v/8uiwek= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1888,29 +1806,28 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.19.0 h1:kTxAhCbGbxhK0IwgSKiMO5awPoDQ0RpfiVYBfK860YM= -golang.org/x/text v0.19.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= +golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= +golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= +golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/text v0.22.0 h1:bofq7m3/HAFvbF51jz3Q9wLg3jkvSPuiZu/pD1XwgtM= +golang.org/x/text v0.22.0/go.mod h1:YRoo4H8PVmsu+E3Ou7cqLVH8oXWIHVoX0jqUWALQhfY= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.6.0 h1:eTDhh4ZXt5Qf0augr54TN6suAUudPcawVZeIAPU7D4U= golang.org/x/time v0.6.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190321232350-e250d351ecad/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= @@ -1920,8 +1837,10 @@ golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBn golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190910044552-dd2b5c81c578/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191108193012-7d206e10da11/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -1933,11 +1852,11 @@ golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtn golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200103221440-774c71fcf114/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200108203644-89082a384178/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= +golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= @@ -1971,15 +1890,16 @@ golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.2.0/go.mod h1:y4OqIKeOV/fWJetJ8bXPU1sEVniLMIyDAZWeHdV+NTA= golang.org/x/tools v0.3.0/go.mod h1:/rWhSS2+zyEVwoJf8YAX6L2f0ntZ7Kn/mGgAWcipA5k= golang.org/x/tools v0.5.0/go.mod h1:N+Kgy78s5I24c24dU8OfWNEotWjutIs8SnJvn5IDq+k= golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/tools v0.24.0 h1:J1shsA93PJUEVaUSaay7UXAyE8aimq3GW0pjlolpa24= -golang.org/x/tools v0.24.0/go.mod h1:YhNqVBIfWHdzvTLs0d8LCuMhkKUgSUKldakyV7W/WDQ= +golang.org/x/tools v0.7.0/go.mod h1:4pg6aUX35JBAogB10C9AtvVL+qowtN4pT3CGSQex14s= +golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= +golang.org/x/tools v0.14.0/go.mod h1:uYBEerGOWcJyEORxN+Ek8+TT266gXkNlHdJBwexUsBg= +golang.org/x/tools v0.29.0 h1:Xx0h3TtM9rzQpQuR4dKLrdglAmCEN5Oi+P74JdhdzXE= +golang.org/x/tools v0.29.0/go.mod h1:KMQVMRsVxU6nHCFXrBPhDB8XncLNLM0lIy/F14RP588= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1988,12 +1908,6 @@ golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= -gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= -gonum.org/v1/gonum v0.0.0-20181121035319-3f7ecaa7e8ca/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= -gonum.org/v1/gonum v0.6.0/go.mod h1:9mxDZsDKxgMAuccQkewq682L+0eCu4dCN2yonUJTCLU= -gonum.org/v1/netlib v0.0.0-20181029234149-ec6d1f5cefe6/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= -gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= -gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc= google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= @@ -2043,8 +1957,8 @@ google.golang.org/api v0.96.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ google.golang.org/api v0.97.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.98.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.100.0/go.mod h1:ZE3Z2+ZOr87Rx7dqFsdRQkRBk36kDtp/h+QpHbB7a70= -google.golang.org/api v0.196.0 h1:k/RafYqebaIJBO3+SMnfEGtFVlvp5vSgqTUF54UN/zg= -google.golang.org/api v0.196.0/go.mod h1:g9IL21uGkYgvQ5BZg6BAtoGJQIm8r6EgaAbpNey5wBE= +google.golang.org/api v0.198.0 h1:OOH5fZatk57iN0A7tjJQzt6aPfYQ1JiWkt1yGseazks= +google.golang.org/api v0.198.0/go.mod h1:/Lblzl3/Xqqk9hw/yS97TImKTUwnf1bv89v7+OagJzc= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -2060,7 +1974,6 @@ google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRn google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190530194941-fb225487d101/go.mod h1:z3L6/3dTEVtUr6QSP8miRzeRqwQOioJ9I66odjN4I7s= -google.golang.org/genproto v0.0.0-20190716160619-c506a9f90610/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= @@ -2068,7 +1981,6 @@ google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvx google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20200108215221-bd8f9a0ef82f/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA= @@ -2163,10 +2075,10 @@ google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1 h1:BulPr26Jqjnd4eYDVe+YvyR7Yc2vJGkO5/0UxD0/jZU= google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:hL97c3SYopEHblzpxRL4lSs523++l8DYxGM1FQiYmb4= -google.golang.org/genproto/googleapis/api v0.0.0-20241021214115-324edc3d5d38 h1:2oV8dfuIkM1Ti7DwXc0BJfnwr9csz4TDXI9EmiI+Rbw= -google.golang.org/genproto/googleapis/api v0.0.0-20241021214115-324edc3d5d38/go.mod h1:vuAjtvlwkDKF6L1GQ0SokiRLCGFfeBUXWr/aFFkHACc= -google.golang.org/genproto/googleapis/rpc v0.0.0-20241021214115-324edc3d5d38 h1:zciRKQ4kBpFgpfC5QQCVtnnNAcLIqweL7plyZRQHVpI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20241021214115-324edc3d5d38/go.mod h1:GX3210XPVPUjJbTUbvwI8f2IpZDMZuPJWDzDuebbviI= +google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489 h1:fCuMM4fowGzigT89NCIsW57Pk9k2D12MMi2ODn+Nk+o= +google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489/go.mod h1:iYONQfRdizDB8JJBybql13nArx91jcUk7zCXEsOofM4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250204164813-702378808489 h1:5bKytslY8ViY0Cj/ewmRtrWHW64bNF03cAatUUFCdFI= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250204164813-702378808489/go.mod h1:8BS3B93F/U1juMFq9+EDk+qOT5CO1R9IzXxG3PTqiRk= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= @@ -2208,9 +2120,11 @@ google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACu google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= -google.golang.org/grpc v1.67.1 h1:zWnc1Vrcno+lHZCOofnIMvycFcc0QRGIzm9dhnDX68E= -google.golang.org/grpc v1.67.1/go.mod h1:1gLDyUQU7CTLJI90u3nXZ9ekeghjeM7pTDZlqFNg2AA= +google.golang.org/grpc v1.70.0 h1:pWFv03aZoHzlRKHWicjsZytKAiYCtNS0dHbXnIdq7jQ= +google.golang.org/grpc v1.70.0/go.mod h1:ofIJqVKDXx/JiXrwr2IG4/zwdH9txy3IlF40RmcJSQw= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= +google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.5.1 h1:F29+wU6Ee6qgu9TddPgooOdaqsxTMunOoj8KA5yuS5A= +google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.5.1/go.mod h1:5KF+wpkbTSbGcR9zteSqZV6fqFOWBl4Yde8En8MryZA= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= @@ -2226,8 +2140,8 @@ google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQ google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.35.1 h1:m3LfL6/Ca+fqnjnlqQXNpFPABW1UD7mjh8KO2mKFytA= -google.golang.org/protobuf v1.35.1/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= +google.golang.org/protobuf v1.36.5 h1:tPhr+woSbjfYvY6/GPufUoYizxw1cF/yFoxJ2fmpwlM= +google.golang.org/protobuf v1.36.5/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -2242,12 +2156,9 @@ gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMy gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce/go.mod h1:5AcXVHNjg+BDxry382+8OKon8SEWiKktQR07RKPsv1c= -gopkg.in/olebedev/go-duktape.v3 v3.0.0-20200619000410-60c24ae608a6/go.mod h1:uAJfkITjFhyEEuUfm7bsmCZRbW5WRq8s9EY8HZ6hCns= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/urfave/cli.v1 v1.20.0/go.mod h1:vuBzUtMdQeixQj8LVd+/98pzhxNGQoyuPBlsXHOQNO0= gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -2263,10 +2174,8 @@ gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= -gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= -gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= +gotest.tools/v3 v3.5.2 h1:7koQfIKdy+I8UTetycgUqXWSDwpgv193Ka+qRsmBY8Q= +gotest.tools/v3 v3.5.2/go.mod h1:LtdLGcnqToBH83WByAAi/wiwSFCArdFIUV/xxN4pcjA= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -2275,7 +2184,6 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= honnef.co/go/tools v0.5.1 h1:4bH5o3b5ZULQ4UrBmP+63W9r7qIkqJClEA9ko5YKx+I= honnef.co/go/tools v0.5.1/go.mod h1:e9irvo83WDG9/irijV44wr3tbhcFeRnfpVlRqVwpzMs= mvdan.cc/gofumpt v0.7.0 h1:bg91ttqXmi9y2xawvkuMXyvAA/1ZGJqYAEGjXuP0JXU= @@ -2283,15 +2191,14 @@ mvdan.cc/gofumpt v0.7.0/go.mod h1:txVFJy/Sc/mvaycET54pV8SW8gWxTlUuGHVEcncmNUo= mvdan.cc/unparam v0.0.0-20240528143540-8a5130ca722f h1:lMpcwN6GxNbWtbpI1+xzFLSW8XzX0u72NttUGVFjO3U= mvdan.cc/unparam v0.0.0-20240528143540-8a5130ca722f/go.mod h1:RSLa7mKKCNeTTMHBw5Hsy2rfJmd6O2ivt9Dw9ZqCQpQ= nhooyr.io/websocket v1.8.6/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= -nhooyr.io/websocket v1.8.7 h1:usjR2uOr/zjjkVMy0lW+PPohFok7PCow5sDjLgX4P4g= -nhooyr.io/websocket v1.8.7/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= +nhooyr.io/websocket v1.8.11 h1:f/qXNc2/3DpoSZkHt1DQu6rj4zGC8JmkkLkWss0MgN0= +nhooyr.io/websocket v1.8.11/go.mod h1:rN9OFWIUwuxg4fR5tELlYC04bXYowCP9GX47ivo2l+c= +nullprogram.com/x/optparse v1.0.0/go.mod h1:KdyPE+Igbe0jQUrVfMqDMeJQIJZEuyV7pjYmp6pbG50= pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw= pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= -rsc.io/pdf v0.1.1/go.mod h1:n8OzWcQ6Sp37PL01nO98y4iUCRdTGarVfzxY20ICaU4= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= -rsc.io/tmplfunc v0.0.3/go.mod h1:AG3sTPzElb1Io3Yg4voV9AGZJuleGAwaVRxL9M49PhA= sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o= sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= From d9526483dff0509468e12df1d904ac1724cce442 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Mon, 10 Feb 2025 16:29:48 +0300 Subject: [PATCH 04/16] feat: upgrade proto generator scripts and versions --- Makefile | 11 ++++++---- buf.gen.yaml | 8 ------- docs/docs.go | 40 +++++++++++++++++++++++++++++++++++ docs/static/openapi.yml | 1 + docs/template/index.tpl | 28 ++++++++++++++++++++++++ proto/Dockerfile | 38 --------------------------------- proto/buf.gen.gogo.yaml | 9 ++++++-- proto/buf.gen.pulsar.yaml | 18 ++++++++++++++++ proto/buf.gen.sta.yaml | 10 +++++++++ proto/buf.gen.swagger.yaml | 9 ++++++++ proto/buf.gen.ts.yaml | 13 ++++++++++++ proto/buf.lock | 28 ++++++++++++++++++++---- proto/buf.yaml | 40 ++++++++++++++++++----------------- scripts/mockgen.sh | 4 ++++ scripts/protoc-swagger-gen.sh | 23 ++++++++++++++++++++ scripts/protocgen-pulsar.sh | 8 +++++++ scripts/protocgen.sh | 28 +++++++++++++++++++++--- 17 files changed, 238 insertions(+), 78 deletions(-) delete mode 100644 buf.gen.yaml create mode 100644 docs/docs.go create mode 100644 docs/static/openapi.yml create mode 100644 docs/template/index.tpl delete mode 100644 proto/Dockerfile create mode 100644 proto/buf.gen.pulsar.yaml create mode 100644 proto/buf.gen.sta.yaml create mode 100644 proto/buf.gen.swagger.yaml create mode 100644 proto/buf.gen.ts.yaml create mode 100755 scripts/mockgen.sh create mode 100755 scripts/protoc-swagger-gen.sh create mode 100755 scripts/protocgen-pulsar.sh diff --git a/Makefile b/Makefile index b695d8cf..95605425 100644 --- a/Makefile +++ b/Makefile @@ -192,6 +192,11 @@ clean: distclean: clean rm -rf vendor/ +mocks: $(MOCKS_DIR) + @go install github.com/golang/mock/mockgen@v1.6.0 + sh ./scripts/mockgen.sh +.PHONY: mocks + ############################################################################### ### Proto ### ############################################################################### @@ -216,14 +221,12 @@ docs: @echo .PHONY: docs -protoVer=0.13.1 +protoVer=0.15.1 protoImageName=ghcr.io/cosmos/proto-builder:$(protoVer) protoImage=$(DOCKER) run --rm -v $(CURDIR):/workspace --workdir /workspace $(protoImageName) -# containerProtoGen=cosmos-sdk-proto-gen-$(protoVer) -# containerProtoFmt=cosmos-sdk-proto-fmt-$(protoVer) proto-gen: - @echo "Generating Protobuf files" + @echo "Generating protobuf files..." @$(protoImage) sh ./scripts/protocgen.sh proto-swagger-gen: diff --git a/buf.gen.yaml b/buf.gen.yaml deleted file mode 100644 index aaa7db84..00000000 --- a/buf.gen.yaml +++ /dev/null @@ -1,8 +0,0 @@ -version: v1 -plugins: - - name: gocosmos - out: . - opt: plugins=interfacetype+grpc,Mgoogle/protobuf/any.proto=github.com/cosmos/cosmos-sdk/codec/types - - name: grpc-gateway - out: . - opt: logtostderr=true,allow_colon_final_segments=true \ No newline at end of file diff --git a/docs/docs.go b/docs/docs.go new file mode 100644 index 00000000..b1f68a63 --- /dev/null +++ b/docs/docs.go @@ -0,0 +1,40 @@ +package docs + +import ( + "embed" + httptemplate "html/template" + "net/http" + + "github.com/gorilla/mux" +) + +const ( + apiFile = "/static/openapi.yml" + indexFile = "template/index.tpl" +) + +//go:embed static +var Static embed.FS + +//go:embed template +var template embed.FS + +func RegisterOpenAPIService(appName string, rtr *mux.Router) { + rtr.Handle(apiFile, http.FileServer(http.FS(Static))) + rtr.HandleFunc("/", handler(appName)) +} + +// handler returns an http handler that servers OpenAPI console for an OpenAPI spec at specURL. +func handler(title string) http.HandlerFunc { + t, _ := httptemplate.ParseFS(template, indexFile) + + return func(w http.ResponseWriter, _ *http.Request) { + _ = t.Execute(w, struct { + Title string + URL string + }{ + title, + apiFile, + }) + } +} diff --git a/docs/static/openapi.yml b/docs/static/openapi.yml new file mode 100644 index 00000000..347c5ac8 --- /dev/null +++ b/docs/static/openapi.yml @@ -0,0 +1 @@ +{"id":"wasmapp","consumes":["application/json"],"produces":["application/json"],"swagger":"2.0","info":{"description":"Chain wasmapp REST API","title":"HTTP API Console","contact":{"name":"wasmapp"},"version":"version not set"},"paths":{"/wasmapp.mymodule.Msg/UpdateParams":{"post":{"tags":["Msg"],"summary":"UpdateParams defines a (governance) operation for updating the module\nparameters. The authority defaults to the x/gov module account.","operationId":"WasmappMsg_UpdateParams","parameters":[{"description":"MsgUpdateParams is the Msg/UpdateParams request type.","name":"body","in":"body","required":true,"schema":{"$ref":"#/definitions/wasmapp.mymodule.MsgUpdateParams"}}],"responses":{"200":{"description":"A successful response.","schema":{"$ref":"#/definitions/wasmapp.mymodule.MsgUpdateParamsResponse"}},"default":{"description":"An unexpected error response.","schema":{"$ref":"#/definitions/google.rpc.Status"}}}}},"/wasmapp/mymodule/params":{"get":{"tags":["Query"],"summary":"Parameters queries the parameters of the module.","operationId":"WasmappQuery_Params","responses":{"200":{"description":"A successful response.","schema":{"$ref":"#/definitions/wasmapp.mymodule.QueryParamsResponse"}},"default":{"description":"An unexpected error response.","schema":{"$ref":"#/definitions/google.rpc.Status"}}}}}},"definitions":{"google.protobuf.Any":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}},"google.rpc.Status":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"details":{"type":"array","items":{"type":"object","$ref":"#/definitions/google.protobuf.Any"}},"message":{"type":"string"}}},"wasmapp.mymodule.MsgUpdateParams":{"description":"MsgUpdateParams is the Msg/UpdateParams request type.","type":"object","properties":{"authority":{"description":"authority is the address that controls the module (defaults to x/gov unless overwritten).","type":"string"},"params":{"description":"params defines the module parameters to update.\n\nNOTE: All parameters must be supplied.","$ref":"#/definitions/wasmapp.mymodule.Params"}}},"wasmapp.mymodule.MsgUpdateParamsResponse":{"description":"MsgUpdateParamsResponse defines the response structure for executing a\nMsgUpdateParams message.","type":"object"},"wasmapp.mymodule.Params":{"description":"Params defines the parameters for the module.","type":"object"},"wasmapp.mymodule.QueryParamsResponse":{"description":"QueryParamsResponse is response type for the Query/Params RPC method.","type":"object","properties":{"params":{"description":"params holds all the parameters of this module.","$ref":"#/definitions/wasmapp.mymodule.Params"}}}},"tags":[{"name":"Query"},{"name":"Msg"}]} \ No newline at end of file diff --git a/docs/template/index.tpl b/docs/template/index.tpl new file mode 100644 index 00000000..ec098e82 --- /dev/null +++ b/docs/template/index.tpl @@ -0,0 +1,28 @@ + + + + + {{ .Title }} + + + + +
+ + + + + +Footer +© 2022 GitHub, Inc. +Footer navigation diff --git a/proto/Dockerfile b/proto/Dockerfile deleted file mode 100644 index 0e699d8d..00000000 --- a/proto/Dockerfile +++ /dev/null @@ -1,38 +0,0 @@ -# This Dockerfile is used for proto generation -# To build, run `make proto-image-build` - -FROM bufbuild/buf:1.9.0 as BUILDER - -FROM golang:1.23-alpine3.20 - -RUN apk add --no-cache \ - nodejs \ - npm \ - git \ - make - -ENV GOLANG_PROTOBUF_VERSION=1.28.1 \ - GOGO_PROTOBUF_VERSION=1.3.2 \ - GRPC_GATEWAY_VERSION=1.16.0 - - -RUN go install github.com/cosmos/cosmos-proto/cmd/protoc-gen-go-pulsar@latest -RUN go install google.golang.org/protobuf/cmd/protoc-gen-go@v${GOLANG_PROTOBUF_VERSION} -RUN go install github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway@v${GRPC_GATEWAY_VERSION} \ - github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger@v${GRPC_GATEWAY_VERSION} - -# install all gogo protobuf binaries -RUN git clone https://github.com/regen-network/protobuf.git; \ - cd protobuf; \ - go mod download; \ - make install - -# we need to use git clone because we use 'replace' directive in go.mod -# protoc-gen-gocosmos was moved to to in cosmos/gogoproto but pending a migration there. -RUN git clone https://github.com/regen-network/cosmos-proto.git; \ - cd cosmos-proto/protoc-gen-gocosmos; \ - go install . - -RUN npm install -g swagger-combine - -COPY --from=BUILDER /usr/local/bin /usr/local/bin diff --git a/proto/buf.gen.gogo.yaml b/proto/buf.gen.gogo.yaml index 32b6adda..9d53ba67 100644 --- a/proto/buf.gen.gogo.yaml +++ b/proto/buf.gen.gogo.yaml @@ -2,7 +2,12 @@ version: v1 plugins: - name: gocosmos out: .. - opt: plugins=plugins=interfacetype+grpc,Mgoogle/protobuf/any.proto=github.com/cosmos/cosmos-sdk/codec/types + opt: + - plugins=grpc + - Mgoogle/protobuf/any.proto=github.com/cosmos/cosmos-sdk/codec/types + - Mcosmos/orm/v1/orm.proto=cosmossdk.io/orm - name: grpc-gateway out: .. - opt: logtostderr=true,allow_colon_final_segments=true + opt: + - logtostderr=true + - allow_colon_final_segments=true diff --git a/proto/buf.gen.pulsar.yaml b/proto/buf.gen.pulsar.yaml new file mode 100644 index 00000000..ea09dd34 --- /dev/null +++ b/proto/buf.gen.pulsar.yaml @@ -0,0 +1,18 @@ +version: v1 +managed: + enabled: true + go_package_prefix: + default: github.com/sge-network/sge/api + except: + - buf.build/googleapis/googleapis + - buf.build/cosmos/gogo-proto + - buf.build/cosmos/cosmos-proto + override: + buf.build/cosmos/cosmos-sdk: cosmossdk.io/api +plugins: + - name: go-pulsar + out: ../api + opt: paths=source_relative + - name: go-grpc + out: ../api + opt: paths=source_relative diff --git a/proto/buf.gen.sta.yaml b/proto/buf.gen.sta.yaml new file mode 100644 index 00000000..6f8cac83 --- /dev/null +++ b/proto/buf.gen.sta.yaml @@ -0,0 +1,10 @@ +version: v1 +plugins: + - name: openapiv2 + out: . + opt: + - logtostderr=true + - openapi_naming_strategy=simple + - ignore_comments=true + - simple_operation_ids=false + - json_names_for_fields=false diff --git a/proto/buf.gen.swagger.yaml b/proto/buf.gen.swagger.yaml new file mode 100644 index 00000000..ebc65417 --- /dev/null +++ b/proto/buf.gen.swagger.yaml @@ -0,0 +1,9 @@ +version: v1 +plugins: + - name: openapiv2 + out: . + opt: + - logtostderr=true + - openapi_naming_strategy=fqn + - json_names_for_fields=false + - generate_unbound_methods=true \ No newline at end of file diff --git a/proto/buf.gen.ts.yaml b/proto/buf.gen.ts.yaml new file mode 100644 index 00000000..9681708c --- /dev/null +++ b/proto/buf.gen.ts.yaml @@ -0,0 +1,13 @@ +version: v1 +managed: + enabled: true +plugins: + - plugin: buf.build/community/stephenh-ts-proto + out: . + opt: + - logtostderr=true + - allow_merge=true + - json_names_for_fields=false + - ts_proto_opt=snakeToCamel=true + - ts_proto_opt=esModuleInterop=true + - ts_proto_out=. diff --git a/proto/buf.lock b/proto/buf.lock index da17c5df..ac7608a8 100644 --- a/proto/buf.lock +++ b/proto/buf.lock @@ -1,6 +1,11 @@ # Generated by buf. DO NOT EDIT. version: v1 deps: + - remote: buf.build + owner: cometbft + repository: cometbft + commit: c0d3497e35d649538679874acdd86660 + digest: shake256:05d2fb9e6b6bf82385ac26b250afbba281a2ca79f51729291373d24ca676d743183bf70a921daae6feafd5f9917120e2548a7c477d9743f668bca27cc1e12fdf - remote: buf.build owner: cosmos repository: cosmos-proto @@ -16,16 +21,31 @@ deps: repository: gogo-proto commit: 88ef6483f90f478fb938c37dde52ece3 digest: shake256:89c45df2aa11e0cff97b0d695436713db3d993d76792e9f8dc1ae90e6ab9a9bec55503d48ceedd6b86069ab07d3041b32001b2bfe0227fa725dd515ff381e5ba + - remote: buf.build + owner: cosmos + repository: ibc + commit: baf134b1c13a45e9903beeba3b2a92ec + digest: shake256:0069c2b35e359966bfe3f30ec98bc76180f277eb6fe722cdc6d20e68257d9b888db3b801c9fdc8ae1014439d786420f21ba2147d8fee7b1dc1dc748ff84e1fe4 + - remote: buf.build + owner: cosmos + repository: ics23 + commit: dc427cb4519143d8996361c045a29ad7 + digest: shake256:f6611c56170e2cb6354fa6e367a225fed7b8b0defca3252f05e842fe311be46997680ebf57d8644b52c1f2cca49b366ffe89ce5e8db5fd055a15259c88e4e41e + - remote: buf.build + owner: cosmwasm + repository: wasmd + commit: 193990ad71b74a7cbc0acf56bb2e808b + digest: shake256:83c37b5591f7d8cc99e46bdd25c40cb19754ba8ebd2f191d99b7586c6bea45050a459ce1ace9539381cfae32f3ae1cedf0f7f9bbfbfbc7d750dcb8b9535d41a7 - remote: buf.build owner: googleapis repository: googleapis - commit: f52d4f76a8434cc5966798b1d3b4f110 - digest: shake256:71566dd80e39b7d85fdaa9b7f82107385181d5b6d17ea56c0aacce61099b35f9f1bcf7333ad9838ca19d24d7f076b039de7c9c09c55d23bb4c2fddfceff4d2c2 + commit: e93e34f48be043dab55be31b4b47f458 + digest: shake256:93dbe51c27606999eef918360df509485a4d272e79aaed6d0016940379a9b06d316fc5228b7b50cca94bb310f34c5fc5955ce7474f655f0d0a224c4121dda3c1 - remote: buf.build owner: protocolbuffers repository: wellknowntypes - commit: 657250e6a39648cbb169d079a60bd9ba - digest: shake256:00de25001b8dd2e29d85fc4bcc3ede7aed886d76d67f5e0f7a9b320b90f871d3eb73507d50818d823a0512f3f8db77a11c043685528403e31ff3fef18323a9fb + commit: d4f14e5e0a9c40889c90d373c74e95eb + digest: shake256:c9824714afd6cc432c2e1fafa20df47c87a8a0aca9e27192cd5732619453997af1721c2eac5c0fbbe7b29a741af5b8d7ba4ee89c85903e782d9c725d7b9436b5 - remote: buf.build owner: tendermint repository: tendermint diff --git a/proto/buf.yaml b/proto/buf.yaml index 555c7bbf..db285eb8 100644 --- a/proto/buf.yaml +++ b/proto/buf.yaml @@ -1,24 +1,26 @@ -version: v1 -name: buf.build/sge-network/sge -deps: - - buf.build/cosmos/cosmos-sdk - - buf.build/cosmos/cosmos-proto - - buf.build/cosmos/gogo-proto - - buf.build/googleapis/googleapis breaking: use: - - FILE + - FILE +deps: +- buf.build/protocolbuffers/wellknowntypes +- buf.build/cosmos/cosmos-sdk +- buf.build/cosmos/cosmos-proto +- buf.build/cosmos/gogo-proto +- buf.build/googleapis/googleapis +- buf.build/cosmos/ics23 +- buf.build/cosmos/ibc +- buf.build/cosmwasm/wasmd lint: - use: - - DEFAULT - - COMMENTS - - FILE_LOWER_SNAKE_CASE except: - - PACKAGE_DIRECTORY_MATCH - - UNARY_RPC - - COMMENT_FIELD - - SERVICE_SUFFIX - - PACKAGE_VERSION_SUFFIX - - RPC_REQUEST_STANDARD_NAME + - UNARY_RPC + - COMMENT_FIELD + - SERVICE_SUFFIX + - PACKAGE_VERSION_SUFFIX + - RPC_REQUEST_STANDARD_NAME ignore: - - tendermint + - tendermint + use: + - DEFAULT + - COMMENTS + - FILE_LOWER_SNAKE_CASE +version: v1 diff --git a/scripts/mockgen.sh b/scripts/mockgen.sh new file mode 100755 index 00000000..33145a7a --- /dev/null +++ b/scripts/mockgen.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash + +mockgen_cmd="mockgen" +$mockgen_cmd -source=x/mint/types/expected_keepers.go -package testutil -destination x/mint/testutil/expected_keepers_mocks.go \ No newline at end of file diff --git a/scripts/protoc-swagger-gen.sh b/scripts/protoc-swagger-gen.sh new file mode 100755 index 00000000..9edbc2d0 --- /dev/null +++ b/scripts/protoc-swagger-gen.sh @@ -0,0 +1,23 @@ +#!/usr/bin/env bash + +set -eo pipefail + +mkdir -p ./tmp-swagger-gen +cd proto +proto_dirs=$(find ./cosmos -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq) +for dir in $proto_dirs; do + # generate swagger files (filter query files) + query_file=$(find "${dir}" -maxdepth 1 \( -name 'query.proto' -o -name 'service.proto' \)) + if [[ ! -z "$query_file" ]]; then + buf generate --template buf.gen.swagger.yaml $query_file + fi +done + +cd .. +# combine swagger files +# uses nodejs package `swagger-combine`. +# all the individual swagger files need to be configured in `config.json` for merging +swagger-combine ./client/docs/config.json -o ./client/docs/swagger-ui/swagger.yaml -f yaml --continueOnConflictingPaths true --includeDefinitions true + +# clean swagger files +rm -rf ./tmp-swagger-gen diff --git a/scripts/protocgen-pulsar.sh b/scripts/protocgen-pulsar.sh new file mode 100755 index 00000000..93198eec --- /dev/null +++ b/scripts/protocgen-pulsar.sh @@ -0,0 +1,8 @@ +# this script is for generating protobuf files for the new google.golang.org/protobuf API +set -eo pipefail + +echo "Cleaning API directory" +(cd api; find ./ -type f \( -iname \*.pulsar.go -o -iname \*.pb.go -o -iname \*.cosmos_orm.go -o -iname \*.pb.gw.go \) -delete; find . -empty -type d -delete; cd ..) + +echo "Generating API module" +(cd proto; buf generate --template buf.gen.pulsar.yaml) diff --git a/scripts/protocgen.sh b/scripts/protocgen.sh index e40db694..507439a8 100755 --- a/scripts/protocgen.sh +++ b/scripts/protocgen.sh @@ -1,15 +1,37 @@ #!/usr/bin/env bash -set -eo pipefail +# How to run manually: +# docker build --pull --rm -f "contrib/devtools/Dockerfile" -t cosmossdk-proto:latest "contrib/devtools" +# docker run --rm -v $(pwd):/workspace --workdir /workspace cosmossdk-proto sh ./scripts/protocgen.sh + +echo "Formatting protobuf files" +find ./ -name "*.proto" -exec clang-format -i {} \; + +set -e echo "Generating gogo proto code" cd proto -buf mod update +proto_dirs=$(find ./sge -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq) +for dir in $proto_dirs; do + for file in $(find "${dir}" -maxdepth 1 -name '*.proto'); do + # this regex checks if a proto file has its go_package set to cosmossdk.io/api/... + # gogo proto files SHOULD ONLY be generated if this is false + # we don't want gogo proto to run for proto files which are natively built for google.golang.org/protobuf + if grep -q "option go_package" "$file" && grep -H -o -c 'option go_package.*cosmossdk.io/api' "$file" | grep -q ':0$'; then + buf generate --template buf.gen.gogo.yaml $file + fi + done +done + cd .. -buf generate + # move proto files to the right places cp -r ./github.com/sge-network/sge/x/* x/ cp -r ./github.com/sge-network/sge/types/* types/ rm -rf ./github.com + +./scripts/protocgen-pulsar.sh + +go mod tidy \ No newline at end of file From 08e5ec9874fab64a14ad4fff0d9858b3d9a645b8 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Mon, 10 Feb 2025 16:31:21 +0300 Subject: [PATCH 05/16] feat: define pulsar proto files and set old types in legacy --- api/sge/legacy/bet/module/v1/module.pulsar.go | 654 + api/sge/legacy/bet/v1beta/bet.pulsar.go | 4691 +++++ api/sge/legacy/bet/v1beta/bet_odds.pulsar.go | 1366 ++ .../legacy/bet/v1beta/constraints.pulsar.go | 654 + api/sge/legacy/bet/v1beta/genesis.pulsar.go | 1312 ++ api/sge/legacy/bet/v1beta/odds_type.pulsar.go | 159 + api/sge/legacy/bet/v1beta/params.pulsar.go | 721 + api/sge/legacy/bet/v1beta/query.pulsar.go | 8191 +++++++++ api/sge/legacy/bet/v1beta/query_grpc.pb.go | 345 + api/sge/legacy/bet/v1beta/stats.pulsar.go | 556 + api/sge/legacy/bet/v1beta/ticket.pulsar.go | 1020 ++ api/sge/legacy/bet/v1beta/tx.pulsar.go | 2165 +++ api/sge/legacy/bet/v1beta/tx_grpc.pb.go | 158 + api/sge/legacy/bet/v1beta/wager.pulsar.go | 726 + .../legacy/house/module/v1/module.pulsar.go | 655 + api/sge/legacy/house/v1beta/authz.pulsar.go | 1055 ++ api/sge/legacy/house/v1beta/deposit.pulsar.go | 1021 ++ api/sge/legacy/house/v1beta/genesis.pulsar.go | 914 + api/sge/legacy/house/v1beta/params.pulsar.go | 723 + api/sge/legacy/house/v1beta/query.pulsar.go | 5813 +++++++ api/sge/legacy/house/v1beta/query_grpc.pb.go | 267 + api/sge/legacy/house/v1beta/ticket.pulsar.go | 1253 ++ api/sge/legacy/house/v1beta/tx.pulsar.go | 3790 +++++ api/sge/legacy/house/v1beta/tx_grpc.pb.go | 206 + .../legacy/house/v1beta/withdraw.pulsar.go | 1062 ++ .../legacy/market/module/v1/module.pulsar.go | 656 + .../legacy/market/v1beta/genesis.pulsar.go | 855 + api/sge/legacy/market/v1beta/market.pulsar.go | 1425 ++ api/sge/legacy/market/v1beta/odds.pulsar.go | 650 + api/sge/legacy/market/v1beta/params.pulsar.go | 502 + api/sge/legacy/market/v1beta/query.pulsar.go | 4376 +++++ api/sge/legacy/market/v1beta/query_grpc.pb.go | 228 + api/sge/legacy/market/v1beta/stats.pulsar.go | 636 + api/sge/legacy/market/v1beta/ticket.pulsar.go | 2388 +++ api/sge/legacy/market/v1beta/tx.pulsar.go | 4474 +++++ api/sge/legacy/market/v1beta/tx_grpc.pb.go | 242 + .../orderbook/module/v1/module.pulsar.go | 657 + .../orderbook/v1beta/exposure.pulsar.go | 1756 ++ .../legacy/orderbook/v1beta/genesis.pulsar.go | 1813 ++ .../orderbook/v1beta/orderbook.pulsar.go | 835 + .../legacy/orderbook/v1beta/params.pulsar.go | 694 + .../orderbook/v1beta/participation.pulsar.go | 2970 ++++ .../legacy/orderbook/v1beta/query.pulsar.go | 14104 ++++++++++++++++ .../legacy/orderbook/v1beta/query_grpc.pb.go | 554 + .../legacy/orderbook/v1beta/stats.pulsar.go | 638 + api/sge/legacy/orderbook/v1beta/tx.pulsar.go | 1100 ++ api/sge/legacy/orderbook/v1beta/tx_grpc.pb.go | 116 + api/sge/legacy/ovm/module/v1/module.pulsar.go | 654 + api/sge/legacy/ovm/v1beta/genesis.pulsar.go | 954 ++ api/sge/legacy/ovm/v1beta/key_vault.pulsar.go | 633 + api/sge/legacy/ovm/v1beta/params.pulsar.go | 499 + api/sge/legacy/ovm/v1beta/proposal.pulsar.go | 1343 ++ api/sge/legacy/ovm/v1beta/query.pulsar.go | 4206 +++++ api/sge/legacy/ovm/v1beta/query_grpc.pb.go | 228 + api/sge/legacy/ovm/v1beta/stats.pulsar.go | 558 + api/sge/legacy/ovm/v1beta/ticket.pulsar.go | 1217 ++ api/sge/legacy/ovm/v1beta/tx.pulsar.go | 3210 ++++ api/sge/legacy/ovm/v1beta/tx_grpc.pb.go | 204 + api/sge/legacy/ovm/v1beta/vote.pulsar.go | 695 + .../legacy/reward/module/v1/module.pulsar.go | 656 + api/sge/legacy/reward/v1beta/authz.pulsar.go | 1533 ++ .../legacy/reward/v1beta/campaign.pulsar.go | 2633 +++ .../legacy/reward/v1beta/genesis.pulsar.go | 1531 ++ api/sge/legacy/reward/v1beta/params.pulsar.go | 501 + .../legacy/reward/v1beta/promoter.pulsar.go | 2510 +++ api/sge/legacy/reward/v1beta/query.pulsar.go | 11301 +++++++++++++ api/sge/legacy/reward/v1beta/query_grpc.pb.go | 464 + api/sge/legacy/reward/v1beta/reward.pulsar.go | 3266 ++++ api/sge/legacy/reward/v1beta/ticket.pulsar.go | 6279 +++++++ api/sge/legacy/reward/v1beta/tx.pulsar.go | 7521 ++++++++ api/sge/legacy/reward/v1beta/tx_grpc.pb.go | 368 + .../subaccount/module/v1/module.pulsar.go | 658 + .../subaccount/v1beta/balance.pulsar.go | 1415 ++ .../subaccount/v1beta/genesis.pulsar.go | 1622 ++ .../legacy/subaccount/v1beta/params.pulsar.go | 635 + .../legacy/subaccount/v1beta/query.pulsar.go | 2457 +++ .../legacy/subaccount/v1beta/query_grpc.pb.go | 150 + .../legacy/subaccount/v1beta/ticket.pulsar.go | 757 + api/sge/legacy/subaccount/v1beta/tx.pulsar.go | 7265 ++++++++ .../legacy/subaccount/v1beta/tx_grpc.pb.go | 372 + api/sge/legacy/type/v1beta/kyc.pulsar.go | 709 + api/sge/mint/module/v1/module.pulsar.go | 651 + api/sge/mint/v1beta/genesis.pulsar.go | 693 + api/sge/mint/v1beta/minter.pulsar.go | 797 + api/sge/mint/v1beta/params.pulsar.go | 869 + api/sge/mint/v1beta/phase.pulsar.go | 660 + api/sge/mint/v1beta/query.pulsar.go | 4541 +++++ api/sge/mint/v1beta/query_grpc.pb.go | 267 + api/sge/mint/v1beta/tx.pulsar.go | 1095 ++ api/sge/mint/v1beta/tx_grpc.pb.go | 117 + proto/sge/legacy/bet/module/v1/module.proto | 18 + .../bet => sge/legacy/bet/v1beta}/bet.proto | 10 +- .../legacy/bet/v1beta}/bet_odds.proto | 4 +- .../legacy/bet/v1beta}/constraints.proto | 4 +- .../legacy/bet/v1beta}/genesis.proto | 10 +- .../legacy/bet/v1beta}/odds_type.proto | 4 +- .../legacy/bet/v1beta}/params.proto | 6 +- .../bet => sge/legacy/bet/v1beta}/query.proto | 16 +- .../bet => sge/legacy/bet/v1beta}/stats.proto | 4 +- .../legacy/bet/v1beta}/ticket.proto | 13 +- .../bet => sge/legacy/bet/v1beta}/tx.proto | 8 +- .../bet => sge/legacy/bet/v1beta}/wager.proto | 4 +- proto/sge/legacy/house/module/v1/module.proto | 18 + .../legacy/house/v1beta}/authz.proto | 4 +- .../legacy/house/v1beta}/deposit.proto | 4 +- .../legacy/house/v1beta}/genesis.proto | 10 +- .../legacy/house/v1beta}/params.proto | 4 +- .../legacy/house/v1beta}/query.proto | 14 +- .../legacy/house/v1beta}/ticket.proto | 13 +- .../legacy/house/v1beta}/tx.proto | 8 +- .../legacy/house/v1beta}/withdraw.proto | 4 +- .../sge/legacy/market/module/v1/module.proto | 18 + .../legacy/market/v1beta}/genesis.proto | 10 +- .../legacy/market/v1beta}/market.proto | 8 +- .../legacy/market/v1beta}/odds.proto | 4 +- .../legacy/market/v1beta}/params.proto | 4 +- .../legacy/market/v1beta}/query.proto | 10 +- .../legacy/market/v1beta}/stats.proto | 4 +- .../legacy/market/v1beta}/ticket.proto | 9 +- .../legacy/market/v1beta}/tx.proto | 8 +- .../legacy/orderbook/module/v1/module.proto | 18 + .../legacy/orderbook/v1beta}/exposure.proto | 4 +- .../legacy/orderbook/v1beta}/genesis.proto | 14 +- .../legacy/orderbook/v1beta}/orderbook.proto | 4 +- .../legacy/orderbook/v1beta}/params.proto | 4 +- .../orderbook/v1beta}/participation.proto | 4 +- .../legacy/orderbook/v1beta}/query.proto | 12 +- .../legacy/orderbook/v1beta}/stats.proto | 4 +- .../legacy/orderbook/v1beta}/tx.proto | 6 +- proto/sge/legacy/ovm/module/v1/module.proto | 18 + .../legacy/ovm/v1beta}/genesis.proto | 12 +- .../legacy/ovm/v1beta}/key_vault.proto | 4 +- .../legacy/ovm/v1beta}/params.proto | 4 +- .../legacy/ovm/v1beta}/proposal.proto | 10 +- .../ovm => sge/legacy/ovm/v1beta}/query.proto | 10 +- .../ovm => sge/legacy/ovm/v1beta}/stats.proto | 4 +- .../legacy/ovm/v1beta}/ticket.proto | 6 +- .../ovm => sge/legacy/ovm/v1beta}/tx.proto | 6 +- .../ovm => sge/legacy/ovm/v1beta}/vote.proto | 4 +- .../sge/legacy/reward/module/v1/module.proto | 18 + .../legacy/reward/v1beta}/authz.proto | 4 +- .../legacy/reward/v1beta}/campaign.proto | 10 +- .../legacy/reward/v1beta}/genesis.proto | 12 +- .../legacy/reward/v1beta}/params.proto | 4 +- .../legacy/reward/v1beta}/promoter.proto | 10 +- .../legacy/reward/v1beta}/query.proto | 19 +- .../legacy/reward/v1beta}/reward.proto | 11 +- .../legacy/reward/v1beta}/ticket.proto | 19 +- .../legacy/reward/v1beta}/tx.proto | 6 +- .../legacy/subaccount/module/v1/module.proto | 18 + .../legacy/subaccount/v1beta}/balance.proto | 4 +- .../legacy/subaccount/v1beta}/genesis.proto | 12 +- .../legacy/subaccount/v1beta}/params.proto | 4 +- .../legacy/subaccount/v1beta}/query.proto | 27 +- .../legacy/subaccount/v1beta}/ticket.proto | 11 +- .../legacy/subaccount/v1beta}/tx.proto | 28 +- .../type => sge/legacy/type/v1beta}/kyc.proto | 6 +- proto/sge/mint/module/v1/module.proto | 18 + .../mint => sge/mint/v1beta}/genesis.proto | 13 +- .../sge/mint => sge/mint/v1beta}/minter.proto | 10 +- .../sge/mint => sge/mint/v1beta}/params.proto | 6 +- .../sge/mint => sge/mint/v1beta}/phase.proto | 5 +- .../sge/mint => sge/mint/v1beta}/query.proto | 17 +- .../sge/mint => sge/mint/v1beta}/tx.proto | 12 +- 164 files changed, 160275 insertions(+), 272 deletions(-) create mode 100644 api/sge/legacy/bet/module/v1/module.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/bet.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/bet_odds.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/constraints.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/genesis.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/odds_type.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/params.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/query.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/query_grpc.pb.go create mode 100644 api/sge/legacy/bet/v1beta/stats.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/ticket.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/tx.pulsar.go create mode 100644 api/sge/legacy/bet/v1beta/tx_grpc.pb.go create mode 100644 api/sge/legacy/bet/v1beta/wager.pulsar.go create mode 100644 api/sge/legacy/house/module/v1/module.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/authz.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/deposit.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/genesis.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/params.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/query.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/query_grpc.pb.go create mode 100644 api/sge/legacy/house/v1beta/ticket.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/tx.pulsar.go create mode 100644 api/sge/legacy/house/v1beta/tx_grpc.pb.go create mode 100644 api/sge/legacy/house/v1beta/withdraw.pulsar.go create mode 100644 api/sge/legacy/market/module/v1/module.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/genesis.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/market.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/odds.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/params.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/query.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/query_grpc.pb.go create mode 100644 api/sge/legacy/market/v1beta/stats.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/ticket.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/tx.pulsar.go create mode 100644 api/sge/legacy/market/v1beta/tx_grpc.pb.go create mode 100644 api/sge/legacy/orderbook/module/v1/module.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/exposure.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/genesis.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/orderbook.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/params.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/participation.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/query.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/query_grpc.pb.go create mode 100644 api/sge/legacy/orderbook/v1beta/stats.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/tx.pulsar.go create mode 100644 api/sge/legacy/orderbook/v1beta/tx_grpc.pb.go create mode 100644 api/sge/legacy/ovm/module/v1/module.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/genesis.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/key_vault.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/params.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/proposal.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/query.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/query_grpc.pb.go create mode 100644 api/sge/legacy/ovm/v1beta/stats.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/ticket.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/tx.pulsar.go create mode 100644 api/sge/legacy/ovm/v1beta/tx_grpc.pb.go create mode 100644 api/sge/legacy/ovm/v1beta/vote.pulsar.go create mode 100644 api/sge/legacy/reward/module/v1/module.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/authz.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/campaign.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/genesis.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/params.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/promoter.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/query.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/query_grpc.pb.go create mode 100644 api/sge/legacy/reward/v1beta/reward.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/ticket.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/tx.pulsar.go create mode 100644 api/sge/legacy/reward/v1beta/tx_grpc.pb.go create mode 100644 api/sge/legacy/subaccount/module/v1/module.pulsar.go create mode 100644 api/sge/legacy/subaccount/v1beta/balance.pulsar.go create mode 100644 api/sge/legacy/subaccount/v1beta/genesis.pulsar.go create mode 100644 api/sge/legacy/subaccount/v1beta/params.pulsar.go create mode 100644 api/sge/legacy/subaccount/v1beta/query.pulsar.go create mode 100644 api/sge/legacy/subaccount/v1beta/query_grpc.pb.go create mode 100644 api/sge/legacy/subaccount/v1beta/ticket.pulsar.go create mode 100644 api/sge/legacy/subaccount/v1beta/tx.pulsar.go create mode 100644 api/sge/legacy/subaccount/v1beta/tx_grpc.pb.go create mode 100644 api/sge/legacy/type/v1beta/kyc.pulsar.go create mode 100644 api/sge/mint/module/v1/module.pulsar.go create mode 100644 api/sge/mint/v1beta/genesis.pulsar.go create mode 100644 api/sge/mint/v1beta/minter.pulsar.go create mode 100644 api/sge/mint/v1beta/params.pulsar.go create mode 100644 api/sge/mint/v1beta/phase.pulsar.go create mode 100644 api/sge/mint/v1beta/query.pulsar.go create mode 100644 api/sge/mint/v1beta/query_grpc.pb.go create mode 100644 api/sge/mint/v1beta/tx.pulsar.go create mode 100644 api/sge/mint/v1beta/tx_grpc.pb.go create mode 100644 proto/sge/legacy/bet/module/v1/module.proto rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/bet.proto (96%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/bet_odds.proto (94%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/constraints.proto (82%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/genesis.proto (79%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/odds_type.proto (77%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/params.proto (78%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/query.proto (94%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/stats.proto (64%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/ticket.proto (67%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/tx.proto (90%) rename proto/{sgenetwork/sge/bet => sge/legacy/bet/v1beta}/wager.proto (84%) create mode 100644 proto/sge/legacy/house/module/v1/module.proto rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/authz.proto (85%) rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/deposit.proto (94%) rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/genesis.proto (67%) rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/params.proto (89%) rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/query.proto (94%) rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/ticket.proto (77%) rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/tx.proto (96%) rename proto/{sgenetwork/sge/house => sge/legacy/house/v1beta}/withdraw.proto (94%) create mode 100644 proto/sge/legacy/market/module/v1/module.proto rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/genesis.proto (66%) rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/market.proto (93%) rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/odds.proto (77%) rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/params.proto (67%) rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/query.proto (92%) rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/stats.proto (70%) rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/ticket.proto (92%) rename proto/{sgenetwork/sge/market => sge/legacy/market/v1beta}/tx.proto (94%) create mode 100644 proto/sge/legacy/orderbook/module/v1/module.proto rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/exposure.proto (95%) rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/genesis.proto (82%) rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/orderbook.proto (91%) rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/params.proto (87%) rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/participation.proto (98%) rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/query.proto (97%) rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/stats.proto (69%) rename proto/{sgenetwork/sge/orderbook => sge/legacy/orderbook/v1beta}/tx.proto (88%) create mode 100644 proto/sge/legacy/ovm/module/v1/module.proto rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/genesis.proto (69%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/key_vault.proto (65%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/params.proto (62%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/proposal.proto (90%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/query.proto (93%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/stats.proto (67%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/ticket.proto (80%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/tx.proto (95%) rename proto/{sgenetwork/sge/ovm => sge/legacy/ovm/v1beta}/vote.proto (80%) create mode 100644 proto/sge/legacy/reward/module/v1/module.proto rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/authz.proto (90%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/campaign.proto (94%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/genesis.proto (69%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/params.proto (61%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/promoter.proto (90%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/query.proto (95%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/reward.proto (95%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/ticket.proto (92%) rename proto/{sgenetwork/sge/reward => sge/legacy/reward/v1beta}/tx.proto (97%) create mode 100644 proto/sge/legacy/subaccount/module/v1/module.proto rename proto/{sgenetwork/sge/subaccount => sge/legacy/subaccount/v1beta}/balance.proto (93%) rename proto/{sgenetwork/sge/subaccount => sge/legacy/subaccount/v1beta}/genesis.proto (83%) rename proto/{sgenetwork/sge/subaccount => sge/legacy/subaccount/v1beta}/params.proto (75%) rename proto/{sgenetwork/sge/subaccount => sge/legacy/subaccount/v1beta}/query.proto (70%) rename proto/{sgenetwork/sge/subaccount => sge/legacy/subaccount/v1beta}/ticket.proto (74%) rename proto/{sgenetwork/sge/subaccount => sge/legacy/subaccount/v1beta}/tx.proto (87%) rename proto/{sgenetwork/sge/type => sge/legacy/type/v1beta}/kyc.proto (84%) create mode 100644 proto/sge/mint/module/v1/module.proto rename proto/{sgenetwork/sge/mint => sge/mint/v1beta}/genesis.proto (50%) rename proto/{sgenetwork/sge/mint => sge/mint/v1beta}/minter.proto (82%) rename proto/{sgenetwork/sge/mint => sge/mint/v1beta}/params.proto (89%) rename proto/{sgenetwork/sge/mint => sge/mint/v1beta}/phase.proto (82%) rename proto/{sgenetwork/sge/mint => sge/mint/v1beta}/query.proto (88%) rename proto/{sgenetwork/sge/mint => sge/mint/v1beta}/tx.proto (94%) diff --git a/api/sge/legacy/bet/module/v1/module.pulsar.go b/api/sge/legacy/bet/module/v1/module.pulsar.go new file mode 100644 index 00000000..3f9777ba --- /dev/null +++ b/api/sge/legacy/bet/module/v1/module.pulsar.go @@ -0,0 +1,654 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_module_v1_module_proto_init() + md_Module = File_sge_legacy_bet_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.legacy.bet.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.bet.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.legacy.bet.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.bet.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.bet.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.legacy.bet.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.bet.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.legacy.bet.module.v1.Module is not mutable")) + case "sge.legacy.bet.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.legacy.bet.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.bet.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.bet.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the bet module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_legacy_bet_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, + 0x31, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, + 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x22, 0x67, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x12, 0x2c, 0x0a, + 0x12, 0x66, 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x5f, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x66, 0x65, 0x65, 0x43, 0x6f, + 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, + 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, 0x11, 0xba, 0xc0, 0x96, 0xda, 0x01, + 0x0b, 0x0a, 0x09, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x62, 0x65, 0x74, 0x42, 0xf2, 0x01, 0x0a, + 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x62, 0x65, 0x74, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, + 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x40, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, + 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x6d, 0x6f, 0x64, 0x75, + 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, 0x31, 0xa2, 0x02, + 0x04, 0x53, 0x4c, 0x42, 0x4d, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x56, 0x31, + 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, + 0x74, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x24, 0x53, 0x67, + 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x4d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, 0x3a, 0x56, + 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_module_v1_module_proto_rawDescOnce sync.Once + file_sge_legacy_bet_module_v1_module_proto_rawDescData = file_sge_legacy_bet_module_v1_module_proto_rawDesc +) + +func file_sge_legacy_bet_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_module_v1_module_proto_rawDescData) + }) + return file_sge_legacy_bet_module_v1_module_proto_rawDescData +} + +var file_sge_legacy_bet_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_bet_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.legacy.bet.module.v1.Module +} +var file_sge_legacy_bet_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_module_v1_module_proto_init() } +func file_sge_legacy_bet_module_v1_module_proto_init() { + if File_sge_legacy_bet_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_module_v1_module_proto_msgTypes, + }.Build() + File_sge_legacy_bet_module_v1_module_proto = out.File + file_sge_legacy_bet_module_v1_module_proto_rawDesc = nil + file_sge_legacy_bet_module_v1_module_proto_goTypes = nil + file_sge_legacy_bet_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/bet.pulsar.go b/api/sge/legacy/bet/v1beta/bet.pulsar.go new file mode 100644 index 00000000..857f2a01 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/bet.pulsar.go @@ -0,0 +1,4691 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_Bet_14_list)(nil) + +type _Bet_14_list struct { + list *[]*BetFulfillment +} + +func (x *_Bet_14_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_Bet_14_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_Bet_14_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*BetFulfillment) + (*x.list)[i] = concreteValue +} + +func (x *_Bet_14_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*BetFulfillment) + *x.list = append(*x.list, concreteValue) +} + +func (x *_Bet_14_list) AppendMutable() protoreflect.Value { + v := new(BetFulfillment) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_Bet_14_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_Bet_14_list) NewElement() protoreflect.Value { + v := new(BetFulfillment) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_Bet_14_list) IsValid() bool { + return x.list != nil +} + +var ( + md_Bet protoreflect.MessageDescriptor + fd_Bet_uid protoreflect.FieldDescriptor + fd_Bet_market_uid protoreflect.FieldDescriptor + fd_Bet_odds_uid protoreflect.FieldDescriptor + fd_Bet_odds_value protoreflect.FieldDescriptor + fd_Bet_amount protoreflect.FieldDescriptor + fd_Bet_fee protoreflect.FieldDescriptor + fd_Bet_status protoreflect.FieldDescriptor + fd_Bet_result protoreflect.FieldDescriptor + fd_Bet_creator protoreflect.FieldDescriptor + fd_Bet_created_at protoreflect.FieldDescriptor + fd_Bet_settlement_height protoreflect.FieldDescriptor + fd_Bet_max_loss_multiplier protoreflect.FieldDescriptor + fd_Bet_bet_fulfillment protoreflect.FieldDescriptor + fd_Bet_meta protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_proto_init() + md_Bet = File_sge_legacy_bet_v1beta_bet_proto.Messages().ByName("Bet") + fd_Bet_uid = md_Bet.Fields().ByName("uid") + fd_Bet_market_uid = md_Bet.Fields().ByName("market_uid") + fd_Bet_odds_uid = md_Bet.Fields().ByName("odds_uid") + fd_Bet_odds_value = md_Bet.Fields().ByName("odds_value") + fd_Bet_amount = md_Bet.Fields().ByName("amount") + fd_Bet_fee = md_Bet.Fields().ByName("fee") + fd_Bet_status = md_Bet.Fields().ByName("status") + fd_Bet_result = md_Bet.Fields().ByName("result") + fd_Bet_creator = md_Bet.Fields().ByName("creator") + fd_Bet_created_at = md_Bet.Fields().ByName("created_at") + fd_Bet_settlement_height = md_Bet.Fields().ByName("settlement_height") + fd_Bet_max_loss_multiplier = md_Bet.Fields().ByName("max_loss_multiplier") + fd_Bet_bet_fulfillment = md_Bet.Fields().ByName("bet_fulfillment") + fd_Bet_meta = md_Bet.Fields().ByName("meta") +} + +var _ protoreflect.Message = (*fastReflection_Bet)(nil) + +type fastReflection_Bet Bet + +func (x *Bet) ProtoReflect() protoreflect.Message { + return (*fastReflection_Bet)(x) +} + +func (x *Bet) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Bet_messageType fastReflection_Bet_messageType +var _ protoreflect.MessageType = fastReflection_Bet_messageType{} + +type fastReflection_Bet_messageType struct{} + +func (x fastReflection_Bet_messageType) Zero() protoreflect.Message { + return (*fastReflection_Bet)(nil) +} +func (x fastReflection_Bet_messageType) New() protoreflect.Message { + return new(fastReflection_Bet) +} +func (x fastReflection_Bet_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Bet +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Bet) Descriptor() protoreflect.MessageDescriptor { + return md_Bet +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Bet) Type() protoreflect.MessageType { + return _fastReflection_Bet_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Bet) New() protoreflect.Message { + return new(fastReflection_Bet) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Bet) Interface() protoreflect.ProtoMessage { + return (*Bet)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Bet) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_Bet_uid, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_Bet_market_uid, value) { + return + } + } + if x.OddsUid != "" { + value := protoreflect.ValueOfString(x.OddsUid) + if !f(fd_Bet_odds_uid, value) { + return + } + } + if x.OddsValue != "" { + value := protoreflect.ValueOfString(x.OddsValue) + if !f(fd_Bet_odds_value, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_Bet_amount, value) { + return + } + } + if x.Fee != "" { + value := protoreflect.ValueOfString(x.Fee) + if !f(fd_Bet_fee, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_Bet_status, value) { + return + } + } + if x.Result != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Result)) + if !f(fd_Bet_result, value) { + return + } + } + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_Bet_creator, value) { + return + } + } + if x.CreatedAt != int64(0) { + value := protoreflect.ValueOfInt64(x.CreatedAt) + if !f(fd_Bet_created_at, value) { + return + } + } + if x.SettlementHeight != int64(0) { + value := protoreflect.ValueOfInt64(x.SettlementHeight) + if !f(fd_Bet_settlement_height, value) { + return + } + } + if x.MaxLossMultiplier != "" { + value := protoreflect.ValueOfString(x.MaxLossMultiplier) + if !f(fd_Bet_max_loss_multiplier, value) { + return + } + } + if len(x.BetFulfillment) != 0 { + value := protoreflect.ValueOfList(&_Bet_14_list{list: &x.BetFulfillment}) + if !f(fd_Bet_bet_fulfillment, value) { + return + } + } + if x.Meta != nil { + value := protoreflect.ValueOfMessage(x.Meta.ProtoReflect()) + if !f(fd_Bet_meta, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Bet) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Bet.uid": + return x.Uid != "" + case "sge.legacy.bet.v1beta.Bet.market_uid": + return x.MarketUid != "" + case "sge.legacy.bet.v1beta.Bet.odds_uid": + return x.OddsUid != "" + case "sge.legacy.bet.v1beta.Bet.odds_value": + return x.OddsValue != "" + case "sge.legacy.bet.v1beta.Bet.amount": + return x.Amount != "" + case "sge.legacy.bet.v1beta.Bet.fee": + return x.Fee != "" + case "sge.legacy.bet.v1beta.Bet.status": + return x.Status != 0 + case "sge.legacy.bet.v1beta.Bet.result": + return x.Result != 0 + case "sge.legacy.bet.v1beta.Bet.creator": + return x.Creator != "" + case "sge.legacy.bet.v1beta.Bet.created_at": + return x.CreatedAt != int64(0) + case "sge.legacy.bet.v1beta.Bet.settlement_height": + return x.SettlementHeight != int64(0) + case "sge.legacy.bet.v1beta.Bet.max_loss_multiplier": + return x.MaxLossMultiplier != "" + case "sge.legacy.bet.v1beta.Bet.bet_fulfillment": + return len(x.BetFulfillment) != 0 + case "sge.legacy.bet.v1beta.Bet.meta": + return x.Meta != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Bet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Bet does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Bet) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Bet.uid": + x.Uid = "" + case "sge.legacy.bet.v1beta.Bet.market_uid": + x.MarketUid = "" + case "sge.legacy.bet.v1beta.Bet.odds_uid": + x.OddsUid = "" + case "sge.legacy.bet.v1beta.Bet.odds_value": + x.OddsValue = "" + case "sge.legacy.bet.v1beta.Bet.amount": + x.Amount = "" + case "sge.legacy.bet.v1beta.Bet.fee": + x.Fee = "" + case "sge.legacy.bet.v1beta.Bet.status": + x.Status = 0 + case "sge.legacy.bet.v1beta.Bet.result": + x.Result = 0 + case "sge.legacy.bet.v1beta.Bet.creator": + x.Creator = "" + case "sge.legacy.bet.v1beta.Bet.created_at": + x.CreatedAt = int64(0) + case "sge.legacy.bet.v1beta.Bet.settlement_height": + x.SettlementHeight = int64(0) + case "sge.legacy.bet.v1beta.Bet.max_loss_multiplier": + x.MaxLossMultiplier = "" + case "sge.legacy.bet.v1beta.Bet.bet_fulfillment": + x.BetFulfillment = nil + case "sge.legacy.bet.v1beta.Bet.meta": + x.Meta = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Bet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Bet does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Bet) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.Bet.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.odds_uid": + value := x.OddsUid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.odds_value": + value := x.OddsValue + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.fee": + value := x.Fee + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.bet.v1beta.Bet.result": + value := x.Result + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.bet.v1beta.Bet.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.created_at": + value := x.CreatedAt + return protoreflect.ValueOfInt64(value) + case "sge.legacy.bet.v1beta.Bet.settlement_height": + value := x.SettlementHeight + return protoreflect.ValueOfInt64(value) + case "sge.legacy.bet.v1beta.Bet.max_loss_multiplier": + value := x.MaxLossMultiplier + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Bet.bet_fulfillment": + if len(x.BetFulfillment) == 0 { + return protoreflect.ValueOfList(&_Bet_14_list{}) + } + listValue := &_Bet_14_list{list: &x.BetFulfillment} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.Bet.meta": + value := x.Meta + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Bet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Bet does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Bet) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Bet.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.odds_uid": + x.OddsUid = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.odds_value": + x.OddsValue = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.amount": + x.Amount = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.fee": + x.Fee = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.status": + x.Status = (Bet_Status)(value.Enum()) + case "sge.legacy.bet.v1beta.Bet.result": + x.Result = (Bet_Result)(value.Enum()) + case "sge.legacy.bet.v1beta.Bet.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.created_at": + x.CreatedAt = value.Int() + case "sge.legacy.bet.v1beta.Bet.settlement_height": + x.SettlementHeight = value.Int() + case "sge.legacy.bet.v1beta.Bet.max_loss_multiplier": + x.MaxLossMultiplier = value.Interface().(string) + case "sge.legacy.bet.v1beta.Bet.bet_fulfillment": + lv := value.List() + clv := lv.(*_Bet_14_list) + x.BetFulfillment = *clv.list + case "sge.legacy.bet.v1beta.Bet.meta": + x.Meta = value.Message().Interface().(*MetaData) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Bet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Bet does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Bet) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Bet.bet_fulfillment": + if x.BetFulfillment == nil { + x.BetFulfillment = []*BetFulfillment{} + } + value := &_Bet_14_list{list: &x.BetFulfillment} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.Bet.meta": + if x.Meta == nil { + x.Meta = new(MetaData) + } + return protoreflect.ValueOfMessage(x.Meta.ProtoReflect()) + case "sge.legacy.bet.v1beta.Bet.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.odds_uid": + panic(fmt.Errorf("field odds_uid of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.odds_value": + panic(fmt.Errorf("field odds_value of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.amount": + panic(fmt.Errorf("field amount of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.fee": + panic(fmt.Errorf("field fee of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.status": + panic(fmt.Errorf("field status of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.result": + panic(fmt.Errorf("field result of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.creator": + panic(fmt.Errorf("field creator of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.created_at": + panic(fmt.Errorf("field created_at of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.settlement_height": + panic(fmt.Errorf("field settlement_height of message sge.legacy.bet.v1beta.Bet is not mutable")) + case "sge.legacy.bet.v1beta.Bet.max_loss_multiplier": + panic(fmt.Errorf("field max_loss_multiplier of message sge.legacy.bet.v1beta.Bet is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Bet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Bet does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Bet) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Bet.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.odds_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.odds_value": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.amount": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.fee": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.status": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.bet.v1beta.Bet.result": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.bet.v1beta.Bet.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.created_at": + return protoreflect.ValueOfInt64(int64(0)) + case "sge.legacy.bet.v1beta.Bet.settlement_height": + return protoreflect.ValueOfInt64(int64(0)) + case "sge.legacy.bet.v1beta.Bet.max_loss_multiplier": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Bet.bet_fulfillment": + list := []*BetFulfillment{} + return protoreflect.ValueOfList(&_Bet_14_list{list: &list}) + case "sge.legacy.bet.v1beta.Bet.meta": + m := new(MetaData) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Bet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Bet does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Bet) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.Bet", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Bet) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Bet) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Bet) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Bet) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Bet) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.OddsUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.OddsValue) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Fee) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.Result != 0 { + n += 1 + runtime.Sov(uint64(x.Result)) + } + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.CreatedAt != 0 { + n += 1 + runtime.Sov(uint64(x.CreatedAt)) + } + if x.SettlementHeight != 0 { + n += 1 + runtime.Sov(uint64(x.SettlementHeight)) + } + l = len(x.MaxLossMultiplier) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.BetFulfillment) > 0 { + for _, e := range x.BetFulfillment { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Meta != nil { + l = options.Size(x.Meta) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Bet) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Meta != nil { + encoded, err := options.Marshal(x.Meta) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x7a + } + if len(x.BetFulfillment) > 0 { + for iNdEx := len(x.BetFulfillment) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.BetFulfillment[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x72 + } + } + if len(x.MaxLossMultiplier) > 0 { + i -= len(x.MaxLossMultiplier) + copy(dAtA[i:], x.MaxLossMultiplier) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MaxLossMultiplier))) + i-- + dAtA[i] = 0x6a + } + if x.SettlementHeight != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.SettlementHeight)) + i-- + dAtA[i] = 0x60 + } + if x.CreatedAt != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.CreatedAt)) + i-- + dAtA[i] = 0x58 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0x52 + } + if x.Result != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Result)) + i-- + dAtA[i] = 0x48 + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x40 + } + if len(x.Fee) > 0 { + i -= len(x.Fee) + copy(dAtA[i:], x.Fee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Fee))) + i-- + dAtA[i] = 0x3a + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x32 + } + if len(x.OddsValue) > 0 { + i -= len(x.OddsValue) + copy(dAtA[i:], x.OddsValue) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OddsValue))) + i-- + dAtA[i] = 0x2a + } + if len(x.OddsUid) > 0 { + i -= len(x.OddsUid) + copy(dAtA[i:], x.OddsUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OddsUid))) + i-- + dAtA[i] = 0x1a + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Bet) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Bet: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Bet: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OddsUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OddsUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OddsValue", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OddsValue = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Fee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Fee = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 8: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= Bet_Status(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 9: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) + } + x.Result = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Result |= Bet_Result(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 10: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 11: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType) + } + x.CreatedAt = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.CreatedAt |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 12: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SettlementHeight", wireType) + } + x.SettlementHeight = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.SettlementHeight |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 13: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxLossMultiplier", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MaxLossMultiplier = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 14: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BetFulfillment", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BetFulfillment = append(x.BetFulfillment, &BetFulfillment{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.BetFulfillment[len(x.BetFulfillment)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 15: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Meta == nil { + x.Meta = &MetaData{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Meta); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_UID2ID protoreflect.MessageDescriptor + fd_UID2ID_uid protoreflect.FieldDescriptor + fd_UID2ID_id protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_proto_init() + md_UID2ID = File_sge_legacy_bet_v1beta_bet_proto.Messages().ByName("UID2ID") + fd_UID2ID_uid = md_UID2ID.Fields().ByName("uid") + fd_UID2ID_id = md_UID2ID.Fields().ByName("id") +} + +var _ protoreflect.Message = (*fastReflection_UID2ID)(nil) + +type fastReflection_UID2ID UID2ID + +func (x *UID2ID) ProtoReflect() protoreflect.Message { + return (*fastReflection_UID2ID)(x) +} + +func (x *UID2ID) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_UID2ID_messageType fastReflection_UID2ID_messageType +var _ protoreflect.MessageType = fastReflection_UID2ID_messageType{} + +type fastReflection_UID2ID_messageType struct{} + +func (x fastReflection_UID2ID_messageType) Zero() protoreflect.Message { + return (*fastReflection_UID2ID)(nil) +} +func (x fastReflection_UID2ID_messageType) New() protoreflect.Message { + return new(fastReflection_UID2ID) +} +func (x fastReflection_UID2ID_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_UID2ID +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_UID2ID) Descriptor() protoreflect.MessageDescriptor { + return md_UID2ID +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_UID2ID) Type() protoreflect.MessageType { + return _fastReflection_UID2ID_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_UID2ID) New() protoreflect.Message { + return new(fastReflection_UID2ID) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_UID2ID) Interface() protoreflect.ProtoMessage { + return (*UID2ID)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_UID2ID) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_UID2ID_uid, value) { + return + } + } + if x.Id != uint64(0) { + value := protoreflect.ValueOfUint64(x.Id) + if !f(fd_UID2ID_id, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_UID2ID) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.UID2ID.uid": + return x.Uid != "" + case "sge.legacy.bet.v1beta.UID2ID.id": + return x.Id != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.UID2ID")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.UID2ID does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UID2ID) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.UID2ID.uid": + x.Uid = "" + case "sge.legacy.bet.v1beta.UID2ID.id": + x.Id = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.UID2ID")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.UID2ID does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_UID2ID) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.UID2ID.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.UID2ID.id": + value := x.Id + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.UID2ID")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.UID2ID does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UID2ID) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.UID2ID.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.bet.v1beta.UID2ID.id": + x.Id = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.UID2ID")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.UID2ID does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UID2ID) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.UID2ID.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.UID2ID is not mutable")) + case "sge.legacy.bet.v1beta.UID2ID.id": + panic(fmt.Errorf("field id of message sge.legacy.bet.v1beta.UID2ID is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.UID2ID")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.UID2ID does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_UID2ID) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.UID2ID.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.UID2ID.id": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.UID2ID")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.UID2ID does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_UID2ID) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.UID2ID", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_UID2ID) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UID2ID) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_UID2ID) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_UID2ID) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*UID2ID) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Id != 0 { + n += 1 + runtime.Sov(uint64(x.Id)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*UID2ID) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Id != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Id)) + i-- + dAtA[i] = 0x10 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*UID2ID) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: UID2ID: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: UID2ID: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + x.Id = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Id |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_PendingBet protoreflect.MessageDescriptor + fd_PendingBet_uid protoreflect.FieldDescriptor + fd_PendingBet_creator protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_proto_init() + md_PendingBet = File_sge_legacy_bet_v1beta_bet_proto.Messages().ByName("PendingBet") + fd_PendingBet_uid = md_PendingBet.Fields().ByName("uid") + fd_PendingBet_creator = md_PendingBet.Fields().ByName("creator") +} + +var _ protoreflect.Message = (*fastReflection_PendingBet)(nil) + +type fastReflection_PendingBet PendingBet + +func (x *PendingBet) ProtoReflect() protoreflect.Message { + return (*fastReflection_PendingBet)(x) +} + +func (x *PendingBet) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_PendingBet_messageType fastReflection_PendingBet_messageType +var _ protoreflect.MessageType = fastReflection_PendingBet_messageType{} + +type fastReflection_PendingBet_messageType struct{} + +func (x fastReflection_PendingBet_messageType) Zero() protoreflect.Message { + return (*fastReflection_PendingBet)(nil) +} +func (x fastReflection_PendingBet_messageType) New() protoreflect.Message { + return new(fastReflection_PendingBet) +} +func (x fastReflection_PendingBet_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_PendingBet +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_PendingBet) Descriptor() protoreflect.MessageDescriptor { + return md_PendingBet +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_PendingBet) Type() protoreflect.MessageType { + return _fastReflection_PendingBet_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_PendingBet) New() protoreflect.Message { + return new(fastReflection_PendingBet) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_PendingBet) Interface() protoreflect.ProtoMessage { + return (*PendingBet)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_PendingBet) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_PendingBet_uid, value) { + return + } + } + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_PendingBet_creator, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_PendingBet) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.PendingBet.uid": + return x.Uid != "" + case "sge.legacy.bet.v1beta.PendingBet.creator": + return x.Creator != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.PendingBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.PendingBet does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PendingBet) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.PendingBet.uid": + x.Uid = "" + case "sge.legacy.bet.v1beta.PendingBet.creator": + x.Creator = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.PendingBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.PendingBet does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_PendingBet) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.PendingBet.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.PendingBet.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.PendingBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.PendingBet does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PendingBet) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.PendingBet.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.bet.v1beta.PendingBet.creator": + x.Creator = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.PendingBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.PendingBet does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PendingBet) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.PendingBet.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.PendingBet is not mutable")) + case "sge.legacy.bet.v1beta.PendingBet.creator": + panic(fmt.Errorf("field creator of message sge.legacy.bet.v1beta.PendingBet is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.PendingBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.PendingBet does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_PendingBet) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.PendingBet.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.PendingBet.creator": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.PendingBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.PendingBet does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_PendingBet) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.PendingBet", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_PendingBet) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PendingBet) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_PendingBet) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_PendingBet) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*PendingBet) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*PendingBet) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*PendingBet) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PendingBet: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PendingBet: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_SettledBet protoreflect.MessageDescriptor + fd_SettledBet_uid protoreflect.FieldDescriptor + fd_SettledBet_bettor_address protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_proto_init() + md_SettledBet = File_sge_legacy_bet_v1beta_bet_proto.Messages().ByName("SettledBet") + fd_SettledBet_uid = md_SettledBet.Fields().ByName("uid") + fd_SettledBet_bettor_address = md_SettledBet.Fields().ByName("bettor_address") +} + +var _ protoreflect.Message = (*fastReflection_SettledBet)(nil) + +type fastReflection_SettledBet SettledBet + +func (x *SettledBet) ProtoReflect() protoreflect.Message { + return (*fastReflection_SettledBet)(x) +} + +func (x *SettledBet) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_SettledBet_messageType fastReflection_SettledBet_messageType +var _ protoreflect.MessageType = fastReflection_SettledBet_messageType{} + +type fastReflection_SettledBet_messageType struct{} + +func (x fastReflection_SettledBet_messageType) Zero() protoreflect.Message { + return (*fastReflection_SettledBet)(nil) +} +func (x fastReflection_SettledBet_messageType) New() protoreflect.Message { + return new(fastReflection_SettledBet) +} +func (x fastReflection_SettledBet_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_SettledBet +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_SettledBet) Descriptor() protoreflect.MessageDescriptor { + return md_SettledBet +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_SettledBet) Type() protoreflect.MessageType { + return _fastReflection_SettledBet_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_SettledBet) New() protoreflect.Message { + return new(fastReflection_SettledBet) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_SettledBet) Interface() protoreflect.ProtoMessage { + return (*SettledBet)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_SettledBet) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_SettledBet_uid, value) { + return + } + } + if x.BettorAddress != "" { + value := protoreflect.ValueOfString(x.BettorAddress) + if !f(fd_SettledBet_bettor_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_SettledBet) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.SettledBet.uid": + return x.Uid != "" + case "sge.legacy.bet.v1beta.SettledBet.bettor_address": + return x.BettorAddress != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.SettledBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.SettledBet does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledBet) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.SettledBet.uid": + x.Uid = "" + case "sge.legacy.bet.v1beta.SettledBet.bettor_address": + x.BettorAddress = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.SettledBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.SettledBet does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_SettledBet) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.SettledBet.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.SettledBet.bettor_address": + value := x.BettorAddress + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.SettledBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.SettledBet does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledBet) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.SettledBet.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.bet.v1beta.SettledBet.bettor_address": + x.BettorAddress = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.SettledBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.SettledBet does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledBet) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.SettledBet.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.SettledBet is not mutable")) + case "sge.legacy.bet.v1beta.SettledBet.bettor_address": + panic(fmt.Errorf("field bettor_address of message sge.legacy.bet.v1beta.SettledBet is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.SettledBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.SettledBet does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_SettledBet) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.SettledBet.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.SettledBet.bettor_address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.SettledBet")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.SettledBet does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_SettledBet) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.SettledBet", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_SettledBet) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledBet) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_SettledBet) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_SettledBet) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*SettledBet) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.BettorAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*SettledBet) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.BettorAddress) > 0 { + i -= len(x.BettorAddress) + copy(dAtA[i:], x.BettorAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BettorAddress))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*SettledBet) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SettledBet: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SettledBet: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BettorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BettorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_BetFulfillment protoreflect.MessageDescriptor + fd_BetFulfillment_participant_address protoreflect.FieldDescriptor + fd_BetFulfillment_participation_index protoreflect.FieldDescriptor + fd_BetFulfillment_bet_amount protoreflect.FieldDescriptor + fd_BetFulfillment_payout_profit protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_proto_init() + md_BetFulfillment = File_sge_legacy_bet_v1beta_bet_proto.Messages().ByName("BetFulfillment") + fd_BetFulfillment_participant_address = md_BetFulfillment.Fields().ByName("participant_address") + fd_BetFulfillment_participation_index = md_BetFulfillment.Fields().ByName("participation_index") + fd_BetFulfillment_bet_amount = md_BetFulfillment.Fields().ByName("bet_amount") + fd_BetFulfillment_payout_profit = md_BetFulfillment.Fields().ByName("payout_profit") +} + +var _ protoreflect.Message = (*fastReflection_BetFulfillment)(nil) + +type fastReflection_BetFulfillment BetFulfillment + +func (x *BetFulfillment) ProtoReflect() protoreflect.Message { + return (*fastReflection_BetFulfillment)(x) +} + +func (x *BetFulfillment) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_BetFulfillment_messageType fastReflection_BetFulfillment_messageType +var _ protoreflect.MessageType = fastReflection_BetFulfillment_messageType{} + +type fastReflection_BetFulfillment_messageType struct{} + +func (x fastReflection_BetFulfillment_messageType) Zero() protoreflect.Message { + return (*fastReflection_BetFulfillment)(nil) +} +func (x fastReflection_BetFulfillment_messageType) New() protoreflect.Message { + return new(fastReflection_BetFulfillment) +} +func (x fastReflection_BetFulfillment_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_BetFulfillment +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_BetFulfillment) Descriptor() protoreflect.MessageDescriptor { + return md_BetFulfillment +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_BetFulfillment) Type() protoreflect.MessageType { + return _fastReflection_BetFulfillment_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_BetFulfillment) New() protoreflect.Message { + return new(fastReflection_BetFulfillment) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_BetFulfillment) Interface() protoreflect.ProtoMessage { + return (*BetFulfillment)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_BetFulfillment) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.ParticipantAddress != "" { + value := protoreflect.ValueOfString(x.ParticipantAddress) + if !f(fd_BetFulfillment_participant_address, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_BetFulfillment_participation_index, value) { + return + } + } + if x.BetAmount != "" { + value := protoreflect.ValueOfString(x.BetAmount) + if !f(fd_BetFulfillment_bet_amount, value) { + return + } + } + if x.PayoutProfit != "" { + value := protoreflect.ValueOfString(x.PayoutProfit) + if !f(fd_BetFulfillment_payout_profit, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_BetFulfillment) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetFulfillment.participant_address": + return x.ParticipantAddress != "" + case "sge.legacy.bet.v1beta.BetFulfillment.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.bet.v1beta.BetFulfillment.bet_amount": + return x.BetAmount != "" + case "sge.legacy.bet.v1beta.BetFulfillment.payout_profit": + return x.PayoutProfit != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetFulfillment")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetFulfillment does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetFulfillment) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetFulfillment.participant_address": + x.ParticipantAddress = "" + case "sge.legacy.bet.v1beta.BetFulfillment.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.bet.v1beta.BetFulfillment.bet_amount": + x.BetAmount = "" + case "sge.legacy.bet.v1beta.BetFulfillment.payout_profit": + x.PayoutProfit = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetFulfillment")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetFulfillment does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_BetFulfillment) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.BetFulfillment.participant_address": + value := x.ParticipantAddress + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.BetFulfillment.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.bet.v1beta.BetFulfillment.bet_amount": + value := x.BetAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.BetFulfillment.payout_profit": + value := x.PayoutProfit + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetFulfillment")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetFulfillment does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetFulfillment) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetFulfillment.participant_address": + x.ParticipantAddress = value.Interface().(string) + case "sge.legacy.bet.v1beta.BetFulfillment.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.bet.v1beta.BetFulfillment.bet_amount": + x.BetAmount = value.Interface().(string) + case "sge.legacy.bet.v1beta.BetFulfillment.payout_profit": + x.PayoutProfit = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetFulfillment")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetFulfillment does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetFulfillment) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetFulfillment.participant_address": + panic(fmt.Errorf("field participant_address of message sge.legacy.bet.v1beta.BetFulfillment is not mutable")) + case "sge.legacy.bet.v1beta.BetFulfillment.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.bet.v1beta.BetFulfillment is not mutable")) + case "sge.legacy.bet.v1beta.BetFulfillment.bet_amount": + panic(fmt.Errorf("field bet_amount of message sge.legacy.bet.v1beta.BetFulfillment is not mutable")) + case "sge.legacy.bet.v1beta.BetFulfillment.payout_profit": + panic(fmt.Errorf("field payout_profit of message sge.legacy.bet.v1beta.BetFulfillment is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetFulfillment")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetFulfillment does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_BetFulfillment) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetFulfillment.participant_address": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.BetFulfillment.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.bet.v1beta.BetFulfillment.bet_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.BetFulfillment.payout_profit": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetFulfillment")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetFulfillment does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_BetFulfillment) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.BetFulfillment", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_BetFulfillment) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetFulfillment) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_BetFulfillment) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_BetFulfillment) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*BetFulfillment) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.ParticipantAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + l = len(x.BetAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.PayoutProfit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*BetFulfillment) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.PayoutProfit) > 0 { + i -= len(x.PayoutProfit) + copy(dAtA[i:], x.PayoutProfit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PayoutProfit))) + i-- + dAtA[i] = 0x22 + } + if len(x.BetAmount) > 0 { + i -= len(x.BetAmount) + copy(dAtA[i:], x.BetAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BetAmount))) + i-- + dAtA[i] = 0x1a + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x10 + } + if len(x.ParticipantAddress) > 0 { + i -= len(x.ParticipantAddress) + copy(dAtA[i:], x.ParticipantAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ParticipantAddress))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*BetFulfillment) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetFulfillment: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetFulfillment: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipantAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipantAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BetAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BetAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PayoutProfit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PayoutProfit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MetaData protoreflect.MessageDescriptor + fd_MetaData_selected_odds_type protoreflect.FieldDescriptor + fd_MetaData_selected_odds_value protoreflect.FieldDescriptor + fd_MetaData_is_main_market protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_proto_init() + md_MetaData = File_sge_legacy_bet_v1beta_bet_proto.Messages().ByName("MetaData") + fd_MetaData_selected_odds_type = md_MetaData.Fields().ByName("selected_odds_type") + fd_MetaData_selected_odds_value = md_MetaData.Fields().ByName("selected_odds_value") + fd_MetaData_is_main_market = md_MetaData.Fields().ByName("is_main_market") +} + +var _ protoreflect.Message = (*fastReflection_MetaData)(nil) + +type fastReflection_MetaData MetaData + +func (x *MetaData) ProtoReflect() protoreflect.Message { + return (*fastReflection_MetaData)(x) +} + +func (x *MetaData) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MetaData_messageType fastReflection_MetaData_messageType +var _ protoreflect.MessageType = fastReflection_MetaData_messageType{} + +type fastReflection_MetaData_messageType struct{} + +func (x fastReflection_MetaData_messageType) Zero() protoreflect.Message { + return (*fastReflection_MetaData)(nil) +} +func (x fastReflection_MetaData_messageType) New() protoreflect.Message { + return new(fastReflection_MetaData) +} +func (x fastReflection_MetaData_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MetaData +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MetaData) Descriptor() protoreflect.MessageDescriptor { + return md_MetaData +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MetaData) Type() protoreflect.MessageType { + return _fastReflection_MetaData_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MetaData) New() protoreflect.Message { + return new(fastReflection_MetaData) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MetaData) Interface() protoreflect.ProtoMessage { + return (*MetaData)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MetaData) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.SelectedOddsType != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.SelectedOddsType)) + if !f(fd_MetaData_selected_odds_type, value) { + return + } + } + if x.SelectedOddsValue != "" { + value := protoreflect.ValueOfString(x.SelectedOddsValue) + if !f(fd_MetaData_selected_odds_value, value) { + return + } + } + if x.IsMainMarket != false { + value := protoreflect.ValueOfBool(x.IsMainMarket) + if !f(fd_MetaData_is_main_market, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MetaData) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MetaData.selected_odds_type": + return x.SelectedOddsType != 0 + case "sge.legacy.bet.v1beta.MetaData.selected_odds_value": + return x.SelectedOddsValue != "" + case "sge.legacy.bet.v1beta.MetaData.is_main_market": + return x.IsMainMarket != false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MetaData")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MetaData does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MetaData) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MetaData.selected_odds_type": + x.SelectedOddsType = 0 + case "sge.legacy.bet.v1beta.MetaData.selected_odds_value": + x.SelectedOddsValue = "" + case "sge.legacy.bet.v1beta.MetaData.is_main_market": + x.IsMainMarket = false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MetaData")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MetaData does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MetaData) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.MetaData.selected_odds_type": + value := x.SelectedOddsType + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.bet.v1beta.MetaData.selected_odds_value": + value := x.SelectedOddsValue + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.MetaData.is_main_market": + value := x.IsMainMarket + return protoreflect.ValueOfBool(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MetaData")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MetaData does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MetaData) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MetaData.selected_odds_type": + x.SelectedOddsType = (OddsType)(value.Enum()) + case "sge.legacy.bet.v1beta.MetaData.selected_odds_value": + x.SelectedOddsValue = value.Interface().(string) + case "sge.legacy.bet.v1beta.MetaData.is_main_market": + x.IsMainMarket = value.Bool() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MetaData")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MetaData does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MetaData) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MetaData.selected_odds_type": + panic(fmt.Errorf("field selected_odds_type of message sge.legacy.bet.v1beta.MetaData is not mutable")) + case "sge.legacy.bet.v1beta.MetaData.selected_odds_value": + panic(fmt.Errorf("field selected_odds_value of message sge.legacy.bet.v1beta.MetaData is not mutable")) + case "sge.legacy.bet.v1beta.MetaData.is_main_market": + panic(fmt.Errorf("field is_main_market of message sge.legacy.bet.v1beta.MetaData is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MetaData")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MetaData does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MetaData) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MetaData.selected_odds_type": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.bet.v1beta.MetaData.selected_odds_value": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.MetaData.is_main_market": + return protoreflect.ValueOfBool(false) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MetaData")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MetaData does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MetaData) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.MetaData", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MetaData) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MetaData) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MetaData) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MetaData) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MetaData) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.SelectedOddsType != 0 { + n += 1 + runtime.Sov(uint64(x.SelectedOddsType)) + } + l = len(x.SelectedOddsValue) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.IsMainMarket { + n += 2 + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MetaData) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.IsMainMarket { + i-- + if x.IsMainMarket { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x18 + } + if len(x.SelectedOddsValue) > 0 { + i -= len(x.SelectedOddsValue) + copy(dAtA[i:], x.SelectedOddsValue) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SelectedOddsValue))) + i-- + dAtA[i] = 0x12 + } + if x.SelectedOddsType != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.SelectedOddsType)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MetaData) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MetaData: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MetaData: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SelectedOddsType", wireType) + } + x.SelectedOddsType = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.SelectedOddsType |= OddsType(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SelectedOddsValue", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SelectedOddsValue = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field IsMainMarket", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.IsMainMarket = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/bet.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Status of the Bet. +type Bet_Status int32 + +const ( + // the invalid or unknown + Bet_STATUS_UNSPECIFIED Bet_Status = 0 + // bet is placed + Bet_STATUS_PLACED Bet_Status = 1 + // bet is canceled by Bettor + Bet_STATUS_CANCELED Bet_Status = 2 + // bet is aborted + Bet_STATUS_ABORTED Bet_Status = 3 + // bet is pending for getting placed + Bet_STATUS_PENDING Bet_Status = 4 + // bet result is declared + Bet_STATUS_RESULT_DECLARED Bet_Status = 5 + // the bet is settled + Bet_STATUS_SETTLED Bet_Status = 6 +) + +// Enum value maps for Bet_Status. +var ( + Bet_Status_name = map[int32]string{ + 0: "STATUS_UNSPECIFIED", + 1: "STATUS_PLACED", + 2: "STATUS_CANCELED", + 3: "STATUS_ABORTED", + 4: "STATUS_PENDING", + 5: "STATUS_RESULT_DECLARED", + 6: "STATUS_SETTLED", + } + Bet_Status_value = map[string]int32{ + "STATUS_UNSPECIFIED": 0, + "STATUS_PLACED": 1, + "STATUS_CANCELED": 2, + "STATUS_ABORTED": 3, + "STATUS_PENDING": 4, + "STATUS_RESULT_DECLARED": 5, + "STATUS_SETTLED": 6, + } +) + +func (x Bet_Status) Enum() *Bet_Status { + p := new(Bet_Status) + *p = x + return p +} + +func (x Bet_Status) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (Bet_Status) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_bet_v1beta_bet_proto_enumTypes[0].Descriptor() +} + +func (Bet_Status) Type() protoreflect.EnumType { + return &file_sge_legacy_bet_v1beta_bet_proto_enumTypes[0] +} + +func (x Bet_Status) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use Bet_Status.Descriptor instead. +func (Bet_Status) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{0, 0} +} + +// Result of the bet. +type Bet_Result int32 + +const ( + // the invalid or unknown + Bet_RESULT_UNSPECIFIED Bet_Result = 0 + // bet result is pending + Bet_RESULT_PENDING Bet_Result = 1 + // bet won by the bettor + Bet_RESULT_WON Bet_Result = 2 + // bet lost by the bettor + Bet_RESULT_LOST Bet_Result = 3 + // bet is refunded + Bet_RESULT_REFUNDED Bet_Result = 4 +) + +// Enum value maps for Bet_Result. +var ( + Bet_Result_name = map[int32]string{ + 0: "RESULT_UNSPECIFIED", + 1: "RESULT_PENDING", + 2: "RESULT_WON", + 3: "RESULT_LOST", + 4: "RESULT_REFUNDED", + } + Bet_Result_value = map[string]int32{ + "RESULT_UNSPECIFIED": 0, + "RESULT_PENDING": 1, + "RESULT_WON": 2, + "RESULT_LOST": 3, + "RESULT_REFUNDED": 4, + } +) + +func (x Bet_Result) Enum() *Bet_Result { + p := new(Bet_Result) + *p = x + return p +} + +func (x Bet_Result) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (Bet_Result) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_bet_v1beta_bet_proto_enumTypes[1].Descriptor() +} + +func (Bet_Result) Type() protoreflect.EnumType { + return &file_sge_legacy_bet_v1beta_bet_proto_enumTypes[1] +} + +func (x Bet_Result) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use Bet_Result.Descriptor instead. +func (Bet_Result) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{0, 1} +} + +// Bet is the transaction order placed by a bettor on a specific event and odd +type Bet struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier assigned to a bet. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // market_uid is the universal unique identifier of + // the market on which the bet is placed. + MarketUid string `protobuf:"bytes,2,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // odds_uid is the universal unique identifier, + // of the odds on which the bet is placed. + OddsUid string `protobuf:"bytes,3,opt,name=odds_uid,proto3" json:"odds_uid,omitempty"` + // odds_value is the odds on which the bet is placed. + OddsValue string `protobuf:"bytes,5,opt,name=odds_value,json=oddsValue,proto3" json:"odds_value,omitempty"` + // amount is the wager amount. + Amount string `protobuf:"bytes,6,opt,name=amount,proto3" json:"amount,omitempty"` + // fee is the betting fee user needs to pay for placing a bet + Fee string `protobuf:"bytes,7,opt,name=fee,proto3" json:"fee,omitempty"` + // status is the status of the bet, such as `unspecified` or `settled`. + Status Bet_Status `protobuf:"varint,8,opt,name=status,proto3,enum=sge.legacy.bet.v1beta.Bet_Status" json:"status,omitempty"` + // result is the result of the bet, such as `won` or `lost`. + Result Bet_Result `protobuf:"varint,9,opt,name=result,proto3,enum=sge.legacy.bet.v1beta.Bet_Result" json:"result,omitempty"` + // creator is the bettor address. + Creator string `protobuf:"bytes,10,opt,name=creator,proto3" json:"creator,omitempty"` + // created_at is the bet placement timestamp. + CreatedAt int64 `protobuf:"varint,11,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` + // settlement_height is the block height at which the bet is settled. + SettlementHeight int64 `protobuf:"varint,12,opt,name=settlement_height,json=settlementHeight,proto3" json:"settlement_height,omitempty"` + // max_loss_multiplier is the multiplier coefficient of max loss. + MaxLossMultiplier string `protobuf:"bytes,13,opt,name=max_loss_multiplier,json=maxLossMultiplier,proto3" json:"max_loss_multiplier,omitempty"` + // bet_fulfillment is the fulfillment data. + BetFulfillment []*BetFulfillment `protobuf:"bytes,14,rep,name=bet_fulfillment,json=betFulfillment,proto3" json:"bet_fulfillment,omitempty"` + // meta is metadata for bet + Meta *MetaData `protobuf:"bytes,15,opt,name=meta,proto3" json:"meta,omitempty"` +} + +func (x *Bet) Reset() { + *x = Bet{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Bet) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Bet) ProtoMessage() {} + +// Deprecated: Use Bet.ProtoReflect.Descriptor instead. +func (*Bet) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{0} +} + +func (x *Bet) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *Bet) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *Bet) GetOddsUid() string { + if x != nil { + return x.OddsUid + } + return "" +} + +func (x *Bet) GetOddsValue() string { + if x != nil { + return x.OddsValue + } + return "" +} + +func (x *Bet) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +func (x *Bet) GetFee() string { + if x != nil { + return x.Fee + } + return "" +} + +func (x *Bet) GetStatus() Bet_Status { + if x != nil { + return x.Status + } + return Bet_STATUS_UNSPECIFIED +} + +func (x *Bet) GetResult() Bet_Result { + if x != nil { + return x.Result + } + return Bet_RESULT_UNSPECIFIED +} + +func (x *Bet) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *Bet) GetCreatedAt() int64 { + if x != nil { + return x.CreatedAt + } + return 0 +} + +func (x *Bet) GetSettlementHeight() int64 { + if x != nil { + return x.SettlementHeight + } + return 0 +} + +func (x *Bet) GetMaxLossMultiplier() string { + if x != nil { + return x.MaxLossMultiplier + } + return "" +} + +func (x *Bet) GetBetFulfillment() []*BetFulfillment { + if x != nil { + return x.BetFulfillment + } + return nil +} + +func (x *Bet) GetMeta() *MetaData { + if x != nil { + return x.Meta + } + return nil +} + +// UID2ID is the type for mapping UIDs and Sequential IDs of bets. +type UID2ID struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier assigned to the bet. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // id is an autogenerated sequential id for a bet. + Id uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *UID2ID) Reset() { + *x = UID2ID{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UID2ID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UID2ID) ProtoMessage() {} + +// Deprecated: Use UID2ID.ProtoReflect.Descriptor instead. +func (*UID2ID) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{1} +} + +func (x *UID2ID) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *UID2ID) GetId() uint64 { + if x != nil { + return x.Id + } + return 0 +} + +// PendingBet is the type for an unsettled bet +type PendingBet struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier for the bet. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // creator is the bettor address. + Creator string `protobuf:"bytes,2,opt,name=creator,proto3" json:"creator,omitempty"` +} + +func (x *PendingBet) Reset() { + *x = PendingBet{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PendingBet) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PendingBet) ProtoMessage() {} + +// Deprecated: Use PendingBet.ProtoReflect.Descriptor instead. +func (*PendingBet) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{2} +} + +func (x *PendingBet) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *PendingBet) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +// SettledBet is the type for a settled bet. +type SettledBet struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier for the bet. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // bettor_address is the bech32 address of the bettor account. + BettorAddress string `protobuf:"bytes,2,opt,name=bettor_address,json=bettorAddress,proto3" json:"bettor_address,omitempty"` +} + +func (x *SettledBet) Reset() { + *x = SettledBet{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SettledBet) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SettledBet) ProtoMessage() {} + +// Deprecated: Use SettledBet.ProtoReflect.Descriptor instead. +func (*SettledBet) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{3} +} + +func (x *SettledBet) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *SettledBet) GetBettorAddress() string { + if x != nil { + return x.BettorAddress + } + return "" +} + +// BetFulfillment: A bet can be fulfilled by multiple users participating as a +// house Every participant is exposed to a share of risk or payout associated +// with the bet For the risk exposure on a bet, an estimated bet amount is also +// allocated to the participant This bet amount is the amount participant +// receive if the bettor loose the bet +type BetFulfillment struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // participant_address is the bech32-encoded address of the participant + // fulfilling bet. + ParticipantAddress string `protobuf:"bytes,1,opt,name=participant_address,json=participantAddress,proto3" json:"participant_address,omitempty"` + // participation_index is the index in initial participation queue index + ParticipationIndex uint64 `protobuf:"varint,2,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // bet amount fulfilled by the participation + BetAmount string `protobuf:"bytes,3,opt,name=bet_amount,json=betAmount,proto3" json:"bet_amount,omitempty"` + // payout_profit is the fulfilled profit by the participation. + PayoutProfit string `protobuf:"bytes,4,opt,name=payout_profit,json=payoutProfit,proto3" json:"payout_profit,omitempty"` +} + +func (x *BetFulfillment) Reset() { + *x = BetFulfillment{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *BetFulfillment) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BetFulfillment) ProtoMessage() {} + +// Deprecated: Use BetFulfillment.ProtoReflect.Descriptor instead. +func (*BetFulfillment) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{4} +} + +func (x *BetFulfillment) GetParticipantAddress() string { + if x != nil { + return x.ParticipantAddress + } + return "" +} + +func (x *BetFulfillment) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *BetFulfillment) GetBetAmount() string { + if x != nil { + return x.BetAmount + } + return "" +} + +func (x *BetFulfillment) GetPayoutProfit() string { + if x != nil { + return x.PayoutProfit + } + return "" +} + +// metadata for bet +type MetaData struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // selected_odds_type is metadata for bet + SelectedOddsType OddsType `protobuf:"varint,1,opt,name=selected_odds_type,json=selectedOddsType,proto3,enum=sge.legacy.bet.v1beta.OddsType" json:"selected_odds_type,omitempty"` + // selected_odds_value is metadata for bet + SelectedOddsValue string `protobuf:"bytes,2,opt,name=selected_odds_value,json=selectedOddsValue,proto3" json:"selected_odds_value,omitempty"` + // is_main_market will tell weather the bet placed on the main market or not + IsMainMarket bool `protobuf:"varint,3,opt,name=is_main_market,json=isMainMarket,proto3" json:"is_main_market,omitempty"` +} + +func (x *MetaData) Reset() { + *x = MetaData{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MetaData) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MetaData) ProtoMessage() {} + +// Deprecated: Use MetaData.ProtoReflect.Descriptor instead. +func (*MetaData) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP(), []int{5} +} + +func (x *MetaData) GetSelectedOddsType() OddsType { + if x != nil { + return x.SelectedOddsType + } + return OddsType_ODDS_TYPE_UNSPECIFIED +} + +func (x *MetaData) GetSelectedOddsValue() string { + if x != nil { + return x.SelectedOddsValue + } + return "" +} + +func (x *MetaData) GetIsMainMarket() bool { + if x != nil { + return x.IsMainMarket + } + return false +} + +var File_sge_legacy_bet_v1beta_bet_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_bet_proto_rawDesc = []byte{ + 0x0a, 0x1f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, + 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x22, 0x85, 0x08, 0x0a, 0x03, 0x42, 0x65, 0x74, 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, + 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x3b, 0x0a, 0x0a, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, + 0xe2, 0xde, 0x1f, 0x09, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, + 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0a, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x33, 0x0a, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, + 0x75, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x17, 0xe2, 0xde, 0x1f, 0x07, 0x4f, + 0x64, 0x64, 0x73, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, + 0x69, 0x64, 0x52, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x1d, 0x0a, 0x0a, + 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x09, 0x6f, 0x64, 0x64, 0x73, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x35, 0x0a, 0x06, 0x61, + 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, + 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, + 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, + 0x6e, 0x74, 0x12, 0x2f, 0x0a, 0x03, 0x66, 0x65, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, + 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x03, + 0x66, 0x65, 0x65, 0x12, 0x39, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x08, 0x20, + 0x01, 0x28, 0x0e, 0x32, 0x21, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, 0x2e, + 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x39, + 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x21, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, + 0x74, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, + 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x1d, 0x0a, + 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x09, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x12, 0x2b, 0x0a, 0x11, + 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x68, 0x65, 0x69, 0x67, 0x68, + 0x74, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x6d, + 0x65, 0x6e, 0x74, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x53, 0x0a, 0x13, 0x6d, 0x61, 0x78, + 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, + 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x42, 0x23, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, + 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0x52, 0x11, 0x6d, 0x61, 0x78, + 0x4c, 0x6f, 0x73, 0x73, 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x12, 0x4e, + 0x0a, 0x0f, 0x62, 0x65, 0x74, 0x5f, 0x66, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x6d, 0x65, 0x6e, + 0x74, 0x18, 0x0e, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x42, 0x65, 0x74, 0x46, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x0e, + 0x62, 0x65, 0x74, 0x46, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x39, + 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x00, 0x52, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x22, 0xa0, 0x01, 0x0a, 0x06, 0x53, 0x74, + 0x61, 0x74, 0x75, 0x73, 0x12, 0x16, 0x0a, 0x12, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, + 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, + 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x50, 0x4c, 0x41, 0x43, 0x45, 0x44, 0x10, 0x01, 0x12, + 0x13, 0x0a, 0x0f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x43, 0x41, 0x4e, 0x43, 0x45, 0x4c, + 0x45, 0x44, 0x10, 0x02, 0x12, 0x12, 0x0a, 0x0e, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, + 0x42, 0x4f, 0x52, 0x54, 0x45, 0x44, 0x10, 0x03, 0x12, 0x12, 0x0a, 0x0e, 0x53, 0x54, 0x41, 0x54, + 0x55, 0x53, 0x5f, 0x50, 0x45, 0x4e, 0x44, 0x49, 0x4e, 0x47, 0x10, 0x04, 0x12, 0x1a, 0x0a, 0x16, + 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x44, 0x45, + 0x43, 0x4c, 0x41, 0x52, 0x45, 0x44, 0x10, 0x05, 0x12, 0x12, 0x0a, 0x0e, 0x53, 0x54, 0x41, 0x54, + 0x55, 0x53, 0x5f, 0x53, 0x45, 0x54, 0x54, 0x4c, 0x45, 0x44, 0x10, 0x06, 0x22, 0x6a, 0x0a, 0x06, + 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x16, 0x0a, 0x12, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, + 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x12, + 0x0a, 0x0e, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x50, 0x45, 0x4e, 0x44, 0x49, 0x4e, 0x47, + 0x10, 0x01, 0x12, 0x0e, 0x0a, 0x0a, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x57, 0x4f, 0x4e, + 0x10, 0x02, 0x12, 0x0f, 0x0a, 0x0b, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x4c, 0x4f, 0x53, + 0x54, 0x10, 0x03, 0x12, 0x13, 0x0a, 0x0f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x52, 0x45, + 0x46, 0x55, 0x4e, 0x44, 0x45, 0x44, 0x10, 0x04, 0x22, 0x48, 0x0a, 0x06, 0x55, 0x49, 0x44, 0x32, + 0x49, 0x44, 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, + 0x03, 0x75, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, + 0x42, 0x0c, 0xe2, 0xde, 0x1f, 0x02, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x02, 0x69, 0x64, 0x52, 0x02, + 0x69, 0x64, 0x22, 0x62, 0x0a, 0x0a, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x65, 0x74, + 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, + 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, + 0x69, 0x64, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x6f, 0x0a, 0x0a, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, + 0x64, 0x42, 0x65, 0x74, 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, + 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x3f, 0x0a, 0x0e, 0x62, 0x65, 0x74, 0x74, 0x6f, 0x72, + 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, + 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x0d, 0x62, 0x65, 0x74, 0x74, 0x6f, 0x72, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xe1, 0x02, 0x0a, 0x0e, 0x42, 0x65, 0x74, 0x46, + 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x4f, 0x0a, 0x13, 0x70, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1e, 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, 0x6d, + 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x6e, 0x74, 0x5f, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x4f, 0x0a, 0x13, 0x70, + 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, + 0x65, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1e, 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, + 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x51, 0x0a, 0x0a, + 0x62, 0x65, 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x32, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, + 0xde, 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x62, 0x65, 0x74, 0x5f, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x22, 0x52, 0x09, 0x62, 0x65, 0x74, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, + 0x5a, 0x0a, 0x0d, 0x70, 0x61, 0x79, 0x6f, 0x75, 0x74, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x74, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x35, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, + 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x14, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, + 0x61, 0x79, 0x6f, 0x75, 0x74, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x74, 0x22, 0x52, 0x0c, 0x70, + 0x61, 0x79, 0x6f, 0x75, 0x74, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x74, 0x22, 0xaf, 0x01, 0x0a, 0x08, + 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, 0x12, 0x4d, 0x0a, 0x12, 0x73, 0x65, 0x6c, 0x65, + 0x63, 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x64, 0x64, + 0x73, 0x54, 0x79, 0x70, 0x65, 0x52, 0x10, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x65, 0x64, 0x4f, + 0x64, 0x64, 0x73, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2e, 0x0a, 0x13, 0x73, 0x65, 0x6c, 0x65, 0x63, + 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x11, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x65, 0x64, 0x4f, 0x64, + 0x64, 0x73, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x24, 0x0a, 0x0e, 0x69, 0x73, 0x5f, 0x6d, 0x61, + 0x69, 0x6e, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x0c, 0x69, 0x73, 0x4d, 0x61, 0x69, 0x6e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x42, 0xdc, 0x01, + 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x08, 0x42, 0x65, 0x74, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x62, 0x65, + 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x42, 0xaa, 0x02, 0x15, + 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, + 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, + 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_bet_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_bet_proto_rawDescData = file_sge_legacy_bet_v1beta_bet_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_bet_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_bet_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_bet_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_bet_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_bet_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_bet_proto_enumTypes = make([]protoimpl.EnumInfo, 2) +var file_sge_legacy_bet_v1beta_bet_proto_msgTypes = make([]protoimpl.MessageInfo, 6) +var file_sge_legacy_bet_v1beta_bet_proto_goTypes = []interface{}{ + (Bet_Status)(0), // 0: sge.legacy.bet.v1beta.Bet.Status + (Bet_Result)(0), // 1: sge.legacy.bet.v1beta.Bet.Result + (*Bet)(nil), // 2: sge.legacy.bet.v1beta.Bet + (*UID2ID)(nil), // 3: sge.legacy.bet.v1beta.UID2ID + (*PendingBet)(nil), // 4: sge.legacy.bet.v1beta.PendingBet + (*SettledBet)(nil), // 5: sge.legacy.bet.v1beta.SettledBet + (*BetFulfillment)(nil), // 6: sge.legacy.bet.v1beta.BetFulfillment + (*MetaData)(nil), // 7: sge.legacy.bet.v1beta.MetaData + (OddsType)(0), // 8: sge.legacy.bet.v1beta.OddsType +} +var file_sge_legacy_bet_v1beta_bet_proto_depIdxs = []int32{ + 0, // 0: sge.legacy.bet.v1beta.Bet.status:type_name -> sge.legacy.bet.v1beta.Bet.Status + 1, // 1: sge.legacy.bet.v1beta.Bet.result:type_name -> sge.legacy.bet.v1beta.Bet.Result + 6, // 2: sge.legacy.bet.v1beta.Bet.bet_fulfillment:type_name -> sge.legacy.bet.v1beta.BetFulfillment + 7, // 3: sge.legacy.bet.v1beta.Bet.meta:type_name -> sge.legacy.bet.v1beta.MetaData + 8, // 4: sge.legacy.bet.v1beta.MetaData.selected_odds_type:type_name -> sge.legacy.bet.v1beta.OddsType + 5, // [5:5] is the sub-list for method output_type + 5, // [5:5] is the sub-list for method input_type + 5, // [5:5] is the sub-list for extension type_name + 5, // [5:5] is the sub-list for extension extendee + 0, // [0:5] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_bet_proto_init() } +func file_sge_legacy_bet_v1beta_bet_proto_init() { + if File_sge_legacy_bet_v1beta_bet_proto != nil { + return + } + file_sge_legacy_bet_v1beta_odds_type_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_bet_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Bet); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_bet_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UID2ID); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_bet_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PendingBet); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_bet_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SettledBet); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_bet_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*BetFulfillment); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_bet_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MetaData); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_bet_proto_rawDesc, + NumEnums: 2, + NumMessages: 6, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_bet_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_bet_proto_depIdxs, + EnumInfos: file_sge_legacy_bet_v1beta_bet_proto_enumTypes, + MessageInfos: file_sge_legacy_bet_v1beta_bet_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_bet_proto = out.File + file_sge_legacy_bet_v1beta_bet_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_bet_proto_goTypes = nil + file_sge_legacy_bet_v1beta_bet_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/bet_odds.pulsar.go b/api/sge/legacy/bet/v1beta/bet_odds.pulsar.go new file mode 100644 index 00000000..adde04c0 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/bet_odds.pulsar.go @@ -0,0 +1,1366 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_BetOdds protoreflect.MessageDescriptor + fd_BetOdds_uid protoreflect.FieldDescriptor + fd_BetOdds_market_uid protoreflect.FieldDescriptor + fd_BetOdds_value protoreflect.FieldDescriptor + fd_BetOdds_max_loss_multiplier protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_odds_proto_init() + md_BetOdds = File_sge_legacy_bet_v1beta_bet_odds_proto.Messages().ByName("BetOdds") + fd_BetOdds_uid = md_BetOdds.Fields().ByName("uid") + fd_BetOdds_market_uid = md_BetOdds.Fields().ByName("market_uid") + fd_BetOdds_value = md_BetOdds.Fields().ByName("value") + fd_BetOdds_max_loss_multiplier = md_BetOdds.Fields().ByName("max_loss_multiplier") +} + +var _ protoreflect.Message = (*fastReflection_BetOdds)(nil) + +type fastReflection_BetOdds BetOdds + +func (x *BetOdds) ProtoReflect() protoreflect.Message { + return (*fastReflection_BetOdds)(x) +} + +func (x *BetOdds) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_BetOdds_messageType fastReflection_BetOdds_messageType +var _ protoreflect.MessageType = fastReflection_BetOdds_messageType{} + +type fastReflection_BetOdds_messageType struct{} + +func (x fastReflection_BetOdds_messageType) Zero() protoreflect.Message { + return (*fastReflection_BetOdds)(nil) +} +func (x fastReflection_BetOdds_messageType) New() protoreflect.Message { + return new(fastReflection_BetOdds) +} +func (x fastReflection_BetOdds_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_BetOdds +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_BetOdds) Descriptor() protoreflect.MessageDescriptor { + return md_BetOdds +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_BetOdds) Type() protoreflect.MessageType { + return _fastReflection_BetOdds_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_BetOdds) New() protoreflect.Message { + return new(fastReflection_BetOdds) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_BetOdds) Interface() protoreflect.ProtoMessage { + return (*BetOdds)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_BetOdds) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_BetOdds_uid, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_BetOdds_market_uid, value) { + return + } + } + if x.Value != "" { + value := protoreflect.ValueOfString(x.Value) + if !f(fd_BetOdds_value, value) { + return + } + } + if x.MaxLossMultiplier != "" { + value := protoreflect.ValueOfString(x.MaxLossMultiplier) + if !f(fd_BetOdds_max_loss_multiplier, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_BetOdds) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOdds.uid": + return x.Uid != "" + case "sge.legacy.bet.v1beta.BetOdds.market_uid": + return x.MarketUid != "" + case "sge.legacy.bet.v1beta.BetOdds.value": + return x.Value != "" + case "sge.legacy.bet.v1beta.BetOdds.max_loss_multiplier": + return x.MaxLossMultiplier != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOdds")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOdds does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOdds) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOdds.uid": + x.Uid = "" + case "sge.legacy.bet.v1beta.BetOdds.market_uid": + x.MarketUid = "" + case "sge.legacy.bet.v1beta.BetOdds.value": + x.Value = "" + case "sge.legacy.bet.v1beta.BetOdds.max_loss_multiplier": + x.MaxLossMultiplier = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOdds")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOdds does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_BetOdds) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.BetOdds.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.BetOdds.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.BetOdds.value": + value := x.Value + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.BetOdds.max_loss_multiplier": + value := x.MaxLossMultiplier + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOdds")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOdds does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOdds) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOdds.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.bet.v1beta.BetOdds.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.bet.v1beta.BetOdds.value": + x.Value = value.Interface().(string) + case "sge.legacy.bet.v1beta.BetOdds.max_loss_multiplier": + x.MaxLossMultiplier = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOdds")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOdds does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOdds) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOdds.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.BetOdds is not mutable")) + case "sge.legacy.bet.v1beta.BetOdds.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.bet.v1beta.BetOdds is not mutable")) + case "sge.legacy.bet.v1beta.BetOdds.value": + panic(fmt.Errorf("field value of message sge.legacy.bet.v1beta.BetOdds is not mutable")) + case "sge.legacy.bet.v1beta.BetOdds.max_loss_multiplier": + panic(fmt.Errorf("field max_loss_multiplier of message sge.legacy.bet.v1beta.BetOdds is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOdds")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOdds does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_BetOdds) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOdds.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.BetOdds.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.BetOdds.value": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.BetOdds.max_loss_multiplier": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOdds")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOdds does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_BetOdds) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.BetOdds", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_BetOdds) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOdds) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_BetOdds) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_BetOdds) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*BetOdds) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Value) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MaxLossMultiplier) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*BetOdds) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.MaxLossMultiplier) > 0 { + i -= len(x.MaxLossMultiplier) + copy(dAtA[i:], x.MaxLossMultiplier) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MaxLossMultiplier))) + i-- + dAtA[i] = 0x22 + } + if len(x.Value) > 0 { + i -= len(x.Value) + copy(dAtA[i:], x.Value) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Value))) + i-- + dAtA[i] = 0x1a + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*BetOdds) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetOdds: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetOdds: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Value = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxLossMultiplier", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MaxLossMultiplier = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_BetOddsCompact protoreflect.MessageDescriptor + fd_BetOddsCompact_uid protoreflect.FieldDescriptor + fd_BetOddsCompact_max_loss_multiplier protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_bet_odds_proto_init() + md_BetOddsCompact = File_sge_legacy_bet_v1beta_bet_odds_proto.Messages().ByName("BetOddsCompact") + fd_BetOddsCompact_uid = md_BetOddsCompact.Fields().ByName("uid") + fd_BetOddsCompact_max_loss_multiplier = md_BetOddsCompact.Fields().ByName("max_loss_multiplier") +} + +var _ protoreflect.Message = (*fastReflection_BetOddsCompact)(nil) + +type fastReflection_BetOddsCompact BetOddsCompact + +func (x *BetOddsCompact) ProtoReflect() protoreflect.Message { + return (*fastReflection_BetOddsCompact)(x) +} + +func (x *BetOddsCompact) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_BetOddsCompact_messageType fastReflection_BetOddsCompact_messageType +var _ protoreflect.MessageType = fastReflection_BetOddsCompact_messageType{} + +type fastReflection_BetOddsCompact_messageType struct{} + +func (x fastReflection_BetOddsCompact_messageType) Zero() protoreflect.Message { + return (*fastReflection_BetOddsCompact)(nil) +} +func (x fastReflection_BetOddsCompact_messageType) New() protoreflect.Message { + return new(fastReflection_BetOddsCompact) +} +func (x fastReflection_BetOddsCompact_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_BetOddsCompact +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_BetOddsCompact) Descriptor() protoreflect.MessageDescriptor { + return md_BetOddsCompact +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_BetOddsCompact) Type() protoreflect.MessageType { + return _fastReflection_BetOddsCompact_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_BetOddsCompact) New() protoreflect.Message { + return new(fastReflection_BetOddsCompact) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_BetOddsCompact) Interface() protoreflect.ProtoMessage { + return (*BetOddsCompact)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_BetOddsCompact) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_BetOddsCompact_uid, value) { + return + } + } + if x.MaxLossMultiplier != "" { + value := protoreflect.ValueOfString(x.MaxLossMultiplier) + if !f(fd_BetOddsCompact_max_loss_multiplier, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_BetOddsCompact) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOddsCompact.uid": + return x.Uid != "" + case "sge.legacy.bet.v1beta.BetOddsCompact.max_loss_multiplier": + return x.MaxLossMultiplier != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOddsCompact")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOddsCompact does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOddsCompact) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOddsCompact.uid": + x.Uid = "" + case "sge.legacy.bet.v1beta.BetOddsCompact.max_loss_multiplier": + x.MaxLossMultiplier = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOddsCompact")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOddsCompact does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_BetOddsCompact) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.BetOddsCompact.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.BetOddsCompact.max_loss_multiplier": + value := x.MaxLossMultiplier + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOddsCompact")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOddsCompact does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOddsCompact) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOddsCompact.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.bet.v1beta.BetOddsCompact.max_loss_multiplier": + x.MaxLossMultiplier = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOddsCompact")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOddsCompact does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOddsCompact) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOddsCompact.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.BetOddsCompact is not mutable")) + case "sge.legacy.bet.v1beta.BetOddsCompact.max_loss_multiplier": + panic(fmt.Errorf("field max_loss_multiplier of message sge.legacy.bet.v1beta.BetOddsCompact is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOddsCompact")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOddsCompact does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_BetOddsCompact) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetOddsCompact.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.BetOddsCompact.max_loss_multiplier": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetOddsCompact")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetOddsCompact does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_BetOddsCompact) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.BetOddsCompact", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_BetOddsCompact) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetOddsCompact) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_BetOddsCompact) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_BetOddsCompact) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*BetOddsCompact) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MaxLossMultiplier) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*BetOddsCompact) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.MaxLossMultiplier) > 0 { + i -= len(x.MaxLossMultiplier) + copy(dAtA[i:], x.MaxLossMultiplier) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MaxLossMultiplier))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*BetOddsCompact) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetOddsCompact: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetOddsCompact: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxLossMultiplier", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MaxLossMultiplier = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/bet_odds.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// BetOdds is the type to store odds of a market. +type BetOdds struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is universal unique identifier of odds. + // Required | Unique | uuid-v4 or code + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // market_uid is the parent, used for fast retrieving. + // Required | NonUnique | - + MarketUid string `protobuf:"bytes,2,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // value of the odds in corresponding odds type proposed in bet placement + // message. Required | NonUnique | "1.286" or "2/7" or "+500" + Value string `protobuf:"bytes,3,opt,name=value,proto3" json:"value,omitempty"` + // max_loss_multiplier is the factor for calculating max loss for given odds + MaxLossMultiplier string `protobuf:"bytes,4,opt,name=max_loss_multiplier,proto3" json:"max_loss_multiplier,omitempty"` +} + +func (x *BetOdds) Reset() { + *x = BetOdds{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *BetOdds) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BetOdds) ProtoMessage() {} + +// Deprecated: Use BetOdds.ProtoReflect.Descriptor instead. +func (*BetOdds) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescGZIP(), []int{0} +} + +func (x *BetOdds) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *BetOdds) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *BetOdds) GetValue() string { + if x != nil { + return x.Value + } + return "" +} + +func (x *BetOdds) GetMaxLossMultiplier() string { + if x != nil { + return x.MaxLossMultiplier + } + return "" +} + +// BetOddsCompact is the compact bet odd type for all odds. +type BetOddsCompact struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is universal unique identifier of odds. + // Required | Unique | uuid-v4 or code + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // max_loss_multiplier is the factor for calculating max loss for given odds + MaxLossMultiplier string `protobuf:"bytes,2,opt,name=max_loss_multiplier,proto3" json:"max_loss_multiplier,omitempty"` +} + +func (x *BetOddsCompact) Reset() { + *x = BetOddsCompact{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *BetOddsCompact) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BetOddsCompact) ProtoMessage() {} + +// Deprecated: Use BetOddsCompact.ProtoReflect.Descriptor instead. +func (*BetOddsCompact) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescGZIP(), []int{1} +} + +func (x *BetOddsCompact) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *BetOddsCompact) GetMaxLossMultiplier() string { + if x != nil { + return x.MaxLossMultiplier + } + return "" +} + +var File_sge_legacy_bet_v1beta_bet_odds_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_bet_odds_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x65, 0x74, 0x5f, 0x6f, 0x64, 0x64, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, + 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x22, 0x82, 0x02, 0x0a, 0x07, 0x42, 0x65, 0x74, 0x4f, 0x64, 0x64, 0x73, 0x12, + 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, + 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, + 0x64, 0x12, 0x3b, 0x0a, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, + 0x69, 0x64, 0x52, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x14, + 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, + 0x61, 0x6c, 0x75, 0x65, 0x12, 0x81, 0x01, 0x0a, 0x13, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, + 0x73, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x42, 0x4f, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xe2, 0xde, 0x1f, 0x11, 0x4d, 0x61, 0x78, 0x4c, 0x6f, + 0x73, 0x73, 0x4d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0xea, 0xde, 0x1f, 0x13, + 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, + 0x69, 0x65, 0x72, 0x52, 0x13, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x5f, 0x6d, 0x75, + 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x22, 0xb6, 0x01, 0x0a, 0x0e, 0x42, 0x65, 0x74, + 0x4f, 0x64, 0x64, 0x73, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x63, 0x74, 0x12, 0x20, 0x0a, 0x03, 0x75, + 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, + 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x81, 0x01, + 0x0a, 0x13, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, + 0x70, 0x6c, 0x69, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x4f, 0xc8, 0xde, 0x1f, + 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, + 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, + 0xe2, 0xde, 0x1f, 0x11, 0x4d, 0x61, 0x78, 0x4c, 0x6f, 0x73, 0x73, 0x4d, 0x75, 0x6c, 0x74, 0x69, + 0x70, 0x6c, 0x69, 0x65, 0x72, 0xea, 0xde, 0x1f, 0x13, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, + 0x73, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x52, 0x13, 0x6d, 0x61, + 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x5f, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x69, 0x65, + 0x72, 0x42, 0xe0, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, + 0x0c, 0x42, 0x65, 0x74, 0x4f, 0x64, 0x64, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, + 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, + 0x02, 0x03, 0x53, 0x4c, 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, + 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, + 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescData = file_sge_legacy_bet_v1beta_bet_odds_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_bet_odds_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_bet_v1beta_bet_odds_proto_goTypes = []interface{}{ + (*BetOdds)(nil), // 0: sge.legacy.bet.v1beta.BetOdds + (*BetOddsCompact)(nil), // 1: sge.legacy.bet.v1beta.BetOddsCompact +} +var file_sge_legacy_bet_v1beta_bet_odds_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_bet_odds_proto_init() } +func file_sge_legacy_bet_v1beta_bet_odds_proto_init() { + if File_sge_legacy_bet_v1beta_bet_odds_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*BetOdds); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*BetOddsCompact); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_bet_odds_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_bet_odds_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_bet_odds_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_bet_odds_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_bet_odds_proto = out.File + file_sge_legacy_bet_v1beta_bet_odds_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_bet_odds_proto_goTypes = nil + file_sge_legacy_bet_v1beta_bet_odds_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/constraints.pulsar.go b/api/sge/legacy/bet/v1beta/constraints.pulsar.go new file mode 100644 index 00000000..09b0b102 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/constraints.pulsar.go @@ -0,0 +1,654 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Constraints protoreflect.MessageDescriptor + fd_Constraints_min_amount protoreflect.FieldDescriptor + fd_Constraints_fee protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_constraints_proto_init() + md_Constraints = File_sge_legacy_bet_v1beta_constraints_proto.Messages().ByName("Constraints") + fd_Constraints_min_amount = md_Constraints.Fields().ByName("min_amount") + fd_Constraints_fee = md_Constraints.Fields().ByName("fee") +} + +var _ protoreflect.Message = (*fastReflection_Constraints)(nil) + +type fastReflection_Constraints Constraints + +func (x *Constraints) ProtoReflect() protoreflect.Message { + return (*fastReflection_Constraints)(x) +} + +func (x *Constraints) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_constraints_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Constraints_messageType fastReflection_Constraints_messageType +var _ protoreflect.MessageType = fastReflection_Constraints_messageType{} + +type fastReflection_Constraints_messageType struct{} + +func (x fastReflection_Constraints_messageType) Zero() protoreflect.Message { + return (*fastReflection_Constraints)(nil) +} +func (x fastReflection_Constraints_messageType) New() protoreflect.Message { + return new(fastReflection_Constraints) +} +func (x fastReflection_Constraints_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Constraints +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Constraints) Descriptor() protoreflect.MessageDescriptor { + return md_Constraints +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Constraints) Type() protoreflect.MessageType { + return _fastReflection_Constraints_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Constraints) New() protoreflect.Message { + return new(fastReflection_Constraints) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Constraints) Interface() protoreflect.ProtoMessage { + return (*Constraints)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Constraints) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MinAmount != "" { + value := protoreflect.ValueOfString(x.MinAmount) + if !f(fd_Constraints_min_amount, value) { + return + } + } + if x.Fee != "" { + value := protoreflect.ValueOfString(x.Fee) + if !f(fd_Constraints_fee, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Constraints) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Constraints.min_amount": + return x.MinAmount != "" + case "sge.legacy.bet.v1beta.Constraints.fee": + return x.Fee != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Constraints")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Constraints does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Constraints) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Constraints.min_amount": + x.MinAmount = "" + case "sge.legacy.bet.v1beta.Constraints.fee": + x.Fee = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Constraints")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Constraints does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Constraints) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.Constraints.min_amount": + value := x.MinAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.Constraints.fee": + value := x.Fee + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Constraints")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Constraints does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Constraints) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Constraints.min_amount": + x.MinAmount = value.Interface().(string) + case "sge.legacy.bet.v1beta.Constraints.fee": + x.Fee = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Constraints")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Constraints does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Constraints) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Constraints.min_amount": + panic(fmt.Errorf("field min_amount of message sge.legacy.bet.v1beta.Constraints is not mutable")) + case "sge.legacy.bet.v1beta.Constraints.fee": + panic(fmt.Errorf("field fee of message sge.legacy.bet.v1beta.Constraints is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Constraints")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Constraints does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Constraints) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Constraints.min_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.Constraints.fee": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Constraints")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Constraints does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Constraints) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.Constraints", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Constraints) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Constraints) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Constraints) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Constraints) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Constraints) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.MinAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Fee) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Constraints) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Fee) > 0 { + i -= len(x.Fee) + copy(dAtA[i:], x.Fee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Fee))) + i-- + dAtA[i] = 0x12 + } + if len(x.MinAmount) > 0 { + i -= len(x.MinAmount) + copy(dAtA[i:], x.MinAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MinAmount))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Constraints) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Constraints: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Constraints: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MinAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Fee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Fee = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/constraints.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Constraints is the bet constrains type for the bets +type Constraints struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // min_amount is the minimum allowed bet amount. + MinAmount string `protobuf:"bytes,1,opt,name=min_amount,json=minAmount,proto3" json:"min_amount,omitempty"` + // fee is the fee that the bettor needs to pay to bet. + Fee string `protobuf:"bytes,2,opt,name=fee,proto3" json:"fee,omitempty"` +} + +func (x *Constraints) Reset() { + *x = Constraints{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_constraints_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Constraints) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Constraints) ProtoMessage() {} + +// Deprecated: Use Constraints.ProtoReflect.Descriptor instead. +func (*Constraints) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_constraints_proto_rawDescGZIP(), []int{0} +} + +func (x *Constraints) GetMinAmount() string { + if x != nil { + return x.MinAmount + } + return "" +} + +func (x *Constraints) GetFee() string { + if x != nil { + return x.Fee + } + return "" +} + +var File_sge_legacy_bet_v1beta_constraints_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_constraints_proto_rawDesc = []byte{ + 0x0a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, + 0x6e, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x7c, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, + 0x61, 0x69, 0x6e, 0x74, 0x73, 0x12, 0x3c, 0x0a, 0x0a, 0x6d, 0x69, 0x6e, 0x5f, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, + 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x09, 0x6d, 0x69, 0x6e, 0x41, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x12, 0x2f, 0x0a, 0x03, 0x66, 0x65, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, + 0x03, 0x66, 0x65, 0x65, 0x42, 0xe4, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x42, 0x10, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x50, + 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, + 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x62, 0x65, 0x74, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x42, 0xaa, 0x02, 0x15, 0x53, + 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, + 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_constraints_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_constraints_proto_rawDescData = file_sge_legacy_bet_v1beta_constraints_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_constraints_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_constraints_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_constraints_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_constraints_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_constraints_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_constraints_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_bet_v1beta_constraints_proto_goTypes = []interface{}{ + (*Constraints)(nil), // 0: sge.legacy.bet.v1beta.Constraints +} +var file_sge_legacy_bet_v1beta_constraints_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_constraints_proto_init() } +func file_sge_legacy_bet_v1beta_constraints_proto_init() { + if File_sge_legacy_bet_v1beta_constraints_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_constraints_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Constraints); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_constraints_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_constraints_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_constraints_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_constraints_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_constraints_proto = out.File + file_sge_legacy_bet_v1beta_constraints_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_constraints_proto_goTypes = nil + file_sge_legacy_bet_v1beta_constraints_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/genesis.pulsar.go b/api/sge/legacy/bet/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..b81a59f1 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/genesis.pulsar.go @@ -0,0 +1,1312 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_2_list)(nil) + +type _GenesisState_2_list struct { + list *[]*Bet +} + +func (x *_GenesisState_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_2_list) AppendMutable() protoreflect.Value { + v := new(Bet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_2_list) NewElement() protoreflect.Value { + v := new(Bet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_3_list)(nil) + +type _GenesisState_3_list struct { + list *[]*PendingBet +} + +func (x *_GenesisState_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PendingBet) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PendingBet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_3_list) AppendMutable() protoreflect.Value { + v := new(PendingBet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_3_list) NewElement() protoreflect.Value { + v := new(PendingBet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_4_list)(nil) + +type _GenesisState_4_list struct { + list *[]*SettledBet +} + +func (x *_GenesisState_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*SettledBet) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*SettledBet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_4_list) AppendMutable() protoreflect.Value { + v := new(SettledBet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_4_list) NewElement() protoreflect.Value { + v := new(SettledBet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_4_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_5_list)(nil) + +type _GenesisState_5_list struct { + list *[]*UID2ID +} + +func (x *_GenesisState_5_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_5_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_5_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*UID2ID) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_5_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*UID2ID) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_5_list) AppendMutable() protoreflect.Value { + v := new(UID2ID) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_5_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_5_list) NewElement() protoreflect.Value { + v := new(UID2ID) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_5_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor + fd_GenesisState_bet_list protoreflect.FieldDescriptor + fd_GenesisState_pending_bet_list protoreflect.FieldDescriptor + fd_GenesisState_settled_bet_list protoreflect.FieldDescriptor + fd_GenesisState_uid2id_list protoreflect.FieldDescriptor + fd_GenesisState_stats protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_genesis_proto_init() + md_GenesisState = File_sge_legacy_bet_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") + fd_GenesisState_bet_list = md_GenesisState.Fields().ByName("bet_list") + fd_GenesisState_pending_bet_list = md_GenesisState.Fields().ByName("pending_bet_list") + fd_GenesisState_settled_bet_list = md_GenesisState.Fields().ByName("settled_bet_list") + fd_GenesisState_uid2id_list = md_GenesisState.Fields().ByName("uid2id_list") + fd_GenesisState_stats = md_GenesisState.Fields().ByName("stats") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } + if len(x.BetList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_2_list{list: &x.BetList}) + if !f(fd_GenesisState_bet_list, value) { + return + } + } + if len(x.PendingBetList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_3_list{list: &x.PendingBetList}) + if !f(fd_GenesisState_pending_bet_list, value) { + return + } + } + if len(x.SettledBetList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_4_list{list: &x.SettledBetList}) + if !f(fd_GenesisState_settled_bet_list, value) { + return + } + } + if len(x.Uid2IdList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_5_list{list: &x.Uid2IdList}) + if !f(fd_GenesisState_uid2id_list, value) { + return + } + } + if x.Stats != nil { + value := protoreflect.ValueOfMessage(x.Stats.ProtoReflect()) + if !f(fd_GenesisState_stats, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.GenesisState.params": + return x.Params != nil + case "sge.legacy.bet.v1beta.GenesisState.bet_list": + return len(x.BetList) != 0 + case "sge.legacy.bet.v1beta.GenesisState.pending_bet_list": + return len(x.PendingBetList) != 0 + case "sge.legacy.bet.v1beta.GenesisState.settled_bet_list": + return len(x.SettledBetList) != 0 + case "sge.legacy.bet.v1beta.GenesisState.uid2id_list": + return len(x.Uid2IdList) != 0 + case "sge.legacy.bet.v1beta.GenesisState.stats": + return x.Stats != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.GenesisState.params": + x.Params = nil + case "sge.legacy.bet.v1beta.GenesisState.bet_list": + x.BetList = nil + case "sge.legacy.bet.v1beta.GenesisState.pending_bet_list": + x.PendingBetList = nil + case "sge.legacy.bet.v1beta.GenesisState.settled_bet_list": + x.SettledBetList = nil + case "sge.legacy.bet.v1beta.GenesisState.uid2id_list": + x.Uid2IdList = nil + case "sge.legacy.bet.v1beta.GenesisState.stats": + x.Stats = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.GenesisState.bet_list": + if len(x.BetList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_2_list{}) + } + listValue := &_GenesisState_2_list{list: &x.BetList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.GenesisState.pending_bet_list": + if len(x.PendingBetList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_3_list{}) + } + listValue := &_GenesisState_3_list{list: &x.PendingBetList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.GenesisState.settled_bet_list": + if len(x.SettledBetList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_4_list{}) + } + listValue := &_GenesisState_4_list{list: &x.SettledBetList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.GenesisState.uid2id_list": + if len(x.Uid2IdList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_5_list{}) + } + listValue := &_GenesisState_5_list{list: &x.Uid2IdList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.GenesisState.stats": + value := x.Stats + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + case "sge.legacy.bet.v1beta.GenesisState.bet_list": + lv := value.List() + clv := lv.(*_GenesisState_2_list) + x.BetList = *clv.list + case "sge.legacy.bet.v1beta.GenesisState.pending_bet_list": + lv := value.List() + clv := lv.(*_GenesisState_3_list) + x.PendingBetList = *clv.list + case "sge.legacy.bet.v1beta.GenesisState.settled_bet_list": + lv := value.List() + clv := lv.(*_GenesisState_4_list) + x.SettledBetList = *clv.list + case "sge.legacy.bet.v1beta.GenesisState.uid2id_list": + lv := value.List() + clv := lv.(*_GenesisState_5_list) + x.Uid2IdList = *clv.list + case "sge.legacy.bet.v1beta.GenesisState.stats": + x.Stats = value.Message().Interface().(*BetStats) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.bet.v1beta.GenesisState.bet_list": + if x.BetList == nil { + x.BetList = []*Bet{} + } + value := &_GenesisState_2_list{list: &x.BetList} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.GenesisState.pending_bet_list": + if x.PendingBetList == nil { + x.PendingBetList = []*PendingBet{} + } + value := &_GenesisState_3_list{list: &x.PendingBetList} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.GenesisState.settled_bet_list": + if x.SettledBetList == nil { + x.SettledBetList = []*SettledBet{} + } + value := &_GenesisState_4_list{list: &x.SettledBetList} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.GenesisState.uid2id_list": + if x.Uid2IdList == nil { + x.Uid2IdList = []*UID2ID{} + } + value := &_GenesisState_5_list{list: &x.Uid2IdList} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.GenesisState.stats": + if x.Stats == nil { + x.Stats = new(BetStats) + } + return protoreflect.ValueOfMessage(x.Stats.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.GenesisState.bet_list": + list := []*Bet{} + return protoreflect.ValueOfList(&_GenesisState_2_list{list: &list}) + case "sge.legacy.bet.v1beta.GenesisState.pending_bet_list": + list := []*PendingBet{} + return protoreflect.ValueOfList(&_GenesisState_3_list{list: &list}) + case "sge.legacy.bet.v1beta.GenesisState.settled_bet_list": + list := []*SettledBet{} + return protoreflect.ValueOfList(&_GenesisState_4_list{list: &list}) + case "sge.legacy.bet.v1beta.GenesisState.uid2id_list": + list := []*UID2ID{} + return protoreflect.ValueOfList(&_GenesisState_5_list{list: &list}) + case "sge.legacy.bet.v1beta.GenesisState.stats": + m := new(BetStats) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.BetList) > 0 { + for _, e := range x.BetList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.PendingBetList) > 0 { + for _, e := range x.PendingBetList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.SettledBetList) > 0 { + for _, e := range x.SettledBetList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.Uid2IdList) > 0 { + for _, e := range x.Uid2IdList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Stats != nil { + l = options.Size(x.Stats) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Stats != nil { + encoded, err := options.Marshal(x.Stats) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x32 + } + if len(x.Uid2IdList) > 0 { + for iNdEx := len(x.Uid2IdList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Uid2IdList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x2a + } + } + if len(x.SettledBetList) > 0 { + for iNdEx := len(x.SettledBetList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.SettledBetList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if len(x.PendingBetList) > 0 { + for iNdEx := len(x.PendingBetList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.PendingBetList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if len(x.BetList) > 0 { + for iNdEx := len(x.BetList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.BetList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BetList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BetList = append(x.BetList, &Bet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.BetList[len(x.BetList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PendingBetList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PendingBetList = append(x.PendingBetList, &PendingBet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.PendingBetList[len(x.PendingBetList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SettledBetList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SettledBetList = append(x.SettledBetList, &SettledBet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.SettledBetList[len(x.SettledBetList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid2IdList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid2IdList = append(x.Uid2IdList, &UID2ID{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Uid2IdList[len(x.Uid2IdList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Stats", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Stats == nil { + x.Stats = &BetStats{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Stats); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the bet module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params contains parameters of bet module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` + // bet_list contains the bet list in the genesis init. + BetList []*Bet `protobuf:"bytes,2,rep,name=bet_list,json=betList,proto3" json:"bet_list,omitempty"` + // pending_bet_list contains the pending bet list in the genesis init. + PendingBetList []*PendingBet `protobuf:"bytes,3,rep,name=pending_bet_list,json=pendingBetList,proto3" json:"pending_bet_list,omitempty"` + // settled_bet_list contains the settled bet list in the genesis init. + SettledBetList []*SettledBet `protobuf:"bytes,4,rep,name=settled_bet_list,json=settledBetList,proto3" json:"settled_bet_list,omitempty"` + // uid2id_list contains bet to id list in the genesis init. + Uid2IdList []*UID2ID `protobuf:"bytes,5,rep,name=uid2id_list,json=uid2idList,proto3" json:"uid2id_list,omitempty"` + // stats contains statistics in the genesis init. + Stats *BetStats `protobuf:"bytes,6,opt,name=stats,proto3" json:"stats,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +func (x *GenesisState) GetBetList() []*Bet { + if x != nil { + return x.BetList + } + return nil +} + +func (x *GenesisState) GetPendingBetList() []*PendingBet { + if x != nil { + return x.PendingBetList + } + return nil +} + +func (x *GenesisState) GetSettledBetList() []*SettledBet { + if x != nil { + return x.SettledBetList + } + return nil +} + +func (x *GenesisState) GetUid2IdList() []*UID2ID { + if x != nil { + return x.Uid2IdList + } + return nil +} + +func (x *GenesisState) GetStats() *BetStats { + if x != nil { + return x.Stats + } + return nil +} + +var File_sge_legacy_bet_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x23, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x1f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, + 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x65, 0x74, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x73, + 0x74, 0x61, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb1, 0x03, 0x0a, 0x0c, 0x47, + 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x3b, 0x0a, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, + 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x3b, 0x0a, 0x08, 0x62, 0x65, 0x74, 0x5f, + 0x6c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x62, 0x65, + 0x74, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x51, 0x0a, 0x10, 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, + 0x5f, 0x62, 0x65, 0x74, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x21, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, + 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0e, 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e, + 0x67, 0x42, 0x65, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x51, 0x0a, 0x10, 0x73, 0x65, 0x74, 0x74, + 0x6c, 0x65, 0x64, 0x5f, 0x62, 0x65, 0x74, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x53, 0x65, 0x74, 0x74, 0x6c, + 0x65, 0x64, 0x42, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0e, 0x73, 0x65, 0x74, + 0x74, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x44, 0x0a, 0x0b, 0x75, + 0x69, 0x64, 0x32, 0x69, 0x64, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x55, 0x49, 0x44, 0x32, 0x49, 0x44, 0x42, + 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0a, 0x75, 0x69, 0x64, 0x32, 0x69, 0x64, 0x4c, 0x69, 0x73, + 0x74, 0x12, 0x3b, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x42, 0xe0, + 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, 0x47, 0x65, + 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, + 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, + 0x4c, 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x42, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, + 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, + 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_genesis_proto_rawDescData = file_sge_legacy_bet_v1beta_genesis_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_genesis_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_genesis_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_bet_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.legacy.bet.v1beta.GenesisState + (*Params)(nil), // 1: sge.legacy.bet.v1beta.Params + (*Bet)(nil), // 2: sge.legacy.bet.v1beta.Bet + (*PendingBet)(nil), // 3: sge.legacy.bet.v1beta.PendingBet + (*SettledBet)(nil), // 4: sge.legacy.bet.v1beta.SettledBet + (*UID2ID)(nil), // 5: sge.legacy.bet.v1beta.UID2ID + (*BetStats)(nil), // 6: sge.legacy.bet.v1beta.BetStats +} +var file_sge_legacy_bet_v1beta_genesis_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.bet.v1beta.GenesisState.params:type_name -> sge.legacy.bet.v1beta.Params + 2, // 1: sge.legacy.bet.v1beta.GenesisState.bet_list:type_name -> sge.legacy.bet.v1beta.Bet + 3, // 2: sge.legacy.bet.v1beta.GenesisState.pending_bet_list:type_name -> sge.legacy.bet.v1beta.PendingBet + 4, // 3: sge.legacy.bet.v1beta.GenesisState.settled_bet_list:type_name -> sge.legacy.bet.v1beta.SettledBet + 5, // 4: sge.legacy.bet.v1beta.GenesisState.uid2id_list:type_name -> sge.legacy.bet.v1beta.UID2ID + 6, // 5: sge.legacy.bet.v1beta.GenesisState.stats:type_name -> sge.legacy.bet.v1beta.BetStats + 6, // [6:6] is the sub-list for method output_type + 6, // [6:6] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_genesis_proto_init() } +func file_sge_legacy_bet_v1beta_genesis_proto_init() { + if File_sge_legacy_bet_v1beta_genesis_proto != nil { + return + } + file_sge_legacy_bet_v1beta_bet_proto_init() + file_sge_legacy_bet_v1beta_params_proto_init() + file_sge_legacy_bet_v1beta_stats_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_genesis_proto = out.File + file_sge_legacy_bet_v1beta_genesis_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_genesis_proto_goTypes = nil + file_sge_legacy_bet_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/odds_type.pulsar.go b/api/sge/legacy/bet/v1beta/odds_type.pulsar.go new file mode 100644 index 00000000..4b384c72 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/odds_type.pulsar.go @@ -0,0 +1,159 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + sync "sync" +) + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/odds_type.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// OddsType is the representation of the type of the odds. +type OddsType int32 + +const ( + // invalid odds type + OddsType_ODDS_TYPE_UNSPECIFIED OddsType = 0 + // decimal odds type (european) + OddsType_ODDS_TYPE_DECIMAL OddsType = 1 + // fractional odds type (british) + OddsType_ODDS_TYPE_FRACTIONAL OddsType = 2 + // moneyline odds type (american) + OddsType_ODDS_TYPE_MONEYLINE OddsType = 3 +) + +// Enum value maps for OddsType. +var ( + OddsType_name = map[int32]string{ + 0: "ODDS_TYPE_UNSPECIFIED", + 1: "ODDS_TYPE_DECIMAL", + 2: "ODDS_TYPE_FRACTIONAL", + 3: "ODDS_TYPE_MONEYLINE", + } + OddsType_value = map[string]int32{ + "ODDS_TYPE_UNSPECIFIED": 0, + "ODDS_TYPE_DECIMAL": 1, + "ODDS_TYPE_FRACTIONAL": 2, + "ODDS_TYPE_MONEYLINE": 3, + } +) + +func (x OddsType) Enum() *OddsType { + p := new(OddsType) + *p = x + return p +} + +func (x OddsType) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (OddsType) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_bet_v1beta_odds_type_proto_enumTypes[0].Descriptor() +} + +func (OddsType) Type() protoreflect.EnumType { + return &file_sge_legacy_bet_v1beta_odds_type_proto_enumTypes[0] +} + +func (x OddsType) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use OddsType.Descriptor instead. +func (OddsType) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_odds_type_proto_rawDescGZIP(), []int{0} +} + +var File_sge_legacy_bet_v1beta_odds_type_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_odds_type_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x74, 0x79, 0x70, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2a, 0x6f, + 0x0a, 0x08, 0x4f, 0x64, 0x64, 0x73, 0x54, 0x79, 0x70, 0x65, 0x12, 0x19, 0x0a, 0x15, 0x4f, 0x44, + 0x44, 0x53, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, + 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x15, 0x0a, 0x11, 0x4f, 0x44, 0x44, 0x53, 0x5f, 0x54, 0x59, + 0x50, 0x45, 0x5f, 0x44, 0x45, 0x43, 0x49, 0x4d, 0x41, 0x4c, 0x10, 0x01, 0x12, 0x18, 0x0a, 0x14, + 0x4f, 0x44, 0x44, 0x53, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x46, 0x52, 0x41, 0x43, 0x54, 0x49, + 0x4f, 0x4e, 0x41, 0x4c, 0x10, 0x02, 0x12, 0x17, 0x0a, 0x13, 0x4f, 0x44, 0x44, 0x53, 0x5f, 0x54, + 0x59, 0x50, 0x45, 0x5f, 0x4d, 0x4f, 0x4e, 0x45, 0x59, 0x4c, 0x49, 0x4e, 0x45, 0x10, 0x03, 0x42, + 0xe1, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0d, 0x4f, + 0x64, 0x64, 0x73, 0x54, 0x79, 0x70, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, + 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4c, 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_odds_type_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_odds_type_proto_rawDescData = file_sge_legacy_bet_v1beta_odds_type_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_odds_type_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_odds_type_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_odds_type_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_odds_type_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_odds_type_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_odds_type_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_sge_legacy_bet_v1beta_odds_type_proto_goTypes = []interface{}{ + (OddsType)(0), // 0: sge.legacy.bet.v1beta.OddsType +} +var file_sge_legacy_bet_v1beta_odds_type_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_odds_type_proto_init() } +func file_sge_legacy_bet_v1beta_odds_type_proto_init() { + if File_sge_legacy_bet_v1beta_odds_type_proto != nil { + return + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_odds_type_proto_rawDesc, + NumEnums: 1, + NumMessages: 0, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_odds_type_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_odds_type_proto_depIdxs, + EnumInfos: file_sge_legacy_bet_v1beta_odds_type_proto_enumTypes, + }.Build() + File_sge_legacy_bet_v1beta_odds_type_proto = out.File + file_sge_legacy_bet_v1beta_odds_type_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_odds_type_proto_goTypes = nil + file_sge_legacy_bet_v1beta_odds_type_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/params.pulsar.go b/api/sge/legacy/bet/v1beta/params.pulsar.go new file mode 100644 index 00000000..cdcf91c3 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/params.pulsar.go @@ -0,0 +1,721 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Params protoreflect.MessageDescriptor + fd_Params_batch_settlement_count protoreflect.FieldDescriptor + fd_Params_max_bet_by_uid_query_count protoreflect.FieldDescriptor + fd_Params_constraints protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_params_proto_init() + md_Params = File_sge_legacy_bet_v1beta_params_proto.Messages().ByName("Params") + fd_Params_batch_settlement_count = md_Params.Fields().ByName("batch_settlement_count") + fd_Params_max_bet_by_uid_query_count = md_Params.Fields().ByName("max_bet_by_uid_query_count") + fd_Params_constraints = md_Params.Fields().ByName("constraints") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.BatchSettlementCount != uint32(0) { + value := protoreflect.ValueOfUint32(x.BatchSettlementCount) + if !f(fd_Params_batch_settlement_count, value) { + return + } + } + if x.MaxBetByUidQueryCount != uint32(0) { + value := protoreflect.ValueOfUint32(x.MaxBetByUidQueryCount) + if !f(fd_Params_max_bet_by_uid_query_count, value) { + return + } + } + if x.Constraints != nil { + value := protoreflect.ValueOfMessage(x.Constraints.ProtoReflect()) + if !f(fd_Params_constraints, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Params.batch_settlement_count": + return x.BatchSettlementCount != uint32(0) + case "sge.legacy.bet.v1beta.Params.max_bet_by_uid_query_count": + return x.MaxBetByUidQueryCount != uint32(0) + case "sge.legacy.bet.v1beta.Params.constraints": + return x.Constraints != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Params.batch_settlement_count": + x.BatchSettlementCount = uint32(0) + case "sge.legacy.bet.v1beta.Params.max_bet_by_uid_query_count": + x.MaxBetByUidQueryCount = uint32(0) + case "sge.legacy.bet.v1beta.Params.constraints": + x.Constraints = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.Params.batch_settlement_count": + value := x.BatchSettlementCount + return protoreflect.ValueOfUint32(value) + case "sge.legacy.bet.v1beta.Params.max_bet_by_uid_query_count": + value := x.MaxBetByUidQueryCount + return protoreflect.ValueOfUint32(value) + case "sge.legacy.bet.v1beta.Params.constraints": + value := x.Constraints + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Params.batch_settlement_count": + x.BatchSettlementCount = uint32(value.Uint()) + case "sge.legacy.bet.v1beta.Params.max_bet_by_uid_query_count": + x.MaxBetByUidQueryCount = uint32(value.Uint()) + case "sge.legacy.bet.v1beta.Params.constraints": + x.Constraints = value.Message().Interface().(*Constraints) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Params.constraints": + if x.Constraints == nil { + x.Constraints = new(Constraints) + } + return protoreflect.ValueOfMessage(x.Constraints.ProtoReflect()) + case "sge.legacy.bet.v1beta.Params.batch_settlement_count": + panic(fmt.Errorf("field batch_settlement_count of message sge.legacy.bet.v1beta.Params is not mutable")) + case "sge.legacy.bet.v1beta.Params.max_bet_by_uid_query_count": + panic(fmt.Errorf("field max_bet_by_uid_query_count of message sge.legacy.bet.v1beta.Params is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.Params.batch_settlement_count": + return protoreflect.ValueOfUint32(uint32(0)) + case "sge.legacy.bet.v1beta.Params.max_bet_by_uid_query_count": + return protoreflect.ValueOfUint32(uint32(0)) + case "sge.legacy.bet.v1beta.Params.constraints": + m := new(Constraints) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.BatchSettlementCount != 0 { + n += 1 + runtime.Sov(uint64(x.BatchSettlementCount)) + } + if x.MaxBetByUidQueryCount != 0 { + n += 1 + runtime.Sov(uint64(x.MaxBetByUidQueryCount)) + } + if x.Constraints != nil { + l = options.Size(x.Constraints) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Constraints != nil { + encoded, err := options.Marshal(x.Constraints) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if x.MaxBetByUidQueryCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.MaxBetByUidQueryCount)) + i-- + dAtA[i] = 0x10 + } + if x.BatchSettlementCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.BatchSettlementCount)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BatchSettlementCount", wireType) + } + x.BatchSettlementCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.BatchSettlementCount |= uint32(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxBetByUidQueryCount", wireType) + } + x.MaxBetByUidQueryCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.MaxBetByUidQueryCount |= uint32(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Constraints", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Constraints == nil { + x.Constraints = &Constraints{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Constraints); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params defines the parameters for the module. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // batch_settlement_count is the batch settlement bet count. + BatchSettlementCount uint32 `protobuf:"varint,1,opt,name=batch_settlement_count,json=batchSettlementCount,proto3" json:"batch_settlement_count,omitempty"` + // max_bet_by_uid_query_count is the maximum bet by uid query items count. + MaxBetByUidQueryCount uint32 `protobuf:"varint,2,opt,name=max_bet_by_uid_query_count,json=maxBetByUidQueryCount,proto3" json:"max_bet_by_uid_query_count,omitempty"` + // constraints is the bet constraints. + Constraints *Constraints `protobuf:"bytes,3,opt,name=constraints,proto3" json:"constraints,omitempty"` +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +func (x *Params) GetBatchSettlementCount() uint32 { + if x != nil { + return x.BatchSettlementCount + } + return 0 +} + +func (x *Params) GetMaxBetByUidQueryCount() uint32 { + if x != nil { + return x.MaxBetByUidQueryCount + } + return 0 +} + +func (x *Params) GetConstraints() *Constraints { + if x != nil { + return x.Constraints + } + return nil +} + +var File_sge_legacy_bet_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, + 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, + 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, + 0x69, 0x6e, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xe1, 0x01, 0x0a, 0x06, 0x50, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x34, 0x0a, 0x16, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x73, + 0x65, 0x74, 0x74, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x14, 0x62, 0x61, 0x74, 0x63, 0x68, 0x53, 0x65, 0x74, 0x74, + 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x39, 0x0a, 0x1a, 0x6d, + 0x61, 0x78, 0x5f, 0x62, 0x65, 0x74, 0x5f, 0x62, 0x79, 0x5f, 0x75, 0x69, 0x64, 0x5f, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, + 0x15, 0x6d, 0x61, 0x78, 0x42, 0x65, 0x74, 0x42, 0x79, 0x55, 0x69, 0x64, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x60, 0x0a, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, + 0x61, 0x69, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x42, + 0x1a, 0xc8, 0xde, 0x1f, 0x00, 0xf2, 0xde, 0x1f, 0x12, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, + 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x22, 0x52, 0x0b, 0x63, 0x6f, 0x6e, + 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xdf, + 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, + 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x42, + 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, + 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_params_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_params_proto_rawDescData = file_sge_legacy_bet_v1beta_params_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_params_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_params_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_bet_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.legacy.bet.v1beta.Params + (*Constraints)(nil), // 1: sge.legacy.bet.v1beta.Constraints +} +var file_sge_legacy_bet_v1beta_params_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.bet.v1beta.Params.constraints:type_name -> sge.legacy.bet.v1beta.Constraints + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_params_proto_init() } +func file_sge_legacy_bet_v1beta_params_proto_init() { + if File_sge_legacy_bet_v1beta_params_proto != nil { + return + } + file_sge_legacy_bet_v1beta_constraints_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_params_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_params_proto = out.File + file_sge_legacy_bet_v1beta_params_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_params_proto_goTypes = nil + file_sge_legacy_bet_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/query.pulsar.go b/api/sge/legacy/bet/v1beta/query.pulsar.go new file mode 100644 index 00000000..faf81498 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/query.pulsar.go @@ -0,0 +1,8191 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + v1beta1 "cosmossdk.io/api/cosmos/base/query/v1beta1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + v1beta "github.com/sge-network/sge/api/sge/legacy/market/v1beta" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryBetRequest protoreflect.MessageDescriptor + fd_QueryBetRequest_creator protoreflect.FieldDescriptor + fd_QueryBetRequest_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetRequest = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetRequest") + fd_QueryBetRequest_creator = md_QueryBetRequest.Fields().ByName("creator") + fd_QueryBetRequest_uid = md_QueryBetRequest.Fields().ByName("uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetRequest)(nil) + +type fastReflection_QueryBetRequest QueryBetRequest + +func (x *QueryBetRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetRequest)(x) +} + +func (x *QueryBetRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetRequest_messageType fastReflection_QueryBetRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetRequest_messageType{} + +type fastReflection_QueryBetRequest_messageType struct{} + +func (x fastReflection_QueryBetRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetRequest)(nil) +} +func (x fastReflection_QueryBetRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetRequest) +} +func (x fastReflection_QueryBetRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryBetRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetRequest) New() protoreflect.Message { + return new(fastReflection_QueryBetRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetRequest) Interface() protoreflect.ProtoMessage { + return (*QueryBetRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_QueryBetRequest_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_QueryBetRequest_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetRequest.creator": + return x.Creator != "" + case "sge.legacy.bet.v1beta.QueryBetRequest.uid": + return x.Uid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetRequest.creator": + x.Creator = "" + case "sge.legacy.bet.v1beta.QueryBetRequest.uid": + x.Uid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetRequest.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.QueryBetRequest.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetRequest.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.bet.v1beta.QueryBetRequest.uid": + x.Uid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetRequest.creator": + panic(fmt.Errorf("field creator of message sge.legacy.bet.v1beta.QueryBetRequest is not mutable")) + case "sge.legacy.bet.v1beta.QueryBetRequest.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.QueryBetRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetRequest.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.QueryBetRequest.uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryBetResponse protoreflect.MessageDescriptor + fd_QueryBetResponse_bet protoreflect.FieldDescriptor + fd_QueryBetResponse_market protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetResponse = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetResponse") + fd_QueryBetResponse_bet = md_QueryBetResponse.Fields().ByName("bet") + fd_QueryBetResponse_market = md_QueryBetResponse.Fields().ByName("market") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetResponse)(nil) + +type fastReflection_QueryBetResponse QueryBetResponse + +func (x *QueryBetResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetResponse)(x) +} + +func (x *QueryBetResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetResponse_messageType fastReflection_QueryBetResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetResponse_messageType{} + +type fastReflection_QueryBetResponse_messageType struct{} + +func (x fastReflection_QueryBetResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetResponse)(nil) +} +func (x fastReflection_QueryBetResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetResponse) +} +func (x fastReflection_QueryBetResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryBetResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetResponse) New() protoreflect.Message { + return new(fastReflection_QueryBetResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetResponse) Interface() protoreflect.ProtoMessage { + return (*QueryBetResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Bet != nil { + value := protoreflect.ValueOfMessage(x.Bet.ProtoReflect()) + if !f(fd_QueryBetResponse_bet, value) { + return + } + } + if x.Market != nil { + value := protoreflect.ValueOfMessage(x.Market.ProtoReflect()) + if !f(fd_QueryBetResponse_market, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetResponse.bet": + return x.Bet != nil + case "sge.legacy.bet.v1beta.QueryBetResponse.market": + return x.Market != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetResponse.bet": + x.Bet = nil + case "sge.legacy.bet.v1beta.QueryBetResponse.market": + x.Market = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetResponse.bet": + value := x.Bet + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryBetResponse.market": + value := x.Market + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetResponse.bet": + x.Bet = value.Message().Interface().(*Bet) + case "sge.legacy.bet.v1beta.QueryBetResponse.market": + x.Market = value.Message().Interface().(*v1beta.Market) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetResponse.bet": + if x.Bet == nil { + x.Bet = new(Bet) + } + return protoreflect.ValueOfMessage(x.Bet.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryBetResponse.market": + if x.Market == nil { + x.Market = new(v1beta.Market) + } + return protoreflect.ValueOfMessage(x.Market.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetResponse.bet": + m := new(Bet) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryBetResponse.market": + m := new(v1beta.Market) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Bet != nil { + l = options.Size(x.Bet) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Market != nil { + l = options.Size(x.Market) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Market != nil { + encoded, err := options.Marshal(x.Market) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if x.Bet != nil { + encoded, err := options.Marshal(x.Bet) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bet", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Bet == nil { + x.Bet = &Bet{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Bet); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Market", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Market == nil { + x.Market = &v1beta.Market{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Market); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryBetsRequest protoreflect.MessageDescriptor + fd_QueryBetsRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetsRequest = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetsRequest") + fd_QueryBetsRequest_pagination = md_QueryBetsRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetsRequest)(nil) + +type fastReflection_QueryBetsRequest QueryBetsRequest + +func (x *QueryBetsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetsRequest)(x) +} + +func (x *QueryBetsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetsRequest_messageType fastReflection_QueryBetsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetsRequest_messageType{} + +type fastReflection_QueryBetsRequest_messageType struct{} + +func (x fastReflection_QueryBetsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetsRequest)(nil) +} +func (x fastReflection_QueryBetsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetsRequest) +} +func (x fastReflection_QueryBetsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryBetsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetsRequest) New() protoreflect.Message { + return new(fastReflection_QueryBetsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryBetsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryBetsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryBetsResponse_1_list)(nil) + +type _QueryBetsResponse_1_list struct { + list *[]*Bet +} + +func (x *_QueryBetsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryBetsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryBetsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + (*x.list)[i] = concreteValue +} + +func (x *_QueryBetsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryBetsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Bet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryBetsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryBetsResponse_1_list) NewElement() protoreflect.Value { + v := new(Bet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryBetsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryBetsResponse protoreflect.MessageDescriptor + fd_QueryBetsResponse_bet protoreflect.FieldDescriptor + fd_QueryBetsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetsResponse = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetsResponse") + fd_QueryBetsResponse_bet = md_QueryBetsResponse.Fields().ByName("bet") + fd_QueryBetsResponse_pagination = md_QueryBetsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetsResponse)(nil) + +type fastReflection_QueryBetsResponse QueryBetsResponse + +func (x *QueryBetsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetsResponse)(x) +} + +func (x *QueryBetsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetsResponse_messageType fastReflection_QueryBetsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetsResponse_messageType{} + +type fastReflection_QueryBetsResponse_messageType struct{} + +func (x fastReflection_QueryBetsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetsResponse)(nil) +} +func (x fastReflection_QueryBetsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetsResponse) +} +func (x fastReflection_QueryBetsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryBetsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetsResponse) New() protoreflect.Message { + return new(fastReflection_QueryBetsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryBetsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Bet) != 0 { + value := protoreflect.ValueOfList(&_QueryBetsResponse_1_list{list: &x.Bet}) + if !f(fd_QueryBetsResponse_bet, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryBetsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsResponse.bet": + return len(x.Bet) != 0 + case "sge.legacy.bet.v1beta.QueryBetsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsResponse.bet": + x.Bet = nil + case "sge.legacy.bet.v1beta.QueryBetsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsResponse.bet": + if len(x.Bet) == 0 { + return protoreflect.ValueOfList(&_QueryBetsResponse_1_list{}) + } + listValue := &_QueryBetsResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.QueryBetsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsResponse.bet": + lv := value.List() + clv := lv.(*_QueryBetsResponse_1_list) + x.Bet = *clv.list + case "sge.legacy.bet.v1beta.QueryBetsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsResponse.bet": + if x.Bet == nil { + x.Bet = []*Bet{} + } + value := &_QueryBetsResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.QueryBetsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsResponse.bet": + list := []*Bet{} + return protoreflect.ValueOfList(&_QueryBetsResponse_1_list{list: &list}) + case "sge.legacy.bet.v1beta.QueryBetsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Bet) > 0 { + for _, e := range x.Bet { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Bet) > 0 { + for iNdEx := len(x.Bet) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Bet[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bet", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Bet = append(x.Bet, &Bet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Bet[len(x.Bet)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryBetsByCreatorRequest protoreflect.MessageDescriptor + fd_QueryBetsByCreatorRequest_pagination protoreflect.FieldDescriptor + fd_QueryBetsByCreatorRequest_creator protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetsByCreatorRequest = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetsByCreatorRequest") + fd_QueryBetsByCreatorRequest_pagination = md_QueryBetsByCreatorRequest.Fields().ByName("pagination") + fd_QueryBetsByCreatorRequest_creator = md_QueryBetsByCreatorRequest.Fields().ByName("creator") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetsByCreatorRequest)(nil) + +type fastReflection_QueryBetsByCreatorRequest QueryBetsByCreatorRequest + +func (x *QueryBetsByCreatorRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetsByCreatorRequest)(x) +} + +func (x *QueryBetsByCreatorRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetsByCreatorRequest_messageType fastReflection_QueryBetsByCreatorRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetsByCreatorRequest_messageType{} + +type fastReflection_QueryBetsByCreatorRequest_messageType struct{} + +func (x fastReflection_QueryBetsByCreatorRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetsByCreatorRequest)(nil) +} +func (x fastReflection_QueryBetsByCreatorRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetsByCreatorRequest) +} +func (x fastReflection_QueryBetsByCreatorRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByCreatorRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetsByCreatorRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByCreatorRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetsByCreatorRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryBetsByCreatorRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetsByCreatorRequest) New() protoreflect.Message { + return new(fastReflection_QueryBetsByCreatorRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetsByCreatorRequest) Interface() protoreflect.ProtoMessage { + return (*QueryBetsByCreatorRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetsByCreatorRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryBetsByCreatorRequest_pagination, value) { + return + } + } + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_QueryBetsByCreatorRequest_creator, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetsByCreatorRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.pagination": + return x.Pagination != nil + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.creator": + return x.Creator != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.pagination": + x.Pagination = nil + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.creator": + x.Creator = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetsByCreatorRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.creator": + x.Creator = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.creator": + panic(fmt.Errorf("field creator of message sge.legacy.bet.v1beta.QueryBetsByCreatorRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetsByCreatorRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.creator": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetsByCreatorRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetsByCreatorRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetsByCreatorRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetsByCreatorRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetsByCreatorRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetsByCreatorRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByCreatorRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0x12 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByCreatorRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByCreatorRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByCreatorRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryBetsByCreatorResponse_1_list)(nil) + +type _QueryBetsByCreatorResponse_1_list struct { + list *[]*Bet +} + +func (x *_QueryBetsByCreatorResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryBetsByCreatorResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryBetsByCreatorResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + (*x.list)[i] = concreteValue +} + +func (x *_QueryBetsByCreatorResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryBetsByCreatorResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Bet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryBetsByCreatorResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryBetsByCreatorResponse_1_list) NewElement() protoreflect.Value { + v := new(Bet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryBetsByCreatorResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryBetsByCreatorResponse protoreflect.MessageDescriptor + fd_QueryBetsByCreatorResponse_bet protoreflect.FieldDescriptor + fd_QueryBetsByCreatorResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetsByCreatorResponse = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetsByCreatorResponse") + fd_QueryBetsByCreatorResponse_bet = md_QueryBetsByCreatorResponse.Fields().ByName("bet") + fd_QueryBetsByCreatorResponse_pagination = md_QueryBetsByCreatorResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetsByCreatorResponse)(nil) + +type fastReflection_QueryBetsByCreatorResponse QueryBetsByCreatorResponse + +func (x *QueryBetsByCreatorResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetsByCreatorResponse)(x) +} + +func (x *QueryBetsByCreatorResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetsByCreatorResponse_messageType fastReflection_QueryBetsByCreatorResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetsByCreatorResponse_messageType{} + +type fastReflection_QueryBetsByCreatorResponse_messageType struct{} + +func (x fastReflection_QueryBetsByCreatorResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetsByCreatorResponse)(nil) +} +func (x fastReflection_QueryBetsByCreatorResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetsByCreatorResponse) +} +func (x fastReflection_QueryBetsByCreatorResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByCreatorResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetsByCreatorResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByCreatorResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetsByCreatorResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryBetsByCreatorResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetsByCreatorResponse) New() protoreflect.Message { + return new(fastReflection_QueryBetsByCreatorResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetsByCreatorResponse) Interface() protoreflect.ProtoMessage { + return (*QueryBetsByCreatorResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetsByCreatorResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Bet) != 0 { + value := protoreflect.ValueOfList(&_QueryBetsByCreatorResponse_1_list{list: &x.Bet}) + if !f(fd_QueryBetsByCreatorResponse_bet, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryBetsByCreatorResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetsByCreatorResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.bet": + return len(x.Bet) != 0 + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.bet": + x.Bet = nil + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetsByCreatorResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.bet": + if len(x.Bet) == 0 { + return protoreflect.ValueOfList(&_QueryBetsByCreatorResponse_1_list{}) + } + listValue := &_QueryBetsByCreatorResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.bet": + lv := value.List() + clv := lv.(*_QueryBetsByCreatorResponse_1_list) + x.Bet = *clv.list + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.bet": + if x.Bet == nil { + x.Bet = []*Bet{} + } + value := &_QueryBetsByCreatorResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetsByCreatorResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.bet": + list := []*Bet{} + return protoreflect.ValueOfList(&_QueryBetsByCreatorResponse_1_list{list: &list}) + case "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByCreatorResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetsByCreatorResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetsByCreatorResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetsByCreatorResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByCreatorResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetsByCreatorResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetsByCreatorResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetsByCreatorResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Bet) > 0 { + for _, e := range x.Bet { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByCreatorResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Bet) > 0 { + for iNdEx := len(x.Bet) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Bet[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByCreatorResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByCreatorResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByCreatorResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bet", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Bet = append(x.Bet, &Bet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Bet[len(x.Bet)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryBetsByUIDsRequest_1_list)(nil) + +type _QueryBetsByUIDsRequest_1_list struct { + list *[]string +} + +func (x *_QueryBetsByUIDsRequest_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryBetsByUIDsRequest_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_QueryBetsByUIDsRequest_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_QueryBetsByUIDsRequest_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryBetsByUIDsRequest_1_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message QueryBetsByUIDsRequest at list field Items as it is not of Message kind")) +} + +func (x *_QueryBetsByUIDsRequest_1_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_QueryBetsByUIDsRequest_1_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_QueryBetsByUIDsRequest_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryBetsByUIDsRequest protoreflect.MessageDescriptor + fd_QueryBetsByUIDsRequest_items protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetsByUIDsRequest = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetsByUIDsRequest") + fd_QueryBetsByUIDsRequest_items = md_QueryBetsByUIDsRequest.Fields().ByName("items") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetsByUIDsRequest)(nil) + +type fastReflection_QueryBetsByUIDsRequest QueryBetsByUIDsRequest + +func (x *QueryBetsByUIDsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetsByUIDsRequest)(x) +} + +func (x *QueryBetsByUIDsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetsByUIDsRequest_messageType fastReflection_QueryBetsByUIDsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetsByUIDsRequest_messageType{} + +type fastReflection_QueryBetsByUIDsRequest_messageType struct{} + +func (x fastReflection_QueryBetsByUIDsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetsByUIDsRequest)(nil) +} +func (x fastReflection_QueryBetsByUIDsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetsByUIDsRequest) +} +func (x fastReflection_QueryBetsByUIDsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByUIDsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetsByUIDsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByUIDsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetsByUIDsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryBetsByUIDsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetsByUIDsRequest) New() protoreflect.Message { + return new(fastReflection_QueryBetsByUIDsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetsByUIDsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryBetsByUIDsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetsByUIDsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Items) != 0 { + value := protoreflect.ValueOfList(&_QueryBetsByUIDsRequest_1_list{list: &x.Items}) + if !f(fd_QueryBetsByUIDsRequest_items, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetsByUIDsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsRequest.items": + return len(x.Items) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsRequest.items": + x.Items = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetsByUIDsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsRequest.items": + if len(x.Items) == 0 { + return protoreflect.ValueOfList(&_QueryBetsByUIDsRequest_1_list{}) + } + listValue := &_QueryBetsByUIDsRequest_1_list{list: &x.Items} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsRequest.items": + lv := value.List() + clv := lv.(*_QueryBetsByUIDsRequest_1_list) + x.Items = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsRequest.items": + if x.Items == nil { + x.Items = []string{} + } + value := &_QueryBetsByUIDsRequest_1_list{list: &x.Items} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetsByUIDsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsRequest.items": + list := []string{} + return protoreflect.ValueOfList(&_QueryBetsByUIDsRequest_1_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetsByUIDsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetsByUIDsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetsByUIDsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetsByUIDsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetsByUIDsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetsByUIDsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Items) > 0 { + for _, s := range x.Items { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByUIDsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Items) > 0 { + for iNdEx := len(x.Items) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.Items[iNdEx]) + copy(dAtA[i:], x.Items[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Items[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByUIDsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByUIDsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByUIDsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Items = append(x.Items, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryBetsByUIDsResponse_1_list)(nil) + +type _QueryBetsByUIDsResponse_1_list struct { + list *[]*Bet +} + +func (x *_QueryBetsByUIDsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryBetsByUIDsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryBetsByUIDsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + (*x.list)[i] = concreteValue +} + +func (x *_QueryBetsByUIDsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryBetsByUIDsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Bet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryBetsByUIDsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryBetsByUIDsResponse_1_list) NewElement() protoreflect.Value { + v := new(Bet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryBetsByUIDsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_QueryBetsByUIDsResponse_2_list)(nil) + +type _QueryBetsByUIDsResponse_2_list struct { + list *[]string +} + +func (x *_QueryBetsByUIDsResponse_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryBetsByUIDsResponse_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_QueryBetsByUIDsResponse_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_QueryBetsByUIDsResponse_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryBetsByUIDsResponse_2_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message QueryBetsByUIDsResponse at list field NotFoundBetUids as it is not of Message kind")) +} + +func (x *_QueryBetsByUIDsResponse_2_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_QueryBetsByUIDsResponse_2_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_QueryBetsByUIDsResponse_2_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryBetsByUIDsResponse protoreflect.MessageDescriptor + fd_QueryBetsByUIDsResponse_bets protoreflect.FieldDescriptor + fd_QueryBetsByUIDsResponse_not_found_bet_uids protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryBetsByUIDsResponse = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryBetsByUIDsResponse") + fd_QueryBetsByUIDsResponse_bets = md_QueryBetsByUIDsResponse.Fields().ByName("bets") + fd_QueryBetsByUIDsResponse_not_found_bet_uids = md_QueryBetsByUIDsResponse.Fields().ByName("not_found_bet_uids") +} + +var _ protoreflect.Message = (*fastReflection_QueryBetsByUIDsResponse)(nil) + +type fastReflection_QueryBetsByUIDsResponse QueryBetsByUIDsResponse + +func (x *QueryBetsByUIDsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryBetsByUIDsResponse)(x) +} + +func (x *QueryBetsByUIDsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryBetsByUIDsResponse_messageType fastReflection_QueryBetsByUIDsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryBetsByUIDsResponse_messageType{} + +type fastReflection_QueryBetsByUIDsResponse_messageType struct{} + +func (x fastReflection_QueryBetsByUIDsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryBetsByUIDsResponse)(nil) +} +func (x fastReflection_QueryBetsByUIDsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryBetsByUIDsResponse) +} +func (x fastReflection_QueryBetsByUIDsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByUIDsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryBetsByUIDsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryBetsByUIDsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryBetsByUIDsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryBetsByUIDsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryBetsByUIDsResponse) New() protoreflect.Message { + return new(fastReflection_QueryBetsByUIDsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryBetsByUIDsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryBetsByUIDsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryBetsByUIDsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Bets) != 0 { + value := protoreflect.ValueOfList(&_QueryBetsByUIDsResponse_1_list{list: &x.Bets}) + if !f(fd_QueryBetsByUIDsResponse_bets, value) { + return + } + } + if len(x.NotFoundBetUids) != 0 { + value := protoreflect.ValueOfList(&_QueryBetsByUIDsResponse_2_list{list: &x.NotFoundBetUids}) + if !f(fd_QueryBetsByUIDsResponse_not_found_bet_uids, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryBetsByUIDsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.bets": + return len(x.Bets) != 0 + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.not_found_bet_uids": + return len(x.NotFoundBetUids) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.bets": + x.Bets = nil + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.not_found_bet_uids": + x.NotFoundBetUids = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryBetsByUIDsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.bets": + if len(x.Bets) == 0 { + return protoreflect.ValueOfList(&_QueryBetsByUIDsResponse_1_list{}) + } + listValue := &_QueryBetsByUIDsResponse_1_list{list: &x.Bets} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.not_found_bet_uids": + if len(x.NotFoundBetUids) == 0 { + return protoreflect.ValueOfList(&_QueryBetsByUIDsResponse_2_list{}) + } + listValue := &_QueryBetsByUIDsResponse_2_list{list: &x.NotFoundBetUids} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.bets": + lv := value.List() + clv := lv.(*_QueryBetsByUIDsResponse_1_list) + x.Bets = *clv.list + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.not_found_bet_uids": + lv := value.List() + clv := lv.(*_QueryBetsByUIDsResponse_2_list) + x.NotFoundBetUids = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.bets": + if x.Bets == nil { + x.Bets = []*Bet{} + } + value := &_QueryBetsByUIDsResponse_1_list{list: &x.Bets} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.not_found_bet_uids": + if x.NotFoundBetUids == nil { + x.NotFoundBetUids = []string{} + } + value := &_QueryBetsByUIDsResponse_2_list{list: &x.NotFoundBetUids} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryBetsByUIDsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.bets": + list := []*Bet{} + return protoreflect.ValueOfList(&_QueryBetsByUIDsResponse_1_list{list: &list}) + case "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.not_found_bet_uids": + list := []string{} + return protoreflect.ValueOfList(&_QueryBetsByUIDsResponse_2_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryBetsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryBetsByUIDsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryBetsByUIDsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryBetsByUIDsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryBetsByUIDsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryBetsByUIDsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryBetsByUIDsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryBetsByUIDsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Bets) > 0 { + for _, e := range x.Bets { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.NotFoundBetUids) > 0 { + for _, s := range x.NotFoundBetUids { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByUIDsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.NotFoundBetUids) > 0 { + for iNdEx := len(x.NotFoundBetUids) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.NotFoundBetUids[iNdEx]) + copy(dAtA[i:], x.NotFoundBetUids[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.NotFoundBetUids[iNdEx]))) + i-- + dAtA[i] = 0x12 + } + } + if len(x.Bets) > 0 { + for iNdEx := len(x.Bets) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Bets[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryBetsByUIDsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByUIDsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryBetsByUIDsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bets", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Bets = append(x.Bets, &Bet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Bets[len(x.Bets)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field NotFoundBetUids", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.NotFoundBetUids = append(x.NotFoundBetUids, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPendingBetsRequest protoreflect.MessageDescriptor + fd_QueryPendingBetsRequest_pagination protoreflect.FieldDescriptor + fd_QueryPendingBetsRequest_market_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryPendingBetsRequest = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryPendingBetsRequest") + fd_QueryPendingBetsRequest_pagination = md_QueryPendingBetsRequest.Fields().ByName("pagination") + fd_QueryPendingBetsRequest_market_uid = md_QueryPendingBetsRequest.Fields().ByName("market_uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryPendingBetsRequest)(nil) + +type fastReflection_QueryPendingBetsRequest QueryPendingBetsRequest + +func (x *QueryPendingBetsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPendingBetsRequest)(x) +} + +func (x *QueryPendingBetsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPendingBetsRequest_messageType fastReflection_QueryPendingBetsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPendingBetsRequest_messageType{} + +type fastReflection_QueryPendingBetsRequest_messageType struct{} + +func (x fastReflection_QueryPendingBetsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPendingBetsRequest)(nil) +} +func (x fastReflection_QueryPendingBetsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPendingBetsRequest) +} +func (x fastReflection_QueryPendingBetsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPendingBetsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPendingBetsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPendingBetsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPendingBetsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPendingBetsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPendingBetsRequest) New() protoreflect.Message { + return new(fastReflection_QueryPendingBetsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPendingBetsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPendingBetsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPendingBetsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryPendingBetsRequest_pagination, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_QueryPendingBetsRequest_market_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPendingBetsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.pagination": + return x.Pagination != nil + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.market_uid": + return x.MarketUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.pagination": + x.Pagination = nil + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.market_uid": + x.MarketUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPendingBetsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.market_uid": + x.MarketUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.bet.v1beta.QueryPendingBetsRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPendingBetsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.QueryPendingBetsRequest.market_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPendingBetsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryPendingBetsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPendingBetsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPendingBetsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPendingBetsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPendingBetsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPendingBetsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x12 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPendingBetsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPendingBetsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPendingBetsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryPendingBetsResponse_1_list)(nil) + +type _QueryPendingBetsResponse_1_list struct { + list *[]*Bet +} + +func (x *_QueryPendingBetsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryPendingBetsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryPendingBetsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + (*x.list)[i] = concreteValue +} + +func (x *_QueryPendingBetsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryPendingBetsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Bet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryPendingBetsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryPendingBetsResponse_1_list) NewElement() protoreflect.Value { + v := new(Bet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryPendingBetsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryPendingBetsResponse protoreflect.MessageDescriptor + fd_QueryPendingBetsResponse_bet protoreflect.FieldDescriptor + fd_QueryPendingBetsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QueryPendingBetsResponse = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QueryPendingBetsResponse") + fd_QueryPendingBetsResponse_bet = md_QueryPendingBetsResponse.Fields().ByName("bet") + fd_QueryPendingBetsResponse_pagination = md_QueryPendingBetsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryPendingBetsResponse)(nil) + +type fastReflection_QueryPendingBetsResponse QueryPendingBetsResponse + +func (x *QueryPendingBetsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPendingBetsResponse)(x) +} + +func (x *QueryPendingBetsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPendingBetsResponse_messageType fastReflection_QueryPendingBetsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPendingBetsResponse_messageType{} + +type fastReflection_QueryPendingBetsResponse_messageType struct{} + +func (x fastReflection_QueryPendingBetsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPendingBetsResponse)(nil) +} +func (x fastReflection_QueryPendingBetsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPendingBetsResponse) +} +func (x fastReflection_QueryPendingBetsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPendingBetsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPendingBetsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPendingBetsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPendingBetsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPendingBetsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPendingBetsResponse) New() protoreflect.Message { + return new(fastReflection_QueryPendingBetsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPendingBetsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPendingBetsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPendingBetsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Bet) != 0 { + value := protoreflect.ValueOfList(&_QueryPendingBetsResponse_1_list{list: &x.Bet}) + if !f(fd_QueryPendingBetsResponse_bet, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryPendingBetsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPendingBetsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.bet": + return len(x.Bet) != 0 + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.bet": + x.Bet = nil + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPendingBetsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.bet": + if len(x.Bet) == 0 { + return protoreflect.ValueOfList(&_QueryPendingBetsResponse_1_list{}) + } + listValue := &_QueryPendingBetsResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.bet": + lv := value.List() + clv := lv.(*_QueryPendingBetsResponse_1_list) + x.Bet = *clv.list + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.bet": + if x.Bet == nil { + x.Bet = []*Bet{} + } + value := &_QueryPendingBetsResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPendingBetsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.bet": + list := []*Bet{} + return protoreflect.ValueOfList(&_QueryPendingBetsResponse_1_list{list: &list}) + case "sge.legacy.bet.v1beta.QueryPendingBetsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QueryPendingBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QueryPendingBetsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPendingBetsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QueryPendingBetsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPendingBetsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPendingBetsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPendingBetsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPendingBetsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPendingBetsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Bet) > 0 { + for _, e := range x.Bet { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPendingBetsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Bet) > 0 { + for iNdEx := len(x.Bet) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Bet[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPendingBetsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPendingBetsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPendingBetsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bet", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Bet = append(x.Bet, &Bet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Bet[len(x.Bet)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QuerySettledBetsOfHeightRequest protoreflect.MessageDescriptor + fd_QuerySettledBetsOfHeightRequest_pagination protoreflect.FieldDescriptor + fd_QuerySettledBetsOfHeightRequest_block_height protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QuerySettledBetsOfHeightRequest = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QuerySettledBetsOfHeightRequest") + fd_QuerySettledBetsOfHeightRequest_pagination = md_QuerySettledBetsOfHeightRequest.Fields().ByName("pagination") + fd_QuerySettledBetsOfHeightRequest_block_height = md_QuerySettledBetsOfHeightRequest.Fields().ByName("block_height") +} + +var _ protoreflect.Message = (*fastReflection_QuerySettledBetsOfHeightRequest)(nil) + +type fastReflection_QuerySettledBetsOfHeightRequest QuerySettledBetsOfHeightRequest + +func (x *QuerySettledBetsOfHeightRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QuerySettledBetsOfHeightRequest)(x) +} + +func (x *QuerySettledBetsOfHeightRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QuerySettledBetsOfHeightRequest_messageType fastReflection_QuerySettledBetsOfHeightRequest_messageType +var _ protoreflect.MessageType = fastReflection_QuerySettledBetsOfHeightRequest_messageType{} + +type fastReflection_QuerySettledBetsOfHeightRequest_messageType struct{} + +func (x fastReflection_QuerySettledBetsOfHeightRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QuerySettledBetsOfHeightRequest)(nil) +} +func (x fastReflection_QuerySettledBetsOfHeightRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QuerySettledBetsOfHeightRequest) +} +func (x fastReflection_QuerySettledBetsOfHeightRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledBetsOfHeightRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledBetsOfHeightRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Type() protoreflect.MessageType { + return _fastReflection_QuerySettledBetsOfHeightRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) New() protoreflect.Message { + return new(fastReflection_QuerySettledBetsOfHeightRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Interface() protoreflect.ProtoMessage { + return (*QuerySettledBetsOfHeightRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QuerySettledBetsOfHeightRequest_pagination, value) { + return + } + } + if x.BlockHeight != int64(0) { + value := protoreflect.ValueOfInt64(x.BlockHeight) + if !f(fd_QuerySettledBetsOfHeightRequest_block_height, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.pagination": + return x.Pagination != nil + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.block_height": + return x.BlockHeight != int64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.pagination": + x.Pagination = nil + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.block_height": + x.BlockHeight = int64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.block_height": + value := x.BlockHeight + return protoreflect.ValueOfInt64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.block_height": + x.BlockHeight = value.Int() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.block_height": + panic(fmt.Errorf("field block_height of message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.block_height": + return protoreflect.ValueOfInt64(int64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QuerySettledBetsOfHeightRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QuerySettledBetsOfHeightRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.BlockHeight != 0 { + n += 1 + runtime.Sov(uint64(x.BlockHeight)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledBetsOfHeightRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.BlockHeight != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.BlockHeight)) + i-- + dAtA[i] = 0x10 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledBetsOfHeightRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledBetsOfHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledBetsOfHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockHeight", wireType) + } + x.BlockHeight = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.BlockHeight |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QuerySettledBetsOfHeightResponse_1_list)(nil) + +type _QuerySettledBetsOfHeightResponse_1_list struct { + list *[]*Bet +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + (*x.list)[i] = concreteValue +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Bet) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Bet) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) NewElement() protoreflect.Value { + v := new(Bet) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySettledBetsOfHeightResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QuerySettledBetsOfHeightResponse protoreflect.MessageDescriptor + fd_QuerySettledBetsOfHeightResponse_bet protoreflect.FieldDescriptor + fd_QuerySettledBetsOfHeightResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_query_proto_init() + md_QuerySettledBetsOfHeightResponse = File_sge_legacy_bet_v1beta_query_proto.Messages().ByName("QuerySettledBetsOfHeightResponse") + fd_QuerySettledBetsOfHeightResponse_bet = md_QuerySettledBetsOfHeightResponse.Fields().ByName("bet") + fd_QuerySettledBetsOfHeightResponse_pagination = md_QuerySettledBetsOfHeightResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QuerySettledBetsOfHeightResponse)(nil) + +type fastReflection_QuerySettledBetsOfHeightResponse QuerySettledBetsOfHeightResponse + +func (x *QuerySettledBetsOfHeightResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QuerySettledBetsOfHeightResponse)(x) +} + +func (x *QuerySettledBetsOfHeightResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QuerySettledBetsOfHeightResponse_messageType fastReflection_QuerySettledBetsOfHeightResponse_messageType +var _ protoreflect.MessageType = fastReflection_QuerySettledBetsOfHeightResponse_messageType{} + +type fastReflection_QuerySettledBetsOfHeightResponse_messageType struct{} + +func (x fastReflection_QuerySettledBetsOfHeightResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QuerySettledBetsOfHeightResponse)(nil) +} +func (x fastReflection_QuerySettledBetsOfHeightResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QuerySettledBetsOfHeightResponse) +} +func (x fastReflection_QuerySettledBetsOfHeightResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledBetsOfHeightResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledBetsOfHeightResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Type() protoreflect.MessageType { + return _fastReflection_QuerySettledBetsOfHeightResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) New() protoreflect.Message { + return new(fastReflection_QuerySettledBetsOfHeightResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Interface() protoreflect.ProtoMessage { + return (*QuerySettledBetsOfHeightResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Bet) != 0 { + value := protoreflect.ValueOfList(&_QuerySettledBetsOfHeightResponse_1_list{list: &x.Bet}) + if !f(fd_QuerySettledBetsOfHeightResponse_bet, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QuerySettledBetsOfHeightResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.bet": + return len(x.Bet) != 0 + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.bet": + x.Bet = nil + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.bet": + if len(x.Bet) == 0 { + return protoreflect.ValueOfList(&_QuerySettledBetsOfHeightResponse_1_list{}) + } + listValue := &_QuerySettledBetsOfHeightResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.bet": + lv := value.List() + clv := lv.(*_QuerySettledBetsOfHeightResponse_1_list) + x.Bet = *clv.list + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.bet": + if x.Bet == nil { + x.Bet = []*Bet{} + } + value := &_QuerySettledBetsOfHeightResponse_1_list{list: &x.Bet} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.bet": + list := []*Bet{} + return protoreflect.ValueOfList(&_QuerySettledBetsOfHeightResponse_1_list{list: &list}) + case "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QuerySettledBetsOfHeightResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QuerySettledBetsOfHeightResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Bet) > 0 { + for _, e := range x.Bet { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledBetsOfHeightResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Bet) > 0 { + for iNdEx := len(x.Bet) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Bet[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledBetsOfHeightResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledBetsOfHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledBetsOfHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Bet", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Bet = append(x.Bet, &Bet{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Bet[len(x.Bet)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is the request type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is the response type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params holds all the parameters of this module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QueryBetRequest is the request type for a single bet query +// Query/Bet RPC method. +type QueryBetRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` +} + +func (x *QueryBetRequest) Reset() { + *x = QueryBetRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetRequest) ProtoMessage() {} + +// Deprecated: Use QueryBetRequest.ProtoReflect.Descriptor instead. +func (*QueryBetRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +func (x *QueryBetRequest) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *QueryBetRequest) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +// QueryBetResponse is the response type for single bet query +// Query/Bet RPC method. +type QueryBetResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Bet *Bet `protobuf:"bytes,1,opt,name=bet,proto3" json:"bet,omitempty"` + Market *v1beta.Market `protobuf:"bytes,2,opt,name=market,proto3" json:"market,omitempty"` +} + +func (x *QueryBetResponse) Reset() { + *x = QueryBetResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetResponse) ProtoMessage() {} + +// Deprecated: Use QueryBetResponse.ProtoReflect.Descriptor instead. +func (*QueryBetResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QueryBetResponse) GetBet() *Bet { + if x != nil { + return x.Bet + } + return nil +} + +func (x *QueryBetResponse) GetMarket() *v1beta.Market { + if x != nil { + return x.Market + } + return nil +} + +// QueryBetsRequest is the request type for the bets list query +// Query/Bets RPC method. +type QueryBetsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryBetsRequest) Reset() { + *x = QueryBetsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetsRequest) ProtoMessage() {} + +// Deprecated: Use QueryBetsRequest.ProtoReflect.Descriptor instead. +func (*QueryBetsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{4} +} + +func (x *QueryBetsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryBetsResponse is the response type for the bets list query +// Query/Bets RPC method. +type QueryBetsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Bet []*Bet `protobuf:"bytes,1,rep,name=bet,proto3" json:"bet,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryBetsResponse) Reset() { + *x = QueryBetsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetsResponse) ProtoMessage() {} + +// Deprecated: Use QueryBetsResponse.ProtoReflect.Descriptor instead. +func (*QueryBetsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{5} +} + +func (x *QueryBetsResponse) GetBet() []*Bet { + if x != nil { + return x.Bet + } + return nil +} + +func (x *QueryBetsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryBetsByUIDsResponse is the request type for bets list of all bets of a +// bettor Query/BetsByCreator RPC method. +type QueryBetsByCreatorRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + Creator string `protobuf:"bytes,2,opt,name=creator,proto3" json:"creator,omitempty"` +} + +func (x *QueryBetsByCreatorRequest) Reset() { + *x = QueryBetsByCreatorRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetsByCreatorRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetsByCreatorRequest) ProtoMessage() {} + +// Deprecated: Use QueryBetsByCreatorRequest.ProtoReflect.Descriptor instead. +func (*QueryBetsByCreatorRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{6} +} + +func (x *QueryBetsByCreatorRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QueryBetsByCreatorRequest) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +// QueryBetsByCreatorResponse is the response type for the bets list of all bets +// of a bettor Query/BetsByCreator RPC method. +type QueryBetsByCreatorResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Bet []*Bet `protobuf:"bytes,1,rep,name=bet,proto3" json:"bet,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryBetsByCreatorResponse) Reset() { + *x = QueryBetsByCreatorResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetsByCreatorResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetsByCreatorResponse) ProtoMessage() {} + +// Deprecated: Use QueryBetsByCreatorResponse.ProtoReflect.Descriptor instead. +func (*QueryBetsByCreatorResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{7} +} + +func (x *QueryBetsByCreatorResponse) GetBet() []*Bet { + if x != nil { + return x.Bet + } + return nil +} + +func (x *QueryBetsByCreatorResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryBetsByUIDsRequest is the request type for a bets list of a certain UID +// list input Query/BetsByUIDs RPC method. +type QueryBetsByUIDsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Items []string `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"` +} + +func (x *QueryBetsByUIDsRequest) Reset() { + *x = QueryBetsByUIDsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetsByUIDsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetsByUIDsRequest) ProtoMessage() {} + +// Deprecated: Use QueryBetsByUIDsRequest.ProtoReflect.Descriptor instead. +func (*QueryBetsByUIDsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{8} +} + +func (x *QueryBetsByUIDsRequest) GetItems() []string { + if x != nil { + return x.Items + } + return nil +} + +// QueryBetsByUIDsResponse is the response type for the bets list of a certain +// UID list input Query/BetsByUIDs RPC method. +type QueryBetsByUIDsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Bets []*Bet `protobuf:"bytes,1,rep,name=bets,proto3" json:"bets,omitempty"` + NotFoundBetUids []string `protobuf:"bytes,2,rep,name=not_found_bet_uids,json=notFoundBetUids,proto3" json:"not_found_bet_uids,omitempty"` +} + +func (x *QueryBetsByUIDsResponse) Reset() { + *x = QueryBetsByUIDsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryBetsByUIDsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryBetsByUIDsResponse) ProtoMessage() {} + +// Deprecated: Use QueryBetsByUIDsResponse.ProtoReflect.Descriptor instead. +func (*QueryBetsByUIDsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{9} +} + +func (x *QueryBetsByUIDsResponse) GetBets() []*Bet { + if x != nil { + return x.Bets + } + return nil +} + +func (x *QueryBetsByUIDsResponse) GetNotFoundBetUids() []string { + if x != nil { + return x.NotFoundBetUids + } + return nil +} + +// QueryPendingBetsRequest is the request type for the active bets list query +// for a market +// Query/ActiveBets RPC method. +type QueryPendingBetsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + MarketUid string `protobuf:"bytes,2,opt,name=market_uid,json=marketUid,proto3" json:"market_uid,omitempty"` +} + +func (x *QueryPendingBetsRequest) Reset() { + *x = QueryPendingBetsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPendingBetsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPendingBetsRequest) ProtoMessage() {} + +// Deprecated: Use QueryPendingBetsRequest.ProtoReflect.Descriptor instead. +func (*QueryPendingBetsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{10} +} + +func (x *QueryPendingBetsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QueryPendingBetsRequest) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +// QueryPendingBetsResponse is the response type for the active bets list query +// Query/PendingBets RPC method. +type QueryPendingBetsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Bet []*Bet `protobuf:"bytes,1,rep,name=bet,proto3" json:"bet,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryPendingBetsResponse) Reset() { + *x = QueryPendingBetsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPendingBetsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPendingBetsResponse) ProtoMessage() {} + +// Deprecated: Use QueryPendingBetsResponse.ProtoReflect.Descriptor instead. +func (*QueryPendingBetsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{11} +} + +func (x *QueryPendingBetsResponse) GetBet() []*Bet { + if x != nil { + return x.Bet + } + return nil +} + +func (x *QueryPendingBetsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QuerySettledBetsOfHeightRequest is the request type for the settled bets of a +// certain height list query. +// Query/ActiveBets RPC method. +type QuerySettledBetsOfHeightRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + BlockHeight int64 `protobuf:"varint,2,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"` +} + +func (x *QuerySettledBetsOfHeightRequest) Reset() { + *x = QuerySettledBetsOfHeightRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QuerySettledBetsOfHeightRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QuerySettledBetsOfHeightRequest) ProtoMessage() {} + +// Deprecated: Use QuerySettledBetsOfHeightRequest.ProtoReflect.Descriptor instead. +func (*QuerySettledBetsOfHeightRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{12} +} + +func (x *QuerySettledBetsOfHeightRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QuerySettledBetsOfHeightRequest) GetBlockHeight() int64 { + if x != nil { + return x.BlockHeight + } + return 0 +} + +// QuerySettledBetsOfHeightResponse is the response type for the settled bets of +// a certain height list query Query/ActiveBets RPC method. +type QuerySettledBetsOfHeightResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Bet []*Bet `protobuf:"bytes,1,rep,name=bet,proto3" json:"bet,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QuerySettledBetsOfHeightResponse) Reset() { + *x = QuerySettledBetsOfHeightResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_query_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QuerySettledBetsOfHeightResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QuerySettledBetsOfHeightResponse) ProtoMessage() {} + +// Deprecated: Use QuerySettledBetsOfHeightResponse.ProtoReflect.Descriptor instead. +func (*QuerySettledBetsOfHeightResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP(), []int{13} +} + +func (x *QuerySettledBetsOfHeightResponse) GetBet() []*Bet { + if x != nil { + return x.Bet + } + return nil +} + +func (x *QuerySettledBetsOfHeightResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +var File_sge_legacy_bet_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x2a, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, + 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x65, 0x74, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x22, 0x14, 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x52, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3b, + 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x60, 0x0a, 0x0f, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x32, + 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, + 0x6f, 0x72, 0x12, 0x19, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x07, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x22, 0x86, 0x01, + 0x0a, 0x10, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x32, 0x0a, 0x03, 0x62, 0x65, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, + 0x00, 0x52, 0x03, 0x62, 0x65, 0x74, 0x12, 0x3e, 0x0a, 0x06, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x22, 0x5a, 0x0a, 0x10, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, + 0x65, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, + 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, + 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0x90, 0x01, 0x0a, 0x11, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x03, 0x62, 0x65, 0x74, 0x18, + 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, + 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x03, 0x62, 0x65, 0x74, 0x12, 0x47, 0x0a, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, + 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x7d, 0x0a, 0x19, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, + 0x74, 0x73, 0x42, 0x79, 0x43, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x72, + 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x22, 0x99, 0x01, 0x0a, 0x1a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, + 0x74, 0x73, 0x42, 0x79, 0x43, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x03, 0x62, 0x65, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x03, 0x62, 0x65, 0x74, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0x39, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, + 0x49, 0x44, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1f, 0x0a, 0x05, 0x69, 0x74, + 0x65, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x42, 0x09, 0xea, 0xde, 0x1f, 0x05, 0x69, + 0x74, 0x65, 0x6d, 0x73, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x22, 0x7c, 0x0a, 0x17, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x34, 0x0a, 0x04, 0x62, 0x65, 0x74, 0x73, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, + 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x04, 0x62, 0x65, 0x74, 0x73, 0x12, 0x2b, 0x0a, 0x12, + 0x6e, 0x6f, 0x74, 0x5f, 0x66, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x62, 0x65, 0x74, 0x5f, 0x75, 0x69, + 0x64, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0f, 0x6e, 0x6f, 0x74, 0x46, 0x6f, 0x75, + 0x6e, 0x64, 0x42, 0x65, 0x74, 0x55, 0x69, 0x64, 0x73, 0x22, 0x80, 0x01, 0x0a, 0x17, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x65, 0x74, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x0a, + 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x55, 0x69, 0x64, 0x22, 0x97, 0x01, 0x0a, + 0x18, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x65, 0x74, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x03, 0x62, 0x65, 0x74, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, + 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x03, 0x62, 0x65, 0x74, 0x12, 0x47, 0x0a, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, + 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, + 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x8c, 0x01, 0x0a, 0x1f, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, + 0x67, 0x68, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, + 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, + 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x65, 0x69, 0x67, + 0x68, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x48, + 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, 0x9f, 0x01, 0x0a, 0x20, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, + 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, + 0x68, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x03, 0x62, 0x65, + 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x42, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x03, 0x62, 0x65, 0x74, 0x12, 0x47, + 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, + 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, + 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, + 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x32, 0xf6, 0x07, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x12, 0x78, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x29, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x17, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x11, 0x12, 0x0f, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x78, 0x0a, 0x03, 0x42, + 0x65, 0x74, 0x12, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x42, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x27, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x20, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1a, 0x12, 0x18, 0x2f, 0x73, 0x67, + 0x65, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x7b, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x7d, 0x2f, + 0x7b, 0x75, 0x69, 0x64, 0x7d, 0x12, 0x9d, 0x01, 0x0a, 0x0d, 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x30, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x31, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x21, 0x12, 0x1f, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x2f, 0x7b, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x7d, + 0x2f, 0x62, 0x65, 0x74, 0x73, 0x12, 0x70, 0x0a, 0x04, 0x42, 0x65, 0x74, 0x73, 0x12, 0x27, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x15, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0f, 0x12, 0x0d, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x62, + 0x65, 0x74, 0x2f, 0x62, 0x65, 0x74, 0x73, 0x12, 0x9a, 0x01, 0x0a, 0x0b, 0x50, 0x65, 0x6e, 0x64, + 0x69, 0x6e, 0x67, 0x42, 0x65, 0x74, 0x73, 0x12, 0x2e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x65, 0x74, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x42, 0x65, 0x74, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, + 0x12, 0x22, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x62, 0x65, 0x74, 0x73, 0x2f, + 0x70, 0x65, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x2f, 0x7b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, + 0x75, 0x69, 0x64, 0x7d, 0x12, 0xb4, 0x01, 0x0a, 0x13, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, + 0x42, 0x65, 0x74, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x36, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, + 0x64, 0x42, 0x65, 0x74, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x37, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x73, 0x4f, 0x66, 0x48, + 0x65, 0x69, 0x67, 0x68, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2c, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x62, 0x65, 0x74, 0x2f, + 0x62, 0x65, 0x74, 0x73, 0x2f, 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x2f, 0x7b, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x7d, 0x12, 0x92, 0x01, 0x0a, 0x0a, + 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, 0x73, 0x12, 0x2d, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, + 0x44, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x1f, 0x12, 0x1d, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x62, 0x65, 0x74, 0x73, + 0x2d, 0x62, 0x79, 0x2d, 0x75, 0x69, 0x64, 0x73, 0x2f, 0x7b, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x7d, + 0x42, 0xde, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, + 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, + 0x4c, 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x42, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, + 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, + 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_query_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_query_proto_rawDescData = file_sge_legacy_bet_v1beta_query_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_query_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_query_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 14) +var file_sge_legacy_bet_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.legacy.bet.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.legacy.bet.v1beta.QueryParamsResponse + (*QueryBetRequest)(nil), // 2: sge.legacy.bet.v1beta.QueryBetRequest + (*QueryBetResponse)(nil), // 3: sge.legacy.bet.v1beta.QueryBetResponse + (*QueryBetsRequest)(nil), // 4: sge.legacy.bet.v1beta.QueryBetsRequest + (*QueryBetsResponse)(nil), // 5: sge.legacy.bet.v1beta.QueryBetsResponse + (*QueryBetsByCreatorRequest)(nil), // 6: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest + (*QueryBetsByCreatorResponse)(nil), // 7: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse + (*QueryBetsByUIDsRequest)(nil), // 8: sge.legacy.bet.v1beta.QueryBetsByUIDsRequest + (*QueryBetsByUIDsResponse)(nil), // 9: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse + (*QueryPendingBetsRequest)(nil), // 10: sge.legacy.bet.v1beta.QueryPendingBetsRequest + (*QueryPendingBetsResponse)(nil), // 11: sge.legacy.bet.v1beta.QueryPendingBetsResponse + (*QuerySettledBetsOfHeightRequest)(nil), // 12: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest + (*QuerySettledBetsOfHeightResponse)(nil), // 13: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse + (*Params)(nil), // 14: sge.legacy.bet.v1beta.Params + (*Bet)(nil), // 15: sge.legacy.bet.v1beta.Bet + (*v1beta.Market)(nil), // 16: sge.legacy.market.v1beta.Market + (*v1beta1.PageRequest)(nil), // 17: cosmos.base.query.v1beta1.PageRequest + (*v1beta1.PageResponse)(nil), // 18: cosmos.base.query.v1beta1.PageResponse +} +var file_sge_legacy_bet_v1beta_query_proto_depIdxs = []int32{ + 14, // 0: sge.legacy.bet.v1beta.QueryParamsResponse.params:type_name -> sge.legacy.bet.v1beta.Params + 15, // 1: sge.legacy.bet.v1beta.QueryBetResponse.bet:type_name -> sge.legacy.bet.v1beta.Bet + 16, // 2: sge.legacy.bet.v1beta.QueryBetResponse.market:type_name -> sge.legacy.market.v1beta.Market + 17, // 3: sge.legacy.bet.v1beta.QueryBetsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 15, // 4: sge.legacy.bet.v1beta.QueryBetsResponse.bet:type_name -> sge.legacy.bet.v1beta.Bet + 18, // 5: sge.legacy.bet.v1beta.QueryBetsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 17, // 6: sge.legacy.bet.v1beta.QueryBetsByCreatorRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 15, // 7: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.bet:type_name -> sge.legacy.bet.v1beta.Bet + 18, // 8: sge.legacy.bet.v1beta.QueryBetsByCreatorResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 15, // 9: sge.legacy.bet.v1beta.QueryBetsByUIDsResponse.bets:type_name -> sge.legacy.bet.v1beta.Bet + 17, // 10: sge.legacy.bet.v1beta.QueryPendingBetsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 15, // 11: sge.legacy.bet.v1beta.QueryPendingBetsResponse.bet:type_name -> sge.legacy.bet.v1beta.Bet + 18, // 12: sge.legacy.bet.v1beta.QueryPendingBetsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 17, // 13: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 15, // 14: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.bet:type_name -> sge.legacy.bet.v1beta.Bet + 18, // 15: sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 0, // 16: sge.legacy.bet.v1beta.Query.Params:input_type -> sge.legacy.bet.v1beta.QueryParamsRequest + 2, // 17: sge.legacy.bet.v1beta.Query.Bet:input_type -> sge.legacy.bet.v1beta.QueryBetRequest + 6, // 18: sge.legacy.bet.v1beta.Query.BetsByCreator:input_type -> sge.legacy.bet.v1beta.QueryBetsByCreatorRequest + 4, // 19: sge.legacy.bet.v1beta.Query.Bets:input_type -> sge.legacy.bet.v1beta.QueryBetsRequest + 10, // 20: sge.legacy.bet.v1beta.Query.PendingBets:input_type -> sge.legacy.bet.v1beta.QueryPendingBetsRequest + 12, // 21: sge.legacy.bet.v1beta.Query.SettledBetsOfHeight:input_type -> sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest + 8, // 22: sge.legacy.bet.v1beta.Query.BetsByUIDs:input_type -> sge.legacy.bet.v1beta.QueryBetsByUIDsRequest + 1, // 23: sge.legacy.bet.v1beta.Query.Params:output_type -> sge.legacy.bet.v1beta.QueryParamsResponse + 3, // 24: sge.legacy.bet.v1beta.Query.Bet:output_type -> sge.legacy.bet.v1beta.QueryBetResponse + 7, // 25: sge.legacy.bet.v1beta.Query.BetsByCreator:output_type -> sge.legacy.bet.v1beta.QueryBetsByCreatorResponse + 5, // 26: sge.legacy.bet.v1beta.Query.Bets:output_type -> sge.legacy.bet.v1beta.QueryBetsResponse + 11, // 27: sge.legacy.bet.v1beta.Query.PendingBets:output_type -> sge.legacy.bet.v1beta.QueryPendingBetsResponse + 13, // 28: sge.legacy.bet.v1beta.Query.SettledBetsOfHeight:output_type -> sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse + 9, // 29: sge.legacy.bet.v1beta.Query.BetsByUIDs:output_type -> sge.legacy.bet.v1beta.QueryBetsByUIDsResponse + 23, // [23:30] is the sub-list for method output_type + 16, // [16:23] is the sub-list for method input_type + 16, // [16:16] is the sub-list for extension type_name + 16, // [16:16] is the sub-list for extension extendee + 0, // [0:16] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_query_proto_init() } +func file_sge_legacy_bet_v1beta_query_proto_init() { + if File_sge_legacy_bet_v1beta_query_proto != nil { + return + } + file_sge_legacy_bet_v1beta_bet_proto_init() + file_sge_legacy_bet_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetsByCreatorRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetsByCreatorResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetsByUIDsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryBetsByUIDsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPendingBetsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPendingBetsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QuerySettledBetsOfHeightRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_query_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QuerySettledBetsOfHeightResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 14, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_bet_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_query_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_query_proto = out.File + file_sge_legacy_bet_v1beta_query_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_query_proto_goTypes = nil + file_sge_legacy_bet_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/query_grpc.pb.go b/api/sge/legacy/bet/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..b9678c4e --- /dev/null +++ b/api/sge/legacy/bet/v1beta/query_grpc.pb.go @@ -0,0 +1,345 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/bet/v1beta/query.proto + +package betv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Params_FullMethodName = "/sge.legacy.bet.v1beta.Query/Params" + Query_Bet_FullMethodName = "/sge.legacy.bet.v1beta.Query/Bet" + Query_BetsByCreator_FullMethodName = "/sge.legacy.bet.v1beta.Query/BetsByCreator" + Query_Bets_FullMethodName = "/sge.legacy.bet.v1beta.Query/Bets" + Query_PendingBets_FullMethodName = "/sge.legacy.bet.v1beta.Query/PendingBets" + Query_SettledBetsOfHeight_FullMethodName = "/sge.legacy.bet.v1beta.Query/SettledBetsOfHeight" + Query_BetsByUIDs_FullMethodName = "/sge.legacy.bet.v1beta.Query/BetsByUIDs" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Params queries the parameters of the module. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) + // Queries a Bet by uid. + Bet(ctx context.Context, in *QueryBetRequest, opts ...grpc.CallOption) (*QueryBetResponse, error) + // Queries list of Bet items of a certain creator sorted by timestamp. + BetsByCreator(ctx context.Context, in *QueryBetsByCreatorRequest, opts ...grpc.CallOption) (*QueryBetsByCreatorResponse, error) + // Queries list of Bet items. + Bets(ctx context.Context, in *QueryBetsRequest, opts ...grpc.CallOption) (*QueryBetsResponse, error) + // Queries list of pending Bet items. + PendingBets(ctx context.Context, in *QueryPendingBetsRequest, opts ...grpc.CallOption) (*QueryPendingBetsResponse, error) + // Queries list of settled Bet items of a certain height. + SettledBetsOfHeight(ctx context.Context, in *QuerySettledBetsOfHeightRequest, opts ...grpc.CallOption) (*QuerySettledBetsOfHeightResponse, error) + // Queries a list of Bet items filtered by uid list. + BetsByUIDs(ctx context.Context, in *QueryBetsByUIDsRequest, opts ...grpc.CallOption) (*QueryBetsByUIDsResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Bet(ctx context.Context, in *QueryBetRequest, opts ...grpc.CallOption) (*QueryBetResponse, error) { + out := new(QueryBetResponse) + err := c.cc.Invoke(ctx, Query_Bet_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) BetsByCreator(ctx context.Context, in *QueryBetsByCreatorRequest, opts ...grpc.CallOption) (*QueryBetsByCreatorResponse, error) { + out := new(QueryBetsByCreatorResponse) + err := c.cc.Invoke(ctx, Query_BetsByCreator_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Bets(ctx context.Context, in *QueryBetsRequest, opts ...grpc.CallOption) (*QueryBetsResponse, error) { + out := new(QueryBetsResponse) + err := c.cc.Invoke(ctx, Query_Bets_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) PendingBets(ctx context.Context, in *QueryPendingBetsRequest, opts ...grpc.CallOption) (*QueryPendingBetsResponse, error) { + out := new(QueryPendingBetsResponse) + err := c.cc.Invoke(ctx, Query_PendingBets_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) SettledBetsOfHeight(ctx context.Context, in *QuerySettledBetsOfHeightRequest, opts ...grpc.CallOption) (*QuerySettledBetsOfHeightResponse, error) { + out := new(QuerySettledBetsOfHeightResponse) + err := c.cc.Invoke(ctx, Query_SettledBetsOfHeight_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) BetsByUIDs(ctx context.Context, in *QueryBetsByUIDsRequest, opts ...grpc.CallOption) (*QueryBetsByUIDsResponse, error) { + out := new(QueryBetsByUIDsResponse) + err := c.cc.Invoke(ctx, Query_BetsByUIDs_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Params queries the parameters of the module. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + // Queries a Bet by uid. + Bet(context.Context, *QueryBetRequest) (*QueryBetResponse, error) + // Queries list of Bet items of a certain creator sorted by timestamp. + BetsByCreator(context.Context, *QueryBetsByCreatorRequest) (*QueryBetsByCreatorResponse, error) + // Queries list of Bet items. + Bets(context.Context, *QueryBetsRequest) (*QueryBetsResponse, error) + // Queries list of pending Bet items. + PendingBets(context.Context, *QueryPendingBetsRequest) (*QueryPendingBetsResponse, error) + // Queries list of settled Bet items of a certain height. + SettledBetsOfHeight(context.Context, *QuerySettledBetsOfHeightRequest) (*QuerySettledBetsOfHeightResponse, error) + // Queries a list of Bet items filtered by uid list. + BetsByUIDs(context.Context, *QueryBetsByUIDsRequest) (*QueryBetsByUIDsResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) Bet(context.Context, *QueryBetRequest) (*QueryBetResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Bet not implemented") +} +func (UnimplementedQueryServer) BetsByCreator(context.Context, *QueryBetsByCreatorRequest) (*QueryBetsByCreatorResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method BetsByCreator not implemented") +} +func (UnimplementedQueryServer) Bets(context.Context, *QueryBetsRequest) (*QueryBetsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Bets not implemented") +} +func (UnimplementedQueryServer) PendingBets(context.Context, *QueryPendingBetsRequest) (*QueryPendingBetsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PendingBets not implemented") +} +func (UnimplementedQueryServer) SettledBetsOfHeight(context.Context, *QuerySettledBetsOfHeightRequest) (*QuerySettledBetsOfHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SettledBetsOfHeight not implemented") +} +func (UnimplementedQueryServer) BetsByUIDs(context.Context, *QueryBetsByUIDsRequest) (*QueryBetsByUIDsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method BetsByUIDs not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Bet_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryBetRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Bet(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Bet_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Bet(ctx, req.(*QueryBetRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_BetsByCreator_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryBetsByCreatorRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).BetsByCreator(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_BetsByCreator_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).BetsByCreator(ctx, req.(*QueryBetsByCreatorRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Bets_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryBetsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Bets(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Bets_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Bets(ctx, req.(*QueryBetsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_PendingBets_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPendingBetsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).PendingBets(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_PendingBets_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).PendingBets(ctx, req.(*QueryPendingBetsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_SettledBetsOfHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QuerySettledBetsOfHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).SettledBetsOfHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_SettledBetsOfHeight_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).SettledBetsOfHeight(ctx, req.(*QuerySettledBetsOfHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_BetsByUIDs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryBetsByUIDsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).BetsByUIDs(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_BetsByUIDs_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).BetsByUIDs(ctx, req.(*QueryBetsByUIDsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.bet.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + { + MethodName: "Bet", + Handler: _Query_Bet_Handler, + }, + { + MethodName: "BetsByCreator", + Handler: _Query_BetsByCreator_Handler, + }, + { + MethodName: "Bets", + Handler: _Query_Bets_Handler, + }, + { + MethodName: "PendingBets", + Handler: _Query_PendingBets_Handler, + }, + { + MethodName: "SettledBetsOfHeight", + Handler: _Query_SettledBetsOfHeight_Handler, + }, + { + MethodName: "BetsByUIDs", + Handler: _Query_BetsByUIDs_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/bet/v1beta/query.proto", +} diff --git a/api/sge/legacy/bet/v1beta/stats.pulsar.go b/api/sge/legacy/bet/v1beta/stats.pulsar.go new file mode 100644 index 00000000..0ce608b6 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/stats.pulsar.go @@ -0,0 +1,556 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_BetStats protoreflect.MessageDescriptor + fd_BetStats_count protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_stats_proto_init() + md_BetStats = File_sge_legacy_bet_v1beta_stats_proto.Messages().ByName("BetStats") + fd_BetStats_count = md_BetStats.Fields().ByName("count") +} + +var _ protoreflect.Message = (*fastReflection_BetStats)(nil) + +type fastReflection_BetStats BetStats + +func (x *BetStats) ProtoReflect() protoreflect.Message { + return (*fastReflection_BetStats)(x) +} + +func (x *BetStats) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_stats_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_BetStats_messageType fastReflection_BetStats_messageType +var _ protoreflect.MessageType = fastReflection_BetStats_messageType{} + +type fastReflection_BetStats_messageType struct{} + +func (x fastReflection_BetStats_messageType) Zero() protoreflect.Message { + return (*fastReflection_BetStats)(nil) +} +func (x fastReflection_BetStats_messageType) New() protoreflect.Message { + return new(fastReflection_BetStats) +} +func (x fastReflection_BetStats_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_BetStats +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_BetStats) Descriptor() protoreflect.MessageDescriptor { + return md_BetStats +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_BetStats) Type() protoreflect.MessageType { + return _fastReflection_BetStats_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_BetStats) New() protoreflect.Message { + return new(fastReflection_BetStats) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_BetStats) Interface() protoreflect.ProtoMessage { + return (*BetStats)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_BetStats) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Count != uint64(0) { + value := protoreflect.ValueOfUint64(x.Count) + if !f(fd_BetStats_count, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_BetStats) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetStats.count": + return x.Count != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetStats")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetStats does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetStats) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetStats.count": + x.Count = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetStats")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetStats does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_BetStats) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.BetStats.count": + value := x.Count + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetStats")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetStats does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetStats) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetStats.count": + x.Count = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetStats")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetStats does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetStats) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetStats.count": + panic(fmt.Errorf("field count of message sge.legacy.bet.v1beta.BetStats is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetStats")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetStats does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_BetStats) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.BetStats.count": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.BetStats")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.BetStats does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_BetStats) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.BetStats", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_BetStats) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_BetStats) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_BetStats) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_BetStats) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*BetStats) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Count != 0 { + n += 1 + runtime.Sov(uint64(x.Count)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*BetStats) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Count != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Count)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*BetStats) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetStats: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: BetStats: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Count", wireType) + } + x.Count = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Count |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/stats.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// BetStats is the type of statistics of the betting in the blockchain state. +type BetStats struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // count is the total count of bets. + Count uint64 `protobuf:"varint,1,opt,name=count,proto3" json:"count,omitempty"` +} + +func (x *BetStats) Reset() { + *x = BetStats{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_stats_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *BetStats) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BetStats) ProtoMessage() {} + +// Deprecated: Use BetStats.ProtoReflect.Descriptor instead. +func (*BetStats) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_stats_proto_rawDescGZIP(), []int{0} +} + +func (x *BetStats) GetCount() uint64 { + if x != nil { + return x.Count + } + return 0 +} + +var File_sge_legacy_bet_v1beta_stats_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_stats_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x22, 0x20, 0x0a, 0x08, 0x42, 0x65, + 0x74, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0xde, 0x01, 0x0a, + 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, + 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, + 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x62, + 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x42, 0xaa, 0x02, + 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, + 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_stats_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_stats_proto_rawDescData = file_sge_legacy_bet_v1beta_stats_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_stats_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_stats_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_stats_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_stats_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_stats_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_stats_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_bet_v1beta_stats_proto_goTypes = []interface{}{ + (*BetStats)(nil), // 0: sge.legacy.bet.v1beta.BetStats +} +var file_sge_legacy_bet_v1beta_stats_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_stats_proto_init() } +func file_sge_legacy_bet_v1beta_stats_proto_init() { + if File_sge_legacy_bet_v1beta_stats_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_stats_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*BetStats); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_stats_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_stats_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_stats_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_stats_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_stats_proto = out.File + file_sge_legacy_bet_v1beta_stats_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_stats_proto_goTypes = nil + file_sge_legacy_bet_v1beta_stats_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/ticket.pulsar.go b/api/sge/legacy/bet/v1beta/ticket.pulsar.go new file mode 100644 index 00000000..3da65fa9 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/ticket.pulsar.go @@ -0,0 +1,1020 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + v1beta "github.com/sge-network/sge/api/sge/legacy/type/v1beta" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_WagerTicketPayload_4_list)(nil) + +type _WagerTicketPayload_4_list struct { + list *[]*BetOddsCompact +} + +func (x *_WagerTicketPayload_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_WagerTicketPayload_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_WagerTicketPayload_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*BetOddsCompact) + (*x.list)[i] = concreteValue +} + +func (x *_WagerTicketPayload_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*BetOddsCompact) + *x.list = append(*x.list, concreteValue) +} + +func (x *_WagerTicketPayload_4_list) AppendMutable() protoreflect.Value { + v := new(BetOddsCompact) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_WagerTicketPayload_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_WagerTicketPayload_4_list) NewElement() protoreflect.Value { + v := new(BetOddsCompact) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_WagerTicketPayload_4_list) IsValid() bool { + return x.list != nil +} + +var ( + md_WagerTicketPayload protoreflect.MessageDescriptor + fd_WagerTicketPayload_selected_odds protoreflect.FieldDescriptor + fd_WagerTicketPayload_kyc_data protoreflect.FieldDescriptor + fd_WagerTicketPayload_all_odds protoreflect.FieldDescriptor + fd_WagerTicketPayload_meta protoreflect.FieldDescriptor + fd_WagerTicketPayload_context protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_ticket_proto_init() + md_WagerTicketPayload = File_sge_legacy_bet_v1beta_ticket_proto.Messages().ByName("WagerTicketPayload") + fd_WagerTicketPayload_selected_odds = md_WagerTicketPayload.Fields().ByName("selected_odds") + fd_WagerTicketPayload_kyc_data = md_WagerTicketPayload.Fields().ByName("kyc_data") + fd_WagerTicketPayload_all_odds = md_WagerTicketPayload.Fields().ByName("all_odds") + fd_WagerTicketPayload_meta = md_WagerTicketPayload.Fields().ByName("meta") + fd_WagerTicketPayload_context = md_WagerTicketPayload.Fields().ByName("context") +} + +var _ protoreflect.Message = (*fastReflection_WagerTicketPayload)(nil) + +type fastReflection_WagerTicketPayload WagerTicketPayload + +func (x *WagerTicketPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_WagerTicketPayload)(x) +} + +func (x *WagerTicketPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_ticket_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_WagerTicketPayload_messageType fastReflection_WagerTicketPayload_messageType +var _ protoreflect.MessageType = fastReflection_WagerTicketPayload_messageType{} + +type fastReflection_WagerTicketPayload_messageType struct{} + +func (x fastReflection_WagerTicketPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_WagerTicketPayload)(nil) +} +func (x fastReflection_WagerTicketPayload_messageType) New() protoreflect.Message { + return new(fastReflection_WagerTicketPayload) +} +func (x fastReflection_WagerTicketPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_WagerTicketPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_WagerTicketPayload) Descriptor() protoreflect.MessageDescriptor { + return md_WagerTicketPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_WagerTicketPayload) Type() protoreflect.MessageType { + return _fastReflection_WagerTicketPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_WagerTicketPayload) New() protoreflect.Message { + return new(fastReflection_WagerTicketPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_WagerTicketPayload) Interface() protoreflect.ProtoMessage { + return (*WagerTicketPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_WagerTicketPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.SelectedOdds != nil { + value := protoreflect.ValueOfMessage(x.SelectedOdds.ProtoReflect()) + if !f(fd_WagerTicketPayload_selected_odds, value) { + return + } + } + if x.KycData != nil { + value := protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + if !f(fd_WagerTicketPayload_kyc_data, value) { + return + } + } + if len(x.AllOdds) != 0 { + value := protoreflect.ValueOfList(&_WagerTicketPayload_4_list{list: &x.AllOdds}) + if !f(fd_WagerTicketPayload_all_odds, value) { + return + } + } + if x.Meta != nil { + value := protoreflect.ValueOfMessage(x.Meta.ProtoReflect()) + if !f(fd_WagerTicketPayload_meta, value) { + return + } + } + if x.Context != "" { + value := protoreflect.ValueOfString(x.Context) + if !f(fd_WagerTicketPayload_context, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_WagerTicketPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerTicketPayload.selected_odds": + return x.SelectedOdds != nil + case "sge.legacy.bet.v1beta.WagerTicketPayload.kyc_data": + return x.KycData != nil + case "sge.legacy.bet.v1beta.WagerTicketPayload.all_odds": + return len(x.AllOdds) != 0 + case "sge.legacy.bet.v1beta.WagerTicketPayload.meta": + return x.Meta != nil + case "sge.legacy.bet.v1beta.WagerTicketPayload.context": + return x.Context != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerTicketPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerTicketPayload.selected_odds": + x.SelectedOdds = nil + case "sge.legacy.bet.v1beta.WagerTicketPayload.kyc_data": + x.KycData = nil + case "sge.legacy.bet.v1beta.WagerTicketPayload.all_odds": + x.AllOdds = nil + case "sge.legacy.bet.v1beta.WagerTicketPayload.meta": + x.Meta = nil + case "sge.legacy.bet.v1beta.WagerTicketPayload.context": + x.Context = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_WagerTicketPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.WagerTicketPayload.selected_odds": + value := x.SelectedOdds + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.kyc_data": + value := x.KycData + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.all_odds": + if len(x.AllOdds) == 0 { + return protoreflect.ValueOfList(&_WagerTicketPayload_4_list{}) + } + listValue := &_WagerTicketPayload_4_list{list: &x.AllOdds} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.bet.v1beta.WagerTicketPayload.meta": + value := x.Meta + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.context": + value := x.Context + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerTicketPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerTicketPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerTicketPayload.selected_odds": + x.SelectedOdds = value.Message().Interface().(*BetOdds) + case "sge.legacy.bet.v1beta.WagerTicketPayload.kyc_data": + x.KycData = value.Message().Interface().(*v1beta.KycDataPayload) + case "sge.legacy.bet.v1beta.WagerTicketPayload.all_odds": + lv := value.List() + clv := lv.(*_WagerTicketPayload_4_list) + x.AllOdds = *clv.list + case "sge.legacy.bet.v1beta.WagerTicketPayload.meta": + x.Meta = value.Message().Interface().(*MetaData) + case "sge.legacy.bet.v1beta.WagerTicketPayload.context": + x.Context = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerTicketPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerTicketPayload.selected_odds": + if x.SelectedOdds == nil { + x.SelectedOdds = new(BetOdds) + } + return protoreflect.ValueOfMessage(x.SelectedOdds.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.kyc_data": + if x.KycData == nil { + x.KycData = new(v1beta.KycDataPayload) + } + return protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.all_odds": + if x.AllOdds == nil { + x.AllOdds = []*BetOddsCompact{} + } + value := &_WagerTicketPayload_4_list{list: &x.AllOdds} + return protoreflect.ValueOfList(value) + case "sge.legacy.bet.v1beta.WagerTicketPayload.meta": + if x.Meta == nil { + x.Meta = new(MetaData) + } + return protoreflect.ValueOfMessage(x.Meta.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.context": + panic(fmt.Errorf("field context of message sge.legacy.bet.v1beta.WagerTicketPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_WagerTicketPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerTicketPayload.selected_odds": + m := new(BetOdds) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.kyc_data": + m := new(v1beta.KycDataPayload) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.all_odds": + list := []*BetOddsCompact{} + return protoreflect.ValueOfList(&_WagerTicketPayload_4_list{list: &list}) + case "sge.legacy.bet.v1beta.WagerTicketPayload.meta": + m := new(MetaData) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.bet.v1beta.WagerTicketPayload.context": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_WagerTicketPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.WagerTicketPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_WagerTicketPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerTicketPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_WagerTicketPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_WagerTicketPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*WagerTicketPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.SelectedOdds != nil { + l = options.Size(x.SelectedOdds) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.KycData != nil { + l = options.Size(x.KycData) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.AllOdds) > 0 { + for _, e := range x.AllOdds { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Meta != nil { + l = options.Size(x.Meta) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Context) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*WagerTicketPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Context) > 0 { + i -= len(x.Context) + copy(dAtA[i:], x.Context) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Context))) + i-- + dAtA[i] = 0x32 + } + if x.Meta != nil { + encoded, err := options.Marshal(x.Meta) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x2a + } + if len(x.AllOdds) > 0 { + for iNdEx := len(x.AllOdds) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.AllOdds[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if x.KycData != nil { + encoded, err := options.Marshal(x.KycData) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if x.SelectedOdds != nil { + encoded, err := options.Marshal(x.SelectedOdds) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*WagerTicketPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WagerTicketPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WagerTicketPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SelectedOdds", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.SelectedOdds == nil { + x.SelectedOdds = &BetOdds{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.SelectedOdds); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field KycData", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.KycData == nil { + x.KycData = &v1beta.KycDataPayload{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.KycData); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AllOdds", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.AllOdds = append(x.AllOdds, &BetOddsCompact{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.AllOdds[len(x.AllOdds)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Meta == nil { + x.Meta = &MetaData{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Meta); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Context", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Context = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/ticket.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// WagerTicketPayload indicates data of bet placement ticket. +type WagerTicketPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // selected_odds is the user-selected odds to place bet. + SelectedOdds *BetOdds `protobuf:"bytes,1,opt,name=selected_odds,json=selectedOdds,proto3" json:"selected_odds,omitempty"` + // kyc_data contains the details of user kyc. + KycData *v1beta.KycDataPayload `protobuf:"bytes,2,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data,omitempty"` + // all odds for the selected market. + AllOdds []*BetOddsCompact `protobuf:"bytes,4,rep,name=all_odds,json=allOdds,proto3" json:"all_odds,omitempty"` + // meta is metadata for bet placement + Meta *MetaData `protobuf:"bytes,5,opt,name=meta,proto3" json:"meta,omitempty"` + // context contains the data from services and just for processing purpose. + Context string `protobuf:"bytes,6,opt,name=context,proto3" json:"context,omitempty"` +} + +func (x *WagerTicketPayload) Reset() { + *x = WagerTicketPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_ticket_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WagerTicketPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WagerTicketPayload) ProtoMessage() {} + +// Deprecated: Use WagerTicketPayload.ProtoReflect.Descriptor instead. +func (*WagerTicketPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_ticket_proto_rawDescGZIP(), []int{0} +} + +func (x *WagerTicketPayload) GetSelectedOdds() *BetOdds { + if x != nil { + return x.SelectedOdds + } + return nil +} + +func (x *WagerTicketPayload) GetKycData() *v1beta.KycDataPayload { + if x != nil { + return x.KycData + } + return nil +} + +func (x *WagerTicketPayload) GetAllOdds() []*BetOddsCompact { + if x != nil { + return x.AllOdds + } + return nil +} + +func (x *WagerTicketPayload) GetMeta() *MetaData { + if x != nil { + return x.Meta + } + return nil +} + +func (x *WagerTicketPayload) GetContext() string { + if x != nil { + return x.Context + } + return "" +} + +var File_sge_legacy_bet_v1beta_ticket_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_ticket_proto_rawDesc = []byte{ + 0x0a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, + 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x1f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, + 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, + 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x65, 0x74, 0x5f, 0x6f, 0x64, + 0x64, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x20, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2f, 0x6b, 0x79, 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb9, 0x02, 0x0a, 0x12, 0x57, + 0x61, 0x67, 0x65, 0x72, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, + 0x64, 0x12, 0x43, 0x0a, 0x0d, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x65, 0x64, 0x5f, 0x6f, 0x64, + 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x42, 0x65, 0x74, 0x4f, 0x64, 0x64, 0x73, 0x52, 0x0c, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, + 0x65, 0x64, 0x4f, 0x64, 0x64, 0x73, 0x12, 0x47, 0x0a, 0x08, 0x6b, 0x79, 0x63, 0x5f, 0x64, 0x61, + 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4b, 0x79, 0x63, 0x44, 0x61, 0x74, 0x61, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, + 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x6b, 0x79, 0x63, 0x44, 0x61, 0x74, 0x61, 0x12, + 0x40, 0x0a, 0x08, 0x61, 0x6c, 0x6c, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x25, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, + 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x42, 0x65, 0x74, 0x4f, 0x64, 0x64, + 0x73, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x63, 0x74, 0x52, 0x07, 0x61, 0x6c, 0x6c, 0x4f, 0x64, 0x64, + 0x73, 0x12, 0x39, 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x65, 0x74, 0x61, 0x44, 0x61, 0x74, 0x61, + 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, + 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, + 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x42, 0xdf, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, + 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, + 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, + 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, + 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_ticket_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_ticket_proto_rawDescData = file_sge_legacy_bet_v1beta_ticket_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_ticket_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_ticket_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_ticket_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_ticket_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_ticket_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_ticket_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_bet_v1beta_ticket_proto_goTypes = []interface{}{ + (*WagerTicketPayload)(nil), // 0: sge.legacy.bet.v1beta.WagerTicketPayload + (*BetOdds)(nil), // 1: sge.legacy.bet.v1beta.BetOdds + (*v1beta.KycDataPayload)(nil), // 2: sge.legacy.type.v1beta.KycDataPayload + (*BetOddsCompact)(nil), // 3: sge.legacy.bet.v1beta.BetOddsCompact + (*MetaData)(nil), // 4: sge.legacy.bet.v1beta.MetaData +} +var file_sge_legacy_bet_v1beta_ticket_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.bet.v1beta.WagerTicketPayload.selected_odds:type_name -> sge.legacy.bet.v1beta.BetOdds + 2, // 1: sge.legacy.bet.v1beta.WagerTicketPayload.kyc_data:type_name -> sge.legacy.type.v1beta.KycDataPayload + 3, // 2: sge.legacy.bet.v1beta.WagerTicketPayload.all_odds:type_name -> sge.legacy.bet.v1beta.BetOddsCompact + 4, // 3: sge.legacy.bet.v1beta.WagerTicketPayload.meta:type_name -> sge.legacy.bet.v1beta.MetaData + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_ticket_proto_init() } +func file_sge_legacy_bet_v1beta_ticket_proto_init() { + if File_sge_legacy_bet_v1beta_ticket_proto != nil { + return + } + file_sge_legacy_bet_v1beta_bet_proto_init() + file_sge_legacy_bet_v1beta_bet_odds_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_ticket_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WagerTicketPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_ticket_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_ticket_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_ticket_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_ticket_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_ticket_proto = out.File + file_sge_legacy_bet_v1beta_ticket_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_ticket_proto_goTypes = nil + file_sge_legacy_bet_v1beta_ticket_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/tx.pulsar.go b/api/sge/legacy/bet/v1beta/tx.pulsar.go new file mode 100644 index 00000000..430c8344 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/tx.pulsar.go @@ -0,0 +1,2165 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_MsgWager protoreflect.MessageDescriptor + fd_MsgWager_creator protoreflect.FieldDescriptor + fd_MsgWager_props protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_tx_proto_init() + md_MsgWager = File_sge_legacy_bet_v1beta_tx_proto.Messages().ByName("MsgWager") + fd_MsgWager_creator = md_MsgWager.Fields().ByName("creator") + fd_MsgWager_props = md_MsgWager.Fields().ByName("props") +} + +var _ protoreflect.Message = (*fastReflection_MsgWager)(nil) + +type fastReflection_MsgWager MsgWager + +func (x *MsgWager) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWager)(x) +} + +func (x *MsgWager) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWager_messageType fastReflection_MsgWager_messageType +var _ protoreflect.MessageType = fastReflection_MsgWager_messageType{} + +type fastReflection_MsgWager_messageType struct{} + +func (x fastReflection_MsgWager_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWager)(nil) +} +func (x fastReflection_MsgWager_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWager) +} +func (x fastReflection_MsgWager_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWager +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWager) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWager +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWager) Type() protoreflect.MessageType { + return _fastReflection_MsgWager_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWager) New() protoreflect.Message { + return new(fastReflection_MsgWager) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWager) Interface() protoreflect.ProtoMessage { + return (*MsgWager)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWager) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgWager_creator, value) { + return + } + } + if x.Props != nil { + value := protoreflect.ValueOfMessage(x.Props.ProtoReflect()) + if !f(fd_MsgWager_props, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWager) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWager.creator": + return x.Creator != "" + case "sge.legacy.bet.v1beta.MsgWager.props": + return x.Props != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWager.creator": + x.Creator = "" + case "sge.legacy.bet.v1beta.MsgWager.props": + x.Props = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWager) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.MsgWager.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.MsgWager.props": + value := x.Props + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWager does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWager.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.bet.v1beta.MsgWager.props": + x.Props = value.Message().Interface().(*WagerProps) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWager.props": + if x.Props == nil { + x.Props = new(WagerProps) + } + return protoreflect.ValueOfMessage(x.Props.ProtoReflect()) + case "sge.legacy.bet.v1beta.MsgWager.creator": + panic(fmt.Errorf("field creator of message sge.legacy.bet.v1beta.MsgWager is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWager) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWager.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.MsgWager.props": + m := new(WagerProps) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWager) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.MsgWager", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWager) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWager) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWager) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWager) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Props != nil { + l = options.Size(x.Props) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWager) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Props != nil { + encoded, err := options.Marshal(x.Props) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWager) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWager: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWager: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Props", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Props == nil { + x.Props = &WagerProps{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Props); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWagerResponse protoreflect.MessageDescriptor + fd_MsgWagerResponse_props protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_tx_proto_init() + md_MsgWagerResponse = File_sge_legacy_bet_v1beta_tx_proto.Messages().ByName("MsgWagerResponse") + fd_MsgWagerResponse_props = md_MsgWagerResponse.Fields().ByName("props") +} + +var _ protoreflect.Message = (*fastReflection_MsgWagerResponse)(nil) + +type fastReflection_MsgWagerResponse MsgWagerResponse + +func (x *MsgWagerResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWagerResponse)(x) +} + +func (x *MsgWagerResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWagerResponse_messageType fastReflection_MsgWagerResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgWagerResponse_messageType{} + +type fastReflection_MsgWagerResponse_messageType struct{} + +func (x fastReflection_MsgWagerResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWagerResponse)(nil) +} +func (x fastReflection_MsgWagerResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWagerResponse) +} +func (x fastReflection_MsgWagerResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWagerResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWagerResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWagerResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWagerResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgWagerResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWagerResponse) New() protoreflect.Message { + return new(fastReflection_MsgWagerResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWagerResponse) Interface() protoreflect.ProtoMessage { + return (*MsgWagerResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWagerResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Props != nil { + value := protoreflect.ValueOfMessage(x.Props.ProtoReflect()) + if !f(fd_MsgWagerResponse_props, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWagerResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWagerResponse.props": + return x.Props != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWagerResponse.props": + x.Props = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWagerResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.MsgWagerResponse.props": + value := x.Props + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWagerResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWagerResponse.props": + x.Props = value.Message().Interface().(*WagerProps) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWagerResponse.props": + if x.Props == nil { + x.Props = new(WagerProps) + } + return protoreflect.ValueOfMessage(x.Props.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWagerResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgWagerResponse.props": + m := new(WagerProps) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWagerResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.MsgWagerResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWagerResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWagerResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWagerResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWagerResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Props != nil { + l = options.Size(x.Props) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWagerResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Props != nil { + encoded, err := options.Marshal(x.Props) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWagerResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWagerResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWagerResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Props", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Props == nil { + x.Props = &WagerProps{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Props); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_legacy_bet_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.legacy.bet.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.legacy.bet.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.legacy.bet.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.bet.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.legacy.bet.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_legacy_bet_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgWager defines a message to place a bet with the given data. +type MsgWager struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the bettor address. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // props contains bet properties. + Props *WagerProps `protobuf:"bytes,2,opt,name=props,proto3" json:"props,omitempty"` +} + +func (x *MsgWager) Reset() { + *x = MsgWager{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWager) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWager) ProtoMessage() {} + +// Deprecated: Use MsgWager.ProtoReflect.Descriptor instead. +func (*MsgWager) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgWager) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgWager) GetProps() *WagerProps { + if x != nil { + return x.Props + } + return nil +} + +// MsgWagerResponse is the returning value in the response +// of MsgWagerResponse request. +type MsgWagerResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Props *WagerProps `protobuf:"bytes,1,opt,name=props,proto3" json:"props,omitempty"` +} + +func (x *MsgWagerResponse) Reset() { + *x = MsgWagerResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWagerResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWagerResponse) ProtoMessage() {} + +// Deprecated: Use MsgWagerResponse.ProtoReflect.Descriptor instead. +func (*MsgWagerResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +func (x *MsgWagerResponse) GetProps() *WagerProps { + if x != nil { + return x.Props + } + return nil +} + +// MsgUpdateParams is the Msg/UpdateParams request type. +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/bet parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_tx_proto_rawDescGZIP(), []int{2} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_tx_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_tx_proto_rawDescGZIP(), []int{3} +} + +var File_sge_legacy_bet_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x1e, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, + 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, + 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, + 0x77, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x85, 0x01, 0x0a, 0x08, + 0x4d, 0x73, 0x67, 0x57, 0x61, 0x67, 0x65, 0x72, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x37, 0x0a, 0x05, + 0x70, 0x72, 0x6f, 0x70, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x57, 0x61, 0x67, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x70, 0x73, 0x52, 0x05, + 0x70, 0x72, 0x6f, 0x70, 0x73, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x6f, 0x72, 0x22, 0x4b, 0x0a, 0x10, 0x4d, 0x73, 0x67, 0x57, 0x61, 0x67, 0x65, 0x72, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x05, 0x70, 0x72, 0x6f, 0x70, 0x73, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x57, + 0x61, 0x67, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x70, 0x73, 0x52, 0x05, 0x70, 0x72, 0x6f, 0x70, 0x73, + 0x22, 0xb0, 0x01, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, + 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x40, 0x0a, 0x06, + 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, + 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x3a, 0x23, + 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, + 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, + 0x69, 0x74, 0x79, 0x22, 0x30, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x3a, 0x15, + 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, + 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x32, 0xe0, 0x01, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x56, 0x0a, + 0x05, 0x57, 0x61, 0x67, 0x65, 0x72, 0x12, 0x1f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, + 0x73, 0x67, 0x57, 0x61, 0x67, 0x65, 0x72, 0x1a, 0x27, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x4d, 0x73, 0x67, 0x57, 0x61, 0x67, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x80, 0x01, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, + 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x2e, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x18, + 0xca, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, + 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x88, 0x02, 0x01, 0x42, 0xdb, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, + 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, + 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, + 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x42, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, + 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, + 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_tx_proto_rawDescData = file_sge_legacy_bet_v1beta_tx_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_tx_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_tx_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 4) +var file_sge_legacy_bet_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgWager)(nil), // 0: sge.legacy.bet.v1beta.MsgWager + (*MsgWagerResponse)(nil), // 1: sge.legacy.bet.v1beta.MsgWagerResponse + (*MsgUpdateParams)(nil), // 2: sge.legacy.bet.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 3: sge.legacy.bet.v1beta.MsgUpdateParamsResponse + (*WagerProps)(nil), // 4: sge.legacy.bet.v1beta.WagerProps + (*Params)(nil), // 5: sge.legacy.bet.v1beta.Params +} +var file_sge_legacy_bet_v1beta_tx_proto_depIdxs = []int32{ + 4, // 0: sge.legacy.bet.v1beta.MsgWager.props:type_name -> sge.legacy.bet.v1beta.WagerProps + 4, // 1: sge.legacy.bet.v1beta.MsgWagerResponse.props:type_name -> sge.legacy.bet.v1beta.WagerProps + 5, // 2: sge.legacy.bet.v1beta.MsgUpdateParams.params:type_name -> sge.legacy.bet.v1beta.Params + 0, // 3: sge.legacy.bet.v1beta.Msg.Wager:input_type -> sge.legacy.bet.v1beta.MsgWager + 2, // 4: sge.legacy.bet.v1beta.Msg.UpdateParams:input_type -> sge.legacy.bet.v1beta.MsgUpdateParams + 1, // 5: sge.legacy.bet.v1beta.Msg.Wager:output_type -> sge.legacy.bet.v1beta.MsgWagerResponse + 3, // 6: sge.legacy.bet.v1beta.Msg.UpdateParams:output_type -> sge.legacy.bet.v1beta.MsgUpdateParamsResponse + 5, // [5:7] is the sub-list for method output_type + 3, // [3:5] is the sub-list for method input_type + 3, // [3:3] is the sub-list for extension type_name + 3, // [3:3] is the sub-list for extension extendee + 0, // [0:3] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_tx_proto_init() } +func file_sge_legacy_bet_v1beta_tx_proto_init() { + if File_sge_legacy_bet_v1beta_tx_proto != nil { + return + } + file_sge_legacy_bet_v1beta_params_proto_init() + file_sge_legacy_bet_v1beta_wager_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWager); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWagerResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_tx_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_bet_v1beta_tx_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 4, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_bet_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_tx_proto = out.File + file_sge_legacy_bet_v1beta_tx_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_tx_proto_goTypes = nil + file_sge_legacy_bet_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/legacy/bet/v1beta/tx_grpc.pb.go b/api/sge/legacy/bet/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..99b64f4c --- /dev/null +++ b/api/sge/legacy/bet/v1beta/tx_grpc.pb.go @@ -0,0 +1,158 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/bet/v1beta/tx.proto + +package betv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_Wager_FullMethodName = "/sge.legacy.bet.v1beta.Msg/Wager" + Msg_UpdateParams_FullMethodName = "/sge.legacy.bet.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // Deprecated: Do not use. + // Wager defines a method to place a bet with the given data. + Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOption) (*MsgWagerResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/bet module + // parameters. The authority is defined in the keeper. + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +// Deprecated: Do not use. +func (c *msgClient) Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOption) (*MsgWagerResponse, error) { + out := new(MsgWagerResponse) + err := c.cc.Invoke(ctx, Msg_Wager_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // Deprecated: Do not use. + // Wager defines a method to place a bet with the given data. + Wager(context.Context, *MsgWager) (*MsgWagerResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/bet module + // parameters. The authority is defined in the keeper. + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) Wager(context.Context, *MsgWager) (*MsgWagerResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Wager not implemented") +} +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_Wager_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgWager) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Wager(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Wager_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Wager(ctx, req.(*MsgWager)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.bet.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Wager", + Handler: _Msg_Wager_Handler, + }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/bet/v1beta/tx.proto", +} diff --git a/api/sge/legacy/bet/v1beta/wager.pulsar.go b/api/sge/legacy/bet/v1beta/wager.pulsar.go new file mode 100644 index 00000000..b9809949 --- /dev/null +++ b/api/sge/legacy/bet/v1beta/wager.pulsar.go @@ -0,0 +1,726 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package betv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_WagerProps protoreflect.MessageDescriptor + fd_WagerProps_uid protoreflect.FieldDescriptor + fd_WagerProps_amount protoreflect.FieldDescriptor + fd_WagerProps_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_bet_v1beta_wager_proto_init() + md_WagerProps = File_sge_legacy_bet_v1beta_wager_proto.Messages().ByName("WagerProps") + fd_WagerProps_uid = md_WagerProps.Fields().ByName("uid") + fd_WagerProps_amount = md_WagerProps.Fields().ByName("amount") + fd_WagerProps_ticket = md_WagerProps.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_WagerProps)(nil) + +type fastReflection_WagerProps WagerProps + +func (x *WagerProps) ProtoReflect() protoreflect.Message { + return (*fastReflection_WagerProps)(x) +} + +func (x *WagerProps) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_bet_v1beta_wager_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_WagerProps_messageType fastReflection_WagerProps_messageType +var _ protoreflect.MessageType = fastReflection_WagerProps_messageType{} + +type fastReflection_WagerProps_messageType struct{} + +func (x fastReflection_WagerProps_messageType) Zero() protoreflect.Message { + return (*fastReflection_WagerProps)(nil) +} +func (x fastReflection_WagerProps_messageType) New() protoreflect.Message { + return new(fastReflection_WagerProps) +} +func (x fastReflection_WagerProps_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_WagerProps +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_WagerProps) Descriptor() protoreflect.MessageDescriptor { + return md_WagerProps +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_WagerProps) Type() protoreflect.MessageType { + return _fastReflection_WagerProps_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_WagerProps) New() protoreflect.Message { + return new(fastReflection_WagerProps) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_WagerProps) Interface() protoreflect.ProtoMessage { + return (*WagerProps)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_WagerProps) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_WagerProps_uid, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_WagerProps_amount, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_WagerProps_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_WagerProps) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerProps.uid": + return x.Uid != "" + case "sge.legacy.bet.v1beta.WagerProps.amount": + return x.Amount != "" + case "sge.legacy.bet.v1beta.WagerProps.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerProps")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerProps does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerProps) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerProps.uid": + x.Uid = "" + case "sge.legacy.bet.v1beta.WagerProps.amount": + x.Amount = "" + case "sge.legacy.bet.v1beta.WagerProps.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerProps")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerProps does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_WagerProps) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.bet.v1beta.WagerProps.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.WagerProps.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + case "sge.legacy.bet.v1beta.WagerProps.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerProps")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerProps does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerProps) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerProps.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.bet.v1beta.WagerProps.amount": + x.Amount = value.Interface().(string) + case "sge.legacy.bet.v1beta.WagerProps.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerProps")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerProps does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerProps) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerProps.uid": + panic(fmt.Errorf("field uid of message sge.legacy.bet.v1beta.WagerProps is not mutable")) + case "sge.legacy.bet.v1beta.WagerProps.amount": + panic(fmt.Errorf("field amount of message sge.legacy.bet.v1beta.WagerProps is not mutable")) + case "sge.legacy.bet.v1beta.WagerProps.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.bet.v1beta.WagerProps is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerProps")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerProps does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_WagerProps) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.bet.v1beta.WagerProps.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.WagerProps.amount": + return protoreflect.ValueOfString("") + case "sge.legacy.bet.v1beta.WagerProps.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.bet.v1beta.WagerProps")) + } + panic(fmt.Errorf("message sge.legacy.bet.v1beta.WagerProps does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_WagerProps) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.bet.v1beta.WagerProps", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_WagerProps) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WagerProps) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_WagerProps) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_WagerProps) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*WagerProps) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*WagerProps) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x1a + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*WagerProps) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WagerProps: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WagerProps: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/bet/v1beta/wager.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// WagerProps contains attributes which come in wager tx request. +type WagerProps struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier assigned to bet. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // amount is the wager amount. + Amount string `protobuf:"bytes,2,opt,name=amount,proto3" json:"amount,omitempty"` + // ticket is a signed string containing important info such as `oddsValue`. + Ticket string `protobuf:"bytes,3,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *WagerProps) Reset() { + *x = WagerProps{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_bet_v1beta_wager_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WagerProps) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WagerProps) ProtoMessage() {} + +// Deprecated: Use WagerProps.ProtoReflect.Descriptor instead. +func (*WagerProps) Descriptor() ([]byte, []int) { + return file_sge_legacy_bet_v1beta_wager_proto_rawDescGZIP(), []int{0} +} + +func (x *WagerProps) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *WagerProps) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +func (x *WagerProps) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +var File_sge_legacy_bet_v1beta_wager_proto protoreflect.FileDescriptor + +var file_sge_legacy_bet_v1beta_wager_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x77, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x22, 0x7d, 0x0a, 0x0a, 0x57, 0x61, 0x67, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x70, 0x73, 0x12, 0x20, + 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, + 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, + 0x12, 0x35, 0x0a, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, + 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x42, + 0xde, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x57, + 0x61, 0x67, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x3b, 0x62, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, + 0x42, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x42, + 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x42, + 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x42, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_bet_v1beta_wager_proto_rawDescOnce sync.Once + file_sge_legacy_bet_v1beta_wager_proto_rawDescData = file_sge_legacy_bet_v1beta_wager_proto_rawDesc +) + +func file_sge_legacy_bet_v1beta_wager_proto_rawDescGZIP() []byte { + file_sge_legacy_bet_v1beta_wager_proto_rawDescOnce.Do(func() { + file_sge_legacy_bet_v1beta_wager_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_bet_v1beta_wager_proto_rawDescData) + }) + return file_sge_legacy_bet_v1beta_wager_proto_rawDescData +} + +var file_sge_legacy_bet_v1beta_wager_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_bet_v1beta_wager_proto_goTypes = []interface{}{ + (*WagerProps)(nil), // 0: sge.legacy.bet.v1beta.WagerProps +} +var file_sge_legacy_bet_v1beta_wager_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_bet_v1beta_wager_proto_init() } +func file_sge_legacy_bet_v1beta_wager_proto_init() { + if File_sge_legacy_bet_v1beta_wager_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_bet_v1beta_wager_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WagerProps); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_bet_v1beta_wager_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_bet_v1beta_wager_proto_goTypes, + DependencyIndexes: file_sge_legacy_bet_v1beta_wager_proto_depIdxs, + MessageInfos: file_sge_legacy_bet_v1beta_wager_proto_msgTypes, + }.Build() + File_sge_legacy_bet_v1beta_wager_proto = out.File + file_sge_legacy_bet_v1beta_wager_proto_rawDesc = nil + file_sge_legacy_bet_v1beta_wager_proto_goTypes = nil + file_sge_legacy_bet_v1beta_wager_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/module/v1/module.pulsar.go b/api/sge/legacy/house/module/v1/module.pulsar.go new file mode 100644 index 00000000..e140d0d8 --- /dev/null +++ b/api/sge/legacy/house/module/v1/module.pulsar.go @@ -0,0 +1,655 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_module_v1_module_proto_init() + md_Module = File_sge_legacy_house_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.legacy.house.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.house.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.legacy.house.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.house.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.legacy.house.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.house.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.legacy.house.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.house.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.legacy.house.module.v1.Module is not mutable")) + case "sge.legacy.house.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.legacy.house.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.house.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.legacy.house.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.house.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the house module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_legacy_house_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1a, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x6d, 0x6f, 0x64, 0x75, + 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, + 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x69, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x12, 0x2c, 0x0a, 0x12, 0x66, 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, + 0x6f, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x66, + 0x65, 0x65, 0x43, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x1c, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, 0x13, 0xba, + 0xc0, 0x96, 0xda, 0x01, 0x0d, 0x0a, 0x0b, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x42, 0xfe, 0x01, 0x0a, 0x1e, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x6d, 0x6f, 0x64, 0x75, + 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x3b, + 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, 0x31, 0xa2, 0x02, 0x04, 0x53, 0x4c, 0x48, 0x4d, 0xaa, + 0x02, 0x1a, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x48, 0x6f, 0x75, + 0x73, 0x65, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x1a, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, + 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x26, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x4d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x3a, 0x3a, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, + 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_module_v1_module_proto_rawDescOnce sync.Once + file_sge_legacy_house_module_v1_module_proto_rawDescData = file_sge_legacy_house_module_v1_module_proto_rawDesc +) + +func file_sge_legacy_house_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_legacy_house_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_module_v1_module_proto_rawDescData) + }) + return file_sge_legacy_house_module_v1_module_proto_rawDescData +} + +var file_sge_legacy_house_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_house_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.legacy.house.module.v1.Module +} +var file_sge_legacy_house_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_module_v1_module_proto_init() } +func file_sge_legacy_house_module_v1_module_proto_init() { + if File_sge_legacy_house_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_house_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_legacy_house_module_v1_module_proto_msgTypes, + }.Build() + File_sge_legacy_house_module_v1_module_proto = out.File + file_sge_legacy_house_module_v1_module_proto_rawDesc = nil + file_sge_legacy_house_module_v1_module_proto_goTypes = nil + file_sge_legacy_house_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/authz.pulsar.go b/api/sge/legacy/house/v1beta/authz.pulsar.go new file mode 100644 index 00000000..13302837 --- /dev/null +++ b/api/sge/legacy/house/v1beta/authz.pulsar.go @@ -0,0 +1,1055 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_DepositAuthorization protoreflect.MessageDescriptor + fd_DepositAuthorization_spend_limit protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_authz_proto_init() + md_DepositAuthorization = File_sge_legacy_house_v1beta_authz_proto.Messages().ByName("DepositAuthorization") + fd_DepositAuthorization_spend_limit = md_DepositAuthorization.Fields().ByName("spend_limit") +} + +var _ protoreflect.Message = (*fastReflection_DepositAuthorization)(nil) + +type fastReflection_DepositAuthorization DepositAuthorization + +func (x *DepositAuthorization) ProtoReflect() protoreflect.Message { + return (*fastReflection_DepositAuthorization)(x) +} + +func (x *DepositAuthorization) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_authz_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_DepositAuthorization_messageType fastReflection_DepositAuthorization_messageType +var _ protoreflect.MessageType = fastReflection_DepositAuthorization_messageType{} + +type fastReflection_DepositAuthorization_messageType struct{} + +func (x fastReflection_DepositAuthorization_messageType) Zero() protoreflect.Message { + return (*fastReflection_DepositAuthorization)(nil) +} +func (x fastReflection_DepositAuthorization_messageType) New() protoreflect.Message { + return new(fastReflection_DepositAuthorization) +} +func (x fastReflection_DepositAuthorization_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_DepositAuthorization +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_DepositAuthorization) Descriptor() protoreflect.MessageDescriptor { + return md_DepositAuthorization +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_DepositAuthorization) Type() protoreflect.MessageType { + return _fastReflection_DepositAuthorization_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_DepositAuthorization) New() protoreflect.Message { + return new(fastReflection_DepositAuthorization) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_DepositAuthorization) Interface() protoreflect.ProtoMessage { + return (*DepositAuthorization)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_DepositAuthorization) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.SpendLimit != "" { + value := protoreflect.ValueOfString(x.SpendLimit) + if !f(fd_DepositAuthorization_spend_limit, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_DepositAuthorization) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositAuthorization.spend_limit": + return x.SpendLimit != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositAuthorization does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositAuthorization) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositAuthorization.spend_limit": + x.SpendLimit = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositAuthorization does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_DepositAuthorization) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.DepositAuthorization.spend_limit": + value := x.SpendLimit + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositAuthorization does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositAuthorization) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositAuthorization.spend_limit": + x.SpendLimit = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositAuthorization does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositAuthorization) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositAuthorization.spend_limit": + panic(fmt.Errorf("field spend_limit of message sge.legacy.house.v1beta.DepositAuthorization is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositAuthorization does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_DepositAuthorization) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositAuthorization.spend_limit": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositAuthorization does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_DepositAuthorization) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.DepositAuthorization", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_DepositAuthorization) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositAuthorization) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_DepositAuthorization) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_DepositAuthorization) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*DepositAuthorization) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.SpendLimit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*DepositAuthorization) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.SpendLimit) > 0 { + i -= len(x.SpendLimit) + copy(dAtA[i:], x.SpendLimit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SpendLimit))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*DepositAuthorization) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: DepositAuthorization: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: DepositAuthorization: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SpendLimit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SpendLimit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_WithdrawAuthorization protoreflect.MessageDescriptor + fd_WithdrawAuthorization_withdraw_limit protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_authz_proto_init() + md_WithdrawAuthorization = File_sge_legacy_house_v1beta_authz_proto.Messages().ByName("WithdrawAuthorization") + fd_WithdrawAuthorization_withdraw_limit = md_WithdrawAuthorization.Fields().ByName("withdraw_limit") +} + +var _ protoreflect.Message = (*fastReflection_WithdrawAuthorization)(nil) + +type fastReflection_WithdrawAuthorization WithdrawAuthorization + +func (x *WithdrawAuthorization) ProtoReflect() protoreflect.Message { + return (*fastReflection_WithdrawAuthorization)(x) +} + +func (x *WithdrawAuthorization) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_authz_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_WithdrawAuthorization_messageType fastReflection_WithdrawAuthorization_messageType +var _ protoreflect.MessageType = fastReflection_WithdrawAuthorization_messageType{} + +type fastReflection_WithdrawAuthorization_messageType struct{} + +func (x fastReflection_WithdrawAuthorization_messageType) Zero() protoreflect.Message { + return (*fastReflection_WithdrawAuthorization)(nil) +} +func (x fastReflection_WithdrawAuthorization_messageType) New() protoreflect.Message { + return new(fastReflection_WithdrawAuthorization) +} +func (x fastReflection_WithdrawAuthorization_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawAuthorization +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_WithdrawAuthorization) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawAuthorization +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_WithdrawAuthorization) Type() protoreflect.MessageType { + return _fastReflection_WithdrawAuthorization_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_WithdrawAuthorization) New() protoreflect.Message { + return new(fastReflection_WithdrawAuthorization) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_WithdrawAuthorization) Interface() protoreflect.ProtoMessage { + return (*WithdrawAuthorization)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_WithdrawAuthorization) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.WithdrawLimit != "" { + value := protoreflect.ValueOfString(x.WithdrawLimit) + if !f(fd_WithdrawAuthorization_withdraw_limit, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_WithdrawAuthorization) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawAuthorization.withdraw_limit": + return x.WithdrawLimit != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawAuthorization does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawAuthorization) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawAuthorization.withdraw_limit": + x.WithdrawLimit = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawAuthorization does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_WithdrawAuthorization) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.WithdrawAuthorization.withdraw_limit": + value := x.WithdrawLimit + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawAuthorization does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawAuthorization) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawAuthorization.withdraw_limit": + x.WithdrawLimit = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawAuthorization does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawAuthorization) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawAuthorization.withdraw_limit": + panic(fmt.Errorf("field withdraw_limit of message sge.legacy.house.v1beta.WithdrawAuthorization is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawAuthorization does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_WithdrawAuthorization) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawAuthorization.withdraw_limit": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawAuthorization does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_WithdrawAuthorization) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.WithdrawAuthorization", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_WithdrawAuthorization) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawAuthorization) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_WithdrawAuthorization) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_WithdrawAuthorization) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*WithdrawAuthorization) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.WithdrawLimit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*WithdrawAuthorization) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.WithdrawLimit) > 0 { + i -= len(x.WithdrawLimit) + copy(dAtA[i:], x.WithdrawLimit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.WithdrawLimit))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*WithdrawAuthorization) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawAuthorization: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawAuthorization: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WithdrawLimit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.WithdrawLimit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/authz.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// DepositAuthorization allows the grantee to spend up to spend_limit from +// the granter's account for deposit. +type DepositAuthorization struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + SpendLimit string `protobuf:"bytes,1,opt,name=spend_limit,json=spendLimit,proto3" json:"spend_limit,omitempty"` +} + +func (x *DepositAuthorization) Reset() { + *x = DepositAuthorization{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_authz_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DepositAuthorization) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DepositAuthorization) ProtoMessage() {} + +// Deprecated: Use DepositAuthorization.ProtoReflect.Descriptor instead. +func (*DepositAuthorization) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_authz_proto_rawDescGZIP(), []int{0} +} + +func (x *DepositAuthorization) GetSpendLimit() string { + if x != nil { + return x.SpendLimit + } + return "" +} + +// WithdrawAuthorization allows the grantee to withdraw up to withdraw_limit +// from the granter's account for deposit. +type WithdrawAuthorization struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + WithdrawLimit string `protobuf:"bytes,1,opt,name=withdraw_limit,json=withdrawLimit,proto3" json:"withdraw_limit,omitempty"` +} + +func (x *WithdrawAuthorization) Reset() { + *x = WithdrawAuthorization{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_authz_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WithdrawAuthorization) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WithdrawAuthorization) ProtoMessage() {} + +// Deprecated: Use WithdrawAuthorization.ProtoReflect.Descriptor instead. +func (*WithdrawAuthorization) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_authz_proto_rawDescGZIP(), []int{1} +} + +func (x *WithdrawAuthorization) GetWithdrawLimit() string { + if x != nil { + return x.WithdrawLimit + } + return "" +} + +var File_sge_legacy_house_v1beta_authz_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_authz_proto_rawDesc = []byte{ + 0x0a, 0x23, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x61, 0x75, 0x74, 0x68, 0x7a, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, + 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x56, 0x0a, 0x14, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x41, + 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3e, 0x0a, 0x0b, + 0x73, 0x70, 0x65, 0x6e, 0x64, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, + 0x52, 0x0a, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0x5d, 0x0a, 0x15, + 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x44, 0x0a, 0x0e, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, + 0x77, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, + 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0d, 0x77, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x42, 0xec, 0x01, 0x0a, 0x1b, + 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x41, 0x75, 0x74, + 0x68, 0x7a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, + 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x3b, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, + 0x53, 0x4c, 0x48, 0xaa, 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x17, + 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1a, + 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x48, 0x6f, 0x75, + 0x73, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_authz_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_authz_proto_rawDescData = file_sge_legacy_house_v1beta_authz_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_authz_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_authz_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_authz_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_authz_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_authz_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_authz_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_house_v1beta_authz_proto_goTypes = []interface{}{ + (*DepositAuthorization)(nil), // 0: sge.legacy.house.v1beta.DepositAuthorization + (*WithdrawAuthorization)(nil), // 1: sge.legacy.house.v1beta.WithdrawAuthorization +} +var file_sge_legacy_house_v1beta_authz_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_authz_proto_init() } +func file_sge_legacy_house_v1beta_authz_proto_init() { + if File_sge_legacy_house_v1beta_authz_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_authz_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*DepositAuthorization); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_authz_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WithdrawAuthorization); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_authz_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_house_v1beta_authz_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_authz_proto_depIdxs, + MessageInfos: file_sge_legacy_house_v1beta_authz_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_authz_proto = out.File + file_sge_legacy_house_v1beta_authz_proto_rawDesc = nil + file_sge_legacy_house_v1beta_authz_proto_goTypes = nil + file_sge_legacy_house_v1beta_authz_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/deposit.pulsar.go b/api/sge/legacy/house/v1beta/deposit.pulsar.go new file mode 100644 index 00000000..23a9c49b --- /dev/null +++ b/api/sge/legacy/house/v1beta/deposit.pulsar.go @@ -0,0 +1,1021 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Deposit protoreflect.MessageDescriptor + fd_Deposit_creator protoreflect.FieldDescriptor + fd_Deposit_depositor_address protoreflect.FieldDescriptor + fd_Deposit_market_uid protoreflect.FieldDescriptor + fd_Deposit_participation_index protoreflect.FieldDescriptor + fd_Deposit_amount protoreflect.FieldDescriptor + fd_Deposit_withdrawal_count protoreflect.FieldDescriptor + fd_Deposit_total_withdrawal_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_deposit_proto_init() + md_Deposit = File_sge_legacy_house_v1beta_deposit_proto.Messages().ByName("Deposit") + fd_Deposit_creator = md_Deposit.Fields().ByName("creator") + fd_Deposit_depositor_address = md_Deposit.Fields().ByName("depositor_address") + fd_Deposit_market_uid = md_Deposit.Fields().ByName("market_uid") + fd_Deposit_participation_index = md_Deposit.Fields().ByName("participation_index") + fd_Deposit_amount = md_Deposit.Fields().ByName("amount") + fd_Deposit_withdrawal_count = md_Deposit.Fields().ByName("withdrawal_count") + fd_Deposit_total_withdrawal_amount = md_Deposit.Fields().ByName("total_withdrawal_amount") +} + +var _ protoreflect.Message = (*fastReflection_Deposit)(nil) + +type fastReflection_Deposit Deposit + +func (x *Deposit) ProtoReflect() protoreflect.Message { + return (*fastReflection_Deposit)(x) +} + +func (x *Deposit) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_deposit_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Deposit_messageType fastReflection_Deposit_messageType +var _ protoreflect.MessageType = fastReflection_Deposit_messageType{} + +type fastReflection_Deposit_messageType struct{} + +func (x fastReflection_Deposit_messageType) Zero() protoreflect.Message { + return (*fastReflection_Deposit)(nil) +} +func (x fastReflection_Deposit_messageType) New() protoreflect.Message { + return new(fastReflection_Deposit) +} +func (x fastReflection_Deposit_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Deposit +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Deposit) Descriptor() protoreflect.MessageDescriptor { + return md_Deposit +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Deposit) Type() protoreflect.MessageType { + return _fastReflection_Deposit_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Deposit) New() protoreflect.Message { + return new(fastReflection_Deposit) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Deposit) Interface() protoreflect.ProtoMessage { + return (*Deposit)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Deposit) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_Deposit_creator, value) { + return + } + } + if x.DepositorAddress != "" { + value := protoreflect.ValueOfString(x.DepositorAddress) + if !f(fd_Deposit_depositor_address, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_Deposit_market_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_Deposit_participation_index, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_Deposit_amount, value) { + return + } + } + if x.WithdrawalCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.WithdrawalCount) + if !f(fd_Deposit_withdrawal_count, value) { + return + } + } + if x.TotalWithdrawalAmount != "" { + value := protoreflect.ValueOfString(x.TotalWithdrawalAmount) + if !f(fd_Deposit_total_withdrawal_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Deposit) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Deposit.creator": + return x.Creator != "" + case "sge.legacy.house.v1beta.Deposit.depositor_address": + return x.DepositorAddress != "" + case "sge.legacy.house.v1beta.Deposit.market_uid": + return x.MarketUid != "" + case "sge.legacy.house.v1beta.Deposit.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.house.v1beta.Deposit.amount": + return x.Amount != "" + case "sge.legacy.house.v1beta.Deposit.withdrawal_count": + return x.WithdrawalCount != uint64(0) + case "sge.legacy.house.v1beta.Deposit.total_withdrawal_amount": + return x.TotalWithdrawalAmount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Deposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Deposit does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Deposit) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Deposit.creator": + x.Creator = "" + case "sge.legacy.house.v1beta.Deposit.depositor_address": + x.DepositorAddress = "" + case "sge.legacy.house.v1beta.Deposit.market_uid": + x.MarketUid = "" + case "sge.legacy.house.v1beta.Deposit.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.house.v1beta.Deposit.amount": + x.Amount = "" + case "sge.legacy.house.v1beta.Deposit.withdrawal_count": + x.WithdrawalCount = uint64(0) + case "sge.legacy.house.v1beta.Deposit.total_withdrawal_amount": + x.TotalWithdrawalAmount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Deposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Deposit does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Deposit) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.Deposit.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Deposit.depositor_address": + value := x.DepositorAddress + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Deposit.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Deposit.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.house.v1beta.Deposit.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Deposit.withdrawal_count": + value := x.WithdrawalCount + return protoreflect.ValueOfUint64(value) + case "sge.legacy.house.v1beta.Deposit.total_withdrawal_amount": + value := x.TotalWithdrawalAmount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Deposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Deposit does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Deposit) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Deposit.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.house.v1beta.Deposit.depositor_address": + x.DepositorAddress = value.Interface().(string) + case "sge.legacy.house.v1beta.Deposit.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.house.v1beta.Deposit.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.house.v1beta.Deposit.amount": + x.Amount = value.Interface().(string) + case "sge.legacy.house.v1beta.Deposit.withdrawal_count": + x.WithdrawalCount = value.Uint() + case "sge.legacy.house.v1beta.Deposit.total_withdrawal_amount": + x.TotalWithdrawalAmount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Deposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Deposit does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Deposit) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Deposit.creator": + panic(fmt.Errorf("field creator of message sge.legacy.house.v1beta.Deposit is not mutable")) + case "sge.legacy.house.v1beta.Deposit.depositor_address": + panic(fmt.Errorf("field depositor_address of message sge.legacy.house.v1beta.Deposit is not mutable")) + case "sge.legacy.house.v1beta.Deposit.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.house.v1beta.Deposit is not mutable")) + case "sge.legacy.house.v1beta.Deposit.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.house.v1beta.Deposit is not mutable")) + case "sge.legacy.house.v1beta.Deposit.amount": + panic(fmt.Errorf("field amount of message sge.legacy.house.v1beta.Deposit is not mutable")) + case "sge.legacy.house.v1beta.Deposit.withdrawal_count": + panic(fmt.Errorf("field withdrawal_count of message sge.legacy.house.v1beta.Deposit is not mutable")) + case "sge.legacy.house.v1beta.Deposit.total_withdrawal_amount": + panic(fmt.Errorf("field total_withdrawal_amount of message sge.legacy.house.v1beta.Deposit is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Deposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Deposit does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Deposit) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Deposit.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Deposit.depositor_address": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Deposit.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Deposit.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.house.v1beta.Deposit.amount": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Deposit.withdrawal_count": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.house.v1beta.Deposit.total_withdrawal_amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Deposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Deposit does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Deposit) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.Deposit", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Deposit) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Deposit) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Deposit) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Deposit) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Deposit) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.DepositorAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.WithdrawalCount != 0 { + n += 1 + runtime.Sov(uint64(x.WithdrawalCount)) + } + l = len(x.TotalWithdrawalAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Deposit) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.TotalWithdrawalAmount) > 0 { + i -= len(x.TotalWithdrawalAmount) + copy(dAtA[i:], x.TotalWithdrawalAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.TotalWithdrawalAmount))) + i-- + dAtA[i] = 0x3a + } + if x.WithdrawalCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.WithdrawalCount)) + i-- + dAtA[i] = 0x30 + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x2a + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x20 + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x1a + } + if len(x.DepositorAddress) > 0 { + i -= len(x.DepositorAddress) + copy(dAtA[i:], x.DepositorAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.DepositorAddress))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Deposit) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Deposit: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Deposit: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DepositorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WithdrawalCount", wireType) + } + x.WithdrawalCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.WithdrawalCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TotalWithdrawalAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.TotalWithdrawalAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/deposit.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Deposit represents the deposit against a market held by an account. +type Deposit struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the bech32-encoded address of the depositor. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // creator is the bech32-encoded address of the depositor. + DepositorAddress string `protobuf:"bytes,2,opt,name=depositor_address,json=depositorAddress,proto3" json:"depositor_address,omitempty"` + // market_uid is the uid of market/order book against which deposit is being + // made. + MarketUid string `protobuf:"bytes,3,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // participation_index is the index corresponding to the order book + // participation + ParticipationIndex uint64 `protobuf:"varint,4,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // amount is the amount being deposited on an order book to be a house + Amount string `protobuf:"bytes,5,opt,name=amount,proto3" json:"amount,omitempty"` + // withdrawal_count is the total count of the withdrawals from an order book + WithdrawalCount uint64 `protobuf:"varint,6,opt,name=withdrawal_count,json=withdrawalCount,proto3" json:"withdrawal_count,omitempty"` + // total_withdrawal_amount is the total amount withdrawn from the liquidity + // provided + TotalWithdrawalAmount string `protobuf:"bytes,7,opt,name=total_withdrawal_amount,json=totalWithdrawalAmount,proto3" json:"total_withdrawal_amount,omitempty"` +} + +func (x *Deposit) Reset() { + *x = Deposit{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_deposit_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Deposit) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Deposit) ProtoMessage() {} + +// Deprecated: Use Deposit.ProtoReflect.Descriptor instead. +func (*Deposit) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_deposit_proto_rawDescGZIP(), []int{0} +} + +func (x *Deposit) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *Deposit) GetDepositorAddress() string { + if x != nil { + return x.DepositorAddress + } + return "" +} + +func (x *Deposit) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *Deposit) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *Deposit) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +func (x *Deposit) GetWithdrawalCount() uint64 { + if x != nil { + return x.WithdrawalCount + } + return 0 +} + +func (x *Deposit) GetTotalWithdrawalAmount() string { + if x != nil { + return x.TotalWithdrawalAmount + } + return "" +} + +var File_sge_legacy_house_v1beta_deposit_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_deposit_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, + 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x22, 0xba, 0x04, 0x0a, 0x07, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x2c, 0x0a, + 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x12, + 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, + 0x72, 0x22, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x61, 0x0a, 0x11, 0x64, + 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x34, 0xf2, 0xde, 0x1f, 0x18, 0x79, 0x61, 0x6d, 0x6c, + 0x3a, 0x22, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x22, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x10, 0x64, 0x65, + 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x3b, + 0x0a, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x42, 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x55, 0x49, + 0x44, 0xea, 0xde, 0x1f, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x52, + 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x4f, 0x0a, 0x13, 0x70, + 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, + 0x65, 0x78, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1e, 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, + 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x46, 0x0a, 0x06, + 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2e, 0xc8, 0xde, + 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, + 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x0d, 0x79, + 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x06, 0x61, 0x6d, + 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x41, 0x0a, 0x10, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, + 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x42, 0x16, + 0xf2, 0xde, 0x1f, 0x12, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, + 0x61, 0x77, 0x61, 0x6c, 0x73, 0x22, 0x52, 0x0f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, + 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x77, 0x0a, 0x17, 0x74, 0x6f, 0x74, 0x61, 0x6c, + 0x5f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x5f, 0x61, 0x6d, 0x6f, 0x75, + 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x3f, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, + 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, + 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x1e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, + 0x6c, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x15, 0x74, 0x6f, 0x74, 0x61, 0x6c, + 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, + 0x3a, 0x0c, 0x88, 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x42, 0xee, + 0x01, 0x0a, 0x1b, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, + 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, + 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x48, 0xaa, 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0xca, 0x02, 0x17, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, + 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x1a, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x3a, 0x3a, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_deposit_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_deposit_proto_rawDescData = file_sge_legacy_house_v1beta_deposit_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_deposit_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_deposit_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_deposit_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_deposit_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_deposit_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_deposit_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_house_v1beta_deposit_proto_goTypes = []interface{}{ + (*Deposit)(nil), // 0: sge.legacy.house.v1beta.Deposit +} +var file_sge_legacy_house_v1beta_deposit_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_deposit_proto_init() } +func file_sge_legacy_house_v1beta_deposit_proto_init() { + if File_sge_legacy_house_v1beta_deposit_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_deposit_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Deposit); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_deposit_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_house_v1beta_deposit_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_deposit_proto_depIdxs, + MessageInfos: file_sge_legacy_house_v1beta_deposit_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_deposit_proto = out.File + file_sge_legacy_house_v1beta_deposit_proto_rawDesc = nil + file_sge_legacy_house_v1beta_deposit_proto_goTypes = nil + file_sge_legacy_house_v1beta_deposit_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/genesis.pulsar.go b/api/sge/legacy/house/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..40986b0b --- /dev/null +++ b/api/sge/legacy/house/v1beta/genesis.pulsar.go @@ -0,0 +1,914 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_2_list)(nil) + +type _GenesisState_2_list struct { + list *[]*Deposit +} + +func (x *_GenesisState_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Deposit) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Deposit) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_2_list) AppendMutable() protoreflect.Value { + v := new(Deposit) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_2_list) NewElement() protoreflect.Value { + v := new(Deposit) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_3_list)(nil) + +type _GenesisState_3_list struct { + list *[]*Withdrawal +} + +func (x *_GenesisState_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Withdrawal) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Withdrawal) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_3_list) AppendMutable() protoreflect.Value { + v := new(Withdrawal) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_3_list) NewElement() protoreflect.Value { + v := new(Withdrawal) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor + fd_GenesisState_deposit_list protoreflect.FieldDescriptor + fd_GenesisState_withdrawal_list protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_genesis_proto_init() + md_GenesisState = File_sge_legacy_house_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") + fd_GenesisState_deposit_list = md_GenesisState.Fields().ByName("deposit_list") + fd_GenesisState_withdrawal_list = md_GenesisState.Fields().ByName("withdrawal_list") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } + if len(x.DepositList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_2_list{list: &x.DepositList}) + if !f(fd_GenesisState_deposit_list, value) { + return + } + } + if len(x.WithdrawalList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_3_list{list: &x.WithdrawalList}) + if !f(fd_GenesisState_withdrawal_list, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.GenesisState.params": + return x.Params != nil + case "sge.legacy.house.v1beta.GenesisState.deposit_list": + return len(x.DepositList) != 0 + case "sge.legacy.house.v1beta.GenesisState.withdrawal_list": + return len(x.WithdrawalList) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.GenesisState.params": + x.Params = nil + case "sge.legacy.house.v1beta.GenesisState.deposit_list": + x.DepositList = nil + case "sge.legacy.house.v1beta.GenesisState.withdrawal_list": + x.WithdrawalList = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.house.v1beta.GenesisState.deposit_list": + if len(x.DepositList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_2_list{}) + } + listValue := &_GenesisState_2_list{list: &x.DepositList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.house.v1beta.GenesisState.withdrawal_list": + if len(x.WithdrawalList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_3_list{}) + } + listValue := &_GenesisState_3_list{list: &x.WithdrawalList} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + case "sge.legacy.house.v1beta.GenesisState.deposit_list": + lv := value.List() + clv := lv.(*_GenesisState_2_list) + x.DepositList = *clv.list + case "sge.legacy.house.v1beta.GenesisState.withdrawal_list": + lv := value.List() + clv := lv.(*_GenesisState_3_list) + x.WithdrawalList = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.house.v1beta.GenesisState.deposit_list": + if x.DepositList == nil { + x.DepositList = []*Deposit{} + } + value := &_GenesisState_2_list{list: &x.DepositList} + return protoreflect.ValueOfList(value) + case "sge.legacy.house.v1beta.GenesisState.withdrawal_list": + if x.WithdrawalList == nil { + x.WithdrawalList = []*Withdrawal{} + } + value := &_GenesisState_3_list{list: &x.WithdrawalList} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.house.v1beta.GenesisState.deposit_list": + list := []*Deposit{} + return protoreflect.ValueOfList(&_GenesisState_2_list{list: &list}) + case "sge.legacy.house.v1beta.GenesisState.withdrawal_list": + list := []*Withdrawal{} + return protoreflect.ValueOfList(&_GenesisState_3_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.DepositList) > 0 { + for _, e := range x.DepositList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.WithdrawalList) > 0 { + for _, e := range x.WithdrawalList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.WithdrawalList) > 0 { + for iNdEx := len(x.WithdrawalList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.WithdrawalList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if len(x.DepositList) > 0 { + for iNdEx := len(x.DepositList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.DepositList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DepositList = append(x.DepositList, &Deposit{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.DepositList[len(x.DepositList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WithdrawalList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.WithdrawalList = append(x.WithdrawalList, &Withdrawal{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.WithdrawalList[len(x.WithdrawalList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the house module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params defines the parameters of the house module at genesis + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` + // deposit_list defines the deposits active at genesis. + DepositList []*Deposit `protobuf:"bytes,2,rep,name=deposit_list,json=depositList,proto3" json:"deposit_list,omitempty"` + // withdrawal_list defines the withdrawals active at genesis. + WithdrawalList []*Withdrawal `protobuf:"bytes,3,rep,name=withdrawal_list,json=withdrawalList,proto3" json:"withdrawal_list,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +func (x *GenesisState) GetDepositList() []*Deposit { + if x != nil { + return x.DepositList + } + return nil +} + +func (x *GenesisState) GetWithdrawalList() []*Withdrawal { + if x != nil { + return x.WithdrawalList + } + return nil +} + +var File_sge_legacy_house_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, + 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, + 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x24, 0x73, + 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x26, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x77, 0x69, 0x74, + 0x68, 0x64, 0x72, 0x61, 0x77, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xec, 0x01, 0x0a, 0x0c, + 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x3d, 0x0a, 0x06, + 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x49, 0x0a, 0x0c, 0x64, + 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x44, 0x65, 0x70, 0x6f, + 0x73, 0x69, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0b, 0x64, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x52, 0x0a, 0x0f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, + 0x61, 0x77, 0x61, 0x6c, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, + 0x61, 0x77, 0x61, 0x6c, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0e, 0x77, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x4c, 0x69, 0x73, 0x74, 0x42, 0xee, 0x01, 0x0a, 0x1b, 0x63, + 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, + 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, + 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x3b, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4c, 0x48, 0xaa, 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, + 0x17, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, + 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, 0x67, 0x65, 0x5c, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x1a, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x48, 0x6f, + 0x75, 0x73, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_genesis_proto_rawDescData = file_sge_legacy_house_v1beta_genesis_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_genesis_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_genesis_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_house_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.legacy.house.v1beta.GenesisState + (*Params)(nil), // 1: sge.legacy.house.v1beta.Params + (*Deposit)(nil), // 2: sge.legacy.house.v1beta.Deposit + (*Withdrawal)(nil), // 3: sge.legacy.house.v1beta.Withdrawal +} +var file_sge_legacy_house_v1beta_genesis_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.house.v1beta.GenesisState.params:type_name -> sge.legacy.house.v1beta.Params + 2, // 1: sge.legacy.house.v1beta.GenesisState.deposit_list:type_name -> sge.legacy.house.v1beta.Deposit + 3, // 2: sge.legacy.house.v1beta.GenesisState.withdrawal_list:type_name -> sge.legacy.house.v1beta.Withdrawal + 3, // [3:3] is the sub-list for method output_type + 3, // [3:3] is the sub-list for method input_type + 3, // [3:3] is the sub-list for extension type_name + 3, // [3:3] is the sub-list for extension extendee + 0, // [0:3] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_genesis_proto_init() } +func file_sge_legacy_house_v1beta_genesis_proto_init() { + if File_sge_legacy_house_v1beta_genesis_proto != nil { + return + } + file_sge_legacy_house_v1beta_deposit_proto_init() + file_sge_legacy_house_v1beta_params_proto_init() + file_sge_legacy_house_v1beta_withdraw_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_house_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_legacy_house_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_genesis_proto = out.File + file_sge_legacy_house_v1beta_genesis_proto_rawDesc = nil + file_sge_legacy_house_v1beta_genesis_proto_goTypes = nil + file_sge_legacy_house_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/params.pulsar.go b/api/sge/legacy/house/v1beta/params.pulsar.go new file mode 100644 index 00000000..3c799d07 --- /dev/null +++ b/api/sge/legacy/house/v1beta/params.pulsar.go @@ -0,0 +1,723 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Params protoreflect.MessageDescriptor + fd_Params_min_deposit protoreflect.FieldDescriptor + fd_Params_house_participation_fee protoreflect.FieldDescriptor + fd_Params_max_withdrawal_count protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_params_proto_init() + md_Params = File_sge_legacy_house_v1beta_params_proto.Messages().ByName("Params") + fd_Params_min_deposit = md_Params.Fields().ByName("min_deposit") + fd_Params_house_participation_fee = md_Params.Fields().ByName("house_participation_fee") + fd_Params_max_withdrawal_count = md_Params.Fields().ByName("max_withdrawal_count") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MinDeposit != "" { + value := protoreflect.ValueOfString(x.MinDeposit) + if !f(fd_Params_min_deposit, value) { + return + } + } + if x.HouseParticipationFee != "" { + value := protoreflect.ValueOfString(x.HouseParticipationFee) + if !f(fd_Params_house_participation_fee, value) { + return + } + } + if x.MaxWithdrawalCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.MaxWithdrawalCount) + if !f(fd_Params_max_withdrawal_count, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Params.min_deposit": + return x.MinDeposit != "" + case "sge.legacy.house.v1beta.Params.house_participation_fee": + return x.HouseParticipationFee != "" + case "sge.legacy.house.v1beta.Params.max_withdrawal_count": + return x.MaxWithdrawalCount != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Params.min_deposit": + x.MinDeposit = "" + case "sge.legacy.house.v1beta.Params.house_participation_fee": + x.HouseParticipationFee = "" + case "sge.legacy.house.v1beta.Params.max_withdrawal_count": + x.MaxWithdrawalCount = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.Params.min_deposit": + value := x.MinDeposit + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Params.house_participation_fee": + value := x.HouseParticipationFee + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Params.max_withdrawal_count": + value := x.MaxWithdrawalCount + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Params.min_deposit": + x.MinDeposit = value.Interface().(string) + case "sge.legacy.house.v1beta.Params.house_participation_fee": + x.HouseParticipationFee = value.Interface().(string) + case "sge.legacy.house.v1beta.Params.max_withdrawal_count": + x.MaxWithdrawalCount = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Params.min_deposit": + panic(fmt.Errorf("field min_deposit of message sge.legacy.house.v1beta.Params is not mutable")) + case "sge.legacy.house.v1beta.Params.house_participation_fee": + panic(fmt.Errorf("field house_participation_fee of message sge.legacy.house.v1beta.Params is not mutable")) + case "sge.legacy.house.v1beta.Params.max_withdrawal_count": + panic(fmt.Errorf("field max_withdrawal_count of message sge.legacy.house.v1beta.Params is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Params.min_deposit": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Params.house_participation_fee": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Params.max_withdrawal_count": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.MinDeposit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.HouseParticipationFee) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.MaxWithdrawalCount != 0 { + n += 1 + runtime.Sov(uint64(x.MaxWithdrawalCount)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.MaxWithdrawalCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.MaxWithdrawalCount)) + i-- + dAtA[i] = 0x18 + } + if len(x.HouseParticipationFee) > 0 { + i -= len(x.HouseParticipationFee) + copy(dAtA[i:], x.HouseParticipationFee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.HouseParticipationFee))) + i-- + dAtA[i] = 0x12 + } + if len(x.MinDeposit) > 0 { + i -= len(x.MinDeposit) + copy(dAtA[i:], x.MinDeposit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MinDeposit))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinDeposit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MinDeposit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field HouseParticipationFee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.HouseParticipationFee = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxWithdrawalCount", wireType) + } + x.MaxWithdrawalCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.MaxWithdrawalCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params define the parameters for the house module. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // min_deposit is the minimum acceptable deposit amount. + MinDeposit string `protobuf:"bytes,1,opt,name=min_deposit,json=minDeposit,proto3" json:"min_deposit,omitempty"` + // house_participation_fee is the % of the deposit to be paid for a house + // participation by the depositor. + HouseParticipationFee string `protobuf:"bytes,2,opt,name=house_participation_fee,json=houseParticipationFee,proto3" json:"house_participation_fee,omitempty"` + // max_withdrawal_count is the maximum number of withdrawals allowed + // per participation index. + MaxWithdrawalCount uint64 `protobuf:"varint,3,opt,name=max_withdrawal_count,json=maxWithdrawalCount,proto3" json:"max_withdrawal_count,omitempty"` +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +func (x *Params) GetMinDeposit() string { + if x != nil { + return x.MinDeposit + } + return "" +} + +func (x *Params) GetHouseParticipationFee() string { + if x != nil { + return x.HouseParticipationFee + } + return "" +} + +func (x *Params) GetMaxWithdrawalCount() uint64 { + if x != nil { + return x.MaxWithdrawalCount + } + return 0 +} + +var File_sge_legacy_house_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, + 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x94, 0x02, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x12, 0x54, 0x0a, 0x0b, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x33, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, + 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x12, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, 0x69, + 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x22, 0x52, 0x0a, 0x6d, 0x69, 0x6e, 0x44, + 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x5b, 0x0a, 0x17, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x5f, + 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x66, 0x65, + 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x23, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, + 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, + 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0x52, 0x15, 0x68, 0x6f, + 0x75, 0x73, 0x65, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x46, 0x65, 0x65, 0x12, 0x51, 0x0a, 0x14, 0x6d, 0x61, 0x78, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x64, + 0x72, 0x61, 0x77, 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x04, 0x42, 0x1f, 0xf2, 0xde, 0x1f, 0x1b, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, 0x61, 0x78, + 0x5f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x22, 0x52, 0x12, 0x6d, 0x61, 0x78, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, + 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xed, 0x01, 0x0a, + 0x1b, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x3b, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, + 0x02, 0x03, 0x53, 0x4c, 0x48, 0xaa, 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, + 0x02, 0x17, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, + 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, + 0x02, 0x1a, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x48, + 0x6f, 0x75, 0x73, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_params_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_params_proto_rawDescData = file_sge_legacy_house_v1beta_params_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_params_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_params_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_house_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.legacy.house.v1beta.Params +} +var file_sge_legacy_house_v1beta_params_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_params_proto_init() } +func file_sge_legacy_house_v1beta_params_proto_init() { + if File_sge_legacy_house_v1beta_params_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_house_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_legacy_house_v1beta_params_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_params_proto = out.File + file_sge_legacy_house_v1beta_params_proto_rawDesc = nil + file_sge_legacy_house_v1beta_params_proto_goTypes = nil + file_sge_legacy_house_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/query.pulsar.go b/api/sge/legacy/house/v1beta/query.pulsar.go new file mode 100644 index 00000000..ffe2ab4b --- /dev/null +++ b/api/sge/legacy/house/v1beta/query.pulsar.go @@ -0,0 +1,5813 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + v1beta1 "cosmossdk.io/api/cosmos/base/query/v1beta1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryDepositsRequest protoreflect.MessageDescriptor + fd_QueryDepositsRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryDepositsRequest = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryDepositsRequest") + fd_QueryDepositsRequest_pagination = md_QueryDepositsRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryDepositsRequest)(nil) + +type fastReflection_QueryDepositsRequest QueryDepositsRequest + +func (x *QueryDepositsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryDepositsRequest)(x) +} + +func (x *QueryDepositsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryDepositsRequest_messageType fastReflection_QueryDepositsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryDepositsRequest_messageType{} + +type fastReflection_QueryDepositsRequest_messageType struct{} + +func (x fastReflection_QueryDepositsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryDepositsRequest)(nil) +} +func (x fastReflection_QueryDepositsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryDepositsRequest) +} +func (x fastReflection_QueryDepositsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryDepositsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryDepositsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryDepositsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryDepositsRequest) New() protoreflect.Message { + return new(fastReflection_QueryDepositsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryDepositsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryDepositsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryDepositsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryDepositsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryDepositsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryDepositsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryDepositsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryDepositsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryDepositsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryDepositsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryDepositsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryDepositsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryDepositsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryDepositsResponse_1_list)(nil) + +type _QueryDepositsResponse_1_list struct { + list *[]*Deposit +} + +func (x *_QueryDepositsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryDepositsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryDepositsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Deposit) + (*x.list)[i] = concreteValue +} + +func (x *_QueryDepositsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Deposit) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryDepositsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Deposit) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryDepositsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryDepositsResponse_1_list) NewElement() protoreflect.Value { + v := new(Deposit) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryDepositsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryDepositsResponse protoreflect.MessageDescriptor + fd_QueryDepositsResponse_deposits protoreflect.FieldDescriptor + fd_QueryDepositsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryDepositsResponse = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryDepositsResponse") + fd_QueryDepositsResponse_deposits = md_QueryDepositsResponse.Fields().ByName("deposits") + fd_QueryDepositsResponse_pagination = md_QueryDepositsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryDepositsResponse)(nil) + +type fastReflection_QueryDepositsResponse QueryDepositsResponse + +func (x *QueryDepositsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryDepositsResponse)(x) +} + +func (x *QueryDepositsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryDepositsResponse_messageType fastReflection_QueryDepositsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryDepositsResponse_messageType{} + +type fastReflection_QueryDepositsResponse_messageType struct{} + +func (x fastReflection_QueryDepositsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryDepositsResponse)(nil) +} +func (x fastReflection_QueryDepositsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryDepositsResponse) +} +func (x fastReflection_QueryDepositsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryDepositsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryDepositsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryDepositsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryDepositsResponse) New() protoreflect.Message { + return new(fastReflection_QueryDepositsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryDepositsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryDepositsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryDepositsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Deposits) != 0 { + value := protoreflect.ValueOfList(&_QueryDepositsResponse_1_list{list: &x.Deposits}) + if !f(fd_QueryDepositsResponse_deposits, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryDepositsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryDepositsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsResponse.deposits": + return len(x.Deposits) != 0 + case "sge.legacy.house.v1beta.QueryDepositsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsResponse.deposits": + x.Deposits = nil + case "sge.legacy.house.v1beta.QueryDepositsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryDepositsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsResponse.deposits": + if len(x.Deposits) == 0 { + return protoreflect.ValueOfList(&_QueryDepositsResponse_1_list{}) + } + listValue := &_QueryDepositsResponse_1_list{list: &x.Deposits} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.house.v1beta.QueryDepositsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsResponse.deposits": + lv := value.List() + clv := lv.(*_QueryDepositsResponse_1_list) + x.Deposits = *clv.list + case "sge.legacy.house.v1beta.QueryDepositsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsResponse.deposits": + if x.Deposits == nil { + x.Deposits = []*Deposit{} + } + value := &_QueryDepositsResponse_1_list{list: &x.Deposits} + return protoreflect.ValueOfList(value) + case "sge.legacy.house.v1beta.QueryDepositsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryDepositsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsResponse.deposits": + list := []*Deposit{} + return protoreflect.ValueOfList(&_QueryDepositsResponse_1_list{list: &list}) + case "sge.legacy.house.v1beta.QueryDepositsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryDepositsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryDepositsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryDepositsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryDepositsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryDepositsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryDepositsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Deposits) > 0 { + for _, e := range x.Deposits { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Deposits) > 0 { + for iNdEx := len(x.Deposits) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Deposits[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Deposits", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Deposits = append(x.Deposits, &Deposit{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Deposits[len(x.Deposits)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryDepositsByAccountRequest protoreflect.MessageDescriptor + fd_QueryDepositsByAccountRequest_address protoreflect.FieldDescriptor + fd_QueryDepositsByAccountRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryDepositsByAccountRequest = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryDepositsByAccountRequest") + fd_QueryDepositsByAccountRequest_address = md_QueryDepositsByAccountRequest.Fields().ByName("address") + fd_QueryDepositsByAccountRequest_pagination = md_QueryDepositsByAccountRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryDepositsByAccountRequest)(nil) + +type fastReflection_QueryDepositsByAccountRequest QueryDepositsByAccountRequest + +func (x *QueryDepositsByAccountRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryDepositsByAccountRequest)(x) +} + +func (x *QueryDepositsByAccountRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryDepositsByAccountRequest_messageType fastReflection_QueryDepositsByAccountRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryDepositsByAccountRequest_messageType{} + +type fastReflection_QueryDepositsByAccountRequest_messageType struct{} + +func (x fastReflection_QueryDepositsByAccountRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryDepositsByAccountRequest)(nil) +} +func (x fastReflection_QueryDepositsByAccountRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryDepositsByAccountRequest) +} +func (x fastReflection_QueryDepositsByAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsByAccountRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryDepositsByAccountRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsByAccountRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryDepositsByAccountRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryDepositsByAccountRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryDepositsByAccountRequest) New() protoreflect.Message { + return new(fastReflection_QueryDepositsByAccountRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryDepositsByAccountRequest) Interface() protoreflect.ProtoMessage { + return (*QueryDepositsByAccountRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryDepositsByAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QueryDepositsByAccountRequest_address, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryDepositsByAccountRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryDepositsByAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.address": + return x.Address != "" + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.address": + x.Address = "" + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryDepositsByAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.address": + x.Address = value.Interface().(string) + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.address": + panic(fmt.Errorf("field address of message sge.legacy.house.v1beta.QueryDepositsByAccountRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryDepositsByAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.address": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.QueryDepositsByAccountRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryDepositsByAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryDepositsByAccountRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryDepositsByAccountRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryDepositsByAccountRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryDepositsByAccountRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryDepositsByAccountRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsByAccountRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsByAccountRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsByAccountRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsByAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryDepositsByAccountResponse_1_list)(nil) + +type _QueryDepositsByAccountResponse_1_list struct { + list *[]*Deposit +} + +func (x *_QueryDepositsByAccountResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryDepositsByAccountResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryDepositsByAccountResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Deposit) + (*x.list)[i] = concreteValue +} + +func (x *_QueryDepositsByAccountResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Deposit) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryDepositsByAccountResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Deposit) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryDepositsByAccountResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryDepositsByAccountResponse_1_list) NewElement() protoreflect.Value { + v := new(Deposit) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryDepositsByAccountResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryDepositsByAccountResponse protoreflect.MessageDescriptor + fd_QueryDepositsByAccountResponse_deposits protoreflect.FieldDescriptor + fd_QueryDepositsByAccountResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryDepositsByAccountResponse = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryDepositsByAccountResponse") + fd_QueryDepositsByAccountResponse_deposits = md_QueryDepositsByAccountResponse.Fields().ByName("deposits") + fd_QueryDepositsByAccountResponse_pagination = md_QueryDepositsByAccountResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryDepositsByAccountResponse)(nil) + +type fastReflection_QueryDepositsByAccountResponse QueryDepositsByAccountResponse + +func (x *QueryDepositsByAccountResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryDepositsByAccountResponse)(x) +} + +func (x *QueryDepositsByAccountResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryDepositsByAccountResponse_messageType fastReflection_QueryDepositsByAccountResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryDepositsByAccountResponse_messageType{} + +type fastReflection_QueryDepositsByAccountResponse_messageType struct{} + +func (x fastReflection_QueryDepositsByAccountResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryDepositsByAccountResponse)(nil) +} +func (x fastReflection_QueryDepositsByAccountResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryDepositsByAccountResponse) +} +func (x fastReflection_QueryDepositsByAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsByAccountResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryDepositsByAccountResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryDepositsByAccountResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryDepositsByAccountResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryDepositsByAccountResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryDepositsByAccountResponse) New() protoreflect.Message { + return new(fastReflection_QueryDepositsByAccountResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryDepositsByAccountResponse) Interface() protoreflect.ProtoMessage { + return (*QueryDepositsByAccountResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryDepositsByAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Deposits) != 0 { + value := protoreflect.ValueOfList(&_QueryDepositsByAccountResponse_1_list{list: &x.Deposits}) + if !f(fd_QueryDepositsByAccountResponse_deposits, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryDepositsByAccountResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryDepositsByAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.deposits": + return len(x.Deposits) != 0 + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.deposits": + x.Deposits = nil + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryDepositsByAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.deposits": + if len(x.Deposits) == 0 { + return protoreflect.ValueOfList(&_QueryDepositsByAccountResponse_1_list{}) + } + listValue := &_QueryDepositsByAccountResponse_1_list{list: &x.Deposits} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.deposits": + lv := value.List() + clv := lv.(*_QueryDepositsByAccountResponse_1_list) + x.Deposits = *clv.list + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.deposits": + if x.Deposits == nil { + x.Deposits = []*Deposit{} + } + value := &_QueryDepositsByAccountResponse_1_list{list: &x.Deposits} + return protoreflect.ValueOfList(value) + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryDepositsByAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.deposits": + list := []*Deposit{} + return protoreflect.ValueOfList(&_QueryDepositsByAccountResponse_1_list{list: &list}) + case "sge.legacy.house.v1beta.QueryDepositsByAccountResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryDepositsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryDepositsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryDepositsByAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryDepositsByAccountResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryDepositsByAccountResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryDepositsByAccountResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryDepositsByAccountResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryDepositsByAccountResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryDepositsByAccountResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Deposits) > 0 { + for _, e := range x.Deposits { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsByAccountResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Deposits) > 0 { + for iNdEx := len(x.Deposits) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Deposits[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryDepositsByAccountResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsByAccountResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryDepositsByAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Deposits", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Deposits = append(x.Deposits, &Deposit{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Deposits[len(x.Deposits)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryWithdrawalsByAccountRequest protoreflect.MessageDescriptor + fd_QueryWithdrawalsByAccountRequest_address protoreflect.FieldDescriptor + fd_QueryWithdrawalsByAccountRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryWithdrawalsByAccountRequest = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryWithdrawalsByAccountRequest") + fd_QueryWithdrawalsByAccountRequest_address = md_QueryWithdrawalsByAccountRequest.Fields().ByName("address") + fd_QueryWithdrawalsByAccountRequest_pagination = md_QueryWithdrawalsByAccountRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryWithdrawalsByAccountRequest)(nil) + +type fastReflection_QueryWithdrawalsByAccountRequest QueryWithdrawalsByAccountRequest + +func (x *QueryWithdrawalsByAccountRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryWithdrawalsByAccountRequest)(x) +} + +func (x *QueryWithdrawalsByAccountRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryWithdrawalsByAccountRequest_messageType fastReflection_QueryWithdrawalsByAccountRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryWithdrawalsByAccountRequest_messageType{} + +type fastReflection_QueryWithdrawalsByAccountRequest_messageType struct{} + +func (x fastReflection_QueryWithdrawalsByAccountRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryWithdrawalsByAccountRequest)(nil) +} +func (x fastReflection_QueryWithdrawalsByAccountRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalsByAccountRequest) +} +func (x fastReflection_QueryWithdrawalsByAccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalsByAccountRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalsByAccountRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryWithdrawalsByAccountRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalsByAccountRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Interface() protoreflect.ProtoMessage { + return (*QueryWithdrawalsByAccountRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QueryWithdrawalsByAccountRequest_address, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryWithdrawalsByAccountRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.address": + return x.Address != "" + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.address": + x.Address = "" + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.address": + x.Address = value.Interface().(string) + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.address": + panic(fmt.Errorf("field address of message sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.address": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryWithdrawalsByAccountRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryWithdrawalsByAccountRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalsByAccountRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalsByAccountRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalsByAccountRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalsByAccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryWithdrawalsByAccountResponse_1_list)(nil) + +type _QueryWithdrawalsByAccountResponse_1_list struct { + list *[]*Withdrawal +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Withdrawal) + (*x.list)[i] = concreteValue +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Withdrawal) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Withdrawal) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) NewElement() protoreflect.Value { + v := new(Withdrawal) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryWithdrawalsByAccountResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryWithdrawalsByAccountResponse protoreflect.MessageDescriptor + fd_QueryWithdrawalsByAccountResponse_withdrawals protoreflect.FieldDescriptor + fd_QueryWithdrawalsByAccountResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryWithdrawalsByAccountResponse = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryWithdrawalsByAccountResponse") + fd_QueryWithdrawalsByAccountResponse_withdrawals = md_QueryWithdrawalsByAccountResponse.Fields().ByName("withdrawals") + fd_QueryWithdrawalsByAccountResponse_pagination = md_QueryWithdrawalsByAccountResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryWithdrawalsByAccountResponse)(nil) + +type fastReflection_QueryWithdrawalsByAccountResponse QueryWithdrawalsByAccountResponse + +func (x *QueryWithdrawalsByAccountResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryWithdrawalsByAccountResponse)(x) +} + +func (x *QueryWithdrawalsByAccountResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryWithdrawalsByAccountResponse_messageType fastReflection_QueryWithdrawalsByAccountResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryWithdrawalsByAccountResponse_messageType{} + +type fastReflection_QueryWithdrawalsByAccountResponse_messageType struct{} + +func (x fastReflection_QueryWithdrawalsByAccountResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryWithdrawalsByAccountResponse)(nil) +} +func (x fastReflection_QueryWithdrawalsByAccountResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalsByAccountResponse) +} +func (x fastReflection_QueryWithdrawalsByAccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalsByAccountResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalsByAccountResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryWithdrawalsByAccountResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalsByAccountResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Interface() protoreflect.ProtoMessage { + return (*QueryWithdrawalsByAccountResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Withdrawals) != 0 { + value := protoreflect.ValueOfList(&_QueryWithdrawalsByAccountResponse_1_list{list: &x.Withdrawals}) + if !f(fd_QueryWithdrawalsByAccountResponse_withdrawals, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryWithdrawalsByAccountResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.withdrawals": + return len(x.Withdrawals) != 0 + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.withdrawals": + x.Withdrawals = nil + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.withdrawals": + if len(x.Withdrawals) == 0 { + return protoreflect.ValueOfList(&_QueryWithdrawalsByAccountResponse_1_list{}) + } + listValue := &_QueryWithdrawalsByAccountResponse_1_list{list: &x.Withdrawals} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.withdrawals": + lv := value.List() + clv := lv.(*_QueryWithdrawalsByAccountResponse_1_list) + x.Withdrawals = *clv.list + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.withdrawals": + if x.Withdrawals == nil { + x.Withdrawals = []*Withdrawal{} + } + value := &_QueryWithdrawalsByAccountResponse_1_list{list: &x.Withdrawals} + return protoreflect.ValueOfList(value) + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.withdrawals": + list := []*Withdrawal{} + return protoreflect.ValueOfList(&_QueryWithdrawalsByAccountResponse_1_list{list: &list}) + case "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryWithdrawalsByAccountResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryWithdrawalsByAccountResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Withdrawals) > 0 { + for _, e := range x.Withdrawals { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalsByAccountResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Withdrawals) > 0 { + for iNdEx := len(x.Withdrawals) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Withdrawals[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalsByAccountResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalsByAccountResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalsByAccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Withdrawals", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Withdrawals = append(x.Withdrawals, &Withdrawal{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Withdrawals[len(x.Withdrawals)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryWithdrawalRequest protoreflect.MessageDescriptor + fd_QueryWithdrawalRequest_depositor_address protoreflect.FieldDescriptor + fd_QueryWithdrawalRequest_market_uid protoreflect.FieldDescriptor + fd_QueryWithdrawalRequest_participation_index protoreflect.FieldDescriptor + fd_QueryWithdrawalRequest_id protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryWithdrawalRequest = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryWithdrawalRequest") + fd_QueryWithdrawalRequest_depositor_address = md_QueryWithdrawalRequest.Fields().ByName("depositor_address") + fd_QueryWithdrawalRequest_market_uid = md_QueryWithdrawalRequest.Fields().ByName("market_uid") + fd_QueryWithdrawalRequest_participation_index = md_QueryWithdrawalRequest.Fields().ByName("participation_index") + fd_QueryWithdrawalRequest_id = md_QueryWithdrawalRequest.Fields().ByName("id") +} + +var _ protoreflect.Message = (*fastReflection_QueryWithdrawalRequest)(nil) + +type fastReflection_QueryWithdrawalRequest QueryWithdrawalRequest + +func (x *QueryWithdrawalRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryWithdrawalRequest)(x) +} + +func (x *QueryWithdrawalRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryWithdrawalRequest_messageType fastReflection_QueryWithdrawalRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryWithdrawalRequest_messageType{} + +type fastReflection_QueryWithdrawalRequest_messageType struct{} + +func (x fastReflection_QueryWithdrawalRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryWithdrawalRequest)(nil) +} +func (x fastReflection_QueryWithdrawalRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalRequest) +} +func (x fastReflection_QueryWithdrawalRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryWithdrawalRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryWithdrawalRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryWithdrawalRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryWithdrawalRequest) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryWithdrawalRequest) Interface() protoreflect.ProtoMessage { + return (*QueryWithdrawalRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryWithdrawalRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.DepositorAddress != "" { + value := protoreflect.ValueOfString(x.DepositorAddress) + if !f(fd_QueryWithdrawalRequest_depositor_address, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_QueryWithdrawalRequest_market_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_QueryWithdrawalRequest_participation_index, value) { + return + } + } + if x.Id != uint64(0) { + value := protoreflect.ValueOfUint64(x.Id) + if !f(fd_QueryWithdrawalRequest_id, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryWithdrawalRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.depositor_address": + return x.DepositorAddress != "" + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.market_uid": + return x.MarketUid != "" + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.id": + return x.Id != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.depositor_address": + x.DepositorAddress = "" + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.market_uid": + x.MarketUid = "" + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.id": + x.Id = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryWithdrawalRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.depositor_address": + value := x.DepositorAddress + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.id": + value := x.Id + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.depositor_address": + x.DepositorAddress = value.Interface().(string) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.id": + x.Id = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.depositor_address": + panic(fmt.Errorf("field depositor_address of message sge.legacy.house.v1beta.QueryWithdrawalRequest is not mutable")) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.house.v1beta.QueryWithdrawalRequest is not mutable")) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.house.v1beta.QueryWithdrawalRequest is not mutable")) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.id": + panic(fmt.Errorf("field id of message sge.legacy.house.v1beta.QueryWithdrawalRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryWithdrawalRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.depositor_address": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.house.v1beta.QueryWithdrawalRequest.id": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalRequest")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryWithdrawalRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryWithdrawalRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryWithdrawalRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryWithdrawalRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryWithdrawalRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryWithdrawalRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.DepositorAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.Id != 0 { + n += 1 + runtime.Sov(uint64(x.Id)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Id != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Id)) + i-- + dAtA[i] = 0x20 + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x18 + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.DepositorAddress) > 0 { + i -= len(x.DepositorAddress) + copy(dAtA[i:], x.DepositorAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.DepositorAddress))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DepositorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + x.Id = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Id |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryWithdrawalResponse protoreflect.MessageDescriptor + fd_QueryWithdrawalResponse_withdrawal protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_query_proto_init() + md_QueryWithdrawalResponse = File_sge_legacy_house_v1beta_query_proto.Messages().ByName("QueryWithdrawalResponse") + fd_QueryWithdrawalResponse_withdrawal = md_QueryWithdrawalResponse.Fields().ByName("withdrawal") +} + +var _ protoreflect.Message = (*fastReflection_QueryWithdrawalResponse)(nil) + +type fastReflection_QueryWithdrawalResponse QueryWithdrawalResponse + +func (x *QueryWithdrawalResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryWithdrawalResponse)(x) +} + +func (x *QueryWithdrawalResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryWithdrawalResponse_messageType fastReflection_QueryWithdrawalResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryWithdrawalResponse_messageType{} + +type fastReflection_QueryWithdrawalResponse_messageType struct{} + +func (x fastReflection_QueryWithdrawalResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryWithdrawalResponse)(nil) +} +func (x fastReflection_QueryWithdrawalResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalResponse) +} +func (x fastReflection_QueryWithdrawalResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryWithdrawalResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryWithdrawalResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryWithdrawalResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryWithdrawalResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryWithdrawalResponse) New() protoreflect.Message { + return new(fastReflection_QueryWithdrawalResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryWithdrawalResponse) Interface() protoreflect.ProtoMessage { + return (*QueryWithdrawalResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryWithdrawalResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Withdrawal != nil { + value := protoreflect.ValueOfMessage(x.Withdrawal.ProtoReflect()) + if !f(fd_QueryWithdrawalResponse_withdrawal, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryWithdrawalResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalResponse.withdrawal": + return x.Withdrawal != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalResponse.withdrawal": + x.Withdrawal = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryWithdrawalResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalResponse.withdrawal": + value := x.Withdrawal + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalResponse.withdrawal": + x.Withdrawal = value.Message().Interface().(*Withdrawal) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalResponse.withdrawal": + if x.Withdrawal == nil { + x.Withdrawal = new(Withdrawal) + } + return protoreflect.ValueOfMessage(x.Withdrawal.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryWithdrawalResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.QueryWithdrawalResponse.withdrawal": + m := new(Withdrawal) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.QueryWithdrawalResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.QueryWithdrawalResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryWithdrawalResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.QueryWithdrawalResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryWithdrawalResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryWithdrawalResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryWithdrawalResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryWithdrawalResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryWithdrawalResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Withdrawal != nil { + l = options.Size(x.Withdrawal) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Withdrawal != nil { + encoded, err := options.Marshal(x.Withdrawal) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryWithdrawalResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryWithdrawalResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Withdrawal", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Withdrawal == nil { + x.Withdrawal = &Withdrawal{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Withdrawal); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is the request type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is the response type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params holds all the parameters of this module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QueryDepositsRequest is request type for Query/Deposits RPC method. +type QueryDepositsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // pagination defines an optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryDepositsRequest) Reset() { + *x = QueryDepositsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryDepositsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryDepositsRequest) ProtoMessage() {} + +// Deprecated: Use QueryDepositsRequest.ProtoReflect.Descriptor instead. +func (*QueryDepositsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +func (x *QueryDepositsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryDepositsResponse is response type for the Query/Deposits RPC method +type QueryDepositsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // deposits is the list of deposits returned for the request. + Deposits []*Deposit `protobuf:"bytes,1,rep,name=deposits,proto3" json:"deposits,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryDepositsResponse) Reset() { + *x = QueryDepositsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryDepositsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryDepositsResponse) ProtoMessage() {} + +// Deprecated: Use QueryDepositsResponse.ProtoReflect.Descriptor instead. +func (*QueryDepositsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QueryDepositsResponse) GetDeposits() []*Deposit { + if x != nil { + return x.Deposits + } + return nil +} + +func (x *QueryDepositsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryDepositsByAccountRequest is request type for Query/DepositsByAccount RPC +// method. +type QueryDepositsByAccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // address defines the address of depositor/account for which deposits are + // queried. + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // pagination defines an optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryDepositsByAccountRequest) Reset() { + *x = QueryDepositsByAccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryDepositsByAccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryDepositsByAccountRequest) ProtoMessage() {} + +// Deprecated: Use QueryDepositsByAccountRequest.ProtoReflect.Descriptor instead. +func (*QueryDepositsByAccountRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{4} +} + +func (x *QueryDepositsByAccountRequest) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *QueryDepositsByAccountRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryDepositsByAccountResponse is response type for the +// Query/DepositsByAccount RPC method +type QueryDepositsByAccountResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // deposits contains all the queried deposits. + Deposits []*Deposit `protobuf:"bytes,1,rep,name=deposits,proto3" json:"deposits,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryDepositsByAccountResponse) Reset() { + *x = QueryDepositsByAccountResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryDepositsByAccountResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryDepositsByAccountResponse) ProtoMessage() {} + +// Deprecated: Use QueryDepositsByAccountResponse.ProtoReflect.Descriptor instead. +func (*QueryDepositsByAccountResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{5} +} + +func (x *QueryDepositsByAccountResponse) GetDeposits() []*Deposit { + if x != nil { + return x.Deposits + } + return nil +} + +func (x *QueryDepositsByAccountResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryDepositorWithdrawalsRequest is request type for +// Query/WithdrawalsByAccount RPC method. +type QueryWithdrawalsByAccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // address defines the address of depositor/account for which withdrawals are + // queried. + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // pagination defines an optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryWithdrawalsByAccountRequest) Reset() { + *x = QueryWithdrawalsByAccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryWithdrawalsByAccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryWithdrawalsByAccountRequest) ProtoMessage() {} + +// Deprecated: Use QueryWithdrawalsByAccountRequest.ProtoReflect.Descriptor instead. +func (*QueryWithdrawalsByAccountRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{6} +} + +func (x *QueryWithdrawalsByAccountRequest) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *QueryWithdrawalsByAccountRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryWithdrawalsByAccountResponse is response type for the +// Query/WithdrawalsByAccount RPC method +type QueryWithdrawalsByAccountResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // withdrawals contains all the queried withdrawals. + Withdrawals []*Withdrawal `protobuf:"bytes,1,rep,name=withdrawals,proto3" json:"withdrawals,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryWithdrawalsByAccountResponse) Reset() { + *x = QueryWithdrawalsByAccountResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryWithdrawalsByAccountResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryWithdrawalsByAccountResponse) ProtoMessage() {} + +// Deprecated: Use QueryWithdrawalsByAccountResponse.ProtoReflect.Descriptor instead. +func (*QueryWithdrawalsByAccountResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{7} +} + +func (x *QueryWithdrawalsByAccountResponse) GetWithdrawals() []*Withdrawal { + if x != nil { + return x.Withdrawals + } + return nil +} + +func (x *QueryWithdrawalsByAccountResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryWithdrawalRequest is the request type for the Query/Withdrawal RPC +// method. Query/Withdrawal RPC method. +type QueryWithdrawalRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + DepositorAddress string `protobuf:"bytes,1,opt,name=depositor_address,json=depositorAddress,proto3" json:"depositor_address,omitempty"` + MarketUid string `protobuf:"bytes,2,opt,name=market_uid,json=marketUid,proto3" json:"market_uid,omitempty"` + // participation_index is the index corresponding to the order book + // participation + ParticipationIndex uint64 `protobuf:"varint,3,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // id is the sequential id of the withdrawal + Id uint64 `protobuf:"varint,4,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *QueryWithdrawalRequest) Reset() { + *x = QueryWithdrawalRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryWithdrawalRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryWithdrawalRequest) ProtoMessage() {} + +// Deprecated: Use QueryWithdrawalRequest.ProtoReflect.Descriptor instead. +func (*QueryWithdrawalRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{8} +} + +func (x *QueryWithdrawalRequest) GetDepositorAddress() string { + if x != nil { + return x.DepositorAddress + } + return "" +} + +func (x *QueryWithdrawalRequest) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *QueryWithdrawalRequest) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *QueryWithdrawalRequest) GetId() uint64 { + if x != nil { + return x.Id + } + return 0 +} + +// QueryWithdrawalResponse is the response type for the Query/Withdrawal RPC +// method. Query/Withdrawal RPC method. +type QueryWithdrawalResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // withdrawal holds all the withdrawal properties. + Withdrawal *Withdrawal `protobuf:"bytes,1,opt,name=withdrawal,proto3" json:"withdrawal,omitempty"` +} + +func (x *QueryWithdrawalResponse) Reset() { + *x = QueryWithdrawalResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_query_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryWithdrawalResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryWithdrawalResponse) ProtoMessage() {} + +// Deprecated: Use QueryWithdrawalResponse.ProtoReflect.Descriptor instead. +func (*QueryWithdrawalResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_query_proto_rawDescGZIP(), []int{9} +} + +func (x *QueryWithdrawalResponse) GetWithdrawal() *Withdrawal { + if x != nil { + return x.Withdrawal + } + return nil +} + +var File_sge_legacy_house_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x23, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x2a, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, 0x71, 0x75, 0x65, 0x72, + 0x79, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, + 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x26, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, + 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x14, + 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x22, 0x54, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3d, 0x0a, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x5e, 0x0a, 0x14, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa4, 0x01, 0x0a, 0x15, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x08, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x08, + 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x22, 0x81, 0x01, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x46, 0x0a, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, + 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, + 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xad, 0x01, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, + 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x08, 0x64, 0x65, 0x70, 0x6f, + 0x73, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x08, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x12, 0x47, 0x0a, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, + 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9e, 0x01, 0x0a, 0x20, 0x51, 0x75, 0x65, 0x72, 0x79, 0x57, + 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, + 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, + 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x46, + 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, + 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, + 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb9, 0x01, 0x0a, 0x21, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4b, 0x0a, 0x0b, + 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0b, 0x77, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, + 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, + 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x22, 0xbf, 0x01, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x45, 0x0a, + 0x11, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, + 0x6e, 0x67, 0x52, 0x10, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, + 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x55, 0x69, 0x64, 0x12, 0x2f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, + 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x6e, 0x64, 0x65, 0x78, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, + 0x52, 0x02, 0x69, 0x64, 0x22, 0x64, 0x0a, 0x17, 0x51, 0x75, 0x65, 0x72, 0x79, 0x57, 0x69, 0x74, + 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x49, 0x0a, 0x0a, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x57, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0a, + 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x32, 0xbf, 0x06, 0x0a, 0x05, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x12, 0x7e, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x2b, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, + 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x19, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x13, 0x12, 0x11, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x70, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x12, 0x86, 0x01, 0x0a, 0x08, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, + 0x73, 0x12, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x2e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, + 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x1b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x15, 0x12, 0x13, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x12, 0xab, 0x01, + 0x0a, 0x11, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x12, 0x36, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x37, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x44, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x25, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1f, 0x12, 0x1d, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, + 0x73, 0x2f, 0x7b, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x12, 0xb7, 0x01, 0x0a, 0x14, + 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x39, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x42, + 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x3a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x57, + 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x42, 0x79, 0x41, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x28, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x22, 0x12, 0x20, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, + 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x2f, 0x7b, 0x61, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x7d, 0x12, 0xc4, 0x01, 0x0a, 0x0a, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, + 0x61, 0x77, 0x61, 0x6c, 0x12, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x30, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x53, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x4d, 0x12, + 0x4b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, + 0x2f, 0x7b, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x7d, 0x2f, 0x7b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, + 0x7d, 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x7d, 0x2f, 0x7b, 0x69, 0x64, 0x7d, 0x42, 0xec, 0x01, 0x0a, + 0x1b, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x3b, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4c, 0x48, 0xaa, 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, + 0x17, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, + 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, 0x67, 0x65, 0x5c, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x1a, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x48, 0x6f, + 0x75, 0x73, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_query_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_query_proto_rawDescData = file_sge_legacy_house_v1beta_query_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_query_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_query_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 10) +var file_sge_legacy_house_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.legacy.house.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.legacy.house.v1beta.QueryParamsResponse + (*QueryDepositsRequest)(nil), // 2: sge.legacy.house.v1beta.QueryDepositsRequest + (*QueryDepositsResponse)(nil), // 3: sge.legacy.house.v1beta.QueryDepositsResponse + (*QueryDepositsByAccountRequest)(nil), // 4: sge.legacy.house.v1beta.QueryDepositsByAccountRequest + (*QueryDepositsByAccountResponse)(nil), // 5: sge.legacy.house.v1beta.QueryDepositsByAccountResponse + (*QueryWithdrawalsByAccountRequest)(nil), // 6: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest + (*QueryWithdrawalsByAccountResponse)(nil), // 7: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse + (*QueryWithdrawalRequest)(nil), // 8: sge.legacy.house.v1beta.QueryWithdrawalRequest + (*QueryWithdrawalResponse)(nil), // 9: sge.legacy.house.v1beta.QueryWithdrawalResponse + (*Params)(nil), // 10: sge.legacy.house.v1beta.Params + (*v1beta1.PageRequest)(nil), // 11: cosmos.base.query.v1beta1.PageRequest + (*Deposit)(nil), // 12: sge.legacy.house.v1beta.Deposit + (*v1beta1.PageResponse)(nil), // 13: cosmos.base.query.v1beta1.PageResponse + (*Withdrawal)(nil), // 14: sge.legacy.house.v1beta.Withdrawal +} +var file_sge_legacy_house_v1beta_query_proto_depIdxs = []int32{ + 10, // 0: sge.legacy.house.v1beta.QueryParamsResponse.params:type_name -> sge.legacy.house.v1beta.Params + 11, // 1: sge.legacy.house.v1beta.QueryDepositsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 12, // 2: sge.legacy.house.v1beta.QueryDepositsResponse.deposits:type_name -> sge.legacy.house.v1beta.Deposit + 13, // 3: sge.legacy.house.v1beta.QueryDepositsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 11, // 4: sge.legacy.house.v1beta.QueryDepositsByAccountRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 12, // 5: sge.legacy.house.v1beta.QueryDepositsByAccountResponse.deposits:type_name -> sge.legacy.house.v1beta.Deposit + 13, // 6: sge.legacy.house.v1beta.QueryDepositsByAccountResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 11, // 7: sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 14, // 8: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.withdrawals:type_name -> sge.legacy.house.v1beta.Withdrawal + 13, // 9: sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 14, // 10: sge.legacy.house.v1beta.QueryWithdrawalResponse.withdrawal:type_name -> sge.legacy.house.v1beta.Withdrawal + 0, // 11: sge.legacy.house.v1beta.Query.Params:input_type -> sge.legacy.house.v1beta.QueryParamsRequest + 2, // 12: sge.legacy.house.v1beta.Query.Deposits:input_type -> sge.legacy.house.v1beta.QueryDepositsRequest + 4, // 13: sge.legacy.house.v1beta.Query.DepositsByAccount:input_type -> sge.legacy.house.v1beta.QueryDepositsByAccountRequest + 6, // 14: sge.legacy.house.v1beta.Query.WithdrawalsByAccount:input_type -> sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest + 8, // 15: sge.legacy.house.v1beta.Query.Withdrawal:input_type -> sge.legacy.house.v1beta.QueryWithdrawalRequest + 1, // 16: sge.legacy.house.v1beta.Query.Params:output_type -> sge.legacy.house.v1beta.QueryParamsResponse + 3, // 17: sge.legacy.house.v1beta.Query.Deposits:output_type -> sge.legacy.house.v1beta.QueryDepositsResponse + 5, // 18: sge.legacy.house.v1beta.Query.DepositsByAccount:output_type -> sge.legacy.house.v1beta.QueryDepositsByAccountResponse + 7, // 19: sge.legacy.house.v1beta.Query.WithdrawalsByAccount:output_type -> sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse + 9, // 20: sge.legacy.house.v1beta.Query.Withdrawal:output_type -> sge.legacy.house.v1beta.QueryWithdrawalResponse + 16, // [16:21] is the sub-list for method output_type + 11, // [11:16] is the sub-list for method input_type + 11, // [11:11] is the sub-list for extension type_name + 11, // [11:11] is the sub-list for extension extendee + 0, // [0:11] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_query_proto_init() } +func file_sge_legacy_house_v1beta_query_proto_init() { + if File_sge_legacy_house_v1beta_query_proto != nil { + return + } + file_sge_legacy_house_v1beta_deposit_proto_init() + file_sge_legacy_house_v1beta_params_proto_init() + file_sge_legacy_house_v1beta_withdraw_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryDepositsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryDepositsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryDepositsByAccountRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryDepositsByAccountResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryWithdrawalsByAccountRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryWithdrawalsByAccountResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryWithdrawalRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_query_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryWithdrawalResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 10, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_house_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_legacy_house_v1beta_query_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_query_proto = out.File + file_sge_legacy_house_v1beta_query_proto_rawDesc = nil + file_sge_legacy_house_v1beta_query_proto_goTypes = nil + file_sge_legacy_house_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/query_grpc.pb.go b/api/sge/legacy/house/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..60d69a24 --- /dev/null +++ b/api/sge/legacy/house/v1beta/query_grpc.pb.go @@ -0,0 +1,267 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/house/v1beta/query.proto + +package housev1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Params_FullMethodName = "/sge.legacy.house.v1beta.Query/Params" + Query_Deposits_FullMethodName = "/sge.legacy.house.v1beta.Query/Deposits" + Query_DepositsByAccount_FullMethodName = "/sge.legacy.house.v1beta.Query/DepositsByAccount" + Query_WithdrawalsByAccount_FullMethodName = "/sge.legacy.house.v1beta.Query/WithdrawalsByAccount" + Query_Withdrawal_FullMethodName = "/sge.legacy.house.v1beta.Query/Withdrawal" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Params queries the parameters of the module. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) + // Deposits queries all deposits. + Deposits(ctx context.Context, in *QueryDepositsRequest, opts ...grpc.CallOption) (*QueryDepositsResponse, error) + // DepositsByAccount queries deposits info for given account. + DepositsByAccount(ctx context.Context, in *QueryDepositsByAccountRequest, opts ...grpc.CallOption) (*QueryDepositsByAccountResponse, error) + // WithdrawalsByAccount queries withdrawals info for given account. + WithdrawalsByAccount(ctx context.Context, in *QueryWithdrawalsByAccountRequest, opts ...grpc.CallOption) (*QueryWithdrawalsByAccountResponse, error) + // Queries a wthdrawal by depositor, market, participation index and id. + Withdrawal(ctx context.Context, in *QueryWithdrawalRequest, opts ...grpc.CallOption) (*QueryWithdrawalResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Deposits(ctx context.Context, in *QueryDepositsRequest, opts ...grpc.CallOption) (*QueryDepositsResponse, error) { + out := new(QueryDepositsResponse) + err := c.cc.Invoke(ctx, Query_Deposits_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) DepositsByAccount(ctx context.Context, in *QueryDepositsByAccountRequest, opts ...grpc.CallOption) (*QueryDepositsByAccountResponse, error) { + out := new(QueryDepositsByAccountResponse) + err := c.cc.Invoke(ctx, Query_DepositsByAccount_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) WithdrawalsByAccount(ctx context.Context, in *QueryWithdrawalsByAccountRequest, opts ...grpc.CallOption) (*QueryWithdrawalsByAccountResponse, error) { + out := new(QueryWithdrawalsByAccountResponse) + err := c.cc.Invoke(ctx, Query_WithdrawalsByAccount_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Withdrawal(ctx context.Context, in *QueryWithdrawalRequest, opts ...grpc.CallOption) (*QueryWithdrawalResponse, error) { + out := new(QueryWithdrawalResponse) + err := c.cc.Invoke(ctx, Query_Withdrawal_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Params queries the parameters of the module. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + // Deposits queries all deposits. + Deposits(context.Context, *QueryDepositsRequest) (*QueryDepositsResponse, error) + // DepositsByAccount queries deposits info for given account. + DepositsByAccount(context.Context, *QueryDepositsByAccountRequest) (*QueryDepositsByAccountResponse, error) + // WithdrawalsByAccount queries withdrawals info for given account. + WithdrawalsByAccount(context.Context, *QueryWithdrawalsByAccountRequest) (*QueryWithdrawalsByAccountResponse, error) + // Queries a wthdrawal by depositor, market, participation index and id. + Withdrawal(context.Context, *QueryWithdrawalRequest) (*QueryWithdrawalResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) Deposits(context.Context, *QueryDepositsRequest) (*QueryDepositsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Deposits not implemented") +} +func (UnimplementedQueryServer) DepositsByAccount(context.Context, *QueryDepositsByAccountRequest) (*QueryDepositsByAccountResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DepositsByAccount not implemented") +} +func (UnimplementedQueryServer) WithdrawalsByAccount(context.Context, *QueryWithdrawalsByAccountRequest) (*QueryWithdrawalsByAccountResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WithdrawalsByAccount not implemented") +} +func (UnimplementedQueryServer) Withdrawal(context.Context, *QueryWithdrawalRequest) (*QueryWithdrawalResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Withdrawal not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Deposits_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryDepositsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Deposits(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Deposits_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Deposits(ctx, req.(*QueryDepositsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_DepositsByAccount_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryDepositsByAccountRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).DepositsByAccount(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_DepositsByAccount_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).DepositsByAccount(ctx, req.(*QueryDepositsByAccountRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_WithdrawalsByAccount_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryWithdrawalsByAccountRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).WithdrawalsByAccount(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_WithdrawalsByAccount_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).WithdrawalsByAccount(ctx, req.(*QueryWithdrawalsByAccountRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Withdrawal_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryWithdrawalRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Withdrawal(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Withdrawal_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Withdrawal(ctx, req.(*QueryWithdrawalRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.house.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + { + MethodName: "Deposits", + Handler: _Query_Deposits_Handler, + }, + { + MethodName: "DepositsByAccount", + Handler: _Query_DepositsByAccount_Handler, + }, + { + MethodName: "WithdrawalsByAccount", + Handler: _Query_WithdrawalsByAccount_Handler, + }, + { + MethodName: "Withdrawal", + Handler: _Query_Withdrawal_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/house/v1beta/query.proto", +} diff --git a/api/sge/legacy/house/v1beta/ticket.pulsar.go b/api/sge/legacy/house/v1beta/ticket.pulsar.go new file mode 100644 index 00000000..64650ac4 --- /dev/null +++ b/api/sge/legacy/house/v1beta/ticket.pulsar.go @@ -0,0 +1,1253 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + v1beta "github.com/sge-network/sge/api/sge/legacy/type/v1beta" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_DepositTicketPayload protoreflect.MessageDescriptor + fd_DepositTicketPayload_kyc_data protoreflect.FieldDescriptor + fd_DepositTicketPayload_depositor_address protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_ticket_proto_init() + md_DepositTicketPayload = File_sge_legacy_house_v1beta_ticket_proto.Messages().ByName("DepositTicketPayload") + fd_DepositTicketPayload_kyc_data = md_DepositTicketPayload.Fields().ByName("kyc_data") + fd_DepositTicketPayload_depositor_address = md_DepositTicketPayload.Fields().ByName("depositor_address") +} + +var _ protoreflect.Message = (*fastReflection_DepositTicketPayload)(nil) + +type fastReflection_DepositTicketPayload DepositTicketPayload + +func (x *DepositTicketPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_DepositTicketPayload)(x) +} + +func (x *DepositTicketPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_ticket_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_DepositTicketPayload_messageType fastReflection_DepositTicketPayload_messageType +var _ protoreflect.MessageType = fastReflection_DepositTicketPayload_messageType{} + +type fastReflection_DepositTicketPayload_messageType struct{} + +func (x fastReflection_DepositTicketPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_DepositTicketPayload)(nil) +} +func (x fastReflection_DepositTicketPayload_messageType) New() protoreflect.Message { + return new(fastReflection_DepositTicketPayload) +} +func (x fastReflection_DepositTicketPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_DepositTicketPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_DepositTicketPayload) Descriptor() protoreflect.MessageDescriptor { + return md_DepositTicketPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_DepositTicketPayload) Type() protoreflect.MessageType { + return _fastReflection_DepositTicketPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_DepositTicketPayload) New() protoreflect.Message { + return new(fastReflection_DepositTicketPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_DepositTicketPayload) Interface() protoreflect.ProtoMessage { + return (*DepositTicketPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_DepositTicketPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.KycData != nil { + value := protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + if !f(fd_DepositTicketPayload_kyc_data, value) { + return + } + } + if x.DepositorAddress != "" { + value := protoreflect.ValueOfString(x.DepositorAddress) + if !f(fd_DepositTicketPayload_depositor_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_DepositTicketPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositTicketPayload.kyc_data": + return x.KycData != nil + case "sge.legacy.house.v1beta.DepositTicketPayload.depositor_address": + return x.DepositorAddress != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositTicketPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositTicketPayload.kyc_data": + x.KycData = nil + case "sge.legacy.house.v1beta.DepositTicketPayload.depositor_address": + x.DepositorAddress = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_DepositTicketPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.DepositTicketPayload.kyc_data": + value := x.KycData + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.house.v1beta.DepositTicketPayload.depositor_address": + value := x.DepositorAddress + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositTicketPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositTicketPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositTicketPayload.kyc_data": + x.KycData = value.Message().Interface().(*v1beta.KycDataPayload) + case "sge.legacy.house.v1beta.DepositTicketPayload.depositor_address": + x.DepositorAddress = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositTicketPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositTicketPayload.kyc_data": + if x.KycData == nil { + x.KycData = new(v1beta.KycDataPayload) + } + return protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + case "sge.legacy.house.v1beta.DepositTicketPayload.depositor_address": + panic(fmt.Errorf("field depositor_address of message sge.legacy.house.v1beta.DepositTicketPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositTicketPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_DepositTicketPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.DepositTicketPayload.kyc_data": + m := new(v1beta.KycDataPayload) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.house.v1beta.DepositTicketPayload.depositor_address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.DepositTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.DepositTicketPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_DepositTicketPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.DepositTicketPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_DepositTicketPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_DepositTicketPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_DepositTicketPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_DepositTicketPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*DepositTicketPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.KycData != nil { + l = options.Size(x.KycData) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.DepositorAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*DepositTicketPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.DepositorAddress) > 0 { + i -= len(x.DepositorAddress) + copy(dAtA[i:], x.DepositorAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.DepositorAddress))) + i-- + dAtA[i] = 0x12 + } + if x.KycData != nil { + encoded, err := options.Marshal(x.KycData) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*DepositTicketPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: DepositTicketPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: DepositTicketPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field KycData", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.KycData == nil { + x.KycData = &v1beta.KycDataPayload{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.KycData); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DepositorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_WithdrawTicketPayload protoreflect.MessageDescriptor + fd_WithdrawTicketPayload_kyc_data protoreflect.FieldDescriptor + fd_WithdrawTicketPayload_depositor_address protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_ticket_proto_init() + md_WithdrawTicketPayload = File_sge_legacy_house_v1beta_ticket_proto.Messages().ByName("WithdrawTicketPayload") + fd_WithdrawTicketPayload_kyc_data = md_WithdrawTicketPayload.Fields().ByName("kyc_data") + fd_WithdrawTicketPayload_depositor_address = md_WithdrawTicketPayload.Fields().ByName("depositor_address") +} + +var _ protoreflect.Message = (*fastReflection_WithdrawTicketPayload)(nil) + +type fastReflection_WithdrawTicketPayload WithdrawTicketPayload + +func (x *WithdrawTicketPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_WithdrawTicketPayload)(x) +} + +func (x *WithdrawTicketPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_ticket_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_WithdrawTicketPayload_messageType fastReflection_WithdrawTicketPayload_messageType +var _ protoreflect.MessageType = fastReflection_WithdrawTicketPayload_messageType{} + +type fastReflection_WithdrawTicketPayload_messageType struct{} + +func (x fastReflection_WithdrawTicketPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_WithdrawTicketPayload)(nil) +} +func (x fastReflection_WithdrawTicketPayload_messageType) New() protoreflect.Message { + return new(fastReflection_WithdrawTicketPayload) +} +func (x fastReflection_WithdrawTicketPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawTicketPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_WithdrawTicketPayload) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawTicketPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_WithdrawTicketPayload) Type() protoreflect.MessageType { + return _fastReflection_WithdrawTicketPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_WithdrawTicketPayload) New() protoreflect.Message { + return new(fastReflection_WithdrawTicketPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_WithdrawTicketPayload) Interface() protoreflect.ProtoMessage { + return (*WithdrawTicketPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_WithdrawTicketPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.KycData != nil { + value := protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + if !f(fd_WithdrawTicketPayload_kyc_data, value) { + return + } + } + if x.DepositorAddress != "" { + value := protoreflect.ValueOfString(x.DepositorAddress) + if !f(fd_WithdrawTicketPayload_depositor_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_WithdrawTicketPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawTicketPayload.kyc_data": + return x.KycData != nil + case "sge.legacy.house.v1beta.WithdrawTicketPayload.depositor_address": + return x.DepositorAddress != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawTicketPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawTicketPayload.kyc_data": + x.KycData = nil + case "sge.legacy.house.v1beta.WithdrawTicketPayload.depositor_address": + x.DepositorAddress = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_WithdrawTicketPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.WithdrawTicketPayload.kyc_data": + value := x.KycData + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.house.v1beta.WithdrawTicketPayload.depositor_address": + value := x.DepositorAddress + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawTicketPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawTicketPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawTicketPayload.kyc_data": + x.KycData = value.Message().Interface().(*v1beta.KycDataPayload) + case "sge.legacy.house.v1beta.WithdrawTicketPayload.depositor_address": + x.DepositorAddress = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawTicketPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawTicketPayload.kyc_data": + if x.KycData == nil { + x.KycData = new(v1beta.KycDataPayload) + } + return protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + case "sge.legacy.house.v1beta.WithdrawTicketPayload.depositor_address": + panic(fmt.Errorf("field depositor_address of message sge.legacy.house.v1beta.WithdrawTicketPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawTicketPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_WithdrawTicketPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.WithdrawTicketPayload.kyc_data": + m := new(v1beta.KycDataPayload) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.house.v1beta.WithdrawTicketPayload.depositor_address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.WithdrawTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.WithdrawTicketPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_WithdrawTicketPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.WithdrawTicketPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_WithdrawTicketPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawTicketPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_WithdrawTicketPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_WithdrawTicketPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*WithdrawTicketPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.KycData != nil { + l = options.Size(x.KycData) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.DepositorAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*WithdrawTicketPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.DepositorAddress) > 0 { + i -= len(x.DepositorAddress) + copy(dAtA[i:], x.DepositorAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.DepositorAddress))) + i-- + dAtA[i] = 0x12 + } + if x.KycData != nil { + encoded, err := options.Marshal(x.KycData) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*WithdrawTicketPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawTicketPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawTicketPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field KycData", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.KycData == nil { + x.KycData = &v1beta.KycDataPayload{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.KycData); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DepositorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/ticket.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// DepositTicketPayload indicates data of the deposit ticket. +type DepositTicketPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // kyc_data contains the details of user kyc. + KycData *v1beta.KycDataPayload `protobuf:"bytes,1,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data,omitempty"` + // depositor_address is the account who makes a deposit + DepositorAddress string `protobuf:"bytes,2,opt,name=depositor_address,json=depositorAddress,proto3" json:"depositor_address,omitempty"` +} + +func (x *DepositTicketPayload) Reset() { + *x = DepositTicketPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_ticket_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DepositTicketPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DepositTicketPayload) ProtoMessage() {} + +// Deprecated: Use DepositTicketPayload.ProtoReflect.Descriptor instead. +func (*DepositTicketPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_ticket_proto_rawDescGZIP(), []int{0} +} + +func (x *DepositTicketPayload) GetKycData() *v1beta.KycDataPayload { + if x != nil { + return x.KycData + } + return nil +} + +func (x *DepositTicketPayload) GetDepositorAddress() string { + if x != nil { + return x.DepositorAddress + } + return "" +} + +// WithdrawTicketPayload indicates data of the withdrawal ticket. +type WithdrawTicketPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // kyc_data contains the details of user kyc. + KycData *v1beta.KycDataPayload `protobuf:"bytes,1,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data,omitempty"` + // depositor_address is the account who makes a deposit + DepositorAddress string `protobuf:"bytes,2,opt,name=depositor_address,json=depositorAddress,proto3" json:"depositor_address,omitempty"` +} + +func (x *WithdrawTicketPayload) Reset() { + *x = WithdrawTicketPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_ticket_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WithdrawTicketPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WithdrawTicketPayload) ProtoMessage() {} + +// Deprecated: Use WithdrawTicketPayload.ProtoReflect.Descriptor instead. +func (*WithdrawTicketPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_ticket_proto_rawDescGZIP(), []int{1} +} + +func (x *WithdrawTicketPayload) GetKycData() *v1beta.KycDataPayload { + if x != nil { + return x.KycData + } + return nil +} + +func (x *WithdrawTicketPayload) GetDepositorAddress() string { + if x != nil { + return x.DepositorAddress + } + return "" +} + +var File_sge_legacy_house_v1beta_ticket_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_ticket_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, + 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x20, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x74, 0x79, 0x70, + 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6b, 0x79, 0x63, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x22, 0xc2, 0x01, 0x0a, 0x14, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x54, 0x69, + 0x63, 0x6b, 0x65, 0x74, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x47, 0x0a, 0x08, 0x6b, + 0x79, 0x63, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4b, 0x79, 0x63, 0x44, 0x61, 0x74, 0x61, 0x50, 0x61, + 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x6b, 0x79, 0x63, + 0x44, 0x61, 0x74, 0x61, 0x12, 0x61, 0x0a, 0x11, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, + 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x34, 0xf2, 0xde, 0x1f, 0x18, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x64, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xd2, 0xb4, 0x2d, + 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, + 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x10, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xc3, 0x01, 0x0a, 0x15, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, + 0x64, 0x12, 0x47, 0x0a, 0x08, 0x6b, 0x79, 0x63, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4b, 0x79, 0x63, + 0x44, 0x61, 0x74, 0x61, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x42, 0x04, 0xc8, 0xde, 0x1f, + 0x00, 0x52, 0x07, 0x6b, 0x79, 0x63, 0x44, 0x61, 0x74, 0x61, 0x12, 0x61, 0x0a, 0x11, 0x64, 0x65, + 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x34, 0xf2, 0xde, 0x1f, 0x18, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x22, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x10, 0x64, 0x65, 0x70, + 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x42, 0xed, 0x01, + 0x0a, 0x1b, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x54, + 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, + 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x3b, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x48, 0xaa, 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xca, 0x02, 0x17, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, + 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, 0x67, 0x65, + 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x1a, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, + 0x48, 0x6f, 0x75, 0x73, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_ticket_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_ticket_proto_rawDescData = file_sge_legacy_house_v1beta_ticket_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_ticket_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_ticket_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_ticket_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_ticket_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_ticket_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_ticket_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_house_v1beta_ticket_proto_goTypes = []interface{}{ + (*DepositTicketPayload)(nil), // 0: sge.legacy.house.v1beta.DepositTicketPayload + (*WithdrawTicketPayload)(nil), // 1: sge.legacy.house.v1beta.WithdrawTicketPayload + (*v1beta.KycDataPayload)(nil), // 2: sge.legacy.type.v1beta.KycDataPayload +} +var file_sge_legacy_house_v1beta_ticket_proto_depIdxs = []int32{ + 2, // 0: sge.legacy.house.v1beta.DepositTicketPayload.kyc_data:type_name -> sge.legacy.type.v1beta.KycDataPayload + 2, // 1: sge.legacy.house.v1beta.WithdrawTicketPayload.kyc_data:type_name -> sge.legacy.type.v1beta.KycDataPayload + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_ticket_proto_init() } +func file_sge_legacy_house_v1beta_ticket_proto_init() { + if File_sge_legacy_house_v1beta_ticket_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_ticket_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*DepositTicketPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_ticket_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WithdrawTicketPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_ticket_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_house_v1beta_ticket_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_ticket_proto_depIdxs, + MessageInfos: file_sge_legacy_house_v1beta_ticket_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_ticket_proto = out.File + file_sge_legacy_house_v1beta_ticket_proto_rawDesc = nil + file_sge_legacy_house_v1beta_ticket_proto_goTypes = nil + file_sge_legacy_house_v1beta_ticket_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/tx.pulsar.go b/api/sge/legacy/house/v1beta/tx.pulsar.go new file mode 100644 index 00000000..9d97c433 --- /dev/null +++ b/api/sge/legacy/house/v1beta/tx.pulsar.go @@ -0,0 +1,3790 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_MsgDeposit protoreflect.MessageDescriptor + fd_MsgDeposit_creator protoreflect.FieldDescriptor + fd_MsgDeposit_market_uid protoreflect.FieldDescriptor + fd_MsgDeposit_amount protoreflect.FieldDescriptor + fd_MsgDeposit_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_tx_proto_init() + md_MsgDeposit = File_sge_legacy_house_v1beta_tx_proto.Messages().ByName("MsgDeposit") + fd_MsgDeposit_creator = md_MsgDeposit.Fields().ByName("creator") + fd_MsgDeposit_market_uid = md_MsgDeposit.Fields().ByName("market_uid") + fd_MsgDeposit_amount = md_MsgDeposit.Fields().ByName("amount") + fd_MsgDeposit_ticket = md_MsgDeposit.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgDeposit)(nil) + +type fastReflection_MsgDeposit MsgDeposit + +func (x *MsgDeposit) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgDeposit)(x) +} + +func (x *MsgDeposit) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgDeposit_messageType fastReflection_MsgDeposit_messageType +var _ protoreflect.MessageType = fastReflection_MsgDeposit_messageType{} + +type fastReflection_MsgDeposit_messageType struct{} + +func (x fastReflection_MsgDeposit_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgDeposit)(nil) +} +func (x fastReflection_MsgDeposit_messageType) New() protoreflect.Message { + return new(fastReflection_MsgDeposit) +} +func (x fastReflection_MsgDeposit_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgDeposit +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgDeposit) Descriptor() protoreflect.MessageDescriptor { + return md_MsgDeposit +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgDeposit) Type() protoreflect.MessageType { + return _fastReflection_MsgDeposit_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgDeposit) New() protoreflect.Message { + return new(fastReflection_MsgDeposit) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgDeposit) Interface() protoreflect.ProtoMessage { + return (*MsgDeposit)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgDeposit) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgDeposit_creator, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_MsgDeposit_market_uid, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_MsgDeposit_amount, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgDeposit_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgDeposit) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDeposit.creator": + return x.Creator != "" + case "sge.legacy.house.v1beta.MsgDeposit.market_uid": + return x.MarketUid != "" + case "sge.legacy.house.v1beta.MsgDeposit.amount": + return x.Amount != "" + case "sge.legacy.house.v1beta.MsgDeposit.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDeposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDeposit does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDeposit) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDeposit.creator": + x.Creator = "" + case "sge.legacy.house.v1beta.MsgDeposit.market_uid": + x.MarketUid = "" + case "sge.legacy.house.v1beta.MsgDeposit.amount": + x.Amount = "" + case "sge.legacy.house.v1beta.MsgDeposit.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDeposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDeposit does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgDeposit) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.MsgDeposit.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgDeposit.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgDeposit.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgDeposit.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDeposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDeposit does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDeposit) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDeposit.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgDeposit.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgDeposit.amount": + x.Amount = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgDeposit.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDeposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDeposit does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDeposit) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDeposit.creator": + panic(fmt.Errorf("field creator of message sge.legacy.house.v1beta.MsgDeposit is not mutable")) + case "sge.legacy.house.v1beta.MsgDeposit.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.house.v1beta.MsgDeposit is not mutable")) + case "sge.legacy.house.v1beta.MsgDeposit.amount": + panic(fmt.Errorf("field amount of message sge.legacy.house.v1beta.MsgDeposit is not mutable")) + case "sge.legacy.house.v1beta.MsgDeposit.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.house.v1beta.MsgDeposit is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDeposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDeposit does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgDeposit) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDeposit.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgDeposit.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgDeposit.amount": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgDeposit.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDeposit")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDeposit does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgDeposit) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.MsgDeposit", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgDeposit) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDeposit) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgDeposit) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgDeposit) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgDeposit) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgDeposit) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x22 + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x1a + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgDeposit) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgDeposit: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgDeposit: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgDepositResponse protoreflect.MessageDescriptor + fd_MsgDepositResponse_market_uid protoreflect.FieldDescriptor + fd_MsgDepositResponse_participation_index protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_tx_proto_init() + md_MsgDepositResponse = File_sge_legacy_house_v1beta_tx_proto.Messages().ByName("MsgDepositResponse") + fd_MsgDepositResponse_market_uid = md_MsgDepositResponse.Fields().ByName("market_uid") + fd_MsgDepositResponse_participation_index = md_MsgDepositResponse.Fields().ByName("participation_index") +} + +var _ protoreflect.Message = (*fastReflection_MsgDepositResponse)(nil) + +type fastReflection_MsgDepositResponse MsgDepositResponse + +func (x *MsgDepositResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgDepositResponse)(x) +} + +func (x *MsgDepositResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgDepositResponse_messageType fastReflection_MsgDepositResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgDepositResponse_messageType{} + +type fastReflection_MsgDepositResponse_messageType struct{} + +func (x fastReflection_MsgDepositResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgDepositResponse)(nil) +} +func (x fastReflection_MsgDepositResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgDepositResponse) +} +func (x fastReflection_MsgDepositResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgDepositResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgDepositResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgDepositResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgDepositResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgDepositResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgDepositResponse) New() protoreflect.Message { + return new(fastReflection_MsgDepositResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgDepositResponse) Interface() protoreflect.ProtoMessage { + return (*MsgDepositResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgDepositResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_MsgDepositResponse_market_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_MsgDepositResponse_participation_index, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgDepositResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDepositResponse.market_uid": + return x.MarketUid != "" + case "sge.legacy.house.v1beta.MsgDepositResponse.participation_index": + return x.ParticipationIndex != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDepositResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDepositResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDepositResponse.market_uid": + x.MarketUid = "" + case "sge.legacy.house.v1beta.MsgDepositResponse.participation_index": + x.ParticipationIndex = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDepositResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgDepositResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.MsgDepositResponse.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgDepositResponse.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDepositResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDepositResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDepositResponse.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgDepositResponse.participation_index": + x.ParticipationIndex = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDepositResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDepositResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDepositResponse.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.house.v1beta.MsgDepositResponse is not mutable")) + case "sge.legacy.house.v1beta.MsgDepositResponse.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.house.v1beta.MsgDepositResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDepositResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgDepositResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgDepositResponse.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgDepositResponse.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgDepositResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgDepositResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.MsgDepositResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgDepositResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgDepositResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgDepositResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgDepositResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgDepositResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgDepositResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x10 + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgDepositResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgDepositResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgDepositResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdraw protoreflect.MessageDescriptor + fd_MsgWithdraw_creator protoreflect.FieldDescriptor + fd_MsgWithdraw_market_uid protoreflect.FieldDescriptor + fd_MsgWithdraw_participation_index protoreflect.FieldDescriptor + fd_MsgWithdraw_mode protoreflect.FieldDescriptor + fd_MsgWithdraw_amount protoreflect.FieldDescriptor + fd_MsgWithdraw_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_tx_proto_init() + md_MsgWithdraw = File_sge_legacy_house_v1beta_tx_proto.Messages().ByName("MsgWithdraw") + fd_MsgWithdraw_creator = md_MsgWithdraw.Fields().ByName("creator") + fd_MsgWithdraw_market_uid = md_MsgWithdraw.Fields().ByName("market_uid") + fd_MsgWithdraw_participation_index = md_MsgWithdraw.Fields().ByName("participation_index") + fd_MsgWithdraw_mode = md_MsgWithdraw.Fields().ByName("mode") + fd_MsgWithdraw_amount = md_MsgWithdraw.Fields().ByName("amount") + fd_MsgWithdraw_ticket = md_MsgWithdraw.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdraw)(nil) + +type fastReflection_MsgWithdraw MsgWithdraw + +func (x *MsgWithdraw) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdraw)(x) +} + +func (x *MsgWithdraw) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdraw_messageType fastReflection_MsgWithdraw_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdraw_messageType{} + +type fastReflection_MsgWithdraw_messageType struct{} + +func (x fastReflection_MsgWithdraw_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdraw)(nil) +} +func (x fastReflection_MsgWithdraw_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdraw) +} +func (x fastReflection_MsgWithdraw_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdraw +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdraw) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdraw +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdraw) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdraw_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdraw) New() protoreflect.Message { + return new(fastReflection_MsgWithdraw) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdraw) Interface() protoreflect.ProtoMessage { + return (*MsgWithdraw)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdraw) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgWithdraw_creator, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_MsgWithdraw_market_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_MsgWithdraw_participation_index, value) { + return + } + } + if x.Mode != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Mode)) + if !f(fd_MsgWithdraw_mode, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_MsgWithdraw_amount, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgWithdraw_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdraw) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdraw.creator": + return x.Creator != "" + case "sge.legacy.house.v1beta.MsgWithdraw.market_uid": + return x.MarketUid != "" + case "sge.legacy.house.v1beta.MsgWithdraw.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.house.v1beta.MsgWithdraw.mode": + return x.Mode != 0 + case "sge.legacy.house.v1beta.MsgWithdraw.amount": + return x.Amount != "" + case "sge.legacy.house.v1beta.MsgWithdraw.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdraw does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdraw) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdraw.creator": + x.Creator = "" + case "sge.legacy.house.v1beta.MsgWithdraw.market_uid": + x.MarketUid = "" + case "sge.legacy.house.v1beta.MsgWithdraw.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.house.v1beta.MsgWithdraw.mode": + x.Mode = 0 + case "sge.legacy.house.v1beta.MsgWithdraw.amount": + x.Amount = "" + case "sge.legacy.house.v1beta.MsgWithdraw.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdraw does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdraw) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.MsgWithdraw.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgWithdraw.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgWithdraw.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.house.v1beta.MsgWithdraw.mode": + value := x.Mode + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.house.v1beta.MsgWithdraw.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgWithdraw.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdraw does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdraw) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdraw.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgWithdraw.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgWithdraw.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.house.v1beta.MsgWithdraw.mode": + x.Mode = (WithdrawalMode)(value.Enum()) + case "sge.legacy.house.v1beta.MsgWithdraw.amount": + x.Amount = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgWithdraw.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdraw does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdraw) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdraw.creator": + panic(fmt.Errorf("field creator of message sge.legacy.house.v1beta.MsgWithdraw is not mutable")) + case "sge.legacy.house.v1beta.MsgWithdraw.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.house.v1beta.MsgWithdraw is not mutable")) + case "sge.legacy.house.v1beta.MsgWithdraw.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.house.v1beta.MsgWithdraw is not mutable")) + case "sge.legacy.house.v1beta.MsgWithdraw.mode": + panic(fmt.Errorf("field mode of message sge.legacy.house.v1beta.MsgWithdraw is not mutable")) + case "sge.legacy.house.v1beta.MsgWithdraw.amount": + panic(fmt.Errorf("field amount of message sge.legacy.house.v1beta.MsgWithdraw is not mutable")) + case "sge.legacy.house.v1beta.MsgWithdraw.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.house.v1beta.MsgWithdraw is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdraw does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdraw) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdraw.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgWithdraw.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgWithdraw.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.house.v1beta.MsgWithdraw.mode": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.house.v1beta.MsgWithdraw.amount": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgWithdraw.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdraw does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdraw) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.MsgWithdraw", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdraw) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdraw) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdraw) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdraw) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdraw) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.Mode != 0 { + n += 1 + runtime.Sov(uint64(x.Mode)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdraw) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x32 + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x2a + } + if x.Mode != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Mode)) + i-- + dAtA[i] = 0x20 + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x18 + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdraw) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdraw: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdraw: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Mode", wireType) + } + x.Mode = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Mode |= WithdrawalMode(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdrawResponse protoreflect.MessageDescriptor + fd_MsgWithdrawResponse_id protoreflect.FieldDescriptor + fd_MsgWithdrawResponse_market_uid protoreflect.FieldDescriptor + fd_MsgWithdrawResponse_participation_index protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_tx_proto_init() + md_MsgWithdrawResponse = File_sge_legacy_house_v1beta_tx_proto.Messages().ByName("MsgWithdrawResponse") + fd_MsgWithdrawResponse_id = md_MsgWithdrawResponse.Fields().ByName("id") + fd_MsgWithdrawResponse_market_uid = md_MsgWithdrawResponse.Fields().ByName("market_uid") + fd_MsgWithdrawResponse_participation_index = md_MsgWithdrawResponse.Fields().ByName("participation_index") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdrawResponse)(nil) + +type fastReflection_MsgWithdrawResponse MsgWithdrawResponse + +func (x *MsgWithdrawResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdrawResponse)(x) +} + +func (x *MsgWithdrawResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdrawResponse_messageType fastReflection_MsgWithdrawResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdrawResponse_messageType{} + +type fastReflection_MsgWithdrawResponse_messageType struct{} + +func (x fastReflection_MsgWithdrawResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdrawResponse)(nil) +} +func (x fastReflection_MsgWithdrawResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawResponse) +} +func (x fastReflection_MsgWithdrawResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdrawResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdrawResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdrawResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdrawResponse) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdrawResponse) Interface() protoreflect.ProtoMessage { + return (*MsgWithdrawResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdrawResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Id != uint64(0) { + value := protoreflect.ValueOfUint64(x.Id) + if !f(fd_MsgWithdrawResponse_id, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_MsgWithdrawResponse_market_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_MsgWithdrawResponse_participation_index, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdrawResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdrawResponse.id": + return x.Id != uint64(0) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.market_uid": + return x.MarketUid != "" + case "sge.legacy.house.v1beta.MsgWithdrawResponse.participation_index": + return x.ParticipationIndex != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdrawResponse.id": + x.Id = uint64(0) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.market_uid": + x.MarketUid = "" + case "sge.legacy.house.v1beta.MsgWithdrawResponse.participation_index": + x.ParticipationIndex = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdrawResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.MsgWithdrawResponse.id": + value := x.Id + return protoreflect.ValueOfUint64(value) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdrawResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdrawResponse.id": + x.Id = value.Uint() + case "sge.legacy.house.v1beta.MsgWithdrawResponse.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.participation_index": + x.ParticipationIndex = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdrawResponse.id": + panic(fmt.Errorf("field id of message sge.legacy.house.v1beta.MsgWithdrawResponse is not mutable")) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.house.v1beta.MsgWithdrawResponse is not mutable")) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.house.v1beta.MsgWithdrawResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdrawResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgWithdrawResponse.id": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.house.v1beta.MsgWithdrawResponse.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgWithdrawResponse.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdrawResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.MsgWithdrawResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdrawResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdrawResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdrawResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdrawResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Id != 0 { + n += 1 + runtime.Sov(uint64(x.Id)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x18 + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x12 + } + if x.Id != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Id)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + x.Id = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Id |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_legacy_house_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.legacy.house.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.legacy.house.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.legacy.house.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.house.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.legacy.house.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_legacy_house_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgDeposit defines a SDK message for performing a deposit of coins to become +// part of the house corresponding to a market. +type MsgDeposit struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the account who makes a deposit + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // market_uid is the uid of market/order book against which deposit is being + // made. + MarketUid string `protobuf:"bytes,2,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // amount is the amount being deposited on an order book to be a house + Amount string `protobuf:"bytes,3,opt,name=amount,proto3" json:"amount,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,4,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgDeposit) Reset() { + *x = MsgDeposit{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgDeposit) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgDeposit) ProtoMessage() {} + +// Deprecated: Use MsgDeposit.ProtoReflect.Descriptor instead. +func (*MsgDeposit) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgDeposit) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgDeposit) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *MsgDeposit) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +func (x *MsgDeposit) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgDepositResponse defines the Msg/Deposit response type. +type MsgDepositResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // market_uid is the uid of market/order book against which deposit is being + // made. + MarketUid string `protobuf:"bytes,1,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // participation_index is the index corresponding to the order book + // participation + ParticipationIndex uint64 `protobuf:"varint,2,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` +} + +func (x *MsgDepositResponse) Reset() { + *x = MsgDepositResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgDepositResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgDepositResponse) ProtoMessage() {} + +// Deprecated: Use MsgDepositResponse.ProtoReflect.Descriptor instead. +func (*MsgDepositResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +func (x *MsgDepositResponse) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *MsgDepositResponse) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +// MsgWithdraw defines a SDK message for performing a withdrawal of coins of +// unused amount corresponding to a deposit. +type MsgWithdraw struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + MarketUid string `protobuf:"bytes,2,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // participation_index is the index corresponding to the order book + // participation + ParticipationIndex uint64 `protobuf:"varint,3,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // mode is the withdrawal mode. It can be full or partial withdraw + Mode WithdrawalMode `protobuf:"varint,4,opt,name=mode,proto3,enum=sge.legacy.house.v1beta.WithdrawalMode" json:"mode,omitempty"` + // amount is the requested withdrawal amount + Amount string `protobuf:"bytes,5,opt,name=amount,proto3" json:"amount,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,6,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgWithdraw) Reset() { + *x = MsgWithdraw{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdraw) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdraw) ProtoMessage() {} + +// Deprecated: Use MsgWithdraw.ProtoReflect.Descriptor instead. +func (*MsgWithdraw) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_tx_proto_rawDescGZIP(), []int{2} +} + +func (x *MsgWithdraw) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgWithdraw) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *MsgWithdraw) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *MsgWithdraw) GetMode() WithdrawalMode { + if x != nil { + return x.Mode + } + return WithdrawalMode_WITHDRAWAL_MODE_UNSPECIFIED +} + +func (x *MsgWithdraw) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +func (x *MsgWithdraw) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgWithdrawResponse defines the Msg/Withdraw response type. +type MsgWithdrawResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // id is the unique identifier for the withdrawal + Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + // market_uid is the id of market/order book from which withdrawal is made + MarketUid string `protobuf:"bytes,2,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // participation_index is the index in order book from which withdrawal is + // made + ParticipationIndex uint64 `protobuf:"varint,3,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` +} + +func (x *MsgWithdrawResponse) Reset() { + *x = MsgWithdrawResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdrawResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdrawResponse) ProtoMessage() {} + +// Deprecated: Use MsgWithdrawResponse.ProtoReflect.Descriptor instead. +func (*MsgWithdrawResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_tx_proto_rawDescGZIP(), []int{3} +} + +func (x *MsgWithdrawResponse) GetId() uint64 { + if x != nil { + return x.Id + } + return 0 +} + +func (x *MsgWithdrawResponse) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *MsgWithdrawResponse) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +// MsgUpdateParams is the Msg/UpdateParams request type. +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/bet parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_tx_proto_rawDescGZIP(), []int{4} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_tx_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_tx_proto_rawDescGZIP(), []int{5} +} + +var File_sge_legacy_house_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x20, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, 0x6d, 0x69, + 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, + 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, + 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x26, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xdc, 0x01, 0x0a, 0x0a, 0x4d, 0x73, 0x67, 0x44, 0x65, + 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x2c, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x12, 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, + 0x3a, 0x22, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x6f, 0x72, 0x12, 0x3b, 0x0a, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, + 0x12, 0x35, 0x0a, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, + 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, + 0x14, 0x88, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, + 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0xa2, 0x01, 0x0a, 0x12, 0x4d, 0x73, 0x67, 0x44, 0x65, 0x70, + 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3b, 0x0a, 0x0a, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x55, 0x49, 0x44, 0xea, + 0xde, 0x1f, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0a, 0x6d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x4f, 0x0a, 0x13, 0x70, 0x61, 0x72, + 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1e, 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, 0x6d, 0x6c, + 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, + 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x94, 0x03, 0x0a, 0x0b, 0x4d, + 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x12, 0x44, 0x0a, 0x07, 0x63, 0x72, + 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2a, 0xf2, 0xde, 0x1f, + 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0xd2, + 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, + 0x12, 0x3b, 0x0a, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, + 0x64, 0x52, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x4f, 0x0a, + 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, + 0x6e, 0x64, 0x65, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1e, 0xf2, 0xde, 0x1f, 0x1a, + 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, + 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x4c, + 0x0a, 0x04, 0x6d, 0x6f, 0x64, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x27, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, + 0x6c, 0x4d, 0x6f, 0x64, 0x65, 0x42, 0x0f, 0xf2, 0xde, 0x1f, 0x0b, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x6d, 0x6f, 0x64, 0x65, 0x22, 0x52, 0x04, 0x6d, 0x6f, 0x64, 0x65, 0x12, 0x35, 0x0a, 0x06, + 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, + 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, + 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x06, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, 0x14, 0x88, 0xa0, 0x1f, + 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, + 0x72, 0x22, 0xce, 0x01, 0x0a, 0x13, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, + 0x77, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x29, 0x0a, 0x02, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x04, 0x42, 0x19, 0xe2, 0xde, 0x1f, 0x02, 0x49, 0x44, 0xea, 0xde, 0x1f, + 0x02, 0x69, 0x64, 0xf2, 0xde, 0x1f, 0x09, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x69, 0x64, 0x22, + 0x52, 0x02, 0x69, 0x64, 0x12, 0x3b, 0x0a, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, + 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, + 0x64, 0x12, 0x4f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1e, + 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x12, + 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, + 0x65, 0x78, 0x22, 0xb2, 0x01, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, + 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x42, + 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, + 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, + 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x3a, 0x23, 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, + 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, 0x30, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x3a, 0x15, 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x32, 0xd3, 0x02, 0x0a, 0x03, 0x4d, 0x73, + 0x67, 0x12, 0x60, 0x0a, 0x07, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x23, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, + 0x74, 0x1a, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x44, + 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, + 0x88, 0x02, 0x01, 0x12, 0x63, 0x0a, 0x08, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x12, + 0x24, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, + 0x68, 0x64, 0x72, 0x61, 0x77, 0x1a, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x84, 0x01, 0x0a, 0x0c, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x1a, 0x30, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, + 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x18, 0xca, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, + 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x88, 0x02, 0x01, 0x42, + 0xe9, 0x01, 0x0a, 0x1b, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, + 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x3b, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4c, 0x48, 0xaa, 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, + 0x17, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, + 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, 0x67, 0x65, 0x5c, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x1a, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x48, 0x6f, + 0x75, 0x73, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_tx_proto_rawDescData = file_sge_legacy_house_v1beta_tx_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_tx_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_tx_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 6) +var file_sge_legacy_house_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgDeposit)(nil), // 0: sge.legacy.house.v1beta.MsgDeposit + (*MsgDepositResponse)(nil), // 1: sge.legacy.house.v1beta.MsgDepositResponse + (*MsgWithdraw)(nil), // 2: sge.legacy.house.v1beta.MsgWithdraw + (*MsgWithdrawResponse)(nil), // 3: sge.legacy.house.v1beta.MsgWithdrawResponse + (*MsgUpdateParams)(nil), // 4: sge.legacy.house.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 5: sge.legacy.house.v1beta.MsgUpdateParamsResponse + (WithdrawalMode)(0), // 6: sge.legacy.house.v1beta.WithdrawalMode + (*Params)(nil), // 7: sge.legacy.house.v1beta.Params +} +var file_sge_legacy_house_v1beta_tx_proto_depIdxs = []int32{ + 6, // 0: sge.legacy.house.v1beta.MsgWithdraw.mode:type_name -> sge.legacy.house.v1beta.WithdrawalMode + 7, // 1: sge.legacy.house.v1beta.MsgUpdateParams.params:type_name -> sge.legacy.house.v1beta.Params + 0, // 2: sge.legacy.house.v1beta.Msg.Deposit:input_type -> sge.legacy.house.v1beta.MsgDeposit + 2, // 3: sge.legacy.house.v1beta.Msg.Withdraw:input_type -> sge.legacy.house.v1beta.MsgWithdraw + 4, // 4: sge.legacy.house.v1beta.Msg.UpdateParams:input_type -> sge.legacy.house.v1beta.MsgUpdateParams + 1, // 5: sge.legacy.house.v1beta.Msg.Deposit:output_type -> sge.legacy.house.v1beta.MsgDepositResponse + 3, // 6: sge.legacy.house.v1beta.Msg.Withdraw:output_type -> sge.legacy.house.v1beta.MsgWithdrawResponse + 5, // 7: sge.legacy.house.v1beta.Msg.UpdateParams:output_type -> sge.legacy.house.v1beta.MsgUpdateParamsResponse + 5, // [5:8] is the sub-list for method output_type + 2, // [2:5] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_tx_proto_init() } +func file_sge_legacy_house_v1beta_tx_proto_init() { + if File_sge_legacy_house_v1beta_tx_proto != nil { + return + } + file_sge_legacy_house_v1beta_params_proto_init() + file_sge_legacy_house_v1beta_withdraw_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgDeposit); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgDepositResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_tx_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdraw); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_tx_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdrawResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_tx_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_house_v1beta_tx_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 6, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_house_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_legacy_house_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_tx_proto = out.File + file_sge_legacy_house_v1beta_tx_proto_rawDesc = nil + file_sge_legacy_house_v1beta_tx_proto_goTypes = nil + file_sge_legacy_house_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/legacy/house/v1beta/tx_grpc.pb.go b/api/sge/legacy/house/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..08f9e671 --- /dev/null +++ b/api/sge/legacy/house/v1beta/tx_grpc.pb.go @@ -0,0 +1,206 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/house/v1beta/tx.proto + +package housev1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_Deposit_FullMethodName = "/sge.legacy.house.v1beta.Msg/Deposit" + Msg_Withdraw_FullMethodName = "/sge.legacy.house.v1beta.Msg/Withdraw" + Msg_UpdateParams_FullMethodName = "/sge.legacy.house.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // Deprecated: Do not use. + // Deposit defines a method for performing a deposit of tokens to become part + // of the order book or be the house for an order book corresponding to a + // market. + Deposit(ctx context.Context, in *MsgDeposit, opts ...grpc.CallOption) (*MsgDepositResponse, error) + // Deprecated: Do not use. + // Withdraw defines a method for performing a withdrawal of tokens of unused + // amount corresponding to a deposit. + Withdraw(ctx context.Context, in *MsgWithdraw, opts ...grpc.CallOption) (*MsgWithdrawResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/house module + // parameters. The authority is defined in the keeper. + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +// Deprecated: Do not use. +func (c *msgClient) Deposit(ctx context.Context, in *MsgDeposit, opts ...grpc.CallOption) (*MsgDepositResponse, error) { + out := new(MsgDepositResponse) + err := c.cc.Invoke(ctx, Msg_Deposit_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) Withdraw(ctx context.Context, in *MsgWithdraw, opts ...grpc.CallOption) (*MsgWithdrawResponse, error) { + out := new(MsgWithdrawResponse) + err := c.cc.Invoke(ctx, Msg_Withdraw_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // Deprecated: Do not use. + // Deposit defines a method for performing a deposit of tokens to become part + // of the order book or be the house for an order book corresponding to a + // market. + Deposit(context.Context, *MsgDeposit) (*MsgDepositResponse, error) + // Deprecated: Do not use. + // Withdraw defines a method for performing a withdrawal of tokens of unused + // amount corresponding to a deposit. + Withdraw(context.Context, *MsgWithdraw) (*MsgWithdrawResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/house module + // parameters. The authority is defined in the keeper. + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) Deposit(context.Context, *MsgDeposit) (*MsgDepositResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Deposit not implemented") +} +func (UnimplementedMsgServer) Withdraw(context.Context, *MsgWithdraw) (*MsgWithdrawResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Withdraw not implemented") +} +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_Deposit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgDeposit) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Deposit(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Deposit_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Deposit(ctx, req.(*MsgDeposit)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_Withdraw_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgWithdraw) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Withdraw(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Withdraw_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Withdraw(ctx, req.(*MsgWithdraw)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.house.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Deposit", + Handler: _Msg_Deposit_Handler, + }, + { + MethodName: "Withdraw", + Handler: _Msg_Withdraw_Handler, + }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/house/v1beta/tx.proto", +} diff --git a/api/sge/legacy/house/v1beta/withdraw.pulsar.go b/api/sge/legacy/house/v1beta/withdraw.pulsar.go new file mode 100644 index 00000000..0e9463ee --- /dev/null +++ b/api/sge/legacy/house/v1beta/withdraw.pulsar.go @@ -0,0 +1,1062 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package housev1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Withdrawal protoreflect.MessageDescriptor + fd_Withdrawal_creator protoreflect.FieldDescriptor + fd_Withdrawal_id protoreflect.FieldDescriptor + fd_Withdrawal_address protoreflect.FieldDescriptor + fd_Withdrawal_market_uid protoreflect.FieldDescriptor + fd_Withdrawal_participation_index protoreflect.FieldDescriptor + fd_Withdrawal_mode protoreflect.FieldDescriptor + fd_Withdrawal_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_house_v1beta_withdraw_proto_init() + md_Withdrawal = File_sge_legacy_house_v1beta_withdraw_proto.Messages().ByName("Withdrawal") + fd_Withdrawal_creator = md_Withdrawal.Fields().ByName("creator") + fd_Withdrawal_id = md_Withdrawal.Fields().ByName("id") + fd_Withdrawal_address = md_Withdrawal.Fields().ByName("address") + fd_Withdrawal_market_uid = md_Withdrawal.Fields().ByName("market_uid") + fd_Withdrawal_participation_index = md_Withdrawal.Fields().ByName("participation_index") + fd_Withdrawal_mode = md_Withdrawal.Fields().ByName("mode") + fd_Withdrawal_amount = md_Withdrawal.Fields().ByName("amount") +} + +var _ protoreflect.Message = (*fastReflection_Withdrawal)(nil) + +type fastReflection_Withdrawal Withdrawal + +func (x *Withdrawal) ProtoReflect() protoreflect.Message { + return (*fastReflection_Withdrawal)(x) +} + +func (x *Withdrawal) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_house_v1beta_withdraw_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Withdrawal_messageType fastReflection_Withdrawal_messageType +var _ protoreflect.MessageType = fastReflection_Withdrawal_messageType{} + +type fastReflection_Withdrawal_messageType struct{} + +func (x fastReflection_Withdrawal_messageType) Zero() protoreflect.Message { + return (*fastReflection_Withdrawal)(nil) +} +func (x fastReflection_Withdrawal_messageType) New() protoreflect.Message { + return new(fastReflection_Withdrawal) +} +func (x fastReflection_Withdrawal_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Withdrawal +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Withdrawal) Descriptor() protoreflect.MessageDescriptor { + return md_Withdrawal +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Withdrawal) Type() protoreflect.MessageType { + return _fastReflection_Withdrawal_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Withdrawal) New() protoreflect.Message { + return new(fastReflection_Withdrawal) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Withdrawal) Interface() protoreflect.ProtoMessage { + return (*Withdrawal)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Withdrawal) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_Withdrawal_creator, value) { + return + } + } + if x.Id != uint64(0) { + value := protoreflect.ValueOfUint64(x.Id) + if !f(fd_Withdrawal_id, value) { + return + } + } + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_Withdrawal_address, value) { + return + } + } + if x.MarketUid != "" { + value := protoreflect.ValueOfString(x.MarketUid) + if !f(fd_Withdrawal_market_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_Withdrawal_participation_index, value) { + return + } + } + if x.Mode != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Mode)) + if !f(fd_Withdrawal_mode, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_Withdrawal_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Withdrawal) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Withdrawal.creator": + return x.Creator != "" + case "sge.legacy.house.v1beta.Withdrawal.id": + return x.Id != uint64(0) + case "sge.legacy.house.v1beta.Withdrawal.address": + return x.Address != "" + case "sge.legacy.house.v1beta.Withdrawal.market_uid": + return x.MarketUid != "" + case "sge.legacy.house.v1beta.Withdrawal.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.house.v1beta.Withdrawal.mode": + return x.Mode != 0 + case "sge.legacy.house.v1beta.Withdrawal.amount": + return x.Amount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Withdrawal")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Withdrawal does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Withdrawal) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Withdrawal.creator": + x.Creator = "" + case "sge.legacy.house.v1beta.Withdrawal.id": + x.Id = uint64(0) + case "sge.legacy.house.v1beta.Withdrawal.address": + x.Address = "" + case "sge.legacy.house.v1beta.Withdrawal.market_uid": + x.MarketUid = "" + case "sge.legacy.house.v1beta.Withdrawal.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.house.v1beta.Withdrawal.mode": + x.Mode = 0 + case "sge.legacy.house.v1beta.Withdrawal.amount": + x.Amount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Withdrawal")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Withdrawal does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Withdrawal) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.house.v1beta.Withdrawal.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Withdrawal.id": + value := x.Id + return protoreflect.ValueOfUint64(value) + case "sge.legacy.house.v1beta.Withdrawal.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Withdrawal.market_uid": + value := x.MarketUid + return protoreflect.ValueOfString(value) + case "sge.legacy.house.v1beta.Withdrawal.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.house.v1beta.Withdrawal.mode": + value := x.Mode + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.house.v1beta.Withdrawal.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Withdrawal")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Withdrawal does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Withdrawal) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Withdrawal.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.house.v1beta.Withdrawal.id": + x.Id = value.Uint() + case "sge.legacy.house.v1beta.Withdrawal.address": + x.Address = value.Interface().(string) + case "sge.legacy.house.v1beta.Withdrawal.market_uid": + x.MarketUid = value.Interface().(string) + case "sge.legacy.house.v1beta.Withdrawal.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.house.v1beta.Withdrawal.mode": + x.Mode = (WithdrawalMode)(value.Enum()) + case "sge.legacy.house.v1beta.Withdrawal.amount": + x.Amount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Withdrawal")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Withdrawal does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Withdrawal) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Withdrawal.creator": + panic(fmt.Errorf("field creator of message sge.legacy.house.v1beta.Withdrawal is not mutable")) + case "sge.legacy.house.v1beta.Withdrawal.id": + panic(fmt.Errorf("field id of message sge.legacy.house.v1beta.Withdrawal is not mutable")) + case "sge.legacy.house.v1beta.Withdrawal.address": + panic(fmt.Errorf("field address of message sge.legacy.house.v1beta.Withdrawal is not mutable")) + case "sge.legacy.house.v1beta.Withdrawal.market_uid": + panic(fmt.Errorf("field market_uid of message sge.legacy.house.v1beta.Withdrawal is not mutable")) + case "sge.legacy.house.v1beta.Withdrawal.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.house.v1beta.Withdrawal is not mutable")) + case "sge.legacy.house.v1beta.Withdrawal.mode": + panic(fmt.Errorf("field mode of message sge.legacy.house.v1beta.Withdrawal is not mutable")) + case "sge.legacy.house.v1beta.Withdrawal.amount": + panic(fmt.Errorf("field amount of message sge.legacy.house.v1beta.Withdrawal is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Withdrawal")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Withdrawal does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Withdrawal) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.house.v1beta.Withdrawal.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Withdrawal.id": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.house.v1beta.Withdrawal.address": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Withdrawal.market_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.house.v1beta.Withdrawal.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.house.v1beta.Withdrawal.mode": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.house.v1beta.Withdrawal.amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.house.v1beta.Withdrawal")) + } + panic(fmt.Errorf("message sge.legacy.house.v1beta.Withdrawal does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Withdrawal) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.house.v1beta.Withdrawal", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Withdrawal) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Withdrawal) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Withdrawal) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Withdrawal) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Withdrawal) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Id != 0 { + n += 1 + runtime.Sov(uint64(x.Id)) + } + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MarketUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.Mode != 0 { + n += 1 + runtime.Sov(uint64(x.Mode)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Withdrawal) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x3a + } + if x.Mode != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Mode)) + i-- + dAtA[i] = 0x30 + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x28 + } + if len(x.MarketUid) > 0 { + i -= len(x.MarketUid) + copy(dAtA[i:], x.MarketUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MarketUid))) + i-- + dAtA[i] = 0x22 + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0x1a + } + if x.Id != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Id)) + i-- + dAtA[i] = 0x10 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Withdrawal) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Withdrawal: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Withdrawal: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + x.Id = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Id |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Mode", wireType) + } + x.Mode = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Mode |= WithdrawalMode(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/house/v1beta/withdraw.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// WithdrawalMode is the enum type for the withdrawal mode. +type WithdrawalMode int32 + +const ( + // invalid + WithdrawalMode_WITHDRAWAL_MODE_UNSPECIFIED WithdrawalMode = 0 + // full + WithdrawalMode_WITHDRAWAL_MODE_FULL WithdrawalMode = 1 + // partial + WithdrawalMode_WITHDRAWAL_MODE_PARTIAL WithdrawalMode = 2 +) + +// Enum value maps for WithdrawalMode. +var ( + WithdrawalMode_name = map[int32]string{ + 0: "WITHDRAWAL_MODE_UNSPECIFIED", + 1: "WITHDRAWAL_MODE_FULL", + 2: "WITHDRAWAL_MODE_PARTIAL", + } + WithdrawalMode_value = map[string]int32{ + "WITHDRAWAL_MODE_UNSPECIFIED": 0, + "WITHDRAWAL_MODE_FULL": 1, + "WITHDRAWAL_MODE_PARTIAL": 2, + } +) + +func (x WithdrawalMode) Enum() *WithdrawalMode { + p := new(WithdrawalMode) + *p = x + return p +} + +func (x WithdrawalMode) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (WithdrawalMode) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_house_v1beta_withdraw_proto_enumTypes[0].Descriptor() +} + +func (WithdrawalMode) Type() protoreflect.EnumType { + return &file_sge_legacy_house_v1beta_withdraw_proto_enumTypes[0] +} + +func (x WithdrawalMode) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use WithdrawalMode.Descriptor instead. +func (WithdrawalMode) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_withdraw_proto_rawDescGZIP(), []int{0} +} + +// Withdrawal represents the withdrawal against a deposit. +type Withdrawal struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the bech32-encoded address of the depositor. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // withdrawal is the withdrawal attempt id. + Id uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"` + // address is the bech32-encoded address of the depositor. + Address string `protobuf:"bytes,3,opt,name=address,proto3" json:"address,omitempty"` + // market_uid is the uid of market against which the deposit is + // being made. + MarketUid string `protobuf:"bytes,4,opt,name=market_uid,proto3" json:"market_uid,omitempty"` + // participation_index is the id corresponding to the book participation + ParticipationIndex uint64 `protobuf:"varint,5,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // mode is the withdrawal mode enum value + Mode WithdrawalMode `protobuf:"varint,6,opt,name=mode,proto3,enum=sge.legacy.house.v1beta.WithdrawalMode" json:"mode,omitempty"` + // amount is the amount being withdrawn. + Amount string `protobuf:"bytes,7,opt,name=amount,proto3" json:"amount,omitempty"` +} + +func (x *Withdrawal) Reset() { + *x = Withdrawal{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_house_v1beta_withdraw_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Withdrawal) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Withdrawal) ProtoMessage() {} + +// Deprecated: Use Withdrawal.ProtoReflect.Descriptor instead. +func (*Withdrawal) Descriptor() ([]byte, []int) { + return file_sge_legacy_house_v1beta_withdraw_proto_rawDescGZIP(), []int{0} +} + +func (x *Withdrawal) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *Withdrawal) GetId() uint64 { + if x != nil { + return x.Id + } + return 0 +} + +func (x *Withdrawal) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *Withdrawal) GetMarketUid() string { + if x != nil { + return x.MarketUid + } + return "" +} + +func (x *Withdrawal) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *Withdrawal) GetMode() WithdrawalMode { + if x != nil { + return x.Mode + } + return WithdrawalMode_WITHDRAWAL_MODE_UNSPECIFIED +} + +func (x *Withdrawal) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +var File_sge_legacy_house_v1beta_withdraw_proto protoreflect.FileDescriptor + +var file_sge_legacy_house_v1beta_withdraw_proto_rawDesc = []byte{ + 0x0a, 0x26, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, 0x6f, 0x75, + 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, + 0x61, 0x77, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x17, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, + 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x22, 0xf5, 0x03, 0x0a, 0x0a, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, + 0x6c, 0x12, 0x44, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x42, 0x2a, 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x72, + 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, + 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x29, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x04, 0x42, 0x19, 0xe2, 0xde, 0x1f, 0x02, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x02, 0x69, + 0x64, 0xf2, 0xde, 0x1f, 0x09, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x69, 0x64, 0x22, 0x52, 0x02, + 0x69, 0x64, 0x12, 0x44, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x2a, 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, + 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x3b, 0x0a, 0x0a, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1b, 0xe2, 0xde, + 0x1f, 0x09, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0a, 0x6d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0a, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x4f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x04, 0x42, 0x1e, 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, + 0x78, 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x4c, 0x0a, 0x04, 0x6d, 0x6f, 0x64, 0x65, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x0e, 0x32, 0x27, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x57, + 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x4d, 0x6f, 0x64, 0x65, 0x42, 0x0f, 0xf2, + 0xde, 0x1f, 0x0b, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, 0x6f, 0x64, 0x65, 0x22, 0x52, 0x04, + 0x6d, 0x6f, 0x64, 0x65, 0x12, 0x46, 0x0a, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x09, 0x42, 0x2e, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, + 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x0d, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x22, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x0c, 0x88, 0xa0, + 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x2a, 0x68, 0x0a, 0x0e, 0x57, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x4d, 0x6f, 0x64, 0x65, 0x12, 0x1f, 0x0a, 0x1b, + 0x57, 0x49, 0x54, 0x48, 0x44, 0x52, 0x41, 0x57, 0x41, 0x4c, 0x5f, 0x4d, 0x4f, 0x44, 0x45, 0x5f, + 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x18, 0x0a, + 0x14, 0x57, 0x49, 0x54, 0x48, 0x44, 0x52, 0x41, 0x57, 0x41, 0x4c, 0x5f, 0x4d, 0x4f, 0x44, 0x45, + 0x5f, 0x46, 0x55, 0x4c, 0x4c, 0x10, 0x01, 0x12, 0x1b, 0x0a, 0x17, 0x57, 0x49, 0x54, 0x48, 0x44, + 0x52, 0x41, 0x57, 0x41, 0x4c, 0x5f, 0x4d, 0x4f, 0x44, 0x45, 0x5f, 0x50, 0x41, 0x52, 0x54, 0x49, + 0x41, 0x4c, 0x10, 0x02, 0x42, 0xef, 0x01, 0x0a, 0x1b, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x42, 0x0d, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, + 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, + 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, + 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x68, 0x6f, + 0x75, 0x73, 0x65, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x48, 0xaa, + 0x02, 0x17, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x48, 0x6f, 0x75, + 0x73, 0x65, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x17, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xe2, 0x02, 0x23, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x5c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1a, 0x53, 0x67, 0x65, 0x3a, + 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x3a, 0x3a, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_house_v1beta_withdraw_proto_rawDescOnce sync.Once + file_sge_legacy_house_v1beta_withdraw_proto_rawDescData = file_sge_legacy_house_v1beta_withdraw_proto_rawDesc +) + +func file_sge_legacy_house_v1beta_withdraw_proto_rawDescGZIP() []byte { + file_sge_legacy_house_v1beta_withdraw_proto_rawDescOnce.Do(func() { + file_sge_legacy_house_v1beta_withdraw_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_house_v1beta_withdraw_proto_rawDescData) + }) + return file_sge_legacy_house_v1beta_withdraw_proto_rawDescData +} + +var file_sge_legacy_house_v1beta_withdraw_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_sge_legacy_house_v1beta_withdraw_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_house_v1beta_withdraw_proto_goTypes = []interface{}{ + (WithdrawalMode)(0), // 0: sge.legacy.house.v1beta.WithdrawalMode + (*Withdrawal)(nil), // 1: sge.legacy.house.v1beta.Withdrawal +} +var file_sge_legacy_house_v1beta_withdraw_proto_depIdxs = []int32{ + 0, // 0: sge.legacy.house.v1beta.Withdrawal.mode:type_name -> sge.legacy.house.v1beta.WithdrawalMode + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_house_v1beta_withdraw_proto_init() } +func file_sge_legacy_house_v1beta_withdraw_proto_init() { + if File_sge_legacy_house_v1beta_withdraw_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_house_v1beta_withdraw_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Withdrawal); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_house_v1beta_withdraw_proto_rawDesc, + NumEnums: 1, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_house_v1beta_withdraw_proto_goTypes, + DependencyIndexes: file_sge_legacy_house_v1beta_withdraw_proto_depIdxs, + EnumInfos: file_sge_legacy_house_v1beta_withdraw_proto_enumTypes, + MessageInfos: file_sge_legacy_house_v1beta_withdraw_proto_msgTypes, + }.Build() + File_sge_legacy_house_v1beta_withdraw_proto = out.File + file_sge_legacy_house_v1beta_withdraw_proto_rawDesc = nil + file_sge_legacy_house_v1beta_withdraw_proto_goTypes = nil + file_sge_legacy_house_v1beta_withdraw_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/module/v1/module.pulsar.go b/api/sge/legacy/market/module/v1/module.pulsar.go new file mode 100644 index 00000000..a6765071 --- /dev/null +++ b/api/sge/legacy/market/module/v1/module.pulsar.go @@ -0,0 +1,656 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_module_v1_module_proto_init() + md_Module = File_sge_legacy_market_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.legacy.market.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.market.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.legacy.market.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.market.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.legacy.market.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.market.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.legacy.market.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.market.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.legacy.market.module.v1.Module is not mutable")) + case "sge.legacy.market.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.legacy.market.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.market.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.legacy.market.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.market.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the market module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_legacy_market_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x28, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x6f, + 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x6d, 0x6f, + 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x6a, 0x0a, 0x06, 0x4d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x12, 0x2c, 0x0a, 0x12, 0x66, 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, + 0x63, 0x74, 0x6f, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x10, 0x66, 0x65, 0x65, 0x43, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, + 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, + 0x14, 0xba, 0xc0, 0x96, 0xda, 0x01, 0x0e, 0x0a, 0x0c, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x6d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x42, 0x84, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, + 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x43, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, + 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, + 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, 0x31, 0xa2, 0x02, 0x04, + 0x53, 0x4c, 0x4d, 0x4d, 0xaa, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, + 0x56, 0x31, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, + 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, + 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1f, 0x53, 0x67, 0x65, + 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_module_v1_module_proto_rawDescOnce sync.Once + file_sge_legacy_market_module_v1_module_proto_rawDescData = file_sge_legacy_market_module_v1_module_proto_rawDesc +) + +func file_sge_legacy_market_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_legacy_market_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_module_v1_module_proto_rawDescData) + }) + return file_sge_legacy_market_module_v1_module_proto_rawDescData +} + +var file_sge_legacy_market_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_market_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.legacy.market.module.v1.Module +} +var file_sge_legacy_market_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_module_v1_module_proto_init() } +func file_sge_legacy_market_module_v1_module_proto_init() { + if File_sge_legacy_market_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_market_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_legacy_market_module_v1_module_proto_msgTypes, + }.Build() + File_sge_legacy_market_module_v1_module_proto = out.File + file_sge_legacy_market_module_v1_module_proto_rawDesc = nil + file_sge_legacy_market_module_v1_module_proto_goTypes = nil + file_sge_legacy_market_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/genesis.pulsar.go b/api/sge/legacy/market/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..a37aaa0e --- /dev/null +++ b/api/sge/legacy/market/v1beta/genesis.pulsar.go @@ -0,0 +1,855 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_2_list)(nil) + +type _GenesisState_2_list struct { + list *[]*Market +} + +func (x *_GenesisState_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Market) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Market) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_2_list) AppendMutable() protoreflect.Value { + v := new(Market) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_2_list) NewElement() protoreflect.Value { + v := new(Market) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor + fd_GenesisState_market_list protoreflect.FieldDescriptor + fd_GenesisState_stats protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_genesis_proto_init() + md_GenesisState = File_sge_legacy_market_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") + fd_GenesisState_market_list = md_GenesisState.Fields().ByName("market_list") + fd_GenesisState_stats = md_GenesisState.Fields().ByName("stats") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } + if len(x.MarketList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_2_list{list: &x.MarketList}) + if !f(fd_GenesisState_market_list, value) { + return + } + } + if x.Stats != nil { + value := protoreflect.ValueOfMessage(x.Stats.ProtoReflect()) + if !f(fd_GenesisState_stats, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.GenesisState.params": + return x.Params != nil + case "sge.legacy.market.v1beta.GenesisState.market_list": + return len(x.MarketList) != 0 + case "sge.legacy.market.v1beta.GenesisState.stats": + return x.Stats != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.GenesisState.params": + x.Params = nil + case "sge.legacy.market.v1beta.GenesisState.market_list": + x.MarketList = nil + case "sge.legacy.market.v1beta.GenesisState.stats": + x.Stats = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.market.v1beta.GenesisState.market_list": + if len(x.MarketList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_2_list{}) + } + listValue := &_GenesisState_2_list{list: &x.MarketList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.market.v1beta.GenesisState.stats": + value := x.Stats + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + case "sge.legacy.market.v1beta.GenesisState.market_list": + lv := value.List() + clv := lv.(*_GenesisState_2_list) + x.MarketList = *clv.list + case "sge.legacy.market.v1beta.GenesisState.stats": + x.Stats = value.Message().Interface().(*MarketStats) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.market.v1beta.GenesisState.market_list": + if x.MarketList == nil { + x.MarketList = []*Market{} + } + value := &_GenesisState_2_list{list: &x.MarketList} + return protoreflect.ValueOfList(value) + case "sge.legacy.market.v1beta.GenesisState.stats": + if x.Stats == nil { + x.Stats = new(MarketStats) + } + return protoreflect.ValueOfMessage(x.Stats.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.market.v1beta.GenesisState.market_list": + list := []*Market{} + return protoreflect.ValueOfList(&_GenesisState_2_list{list: &list}) + case "sge.legacy.market.v1beta.GenesisState.stats": + m := new(MarketStats) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.MarketList) > 0 { + for _, e := range x.MarketList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Stats != nil { + l = options.Size(x.Stats) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Stats != nil { + encoded, err := options.Marshal(x.Stats) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if len(x.MarketList) > 0 { + for iNdEx := len(x.MarketList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.MarketList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MarketList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MarketList = append(x.MarketList, &Market{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.MarketList[len(x.MarketList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Stats", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Stats == nil { + x.Stats = &MarketStats{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Stats); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the market module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params are the parameters of the market module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` + // market_list is the list of markets that are available in the + // chain init. + MarketList []*Market `protobuf:"bytes,2,rep,name=market_list,json=marketList,proto3" json:"market_list,omitempty"` + // stats is the statistics of the markets + Stats *MarketStats `protobuf:"bytes,3,opt,name=stats,proto3" json:"stats,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +func (x *GenesisState) GetMarketList() []*Market { + if x != nil { + return x.MarketList + } + return nil +} + +func (x *GenesisState) GetStats() *MarketStats { + if x != nil { + return x.Stats + } + return nil +} + +var File_sge_legacy_market_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x26, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x73, + 0x69, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, + 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, + 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xda, 0x01, 0x0a, + 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x3e, 0x0a, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, + 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x47, 0x0a, + 0x0b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0a, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x41, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x73, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x42, 0xf5, 0x01, 0x0a, 0x1c, 0x63, 0x6f, + 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, + 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4d, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_genesis_proto_rawDescData = file_sge_legacy_market_v1beta_genesis_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_genesis_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_genesis_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_market_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.legacy.market.v1beta.GenesisState + (*Params)(nil), // 1: sge.legacy.market.v1beta.Params + (*Market)(nil), // 2: sge.legacy.market.v1beta.Market + (*MarketStats)(nil), // 3: sge.legacy.market.v1beta.MarketStats +} +var file_sge_legacy_market_v1beta_genesis_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.market.v1beta.GenesisState.params:type_name -> sge.legacy.market.v1beta.Params + 2, // 1: sge.legacy.market.v1beta.GenesisState.market_list:type_name -> sge.legacy.market.v1beta.Market + 3, // 2: sge.legacy.market.v1beta.GenesisState.stats:type_name -> sge.legacy.market.v1beta.MarketStats + 3, // [3:3] is the sub-list for method output_type + 3, // [3:3] is the sub-list for method input_type + 3, // [3:3] is the sub-list for extension type_name + 3, // [3:3] is the sub-list for extension extendee + 0, // [0:3] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_genesis_proto_init() } +func file_sge_legacy_market_v1beta_genesis_proto_init() { + if File_sge_legacy_market_v1beta_genesis_proto != nil { + return + } + file_sge_legacy_market_v1beta_market_proto_init() + file_sge_legacy_market_v1beta_params_proto_init() + file_sge_legacy_market_v1beta_stats_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_market_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_legacy_market_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_genesis_proto = out.File + file_sge_legacy_market_v1beta_genesis_proto_rawDesc = nil + file_sge_legacy_market_v1beta_genesis_proto_goTypes = nil + file_sge_legacy_market_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/market.pulsar.go b/api/sge/legacy/market/v1beta/market.pulsar.go new file mode 100644 index 00000000..9e6fc325 --- /dev/null +++ b/api/sge/legacy/market/v1beta/market.pulsar.go @@ -0,0 +1,1425 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_Market_4_list)(nil) + +type _Market_4_list struct { + list *[]*Odds +} + +func (x *_Market_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_Market_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_Market_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Odds) + (*x.list)[i] = concreteValue +} + +func (x *_Market_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Odds) + *x.list = append(*x.list, concreteValue) +} + +func (x *_Market_4_list) AppendMutable() protoreflect.Value { + v := new(Odds) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_Market_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_Market_4_list) NewElement() protoreflect.Value { + v := new(Odds) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_Market_4_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_Market_5_list)(nil) + +type _Market_5_list struct { + list *[]string +} + +func (x *_Market_5_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_Market_5_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_Market_5_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_Market_5_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_Market_5_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message Market at list field WinnerOddsUids as it is not of Message kind")) +} + +func (x *_Market_5_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_Market_5_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_Market_5_list) IsValid() bool { + return x.list != nil +} + +var ( + md_Market protoreflect.MessageDescriptor + fd_Market_uid protoreflect.FieldDescriptor + fd_Market_start_ts protoreflect.FieldDescriptor + fd_Market_end_ts protoreflect.FieldDescriptor + fd_Market_odds protoreflect.FieldDescriptor + fd_Market_winner_odds_uids protoreflect.FieldDescriptor + fd_Market_status protoreflect.FieldDescriptor + fd_Market_resolution_ts protoreflect.FieldDescriptor + fd_Market_creator protoreflect.FieldDescriptor + fd_Market_meta protoreflect.FieldDescriptor + fd_Market_book_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_market_proto_init() + md_Market = File_sge_legacy_market_v1beta_market_proto.Messages().ByName("Market") + fd_Market_uid = md_Market.Fields().ByName("uid") + fd_Market_start_ts = md_Market.Fields().ByName("start_ts") + fd_Market_end_ts = md_Market.Fields().ByName("end_ts") + fd_Market_odds = md_Market.Fields().ByName("odds") + fd_Market_winner_odds_uids = md_Market.Fields().ByName("winner_odds_uids") + fd_Market_status = md_Market.Fields().ByName("status") + fd_Market_resolution_ts = md_Market.Fields().ByName("resolution_ts") + fd_Market_creator = md_Market.Fields().ByName("creator") + fd_Market_meta = md_Market.Fields().ByName("meta") + fd_Market_book_uid = md_Market.Fields().ByName("book_uid") +} + +var _ protoreflect.Message = (*fastReflection_Market)(nil) + +type fastReflection_Market Market + +func (x *Market) ProtoReflect() protoreflect.Message { + return (*fastReflection_Market)(x) +} + +func (x *Market) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_market_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Market_messageType fastReflection_Market_messageType +var _ protoreflect.MessageType = fastReflection_Market_messageType{} + +type fastReflection_Market_messageType struct{} + +func (x fastReflection_Market_messageType) Zero() protoreflect.Message { + return (*fastReflection_Market)(nil) +} +func (x fastReflection_Market_messageType) New() protoreflect.Message { + return new(fastReflection_Market) +} +func (x fastReflection_Market_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Market +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Market) Descriptor() protoreflect.MessageDescriptor { + return md_Market +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Market) Type() protoreflect.MessageType { + return _fastReflection_Market_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Market) New() protoreflect.Message { + return new(fastReflection_Market) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Market) Interface() protoreflect.ProtoMessage { + return (*Market)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Market) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_Market_uid, value) { + return + } + } + if x.StartTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.StartTs) + if !f(fd_Market_start_ts, value) { + return + } + } + if x.EndTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.EndTs) + if !f(fd_Market_end_ts, value) { + return + } + } + if len(x.Odds) != 0 { + value := protoreflect.ValueOfList(&_Market_4_list{list: &x.Odds}) + if !f(fd_Market_odds, value) { + return + } + } + if len(x.WinnerOddsUids) != 0 { + value := protoreflect.ValueOfList(&_Market_5_list{list: &x.WinnerOddsUids}) + if !f(fd_Market_winner_odds_uids, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_Market_status, value) { + return + } + } + if x.ResolutionTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.ResolutionTs) + if !f(fd_Market_resolution_ts, value) { + return + } + } + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_Market_creator, value) { + return + } + } + if x.Meta != "" { + value := protoreflect.ValueOfString(x.Meta) + if !f(fd_Market_meta, value) { + return + } + } + if x.BookUid != "" { + value := protoreflect.ValueOfString(x.BookUid) + if !f(fd_Market_book_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Market) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Market.uid": + return x.Uid != "" + case "sge.legacy.market.v1beta.Market.start_ts": + return x.StartTs != uint64(0) + case "sge.legacy.market.v1beta.Market.end_ts": + return x.EndTs != uint64(0) + case "sge.legacy.market.v1beta.Market.odds": + return len(x.Odds) != 0 + case "sge.legacy.market.v1beta.Market.winner_odds_uids": + return len(x.WinnerOddsUids) != 0 + case "sge.legacy.market.v1beta.Market.status": + return x.Status != 0 + case "sge.legacy.market.v1beta.Market.resolution_ts": + return x.ResolutionTs != uint64(0) + case "sge.legacy.market.v1beta.Market.creator": + return x.Creator != "" + case "sge.legacy.market.v1beta.Market.meta": + return x.Meta != "" + case "sge.legacy.market.v1beta.Market.book_uid": + return x.BookUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Market")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Market does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Market) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Market.uid": + x.Uid = "" + case "sge.legacy.market.v1beta.Market.start_ts": + x.StartTs = uint64(0) + case "sge.legacy.market.v1beta.Market.end_ts": + x.EndTs = uint64(0) + case "sge.legacy.market.v1beta.Market.odds": + x.Odds = nil + case "sge.legacy.market.v1beta.Market.winner_odds_uids": + x.WinnerOddsUids = nil + case "sge.legacy.market.v1beta.Market.status": + x.Status = 0 + case "sge.legacy.market.v1beta.Market.resolution_ts": + x.ResolutionTs = uint64(0) + case "sge.legacy.market.v1beta.Market.creator": + x.Creator = "" + case "sge.legacy.market.v1beta.Market.meta": + x.Meta = "" + case "sge.legacy.market.v1beta.Market.book_uid": + x.BookUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Market")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Market does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Market) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.Market.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.Market.start_ts": + value := x.StartTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.Market.end_ts": + value := x.EndTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.Market.odds": + if len(x.Odds) == 0 { + return protoreflect.ValueOfList(&_Market_4_list{}) + } + listValue := &_Market_4_list{list: &x.Odds} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.market.v1beta.Market.winner_odds_uids": + if len(x.WinnerOddsUids) == 0 { + return protoreflect.ValueOfList(&_Market_5_list{}) + } + listValue := &_Market_5_list{list: &x.WinnerOddsUids} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.market.v1beta.Market.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.market.v1beta.Market.resolution_ts": + value := x.ResolutionTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.Market.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.Market.meta": + value := x.Meta + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.Market.book_uid": + value := x.BookUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Market")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Market does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Market) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Market.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.market.v1beta.Market.start_ts": + x.StartTs = value.Uint() + case "sge.legacy.market.v1beta.Market.end_ts": + x.EndTs = value.Uint() + case "sge.legacy.market.v1beta.Market.odds": + lv := value.List() + clv := lv.(*_Market_4_list) + x.Odds = *clv.list + case "sge.legacy.market.v1beta.Market.winner_odds_uids": + lv := value.List() + clv := lv.(*_Market_5_list) + x.WinnerOddsUids = *clv.list + case "sge.legacy.market.v1beta.Market.status": + x.Status = (MarketStatus)(value.Enum()) + case "sge.legacy.market.v1beta.Market.resolution_ts": + x.ResolutionTs = value.Uint() + case "sge.legacy.market.v1beta.Market.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.market.v1beta.Market.meta": + x.Meta = value.Interface().(string) + case "sge.legacy.market.v1beta.Market.book_uid": + x.BookUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Market")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Market does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Market) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Market.odds": + if x.Odds == nil { + x.Odds = []*Odds{} + } + value := &_Market_4_list{list: &x.Odds} + return protoreflect.ValueOfList(value) + case "sge.legacy.market.v1beta.Market.winner_odds_uids": + if x.WinnerOddsUids == nil { + x.WinnerOddsUids = []string{} + } + value := &_Market_5_list{list: &x.WinnerOddsUids} + return protoreflect.ValueOfList(value) + case "sge.legacy.market.v1beta.Market.uid": + panic(fmt.Errorf("field uid of message sge.legacy.market.v1beta.Market is not mutable")) + case "sge.legacy.market.v1beta.Market.start_ts": + panic(fmt.Errorf("field start_ts of message sge.legacy.market.v1beta.Market is not mutable")) + case "sge.legacy.market.v1beta.Market.end_ts": + panic(fmt.Errorf("field end_ts of message sge.legacy.market.v1beta.Market is not mutable")) + case "sge.legacy.market.v1beta.Market.status": + panic(fmt.Errorf("field status of message sge.legacy.market.v1beta.Market is not mutable")) + case "sge.legacy.market.v1beta.Market.resolution_ts": + panic(fmt.Errorf("field resolution_ts of message sge.legacy.market.v1beta.Market is not mutable")) + case "sge.legacy.market.v1beta.Market.creator": + panic(fmt.Errorf("field creator of message sge.legacy.market.v1beta.Market is not mutable")) + case "sge.legacy.market.v1beta.Market.meta": + panic(fmt.Errorf("field meta of message sge.legacy.market.v1beta.Market is not mutable")) + case "sge.legacy.market.v1beta.Market.book_uid": + panic(fmt.Errorf("field book_uid of message sge.legacy.market.v1beta.Market is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Market")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Market does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Market) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Market.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.Market.start_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.Market.end_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.Market.odds": + list := []*Odds{} + return protoreflect.ValueOfList(&_Market_4_list{list: &list}) + case "sge.legacy.market.v1beta.Market.winner_odds_uids": + list := []string{} + return protoreflect.ValueOfList(&_Market_5_list{list: &list}) + case "sge.legacy.market.v1beta.Market.status": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.market.v1beta.Market.resolution_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.Market.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.Market.meta": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.Market.book_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Market")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Market does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Market) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.Market", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Market) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Market) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Market) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Market) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Market) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.StartTs != 0 { + n += 1 + runtime.Sov(uint64(x.StartTs)) + } + if x.EndTs != 0 { + n += 1 + runtime.Sov(uint64(x.EndTs)) + } + if len(x.Odds) > 0 { + for _, e := range x.Odds { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.WinnerOddsUids) > 0 { + for _, s := range x.WinnerOddsUids { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.ResolutionTs != 0 { + n += 1 + runtime.Sov(uint64(x.ResolutionTs)) + } + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Meta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.BookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Market) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.BookUid) > 0 { + i -= len(x.BookUid) + copy(dAtA[i:], x.BookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BookUid))) + i-- + dAtA[i] = 0x52 + } + if len(x.Meta) > 0 { + i -= len(x.Meta) + copy(dAtA[i:], x.Meta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Meta))) + i-- + dAtA[i] = 0x4a + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0x42 + } + if x.ResolutionTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ResolutionTs)) + i-- + dAtA[i] = 0x38 + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x30 + } + if len(x.WinnerOddsUids) > 0 { + for iNdEx := len(x.WinnerOddsUids) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.WinnerOddsUids[iNdEx]) + copy(dAtA[i:], x.WinnerOddsUids[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.WinnerOddsUids[iNdEx]))) + i-- + dAtA[i] = 0x2a + } + } + if len(x.Odds) > 0 { + for iNdEx := len(x.Odds) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Odds[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if x.EndTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.EndTs)) + i-- + dAtA[i] = 0x18 + } + if x.StartTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.StartTs)) + i-- + dAtA[i] = 0x10 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Market) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Market: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Market: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field StartTs", wireType) + } + x.StartTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.StartTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EndTs", wireType) + } + x.EndTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.EndTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Odds", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Odds = append(x.Odds, &Odds{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Odds[len(x.Odds)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WinnerOddsUids", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.WinnerOddsUids = append(x.WinnerOddsUids, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 6: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= MarketStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ResolutionTs", wireType) + } + x.ResolutionTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ResolutionTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 9: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Meta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 10: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/market.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MarketStatus is the market status enumeration +type MarketStatus int32 + +const ( + // unspecified market + MarketStatus_MARKET_STATUS_UNSPECIFIED MarketStatus = 0 + // market is active + MarketStatus_MARKET_STATUS_ACTIVE MarketStatus = 1 + // market is inactive + MarketStatus_MARKET_STATUS_INACTIVE MarketStatus = 2 + // market is canceled + MarketStatus_MARKET_STATUS_CANCELED MarketStatus = 3 + // market is aborted + MarketStatus_MARKET_STATUS_ABORTED MarketStatus = 4 + // result of the market is declared + MarketStatus_MARKET_STATUS_RESULT_DECLARED MarketStatus = 5 +) + +// Enum value maps for MarketStatus. +var ( + MarketStatus_name = map[int32]string{ + 0: "MARKET_STATUS_UNSPECIFIED", + 1: "MARKET_STATUS_ACTIVE", + 2: "MARKET_STATUS_INACTIVE", + 3: "MARKET_STATUS_CANCELED", + 4: "MARKET_STATUS_ABORTED", + 5: "MARKET_STATUS_RESULT_DECLARED", + } + MarketStatus_value = map[string]int32{ + "MARKET_STATUS_UNSPECIFIED": 0, + "MARKET_STATUS_ACTIVE": 1, + "MARKET_STATUS_INACTIVE": 2, + "MARKET_STATUS_CANCELED": 3, + "MARKET_STATUS_ABORTED": 4, + "MARKET_STATUS_RESULT_DECLARED": 5, + } +) + +func (x MarketStatus) Enum() *MarketStatus { + p := new(MarketStatus) + *p = x + return p +} + +func (x MarketStatus) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (MarketStatus) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_market_v1beta_market_proto_enumTypes[0].Descriptor() +} + +func (MarketStatus) Type() protoreflect.EnumType { + return &file_sge_legacy_market_v1beta_market_proto_enumTypes[0] +} + +func (x MarketStatus) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use MarketStatus.Descriptor instead. +func (MarketStatus) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_market_proto_rawDescGZIP(), []int{0} +} + +// Market is the representation of the market to be stored in +// the market state. +type Market struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier of the market. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // start_ts is the start timestamp of the market. + StartTs uint64 `protobuf:"varint,2,opt,name=start_ts,proto3" json:"start_ts,omitempty"` + // end_ts is the end timestamp of the market. + EndTs uint64 `protobuf:"varint,3,opt,name=end_ts,proto3" json:"end_ts,omitempty"` + // odds is the list of odds of the market. + Odds []*Odds `protobuf:"bytes,4,rep,name=odds,proto3" json:"odds,omitempty"` + // winner_odds_uids is the list of winner odds universal unique identifiers. + WinnerOddsUids []string `protobuf:"bytes,5,rep,name=winner_odds_uids,proto3" json:"winner_odds_uids,omitempty"` + // status is the current status of the market. + Status MarketStatus `protobuf:"varint,6,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` + // resolution_ts is the timestamp of the resolution of market. + ResolutionTs uint64 `protobuf:"varint,7,opt,name=resolution_ts,proto3" json:"resolution_ts,omitempty"` + // creator is the address of the creator of market. + Creator string `protobuf:"bytes,8,opt,name=creator,proto3" json:"creator,omitempty"` + // meta contains human-readable metadata of the market. + Meta string `protobuf:"bytes,9,opt,name=meta,proto3" json:"meta,omitempty"` + // book_uid is the unique identifier corresponding to the book + BookUid string `protobuf:"bytes,10,opt,name=book_uid,proto3" json:"book_uid,omitempty"` +} + +func (x *Market) Reset() { + *x = Market{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_market_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Market) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Market) ProtoMessage() {} + +// Deprecated: Use Market.ProtoReflect.Descriptor instead. +func (*Market) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_market_proto_rawDescGZIP(), []int{0} +} + +func (x *Market) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *Market) GetStartTs() uint64 { + if x != nil { + return x.StartTs + } + return 0 +} + +func (x *Market) GetEndTs() uint64 { + if x != nil { + return x.EndTs + } + return 0 +} + +func (x *Market) GetOdds() []*Odds { + if x != nil { + return x.Odds + } + return nil +} + +func (x *Market) GetWinnerOddsUids() []string { + if x != nil { + return x.WinnerOddsUids + } + return nil +} + +func (x *Market) GetStatus() MarketStatus { + if x != nil { + return x.Status + } + return MarketStatus_MARKET_STATUS_UNSPECIFIED +} + +func (x *Market) GetResolutionTs() uint64 { + if x != nil { + return x.ResolutionTs + } + return 0 +} + +func (x *Market) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *Market) GetMeta() string { + if x != nil { + return x.Meta + } + return "" +} + +func (x *Market) GetBookUid() string { + if x != nil { + return x.BookUid + } + return "" +} + +var File_sge_legacy_market_v1beta_market_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_market_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x23, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6f, 0x64, 0x64, + 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x9a, 0x04, 0x0a, 0x06, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, + 0x03, 0x75, 0x69, 0x64, 0x12, 0x33, 0x0a, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x17, 0xe2, 0xde, 0x1f, 0x07, 0x53, 0x74, 0x61, 0x72, + 0x74, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x52, + 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x12, 0x2b, 0x0a, 0x06, 0x65, 0x6e, 0x64, + 0x5f, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x13, 0xe2, 0xde, 0x1f, 0x05, 0x45, + 0x6e, 0x64, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x06, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x52, 0x06, + 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x12, 0x32, 0x0a, 0x04, 0x6f, 0x64, 0x64, 0x73, 0x18, 0x04, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x4f, 0x64, 0x64, 0x73, 0x52, 0x04, 0x6f, 0x64, 0x64, 0x73, 0x12, 0x52, 0x0a, 0x10, 0x77, 0x69, + 0x6e, 0x6e, 0x65, 0x72, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x73, 0x18, 0x05, + 0x20, 0x03, 0x28, 0x09, 0x42, 0x26, 0xe2, 0xde, 0x1f, 0x0e, 0x57, 0x69, 0x6e, 0x6e, 0x65, 0x72, + 0x4f, 0x64, 0x64, 0x73, 0x55, 0x49, 0x44, 0x73, 0xea, 0xde, 0x1f, 0x10, 0x77, 0x69, 0x6e, 0x6e, + 0x65, 0x72, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x73, 0x52, 0x10, 0x77, 0x69, + 0x6e, 0x6e, 0x65, 0x72, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x73, 0x12, 0x3e, + 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x26, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x47, + 0x0a, 0x0d, 0x72, 0x65, 0x73, 0x6f, 0x6c, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x73, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x04, 0x42, 0x21, 0xe2, 0xde, 0x1f, 0x0c, 0x52, 0x65, 0x73, 0x6f, 0x6c, + 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x0d, 0x72, 0x65, 0x73, 0x6f, 0x6c, + 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x73, 0x52, 0x0d, 0x72, 0x65, 0x73, 0x6f, 0x6c, 0x75, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x73, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, + 0x6f, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, + 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x12, 0x0a, 0x04, 0x6d, + 0x65, 0x74, 0x61, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x12, + 0x33, 0x0a, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x17, 0xe2, 0xde, 0x1f, 0x07, 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x49, 0x44, 0xea, 0xde, + 0x1f, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x08, 0x62, 0x6f, 0x6f, 0x6b, + 0x5f, 0x75, 0x69, 0x64, 0x2a, 0xbd, 0x01, 0x0a, 0x0c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x53, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1d, 0x0a, 0x19, 0x4d, 0x41, 0x52, 0x4b, 0x45, 0x54, 0x5f, + 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, + 0x45, 0x44, 0x10, 0x00, 0x12, 0x18, 0x0a, 0x14, 0x4d, 0x41, 0x52, 0x4b, 0x45, 0x54, 0x5f, 0x53, + 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, 0x43, 0x54, 0x49, 0x56, 0x45, 0x10, 0x01, 0x12, 0x1a, + 0x0a, 0x16, 0x4d, 0x41, 0x52, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, + 0x49, 0x4e, 0x41, 0x43, 0x54, 0x49, 0x56, 0x45, 0x10, 0x02, 0x12, 0x1a, 0x0a, 0x16, 0x4d, 0x41, + 0x52, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x43, 0x41, 0x4e, 0x43, + 0x45, 0x4c, 0x45, 0x44, 0x10, 0x03, 0x12, 0x19, 0x0a, 0x15, 0x4d, 0x41, 0x52, 0x4b, 0x45, 0x54, + 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, 0x42, 0x4f, 0x52, 0x54, 0x45, 0x44, 0x10, + 0x04, 0x12, 0x21, 0x0a, 0x1d, 0x4d, 0x41, 0x52, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x54, 0x41, 0x54, + 0x55, 0x53, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x44, 0x45, 0x43, 0x4c, 0x41, 0x52, + 0x45, 0x44, 0x10, 0x05, 0x42, 0xf4, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4d, + 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, + 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, + 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_v1beta_market_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_market_proto_rawDescData = file_sge_legacy_market_v1beta_market_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_market_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_market_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_market_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_market_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_market_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_market_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_sge_legacy_market_v1beta_market_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_market_v1beta_market_proto_goTypes = []interface{}{ + (MarketStatus)(0), // 0: sge.legacy.market.v1beta.MarketStatus + (*Market)(nil), // 1: sge.legacy.market.v1beta.Market + (*Odds)(nil), // 2: sge.legacy.market.v1beta.Odds +} +var file_sge_legacy_market_v1beta_market_proto_depIdxs = []int32{ + 2, // 0: sge.legacy.market.v1beta.Market.odds:type_name -> sge.legacy.market.v1beta.Odds + 0, // 1: sge.legacy.market.v1beta.Market.status:type_name -> sge.legacy.market.v1beta.MarketStatus + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_market_proto_init() } +func file_sge_legacy_market_v1beta_market_proto_init() { + if File_sge_legacy_market_v1beta_market_proto != nil { + return + } + file_sge_legacy_market_v1beta_odds_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_market_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Market); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_market_proto_rawDesc, + NumEnums: 1, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_market_v1beta_market_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_market_proto_depIdxs, + EnumInfos: file_sge_legacy_market_v1beta_market_proto_enumTypes, + MessageInfos: file_sge_legacy_market_v1beta_market_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_market_proto = out.File + file_sge_legacy_market_v1beta_market_proto_rawDesc = nil + file_sge_legacy_market_v1beta_market_proto_goTypes = nil + file_sge_legacy_market_v1beta_market_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/odds.pulsar.go b/api/sge/legacy/market/v1beta/odds.pulsar.go new file mode 100644 index 00000000..935d348e --- /dev/null +++ b/api/sge/legacy/market/v1beta/odds.pulsar.go @@ -0,0 +1,650 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Odds protoreflect.MessageDescriptor + fd_Odds_uid protoreflect.FieldDescriptor + fd_Odds_meta protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_odds_proto_init() + md_Odds = File_sge_legacy_market_v1beta_odds_proto.Messages().ByName("Odds") + fd_Odds_uid = md_Odds.Fields().ByName("uid") + fd_Odds_meta = md_Odds.Fields().ByName("meta") +} + +var _ protoreflect.Message = (*fastReflection_Odds)(nil) + +type fastReflection_Odds Odds + +func (x *Odds) ProtoReflect() protoreflect.Message { + return (*fastReflection_Odds)(x) +} + +func (x *Odds) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_odds_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Odds_messageType fastReflection_Odds_messageType +var _ protoreflect.MessageType = fastReflection_Odds_messageType{} + +type fastReflection_Odds_messageType struct{} + +func (x fastReflection_Odds_messageType) Zero() protoreflect.Message { + return (*fastReflection_Odds)(nil) +} +func (x fastReflection_Odds_messageType) New() protoreflect.Message { + return new(fastReflection_Odds) +} +func (x fastReflection_Odds_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Odds +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Odds) Descriptor() protoreflect.MessageDescriptor { + return md_Odds +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Odds) Type() protoreflect.MessageType { + return _fastReflection_Odds_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Odds) New() protoreflect.Message { + return new(fastReflection_Odds) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Odds) Interface() protoreflect.ProtoMessage { + return (*Odds)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Odds) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_Odds_uid, value) { + return + } + } + if x.Meta != "" { + value := protoreflect.ValueOfString(x.Meta) + if !f(fd_Odds_meta, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Odds) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Odds.uid": + return x.Uid != "" + case "sge.legacy.market.v1beta.Odds.meta": + return x.Meta != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Odds")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Odds does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Odds) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Odds.uid": + x.Uid = "" + case "sge.legacy.market.v1beta.Odds.meta": + x.Meta = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Odds")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Odds does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Odds) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.Odds.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.Odds.meta": + value := x.Meta + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Odds")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Odds does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Odds) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Odds.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.market.v1beta.Odds.meta": + x.Meta = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Odds")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Odds does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Odds) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Odds.uid": + panic(fmt.Errorf("field uid of message sge.legacy.market.v1beta.Odds is not mutable")) + case "sge.legacy.market.v1beta.Odds.meta": + panic(fmt.Errorf("field meta of message sge.legacy.market.v1beta.Odds is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Odds")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Odds does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Odds) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.Odds.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.Odds.meta": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Odds")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Odds does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Odds) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.Odds", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Odds) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Odds) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Odds) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Odds) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Odds) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Meta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Odds) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Meta) > 0 { + i -= len(x.Meta) + copy(dAtA[i:], x.Meta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Meta))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Odds) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Odds: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Odds: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Meta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/odds.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Odds is a representation of market odds. +type Odds struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier of the odds. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // meta contains any human-readable metadata of the odds. + Meta string `protobuf:"bytes,2,opt,name=meta,proto3" json:"meta,omitempty"` +} + +func (x *Odds) Reset() { + *x = Odds{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_odds_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Odds) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Odds) ProtoMessage() {} + +// Deprecated: Use Odds.ProtoReflect.Descriptor instead. +func (*Odds) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_odds_proto_rawDescGZIP(), []int{0} +} + +func (x *Odds) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *Odds) GetMeta() string { + if x != nil { + return x.Meta + } + return "" +} + +var File_sge_legacy_market_v1beta_odds_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_odds_proto_rawDesc = []byte{ + 0x0a, 0x23, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6f, 0x64, 0x64, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, + 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x3c, 0x0a, 0x04, 0x4f, 0x64, 0x64, 0x73, 0x12, 0x20, 0x0a, + 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, + 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, + 0x12, 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, + 0x65, 0x74, 0x61, 0x42, 0xf2, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x42, 0x09, 0x4f, 0x64, 0x64, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, + 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, + 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, + 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4d, 0xaa, 0x02, 0x18, + 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, + 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, + 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_v1beta_odds_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_odds_proto_rawDescData = file_sge_legacy_market_v1beta_odds_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_odds_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_odds_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_odds_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_odds_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_odds_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_odds_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_market_v1beta_odds_proto_goTypes = []interface{}{ + (*Odds)(nil), // 0: sge.legacy.market.v1beta.Odds +} +var file_sge_legacy_market_v1beta_odds_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_odds_proto_init() } +func file_sge_legacy_market_v1beta_odds_proto_init() { + if File_sge_legacy_market_v1beta_odds_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_odds_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Odds); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_odds_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_market_v1beta_odds_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_odds_proto_depIdxs, + MessageInfos: file_sge_legacy_market_v1beta_odds_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_odds_proto = out.File + file_sge_legacy_market_v1beta_odds_proto_rawDesc = nil + file_sge_legacy_market_v1beta_odds_proto_goTypes = nil + file_sge_legacy_market_v1beta_odds_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/params.pulsar.go b/api/sge/legacy/market/v1beta/params.pulsar.go new file mode 100644 index 00000000..75c8a017 --- /dev/null +++ b/api/sge/legacy/market/v1beta/params.pulsar.go @@ -0,0 +1,502 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Params protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_params_proto_init() + md_Params = File_sge_legacy_market_v1beta_params_proto.Messages().ByName("Params") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params defines the parameters for the module. +// It contains bet constraints associated to a market. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +var File_sge_legacy_market_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, + 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x0e, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xf4, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x3b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, + 0x53, 0x4c, 0x4d, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, + 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_v1beta_params_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_params_proto_rawDescData = file_sge_legacy_market_v1beta_params_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_params_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_params_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_market_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.legacy.market.v1beta.Params +} +var file_sge_legacy_market_v1beta_params_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_params_proto_init() } +func file_sge_legacy_market_v1beta_params_proto_init() { + if File_sge_legacy_market_v1beta_params_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_market_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_legacy_market_v1beta_params_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_params_proto = out.File + file_sge_legacy_market_v1beta_params_proto_rawDesc = nil + file_sge_legacy_market_v1beta_params_proto_goTypes = nil + file_sge_legacy_market_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/query.pulsar.go b/api/sge/legacy/market/v1beta/query.pulsar.go new file mode 100644 index 00000000..1e509801 --- /dev/null +++ b/api/sge/legacy/market/v1beta/query.pulsar.go @@ -0,0 +1,4376 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + v1beta1 "cosmossdk.io/api/cosmos/base/query/v1beta1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryMarketRequest protoreflect.MessageDescriptor + fd_QueryMarketRequest_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryMarketRequest = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryMarketRequest") + fd_QueryMarketRequest_uid = md_QueryMarketRequest.Fields().ByName("uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryMarketRequest)(nil) + +type fastReflection_QueryMarketRequest QueryMarketRequest + +func (x *QueryMarketRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryMarketRequest)(x) +} + +func (x *QueryMarketRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryMarketRequest_messageType fastReflection_QueryMarketRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryMarketRequest_messageType{} + +type fastReflection_QueryMarketRequest_messageType struct{} + +func (x fastReflection_QueryMarketRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryMarketRequest)(nil) +} +func (x fastReflection_QueryMarketRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryMarketRequest) +} +func (x fastReflection_QueryMarketRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryMarketRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryMarketRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryMarketRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryMarketRequest) New() protoreflect.Message { + return new(fastReflection_QueryMarketRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryMarketRequest) Interface() protoreflect.ProtoMessage { + return (*QueryMarketRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryMarketRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_QueryMarketRequest_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryMarketRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketRequest.uid": + return x.Uid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketRequest.uid": + x.Uid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryMarketRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.QueryMarketRequest.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketRequest.uid": + x.Uid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketRequest.uid": + panic(fmt.Errorf("field uid of message sge.legacy.market.v1beta.QueryMarketRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryMarketRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketRequest.uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryMarketRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryMarketRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryMarketRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryMarketRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryMarketRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryMarketRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryMarketResponse protoreflect.MessageDescriptor + fd_QueryMarketResponse_market protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryMarketResponse = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryMarketResponse") + fd_QueryMarketResponse_market = md_QueryMarketResponse.Fields().ByName("market") +} + +var _ protoreflect.Message = (*fastReflection_QueryMarketResponse)(nil) + +type fastReflection_QueryMarketResponse QueryMarketResponse + +func (x *QueryMarketResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryMarketResponse)(x) +} + +func (x *QueryMarketResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryMarketResponse_messageType fastReflection_QueryMarketResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryMarketResponse_messageType{} + +type fastReflection_QueryMarketResponse_messageType struct{} + +func (x fastReflection_QueryMarketResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryMarketResponse)(nil) +} +func (x fastReflection_QueryMarketResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryMarketResponse) +} +func (x fastReflection_QueryMarketResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryMarketResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryMarketResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryMarketResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryMarketResponse) New() protoreflect.Message { + return new(fastReflection_QueryMarketResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryMarketResponse) Interface() protoreflect.ProtoMessage { + return (*QueryMarketResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryMarketResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Market != nil { + value := protoreflect.ValueOfMessage(x.Market.ProtoReflect()) + if !f(fd_QueryMarketResponse_market, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryMarketResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketResponse.market": + return x.Market != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketResponse.market": + x.Market = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryMarketResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.QueryMarketResponse.market": + value := x.Market + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketResponse.market": + x.Market = value.Message().Interface().(*Market) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketResponse.market": + if x.Market == nil { + x.Market = new(Market) + } + return protoreflect.ValueOfMessage(x.Market.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryMarketResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketResponse.market": + m := new(Market) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryMarketResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryMarketResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryMarketResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryMarketResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryMarketResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryMarketResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Market != nil { + l = options.Size(x.Market) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Market != nil { + encoded, err := options.Marshal(x.Market) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Market", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Market == nil { + x.Market = &Market{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Market); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryMarketsRequest protoreflect.MessageDescriptor + fd_QueryMarketsRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryMarketsRequest = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryMarketsRequest") + fd_QueryMarketsRequest_pagination = md_QueryMarketsRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryMarketsRequest)(nil) + +type fastReflection_QueryMarketsRequest QueryMarketsRequest + +func (x *QueryMarketsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryMarketsRequest)(x) +} + +func (x *QueryMarketsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryMarketsRequest_messageType fastReflection_QueryMarketsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryMarketsRequest_messageType{} + +type fastReflection_QueryMarketsRequest_messageType struct{} + +func (x fastReflection_QueryMarketsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryMarketsRequest)(nil) +} +func (x fastReflection_QueryMarketsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryMarketsRequest) +} +func (x fastReflection_QueryMarketsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryMarketsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryMarketsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryMarketsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryMarketsRequest) New() protoreflect.Message { + return new(fastReflection_QueryMarketsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryMarketsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryMarketsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryMarketsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryMarketsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryMarketsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryMarketsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryMarketsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryMarketsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryMarketsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryMarketsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryMarketsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryMarketsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryMarketsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryMarketsResponse_1_list)(nil) + +type _QueryMarketsResponse_1_list struct { + list *[]*Market +} + +func (x *_QueryMarketsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryMarketsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryMarketsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Market) + (*x.list)[i] = concreteValue +} + +func (x *_QueryMarketsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Market) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryMarketsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Market) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryMarketsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryMarketsResponse_1_list) NewElement() protoreflect.Value { + v := new(Market) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryMarketsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryMarketsResponse protoreflect.MessageDescriptor + fd_QueryMarketsResponse_market protoreflect.FieldDescriptor + fd_QueryMarketsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryMarketsResponse = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryMarketsResponse") + fd_QueryMarketsResponse_market = md_QueryMarketsResponse.Fields().ByName("market") + fd_QueryMarketsResponse_pagination = md_QueryMarketsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryMarketsResponse)(nil) + +type fastReflection_QueryMarketsResponse QueryMarketsResponse + +func (x *QueryMarketsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryMarketsResponse)(x) +} + +func (x *QueryMarketsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryMarketsResponse_messageType fastReflection_QueryMarketsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryMarketsResponse_messageType{} + +type fastReflection_QueryMarketsResponse_messageType struct{} + +func (x fastReflection_QueryMarketsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryMarketsResponse)(nil) +} +func (x fastReflection_QueryMarketsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryMarketsResponse) +} +func (x fastReflection_QueryMarketsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryMarketsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryMarketsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryMarketsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryMarketsResponse) New() protoreflect.Message { + return new(fastReflection_QueryMarketsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryMarketsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryMarketsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryMarketsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Market) != 0 { + value := protoreflect.ValueOfList(&_QueryMarketsResponse_1_list{list: &x.Market}) + if !f(fd_QueryMarketsResponse_market, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryMarketsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryMarketsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsResponse.market": + return len(x.Market) != 0 + case "sge.legacy.market.v1beta.QueryMarketsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsResponse.market": + x.Market = nil + case "sge.legacy.market.v1beta.QueryMarketsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryMarketsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsResponse.market": + if len(x.Market) == 0 { + return protoreflect.ValueOfList(&_QueryMarketsResponse_1_list{}) + } + listValue := &_QueryMarketsResponse_1_list{list: &x.Market} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.market.v1beta.QueryMarketsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsResponse.market": + lv := value.List() + clv := lv.(*_QueryMarketsResponse_1_list) + x.Market = *clv.list + case "sge.legacy.market.v1beta.QueryMarketsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsResponse.market": + if x.Market == nil { + x.Market = []*Market{} + } + value := &_QueryMarketsResponse_1_list{list: &x.Market} + return protoreflect.ValueOfList(value) + case "sge.legacy.market.v1beta.QueryMarketsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryMarketsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsResponse.market": + list := []*Market{} + return protoreflect.ValueOfList(&_QueryMarketsResponse_1_list{list: &list}) + case "sge.legacy.market.v1beta.QueryMarketsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryMarketsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryMarketsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryMarketsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryMarketsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryMarketsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryMarketsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Market) > 0 { + for _, e := range x.Market { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Market) > 0 { + for iNdEx := len(x.Market) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Market[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Market", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Market = append(x.Market, &Market{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Market[len(x.Market)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryMarketsByUIDsRequest_1_list)(nil) + +type _QueryMarketsByUIDsRequest_1_list struct { + list *[]string +} + +func (x *_QueryMarketsByUIDsRequest_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryMarketsByUIDsRequest_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_QueryMarketsByUIDsRequest_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_QueryMarketsByUIDsRequest_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryMarketsByUIDsRequest_1_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message QueryMarketsByUIDsRequest at list field Uids as it is not of Message kind")) +} + +func (x *_QueryMarketsByUIDsRequest_1_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_QueryMarketsByUIDsRequest_1_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_QueryMarketsByUIDsRequest_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryMarketsByUIDsRequest protoreflect.MessageDescriptor + fd_QueryMarketsByUIDsRequest_uids protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryMarketsByUIDsRequest = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryMarketsByUIDsRequest") + fd_QueryMarketsByUIDsRequest_uids = md_QueryMarketsByUIDsRequest.Fields().ByName("uids") +} + +var _ protoreflect.Message = (*fastReflection_QueryMarketsByUIDsRequest)(nil) + +type fastReflection_QueryMarketsByUIDsRequest QueryMarketsByUIDsRequest + +func (x *QueryMarketsByUIDsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryMarketsByUIDsRequest)(x) +} + +func (x *QueryMarketsByUIDsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryMarketsByUIDsRequest_messageType fastReflection_QueryMarketsByUIDsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryMarketsByUIDsRequest_messageType{} + +type fastReflection_QueryMarketsByUIDsRequest_messageType struct{} + +func (x fastReflection_QueryMarketsByUIDsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryMarketsByUIDsRequest)(nil) +} +func (x fastReflection_QueryMarketsByUIDsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryMarketsByUIDsRequest) +} +func (x fastReflection_QueryMarketsByUIDsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsByUIDsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryMarketsByUIDsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsByUIDsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryMarketsByUIDsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryMarketsByUIDsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryMarketsByUIDsRequest) New() protoreflect.Message { + return new(fastReflection_QueryMarketsByUIDsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryMarketsByUIDsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryMarketsByUIDsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryMarketsByUIDsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Uids) != 0 { + value := protoreflect.ValueOfList(&_QueryMarketsByUIDsRequest_1_list{list: &x.Uids}) + if !f(fd_QueryMarketsByUIDsRequest_uids, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryMarketsByUIDsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsRequest.uids": + return len(x.Uids) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsRequest.uids": + x.Uids = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryMarketsByUIDsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsRequest.uids": + if len(x.Uids) == 0 { + return protoreflect.ValueOfList(&_QueryMarketsByUIDsRequest_1_list{}) + } + listValue := &_QueryMarketsByUIDsRequest_1_list{list: &x.Uids} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsRequest.uids": + lv := value.List() + clv := lv.(*_QueryMarketsByUIDsRequest_1_list) + x.Uids = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsRequest.uids": + if x.Uids == nil { + x.Uids = []string{} + } + value := &_QueryMarketsByUIDsRequest_1_list{list: &x.Uids} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryMarketsByUIDsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsRequest.uids": + list := []string{} + return protoreflect.ValueOfList(&_QueryMarketsByUIDsRequest_1_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsRequest")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryMarketsByUIDsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryMarketsByUIDsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryMarketsByUIDsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryMarketsByUIDsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryMarketsByUIDsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryMarketsByUIDsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Uids) > 0 { + for _, s := range x.Uids { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsByUIDsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Uids) > 0 { + for iNdEx := len(x.Uids) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.Uids[iNdEx]) + copy(dAtA[i:], x.Uids[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uids[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsByUIDsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsByUIDsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsByUIDsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uids", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uids = append(x.Uids, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryMarketsByUIDsResponse_1_list)(nil) + +type _QueryMarketsByUIDsResponse_1_list struct { + list *[]*Market +} + +func (x *_QueryMarketsByUIDsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryMarketsByUIDsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryMarketsByUIDsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Market) + (*x.list)[i] = concreteValue +} + +func (x *_QueryMarketsByUIDsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Market) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryMarketsByUIDsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Market) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryMarketsByUIDsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryMarketsByUIDsResponse_1_list) NewElement() protoreflect.Value { + v := new(Market) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryMarketsByUIDsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_QueryMarketsByUIDsResponse_2_list)(nil) + +type _QueryMarketsByUIDsResponse_2_list struct { + list *[]string +} + +func (x *_QueryMarketsByUIDsResponse_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryMarketsByUIDsResponse_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_QueryMarketsByUIDsResponse_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_QueryMarketsByUIDsResponse_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryMarketsByUIDsResponse_2_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message QueryMarketsByUIDsResponse at list field FailedMarkets as it is not of Message kind")) +} + +func (x *_QueryMarketsByUIDsResponse_2_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_QueryMarketsByUIDsResponse_2_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_QueryMarketsByUIDsResponse_2_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryMarketsByUIDsResponse protoreflect.MessageDescriptor + fd_QueryMarketsByUIDsResponse_markets protoreflect.FieldDescriptor + fd_QueryMarketsByUIDsResponse_failed_markets protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_query_proto_init() + md_QueryMarketsByUIDsResponse = File_sge_legacy_market_v1beta_query_proto.Messages().ByName("QueryMarketsByUIDsResponse") + fd_QueryMarketsByUIDsResponse_markets = md_QueryMarketsByUIDsResponse.Fields().ByName("markets") + fd_QueryMarketsByUIDsResponse_failed_markets = md_QueryMarketsByUIDsResponse.Fields().ByName("failed_markets") +} + +var _ protoreflect.Message = (*fastReflection_QueryMarketsByUIDsResponse)(nil) + +type fastReflection_QueryMarketsByUIDsResponse QueryMarketsByUIDsResponse + +func (x *QueryMarketsByUIDsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryMarketsByUIDsResponse)(x) +} + +func (x *QueryMarketsByUIDsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryMarketsByUIDsResponse_messageType fastReflection_QueryMarketsByUIDsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryMarketsByUIDsResponse_messageType{} + +type fastReflection_QueryMarketsByUIDsResponse_messageType struct{} + +func (x fastReflection_QueryMarketsByUIDsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryMarketsByUIDsResponse)(nil) +} +func (x fastReflection_QueryMarketsByUIDsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryMarketsByUIDsResponse) +} +func (x fastReflection_QueryMarketsByUIDsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsByUIDsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryMarketsByUIDsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryMarketsByUIDsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryMarketsByUIDsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryMarketsByUIDsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryMarketsByUIDsResponse) New() protoreflect.Message { + return new(fastReflection_QueryMarketsByUIDsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryMarketsByUIDsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryMarketsByUIDsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryMarketsByUIDsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Markets) != 0 { + value := protoreflect.ValueOfList(&_QueryMarketsByUIDsResponse_1_list{list: &x.Markets}) + if !f(fd_QueryMarketsByUIDsResponse_markets, value) { + return + } + } + if len(x.FailedMarkets) != 0 { + value := protoreflect.ValueOfList(&_QueryMarketsByUIDsResponse_2_list{list: &x.FailedMarkets}) + if !f(fd_QueryMarketsByUIDsResponse_failed_markets, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryMarketsByUIDsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.markets": + return len(x.Markets) != 0 + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.failed_markets": + return len(x.FailedMarkets) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.markets": + x.Markets = nil + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.failed_markets": + x.FailedMarkets = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryMarketsByUIDsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.markets": + if len(x.Markets) == 0 { + return protoreflect.ValueOfList(&_QueryMarketsByUIDsResponse_1_list{}) + } + listValue := &_QueryMarketsByUIDsResponse_1_list{list: &x.Markets} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.failed_markets": + if len(x.FailedMarkets) == 0 { + return protoreflect.ValueOfList(&_QueryMarketsByUIDsResponse_2_list{}) + } + listValue := &_QueryMarketsByUIDsResponse_2_list{list: &x.FailedMarkets} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.markets": + lv := value.List() + clv := lv.(*_QueryMarketsByUIDsResponse_1_list) + x.Markets = *clv.list + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.failed_markets": + lv := value.List() + clv := lv.(*_QueryMarketsByUIDsResponse_2_list) + x.FailedMarkets = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.markets": + if x.Markets == nil { + x.Markets = []*Market{} + } + value := &_QueryMarketsByUIDsResponse_1_list{list: &x.Markets} + return protoreflect.ValueOfList(value) + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.failed_markets": + if x.FailedMarkets == nil { + x.FailedMarkets = []string{} + } + value := &_QueryMarketsByUIDsResponse_2_list{list: &x.FailedMarkets} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryMarketsByUIDsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.markets": + list := []*Market{} + return protoreflect.ValueOfList(&_QueryMarketsByUIDsResponse_1_list{list: &list}) + case "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.failed_markets": + list := []string{} + return protoreflect.ValueOfList(&_QueryMarketsByUIDsResponse_2_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.QueryMarketsByUIDsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryMarketsByUIDsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.QueryMarketsByUIDsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryMarketsByUIDsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryMarketsByUIDsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryMarketsByUIDsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryMarketsByUIDsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryMarketsByUIDsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Markets) > 0 { + for _, e := range x.Markets { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.FailedMarkets) > 0 { + for _, s := range x.FailedMarkets { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsByUIDsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.FailedMarkets) > 0 { + for iNdEx := len(x.FailedMarkets) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.FailedMarkets[iNdEx]) + copy(dAtA[i:], x.FailedMarkets[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FailedMarkets[iNdEx]))) + i-- + dAtA[i] = 0x12 + } + } + if len(x.Markets) > 0 { + for iNdEx := len(x.Markets) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Markets[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryMarketsByUIDsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsByUIDsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryMarketsByUIDsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Markets", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Markets = append(x.Markets, &Market{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Markets[len(x.Markets)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FailedMarkets", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FailedMarkets = append(x.FailedMarkets, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is the request type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is the response type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params hold all the parameters of this module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QueryMarketRequest is the request type for the Query/{uid} RPC method. +// Query/Market RPC method. +type QueryMarketRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` +} + +func (x *QueryMarketRequest) Reset() { + *x = QueryMarketRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryMarketRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryMarketRequest) ProtoMessage() {} + +// Deprecated: Use QueryMarketRequest.ProtoReflect.Descriptor instead. +func (*QueryMarketRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +func (x *QueryMarketRequest) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +// QueryMarketRequest is the response type for the Query/{uid} RPC method. +// Query/Market RPC method. +type QueryMarketResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Market *Market `protobuf:"bytes,1,opt,name=market,proto3" json:"market,omitempty"` +} + +func (x *QueryMarketResponse) Reset() { + *x = QueryMarketResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryMarketResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryMarketResponse) ProtoMessage() {} + +// Deprecated: Use QueryMarketResponse.ProtoReflect.Descriptor instead. +func (*QueryMarketResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QueryMarketResponse) GetMarket() *Market { + if x != nil { + return x.Market + } + return nil +} + +// QueryMarketsRequest is the request type for the Query/markets RPC +// method. +// Query/Markets RPC method. +type QueryMarketsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryMarketsRequest) Reset() { + *x = QueryMarketsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryMarketsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryMarketsRequest) ProtoMessage() {} + +// Deprecated: Use QueryMarketsRequest.ProtoReflect.Descriptor instead. +func (*QueryMarketsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{4} +} + +func (x *QueryMarketsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryMarketsResponse is the response type for the Query/markets RPC +// method. +// Query/Markets RPC method. +type QueryMarketsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Market []*Market `protobuf:"bytes,1,rep,name=market,proto3" json:"market,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryMarketsResponse) Reset() { + *x = QueryMarketsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryMarketsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryMarketsResponse) ProtoMessage() {} + +// Deprecated: Use QueryMarketsResponse.ProtoReflect.Descriptor instead. +func (*QueryMarketsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{5} +} + +func (x *QueryMarketsResponse) GetMarket() []*Market { + if x != nil { + return x.Market + } + return nil +} + +func (x *QueryMarketsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryMarketsByUIDsRequest is the request type for the +// Query/MarketsByUIDs RPC method. +type QueryMarketsByUIDsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Uids []string `protobuf:"bytes,1,rep,name=uids,proto3" json:"uids,omitempty"` +} + +func (x *QueryMarketsByUIDsRequest) Reset() { + *x = QueryMarketsByUIDsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryMarketsByUIDsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryMarketsByUIDsRequest) ProtoMessage() {} + +// Deprecated: Use QueryMarketsByUIDsRequest.ProtoReflect.Descriptor instead. +func (*QueryMarketsByUIDsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{6} +} + +func (x *QueryMarketsByUIDsRequest) GetUids() []string { + if x != nil { + return x.Uids + } + return nil +} + +// QueryMarketsByUIDsResponse is the response type for the +// Query/MarketsByUIDs RPC method. +type QueryMarketsByUIDsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Markets []*Market `protobuf:"bytes,1,rep,name=markets,proto3" json:"markets,omitempty"` + FailedMarkets []string `protobuf:"bytes,2,rep,name=failed_markets,json=failedMarkets,proto3" json:"failed_markets,omitempty"` +} + +func (x *QueryMarketsByUIDsResponse) Reset() { + *x = QueryMarketsByUIDsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryMarketsByUIDsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryMarketsByUIDsResponse) ProtoMessage() {} + +// Deprecated: Use QueryMarketsByUIDsResponse.ProtoReflect.Descriptor instead. +func (*QueryMarketsByUIDsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_query_proto_rawDescGZIP(), []int{7} +} + +func (x *QueryMarketsByUIDsResponse) GetMarkets() []*Market { + if x != nil { + return x.Markets + } + return nil +} + +func (x *QueryMarketsByUIDsResponse) GetFailedMarkets() []string { + if x != nil { + return x.FailedMarkets + } + return nil +} + +var File_sge_legacy_market_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x1a, 0x2a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, + 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x14, + 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x22, 0x55, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x26, 0x0a, 0x12, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, + 0x75, 0x69, 0x64, 0x22, 0x55, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x06, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x06, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x22, 0x5d, 0x0a, 0x13, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, + 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, + 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9f, 0x01, 0x0a, 0x14, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x06, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x18, 0x01, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x39, 0x0a, 0x19, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x04, 0x75, 0x69, 0x64, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x42, 0x08, 0xea, 0xde, 0x1f, 0x04, 0x75, 0x69, 0x64, 0x73, + 0x52, 0x04, 0x75, 0x69, 0x64, 0x73, 0x22, 0x85, 0x01, 0x0a, 0x1a, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x07, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x12, 0x25, 0x0a, 0x0e, 0x66, 0x61, 0x69, 0x6c, 0x65, + 0x64, 0x5f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, + 0x0d, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x32, 0xbf, + 0x04, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x81, 0x01, 0x0a, 0x06, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x12, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x1a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x14, 0x12, 0x12, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x80, 0x01, 0x0a, + 0x06, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x12, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x19, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x13, 0x12, 0x11, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x7b, 0x75, 0x69, 0x64, 0x7d, 0x12, + 0x85, 0x01, 0x0a, 0x07, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x12, 0x2d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1b, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x15, 0x12, 0x13, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x12, 0xa6, 0x01, 0x0a, 0x0d, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, 0x73, 0x12, 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x34, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x73, 0x42, 0x79, 0x55, 0x49, 0x44, 0x73, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x12, 0x22, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x73, 0x5f, 0x62, 0x79, 0x5f, 0x75, 0x69, 0x64, 0x73, 0x2f, 0x7b, 0x75, 0x69, 0x64, 0x73, 0x7d, + 0x42, 0xf3, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, + 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4d, 0xaa, 0x02, 0x18, 0x53, 0x67, + 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_v1beta_query_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_query_proto_rawDescData = file_sge_legacy_market_v1beta_query_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_query_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_query_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 8) +var file_sge_legacy_market_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.legacy.market.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.legacy.market.v1beta.QueryParamsResponse + (*QueryMarketRequest)(nil), // 2: sge.legacy.market.v1beta.QueryMarketRequest + (*QueryMarketResponse)(nil), // 3: sge.legacy.market.v1beta.QueryMarketResponse + (*QueryMarketsRequest)(nil), // 4: sge.legacy.market.v1beta.QueryMarketsRequest + (*QueryMarketsResponse)(nil), // 5: sge.legacy.market.v1beta.QueryMarketsResponse + (*QueryMarketsByUIDsRequest)(nil), // 6: sge.legacy.market.v1beta.QueryMarketsByUIDsRequest + (*QueryMarketsByUIDsResponse)(nil), // 7: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse + (*Params)(nil), // 8: sge.legacy.market.v1beta.Params + (*Market)(nil), // 9: sge.legacy.market.v1beta.Market + (*v1beta1.PageRequest)(nil), // 10: cosmos.base.query.v1beta1.PageRequest + (*v1beta1.PageResponse)(nil), // 11: cosmos.base.query.v1beta1.PageResponse +} +var file_sge_legacy_market_v1beta_query_proto_depIdxs = []int32{ + 8, // 0: sge.legacy.market.v1beta.QueryParamsResponse.params:type_name -> sge.legacy.market.v1beta.Params + 9, // 1: sge.legacy.market.v1beta.QueryMarketResponse.market:type_name -> sge.legacy.market.v1beta.Market + 10, // 2: sge.legacy.market.v1beta.QueryMarketsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 9, // 3: sge.legacy.market.v1beta.QueryMarketsResponse.market:type_name -> sge.legacy.market.v1beta.Market + 11, // 4: sge.legacy.market.v1beta.QueryMarketsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 9, // 5: sge.legacy.market.v1beta.QueryMarketsByUIDsResponse.markets:type_name -> sge.legacy.market.v1beta.Market + 0, // 6: sge.legacy.market.v1beta.Query.Params:input_type -> sge.legacy.market.v1beta.QueryParamsRequest + 2, // 7: sge.legacy.market.v1beta.Query.Market:input_type -> sge.legacy.market.v1beta.QueryMarketRequest + 4, // 8: sge.legacy.market.v1beta.Query.Markets:input_type -> sge.legacy.market.v1beta.QueryMarketsRequest + 6, // 9: sge.legacy.market.v1beta.Query.MarketsByUIDs:input_type -> sge.legacy.market.v1beta.QueryMarketsByUIDsRequest + 1, // 10: sge.legacy.market.v1beta.Query.Params:output_type -> sge.legacy.market.v1beta.QueryParamsResponse + 3, // 11: sge.legacy.market.v1beta.Query.Market:output_type -> sge.legacy.market.v1beta.QueryMarketResponse + 5, // 12: sge.legacy.market.v1beta.Query.Markets:output_type -> sge.legacy.market.v1beta.QueryMarketsResponse + 7, // 13: sge.legacy.market.v1beta.Query.MarketsByUIDs:output_type -> sge.legacy.market.v1beta.QueryMarketsByUIDsResponse + 10, // [10:14] is the sub-list for method output_type + 6, // [6:10] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_query_proto_init() } +func file_sge_legacy_market_v1beta_query_proto_init() { + if File_sge_legacy_market_v1beta_query_proto != nil { + return + } + file_sge_legacy_market_v1beta_market_proto_init() + file_sge_legacy_market_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryMarketRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryMarketResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryMarketsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryMarketsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryMarketsByUIDsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryMarketsByUIDsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 8, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_market_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_legacy_market_v1beta_query_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_query_proto = out.File + file_sge_legacy_market_v1beta_query_proto_rawDesc = nil + file_sge_legacy_market_v1beta_query_proto_goTypes = nil + file_sge_legacy_market_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/query_grpc.pb.go b/api/sge/legacy/market/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..0c3bd157 --- /dev/null +++ b/api/sge/legacy/market/v1beta/query_grpc.pb.go @@ -0,0 +1,228 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/market/v1beta/query.proto + +package marketv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Params_FullMethodName = "/sge.legacy.market.v1beta.Query/Params" + Query_Market_FullMethodName = "/sge.legacy.market.v1beta.Query/Market" + Query_Markets_FullMethodName = "/sge.legacy.market.v1beta.Query/Markets" + Query_MarketsByUIDs_FullMethodName = "/sge.legacy.market.v1beta.Query/MarketsByUIDs" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Params queries the parameters of the module. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) + // Queries a market by uid. + Market(ctx context.Context, in *QueryMarketRequest, opts ...grpc.CallOption) (*QueryMarketResponse, error) + // Queries a list of all the markets + Markets(ctx context.Context, in *QueryMarketsRequest, opts ...grpc.CallOption) (*QueryMarketsResponse, error) + // Queries a list of markets by UIDs. + MarketsByUIDs(ctx context.Context, in *QueryMarketsByUIDsRequest, opts ...grpc.CallOption) (*QueryMarketsByUIDsResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Market(ctx context.Context, in *QueryMarketRequest, opts ...grpc.CallOption) (*QueryMarketResponse, error) { + out := new(QueryMarketResponse) + err := c.cc.Invoke(ctx, Query_Market_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Markets(ctx context.Context, in *QueryMarketsRequest, opts ...grpc.CallOption) (*QueryMarketsResponse, error) { + out := new(QueryMarketsResponse) + err := c.cc.Invoke(ctx, Query_Markets_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) MarketsByUIDs(ctx context.Context, in *QueryMarketsByUIDsRequest, opts ...grpc.CallOption) (*QueryMarketsByUIDsResponse, error) { + out := new(QueryMarketsByUIDsResponse) + err := c.cc.Invoke(ctx, Query_MarketsByUIDs_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Params queries the parameters of the module. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + // Queries a market by uid. + Market(context.Context, *QueryMarketRequest) (*QueryMarketResponse, error) + // Queries a list of all the markets + Markets(context.Context, *QueryMarketsRequest) (*QueryMarketsResponse, error) + // Queries a list of markets by UIDs. + MarketsByUIDs(context.Context, *QueryMarketsByUIDsRequest) (*QueryMarketsByUIDsResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) Market(context.Context, *QueryMarketRequest) (*QueryMarketResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Market not implemented") +} +func (UnimplementedQueryServer) Markets(context.Context, *QueryMarketsRequest) (*QueryMarketsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Markets not implemented") +} +func (UnimplementedQueryServer) MarketsByUIDs(context.Context, *QueryMarketsByUIDsRequest) (*QueryMarketsByUIDsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method MarketsByUIDs not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Market_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryMarketRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Market(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Market_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Market(ctx, req.(*QueryMarketRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Markets_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryMarketsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Markets(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Markets_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Markets(ctx, req.(*QueryMarketsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_MarketsByUIDs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryMarketsByUIDsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).MarketsByUIDs(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_MarketsByUIDs_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).MarketsByUIDs(ctx, req.(*QueryMarketsByUIDsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.market.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + { + MethodName: "Market", + Handler: _Query_Market_Handler, + }, + { + MethodName: "Markets", + Handler: _Query_Markets_Handler, + }, + { + MethodName: "MarketsByUIDs", + Handler: _Query_MarketsByUIDs_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/market/v1beta/query.proto", +} diff --git a/api/sge/legacy/market/v1beta/stats.pulsar.go b/api/sge/legacy/market/v1beta/stats.pulsar.go new file mode 100644 index 00000000..a3f52bc0 --- /dev/null +++ b/api/sge/legacy/market/v1beta/stats.pulsar.go @@ -0,0 +1,636 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_MarketStats_1_list)(nil) + +type _MarketStats_1_list struct { + list *[]string +} + +func (x *_MarketStats_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_MarketStats_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_MarketStats_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_MarketStats_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_MarketStats_1_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message MarketStats at list field ResolvedUnsettled as it is not of Message kind")) +} + +func (x *_MarketStats_1_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_MarketStats_1_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_MarketStats_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_MarketStats protoreflect.MessageDescriptor + fd_MarketStats_resolved_unsettled protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_stats_proto_init() + md_MarketStats = File_sge_legacy_market_v1beta_stats_proto.Messages().ByName("MarketStats") + fd_MarketStats_resolved_unsettled = md_MarketStats.Fields().ByName("resolved_unsettled") +} + +var _ protoreflect.Message = (*fastReflection_MarketStats)(nil) + +type fastReflection_MarketStats MarketStats + +func (x *MarketStats) ProtoReflect() protoreflect.Message { + return (*fastReflection_MarketStats)(x) +} + +func (x *MarketStats) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_stats_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MarketStats_messageType fastReflection_MarketStats_messageType +var _ protoreflect.MessageType = fastReflection_MarketStats_messageType{} + +type fastReflection_MarketStats_messageType struct{} + +func (x fastReflection_MarketStats_messageType) Zero() protoreflect.Message { + return (*fastReflection_MarketStats)(nil) +} +func (x fastReflection_MarketStats_messageType) New() protoreflect.Message { + return new(fastReflection_MarketStats) +} +func (x fastReflection_MarketStats_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MarketStats +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MarketStats) Descriptor() protoreflect.MessageDescriptor { + return md_MarketStats +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MarketStats) Type() protoreflect.MessageType { + return _fastReflection_MarketStats_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MarketStats) New() protoreflect.Message { + return new(fastReflection_MarketStats) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MarketStats) Interface() protoreflect.ProtoMessage { + return (*MarketStats)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MarketStats) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.ResolvedUnsettled) != 0 { + value := protoreflect.ValueOfList(&_MarketStats_1_list{list: &x.ResolvedUnsettled}) + if !f(fd_MarketStats_resolved_unsettled, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MarketStats) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketStats.resolved_unsettled": + return len(x.ResolvedUnsettled) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketStats")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketStats does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketStats) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketStats.resolved_unsettled": + x.ResolvedUnsettled = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketStats")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketStats does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MarketStats) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MarketStats.resolved_unsettled": + if len(x.ResolvedUnsettled) == 0 { + return protoreflect.ValueOfList(&_MarketStats_1_list{}) + } + listValue := &_MarketStats_1_list{list: &x.ResolvedUnsettled} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketStats")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketStats does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketStats) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketStats.resolved_unsettled": + lv := value.List() + clv := lv.(*_MarketStats_1_list) + x.ResolvedUnsettled = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketStats")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketStats does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketStats) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketStats.resolved_unsettled": + if x.ResolvedUnsettled == nil { + x.ResolvedUnsettled = []string{} + } + value := &_MarketStats_1_list{list: &x.ResolvedUnsettled} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketStats")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketStats does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MarketStats) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketStats.resolved_unsettled": + list := []string{} + return protoreflect.ValueOfList(&_MarketStats_1_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketStats")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketStats does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MarketStats) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MarketStats", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MarketStats) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketStats) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MarketStats) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MarketStats) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MarketStats) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.ResolvedUnsettled) > 0 { + for _, s := range x.ResolvedUnsettled { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MarketStats) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.ResolvedUnsettled) > 0 { + for iNdEx := len(x.ResolvedUnsettled) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.ResolvedUnsettled[iNdEx]) + copy(dAtA[i:], x.ResolvedUnsettled[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ResolvedUnsettled[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MarketStats) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketStats: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketStats: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ResolvedUnsettled", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ResolvedUnsettled = append(x.ResolvedUnsettled, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/stats.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MarketStats holds statistics of the market +type MarketStats struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // resolved_unsettled is the list of universal unique identifiers + // of resolved markets that have unsettled bets + ResolvedUnsettled []string `protobuf:"bytes,1,rep,name=resolved_unsettled,json=resolvedUnsettled,proto3" json:"resolved_unsettled,omitempty"` +} + +func (x *MarketStats) Reset() { + *x = MarketStats{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_stats_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MarketStats) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MarketStats) ProtoMessage() {} + +// Deprecated: Use MarketStats.ProtoReflect.Descriptor instead. +func (*MarketStats) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_stats_proto_rawDescGZIP(), []int{0} +} + +func (x *MarketStats) GetResolvedUnsettled() []string { + if x != nil { + return x.ResolvedUnsettled + } + return nil +} + +var File_sge_legacy_market_v1beta_stats_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_stats_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x22, 0x3c, 0x0a, 0x0b, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, + 0x2d, 0x0a, 0x12, 0x72, 0x65, 0x73, 0x6f, 0x6c, 0x76, 0x65, 0x64, 0x5f, 0x75, 0x6e, 0x73, 0x65, + 0x74, 0x74, 0x6c, 0x65, 0x64, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, 0x72, 0x65, 0x73, + 0x6f, 0x6c, 0x76, 0x65, 0x64, 0x55, 0x6e, 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x42, 0xf3, + 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, + 0x0a, 0x53, 0x74, 0x61, 0x74, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, + 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, + 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, + 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4d, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, + 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_v1beta_stats_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_stats_proto_rawDescData = file_sge_legacy_market_v1beta_stats_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_stats_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_stats_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_stats_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_stats_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_stats_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_stats_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_market_v1beta_stats_proto_goTypes = []interface{}{ + (*MarketStats)(nil), // 0: sge.legacy.market.v1beta.MarketStats +} +var file_sge_legacy_market_v1beta_stats_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_stats_proto_init() } +func file_sge_legacy_market_v1beta_stats_proto_init() { + if File_sge_legacy_market_v1beta_stats_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_stats_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MarketStats); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_stats_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_market_v1beta_stats_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_stats_proto_depIdxs, + MessageInfos: file_sge_legacy_market_v1beta_stats_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_stats_proto = out.File + file_sge_legacy_market_v1beta_stats_proto_rawDesc = nil + file_sge_legacy_market_v1beta_stats_proto_goTypes = nil + file_sge_legacy_market_v1beta_stats_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/ticket.pulsar.go b/api/sge/legacy/market/v1beta/ticket.pulsar.go new file mode 100644 index 00000000..462e7765 --- /dev/null +++ b/api/sge/legacy/market/v1beta/ticket.pulsar.go @@ -0,0 +1,2388 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_MarketAddTicketPayload_4_list)(nil) + +type _MarketAddTicketPayload_4_list struct { + list *[]*Odds +} + +func (x *_MarketAddTicketPayload_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_MarketAddTicketPayload_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_MarketAddTicketPayload_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Odds) + (*x.list)[i] = concreteValue +} + +func (x *_MarketAddTicketPayload_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Odds) + *x.list = append(*x.list, concreteValue) +} + +func (x *_MarketAddTicketPayload_4_list) AppendMutable() protoreflect.Value { + v := new(Odds) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_MarketAddTicketPayload_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_MarketAddTicketPayload_4_list) NewElement() protoreflect.Value { + v := new(Odds) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_MarketAddTicketPayload_4_list) IsValid() bool { + return x.list != nil +} + +var ( + md_MarketAddTicketPayload protoreflect.MessageDescriptor + fd_MarketAddTicketPayload_uid protoreflect.FieldDescriptor + fd_MarketAddTicketPayload_start_ts protoreflect.FieldDescriptor + fd_MarketAddTicketPayload_end_ts protoreflect.FieldDescriptor + fd_MarketAddTicketPayload_odds protoreflect.FieldDescriptor + fd_MarketAddTicketPayload_status protoreflect.FieldDescriptor + fd_MarketAddTicketPayload_meta protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_ticket_proto_init() + md_MarketAddTicketPayload = File_sge_legacy_market_v1beta_ticket_proto.Messages().ByName("MarketAddTicketPayload") + fd_MarketAddTicketPayload_uid = md_MarketAddTicketPayload.Fields().ByName("uid") + fd_MarketAddTicketPayload_start_ts = md_MarketAddTicketPayload.Fields().ByName("start_ts") + fd_MarketAddTicketPayload_end_ts = md_MarketAddTicketPayload.Fields().ByName("end_ts") + fd_MarketAddTicketPayload_odds = md_MarketAddTicketPayload.Fields().ByName("odds") + fd_MarketAddTicketPayload_status = md_MarketAddTicketPayload.Fields().ByName("status") + fd_MarketAddTicketPayload_meta = md_MarketAddTicketPayload.Fields().ByName("meta") +} + +var _ protoreflect.Message = (*fastReflection_MarketAddTicketPayload)(nil) + +type fastReflection_MarketAddTicketPayload MarketAddTicketPayload + +func (x *MarketAddTicketPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_MarketAddTicketPayload)(x) +} + +func (x *MarketAddTicketPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_ticket_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MarketAddTicketPayload_messageType fastReflection_MarketAddTicketPayload_messageType +var _ protoreflect.MessageType = fastReflection_MarketAddTicketPayload_messageType{} + +type fastReflection_MarketAddTicketPayload_messageType struct{} + +func (x fastReflection_MarketAddTicketPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_MarketAddTicketPayload)(nil) +} +func (x fastReflection_MarketAddTicketPayload_messageType) New() protoreflect.Message { + return new(fastReflection_MarketAddTicketPayload) +} +func (x fastReflection_MarketAddTicketPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MarketAddTicketPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MarketAddTicketPayload) Descriptor() protoreflect.MessageDescriptor { + return md_MarketAddTicketPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MarketAddTicketPayload) Type() protoreflect.MessageType { + return _fastReflection_MarketAddTicketPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MarketAddTicketPayload) New() protoreflect.Message { + return new(fastReflection_MarketAddTicketPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MarketAddTicketPayload) Interface() protoreflect.ProtoMessage { + return (*MarketAddTicketPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MarketAddTicketPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MarketAddTicketPayload_uid, value) { + return + } + } + if x.StartTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.StartTs) + if !f(fd_MarketAddTicketPayload_start_ts, value) { + return + } + } + if x.EndTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.EndTs) + if !f(fd_MarketAddTicketPayload_end_ts, value) { + return + } + } + if len(x.Odds) != 0 { + value := protoreflect.ValueOfList(&_MarketAddTicketPayload_4_list{list: &x.Odds}) + if !f(fd_MarketAddTicketPayload_odds, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_MarketAddTicketPayload_status, value) { + return + } + } + if x.Meta != "" { + value := protoreflect.ValueOfString(x.Meta) + if !f(fd_MarketAddTicketPayload_meta, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MarketAddTicketPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketAddTicketPayload.uid": + return x.Uid != "" + case "sge.legacy.market.v1beta.MarketAddTicketPayload.start_ts": + return x.StartTs != uint64(0) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.end_ts": + return x.EndTs != uint64(0) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.odds": + return len(x.Odds) != 0 + case "sge.legacy.market.v1beta.MarketAddTicketPayload.status": + return x.Status != 0 + case "sge.legacy.market.v1beta.MarketAddTicketPayload.meta": + return x.Meta != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketAddTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketAddTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketAddTicketPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketAddTicketPayload.uid": + x.Uid = "" + case "sge.legacy.market.v1beta.MarketAddTicketPayload.start_ts": + x.StartTs = uint64(0) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.end_ts": + x.EndTs = uint64(0) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.odds": + x.Odds = nil + case "sge.legacy.market.v1beta.MarketAddTicketPayload.status": + x.Status = 0 + case "sge.legacy.market.v1beta.MarketAddTicketPayload.meta": + x.Meta = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketAddTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketAddTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MarketAddTicketPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MarketAddTicketPayload.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.start_ts": + value := x.StartTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.end_ts": + value := x.EndTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.odds": + if len(x.Odds) == 0 { + return protoreflect.ValueOfList(&_MarketAddTicketPayload_4_list{}) + } + listValue := &_MarketAddTicketPayload_4_list{list: &x.Odds} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.meta": + value := x.Meta + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketAddTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketAddTicketPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketAddTicketPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketAddTicketPayload.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.start_ts": + x.StartTs = value.Uint() + case "sge.legacy.market.v1beta.MarketAddTicketPayload.end_ts": + x.EndTs = value.Uint() + case "sge.legacy.market.v1beta.MarketAddTicketPayload.odds": + lv := value.List() + clv := lv.(*_MarketAddTicketPayload_4_list) + x.Odds = *clv.list + case "sge.legacy.market.v1beta.MarketAddTicketPayload.status": + x.Status = (MarketStatus)(value.Enum()) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.meta": + x.Meta = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketAddTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketAddTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketAddTicketPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketAddTicketPayload.odds": + if x.Odds == nil { + x.Odds = []*Odds{} + } + value := &_MarketAddTicketPayload_4_list{list: &x.Odds} + return protoreflect.ValueOfList(value) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.uid": + panic(fmt.Errorf("field uid of message sge.legacy.market.v1beta.MarketAddTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.start_ts": + panic(fmt.Errorf("field start_ts of message sge.legacy.market.v1beta.MarketAddTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.end_ts": + panic(fmt.Errorf("field end_ts of message sge.legacy.market.v1beta.MarketAddTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.status": + panic(fmt.Errorf("field status of message sge.legacy.market.v1beta.MarketAddTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.meta": + panic(fmt.Errorf("field meta of message sge.legacy.market.v1beta.MarketAddTicketPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketAddTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketAddTicketPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MarketAddTicketPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketAddTicketPayload.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MarketAddTicketPayload.start_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.end_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.odds": + list := []*Odds{} + return protoreflect.ValueOfList(&_MarketAddTicketPayload_4_list{list: &list}) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.status": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.market.v1beta.MarketAddTicketPayload.meta": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketAddTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketAddTicketPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MarketAddTicketPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MarketAddTicketPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MarketAddTicketPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketAddTicketPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MarketAddTicketPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MarketAddTicketPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MarketAddTicketPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.StartTs != 0 { + n += 1 + runtime.Sov(uint64(x.StartTs)) + } + if x.EndTs != 0 { + n += 1 + runtime.Sov(uint64(x.EndTs)) + } + if len(x.Odds) > 0 { + for _, e := range x.Odds { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + l = len(x.Meta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MarketAddTicketPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Meta) > 0 { + i -= len(x.Meta) + copy(dAtA[i:], x.Meta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Meta))) + i-- + dAtA[i] = 0x32 + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x28 + } + if len(x.Odds) > 0 { + for iNdEx := len(x.Odds) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Odds[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if x.EndTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.EndTs)) + i-- + dAtA[i] = 0x18 + } + if x.StartTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.StartTs)) + i-- + dAtA[i] = 0x10 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MarketAddTicketPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketAddTicketPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketAddTicketPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field StartTs", wireType) + } + x.StartTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.StartTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EndTs", wireType) + } + x.EndTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.EndTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Odds", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Odds = append(x.Odds, &Odds{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Odds[len(x.Odds)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= MarketStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Meta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MarketUpdateTicketPayload protoreflect.MessageDescriptor + fd_MarketUpdateTicketPayload_uid protoreflect.FieldDescriptor + fd_MarketUpdateTicketPayload_start_ts protoreflect.FieldDescriptor + fd_MarketUpdateTicketPayload_end_ts protoreflect.FieldDescriptor + fd_MarketUpdateTicketPayload_status protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_ticket_proto_init() + md_MarketUpdateTicketPayload = File_sge_legacy_market_v1beta_ticket_proto.Messages().ByName("MarketUpdateTicketPayload") + fd_MarketUpdateTicketPayload_uid = md_MarketUpdateTicketPayload.Fields().ByName("uid") + fd_MarketUpdateTicketPayload_start_ts = md_MarketUpdateTicketPayload.Fields().ByName("start_ts") + fd_MarketUpdateTicketPayload_end_ts = md_MarketUpdateTicketPayload.Fields().ByName("end_ts") + fd_MarketUpdateTicketPayload_status = md_MarketUpdateTicketPayload.Fields().ByName("status") +} + +var _ protoreflect.Message = (*fastReflection_MarketUpdateTicketPayload)(nil) + +type fastReflection_MarketUpdateTicketPayload MarketUpdateTicketPayload + +func (x *MarketUpdateTicketPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_MarketUpdateTicketPayload)(x) +} + +func (x *MarketUpdateTicketPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_ticket_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MarketUpdateTicketPayload_messageType fastReflection_MarketUpdateTicketPayload_messageType +var _ protoreflect.MessageType = fastReflection_MarketUpdateTicketPayload_messageType{} + +type fastReflection_MarketUpdateTicketPayload_messageType struct{} + +func (x fastReflection_MarketUpdateTicketPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_MarketUpdateTicketPayload)(nil) +} +func (x fastReflection_MarketUpdateTicketPayload_messageType) New() protoreflect.Message { + return new(fastReflection_MarketUpdateTicketPayload) +} +func (x fastReflection_MarketUpdateTicketPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MarketUpdateTicketPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MarketUpdateTicketPayload) Descriptor() protoreflect.MessageDescriptor { + return md_MarketUpdateTicketPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MarketUpdateTicketPayload) Type() protoreflect.MessageType { + return _fastReflection_MarketUpdateTicketPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MarketUpdateTicketPayload) New() protoreflect.Message { + return new(fastReflection_MarketUpdateTicketPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MarketUpdateTicketPayload) Interface() protoreflect.ProtoMessage { + return (*MarketUpdateTicketPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MarketUpdateTicketPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MarketUpdateTicketPayload_uid, value) { + return + } + } + if x.StartTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.StartTs) + if !f(fd_MarketUpdateTicketPayload_start_ts, value) { + return + } + } + if x.EndTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.EndTs) + if !f(fd_MarketUpdateTicketPayload_end_ts, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_MarketUpdateTicketPayload_status, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MarketUpdateTicketPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.uid": + return x.Uid != "" + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.start_ts": + return x.StartTs != uint64(0) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.end_ts": + return x.EndTs != uint64(0) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.status": + return x.Status != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketUpdateTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketUpdateTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketUpdateTicketPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.uid": + x.Uid = "" + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.start_ts": + x.StartTs = uint64(0) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.end_ts": + x.EndTs = uint64(0) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.status": + x.Status = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketUpdateTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketUpdateTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MarketUpdateTicketPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.start_ts": + value := x.StartTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.end_ts": + value := x.EndTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketUpdateTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketUpdateTicketPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketUpdateTicketPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.start_ts": + x.StartTs = value.Uint() + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.end_ts": + x.EndTs = value.Uint() + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.status": + x.Status = (MarketStatus)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketUpdateTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketUpdateTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketUpdateTicketPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.uid": + panic(fmt.Errorf("field uid of message sge.legacy.market.v1beta.MarketUpdateTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.start_ts": + panic(fmt.Errorf("field start_ts of message sge.legacy.market.v1beta.MarketUpdateTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.end_ts": + panic(fmt.Errorf("field end_ts of message sge.legacy.market.v1beta.MarketUpdateTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.status": + panic(fmt.Errorf("field status of message sge.legacy.market.v1beta.MarketUpdateTicketPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketUpdateTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketUpdateTicketPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MarketUpdateTicketPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.start_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.end_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.MarketUpdateTicketPayload.status": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketUpdateTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketUpdateTicketPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MarketUpdateTicketPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MarketUpdateTicketPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MarketUpdateTicketPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketUpdateTicketPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MarketUpdateTicketPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MarketUpdateTicketPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MarketUpdateTicketPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.StartTs != 0 { + n += 1 + runtime.Sov(uint64(x.StartTs)) + } + if x.EndTs != 0 { + n += 1 + runtime.Sov(uint64(x.EndTs)) + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MarketUpdateTicketPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x20 + } + if x.EndTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.EndTs)) + i-- + dAtA[i] = 0x18 + } + if x.StartTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.StartTs)) + i-- + dAtA[i] = 0x10 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MarketUpdateTicketPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketUpdateTicketPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketUpdateTicketPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field StartTs", wireType) + } + x.StartTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.StartTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EndTs", wireType) + } + x.EndTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.EndTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= MarketStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_MarketResolutionTicketPayload_3_list)(nil) + +type _MarketResolutionTicketPayload_3_list struct { + list *[]string +} + +func (x *_MarketResolutionTicketPayload_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_MarketResolutionTicketPayload_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_MarketResolutionTicketPayload_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_MarketResolutionTicketPayload_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_MarketResolutionTicketPayload_3_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message MarketResolutionTicketPayload at list field WinnerOddsUids as it is not of Message kind")) +} + +func (x *_MarketResolutionTicketPayload_3_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_MarketResolutionTicketPayload_3_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_MarketResolutionTicketPayload_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_MarketResolutionTicketPayload protoreflect.MessageDescriptor + fd_MarketResolutionTicketPayload_uid protoreflect.FieldDescriptor + fd_MarketResolutionTicketPayload_resolution_ts protoreflect.FieldDescriptor + fd_MarketResolutionTicketPayload_winner_odds_uids protoreflect.FieldDescriptor + fd_MarketResolutionTicketPayload_status protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_ticket_proto_init() + md_MarketResolutionTicketPayload = File_sge_legacy_market_v1beta_ticket_proto.Messages().ByName("MarketResolutionTicketPayload") + fd_MarketResolutionTicketPayload_uid = md_MarketResolutionTicketPayload.Fields().ByName("uid") + fd_MarketResolutionTicketPayload_resolution_ts = md_MarketResolutionTicketPayload.Fields().ByName("resolution_ts") + fd_MarketResolutionTicketPayload_winner_odds_uids = md_MarketResolutionTicketPayload.Fields().ByName("winner_odds_uids") + fd_MarketResolutionTicketPayload_status = md_MarketResolutionTicketPayload.Fields().ByName("status") +} + +var _ protoreflect.Message = (*fastReflection_MarketResolutionTicketPayload)(nil) + +type fastReflection_MarketResolutionTicketPayload MarketResolutionTicketPayload + +func (x *MarketResolutionTicketPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_MarketResolutionTicketPayload)(x) +} + +func (x *MarketResolutionTicketPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_ticket_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MarketResolutionTicketPayload_messageType fastReflection_MarketResolutionTicketPayload_messageType +var _ protoreflect.MessageType = fastReflection_MarketResolutionTicketPayload_messageType{} + +type fastReflection_MarketResolutionTicketPayload_messageType struct{} + +func (x fastReflection_MarketResolutionTicketPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_MarketResolutionTicketPayload)(nil) +} +func (x fastReflection_MarketResolutionTicketPayload_messageType) New() protoreflect.Message { + return new(fastReflection_MarketResolutionTicketPayload) +} +func (x fastReflection_MarketResolutionTicketPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MarketResolutionTicketPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MarketResolutionTicketPayload) Descriptor() protoreflect.MessageDescriptor { + return md_MarketResolutionTicketPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MarketResolutionTicketPayload) Type() protoreflect.MessageType { + return _fastReflection_MarketResolutionTicketPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MarketResolutionTicketPayload) New() protoreflect.Message { + return new(fastReflection_MarketResolutionTicketPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MarketResolutionTicketPayload) Interface() protoreflect.ProtoMessage { + return (*MarketResolutionTicketPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MarketResolutionTicketPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MarketResolutionTicketPayload_uid, value) { + return + } + } + if x.ResolutionTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.ResolutionTs) + if !f(fd_MarketResolutionTicketPayload_resolution_ts, value) { + return + } + } + if len(x.WinnerOddsUids) != 0 { + value := protoreflect.ValueOfList(&_MarketResolutionTicketPayload_3_list{list: &x.WinnerOddsUids}) + if !f(fd_MarketResolutionTicketPayload_winner_odds_uids, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_MarketResolutionTicketPayload_status, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MarketResolutionTicketPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.uid": + return x.Uid != "" + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.resolution_ts": + return x.ResolutionTs != uint64(0) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.winner_odds_uids": + return len(x.WinnerOddsUids) != 0 + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.status": + return x.Status != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketResolutionTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketResolutionTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketResolutionTicketPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.uid": + x.Uid = "" + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.resolution_ts": + x.ResolutionTs = uint64(0) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.winner_odds_uids": + x.WinnerOddsUids = nil + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.status": + x.Status = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketResolutionTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketResolutionTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MarketResolutionTicketPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.resolution_ts": + value := x.ResolutionTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.winner_odds_uids": + if len(x.WinnerOddsUids) == 0 { + return protoreflect.ValueOfList(&_MarketResolutionTicketPayload_3_list{}) + } + listValue := &_MarketResolutionTicketPayload_3_list{list: &x.WinnerOddsUids} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketResolutionTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketResolutionTicketPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketResolutionTicketPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.resolution_ts": + x.ResolutionTs = value.Uint() + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.winner_odds_uids": + lv := value.List() + clv := lv.(*_MarketResolutionTicketPayload_3_list) + x.WinnerOddsUids = *clv.list + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.status": + x.Status = (MarketStatus)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketResolutionTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketResolutionTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketResolutionTicketPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.winner_odds_uids": + if x.WinnerOddsUids == nil { + x.WinnerOddsUids = []string{} + } + value := &_MarketResolutionTicketPayload_3_list{list: &x.WinnerOddsUids} + return protoreflect.ValueOfList(value) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.uid": + panic(fmt.Errorf("field uid of message sge.legacy.market.v1beta.MarketResolutionTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.resolution_ts": + panic(fmt.Errorf("field resolution_ts of message sge.legacy.market.v1beta.MarketResolutionTicketPayload is not mutable")) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.status": + panic(fmt.Errorf("field status of message sge.legacy.market.v1beta.MarketResolutionTicketPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketResolutionTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketResolutionTicketPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MarketResolutionTicketPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.resolution_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.winner_odds_uids": + list := []string{} + return protoreflect.ValueOfList(&_MarketResolutionTicketPayload_3_list{list: &list}) + case "sge.legacy.market.v1beta.MarketResolutionTicketPayload.status": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MarketResolutionTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MarketResolutionTicketPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MarketResolutionTicketPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MarketResolutionTicketPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MarketResolutionTicketPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MarketResolutionTicketPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MarketResolutionTicketPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MarketResolutionTicketPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MarketResolutionTicketPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ResolutionTs != 0 { + n += 1 + runtime.Sov(uint64(x.ResolutionTs)) + } + if len(x.WinnerOddsUids) > 0 { + for _, s := range x.WinnerOddsUids { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MarketResolutionTicketPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x20 + } + if len(x.WinnerOddsUids) > 0 { + for iNdEx := len(x.WinnerOddsUids) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.WinnerOddsUids[iNdEx]) + copy(dAtA[i:], x.WinnerOddsUids[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.WinnerOddsUids[iNdEx]))) + i-- + dAtA[i] = 0x1a + } + } + if x.ResolutionTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ResolutionTs)) + i-- + dAtA[i] = 0x10 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MarketResolutionTicketPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketResolutionTicketPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MarketResolutionTicketPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ResolutionTs", wireType) + } + x.ResolutionTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ResolutionTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WinnerOddsUids", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.WinnerOddsUids = append(x.WinnerOddsUids, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= MarketStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/ticket.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MarketAddTicketPayload indicates data of add market ticket +type MarketAddTicketPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier of the market. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // start_ts is the start timestamp of the market. + StartTs uint64 `protobuf:"varint,2,opt,name=start_ts,proto3" json:"start_ts,omitempty"` + // end_ts is the end timestamp of the market. + EndTs uint64 `protobuf:"varint,3,opt,name=end_ts,proto3" json:"end_ts,omitempty"` + // odds is the list of odds of the market. + Odds []*Odds `protobuf:"bytes,4,rep,name=odds,proto3" json:"odds,omitempty"` + // status is the current status of the market. + Status MarketStatus `protobuf:"varint,5,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` + // meta contains human-readable metadata of the market. + Meta string `protobuf:"bytes,6,opt,name=meta,proto3" json:"meta,omitempty"` +} + +func (x *MarketAddTicketPayload) Reset() { + *x = MarketAddTicketPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_ticket_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MarketAddTicketPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MarketAddTicketPayload) ProtoMessage() {} + +// Deprecated: Use MarketAddTicketPayload.ProtoReflect.Descriptor instead. +func (*MarketAddTicketPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_ticket_proto_rawDescGZIP(), []int{0} +} + +func (x *MarketAddTicketPayload) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MarketAddTicketPayload) GetStartTs() uint64 { + if x != nil { + return x.StartTs + } + return 0 +} + +func (x *MarketAddTicketPayload) GetEndTs() uint64 { + if x != nil { + return x.EndTs + } + return 0 +} + +func (x *MarketAddTicketPayload) GetOdds() []*Odds { + if x != nil { + return x.Odds + } + return nil +} + +func (x *MarketAddTicketPayload) GetStatus() MarketStatus { + if x != nil { + return x.Status + } + return MarketStatus_MARKET_STATUS_UNSPECIFIED +} + +func (x *MarketAddTicketPayload) GetMeta() string { + if x != nil { + return x.Meta + } + return "" +} + +// MarketUpdateTicketPayload indicates data of the market update ticket +type MarketUpdateTicketPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the uuid of the market + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // start_ts is the start timestamp of the market + StartTs uint64 `protobuf:"varint,2,opt,name=start_ts,proto3" json:"start_ts,omitempty"` + // end_ts is the end timestamp of the market + EndTs uint64 `protobuf:"varint,3,opt,name=end_ts,proto3" json:"end_ts,omitempty"` + // status is the status of the resolution. + Status MarketStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` +} + +func (x *MarketUpdateTicketPayload) Reset() { + *x = MarketUpdateTicketPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_ticket_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MarketUpdateTicketPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MarketUpdateTicketPayload) ProtoMessage() {} + +// Deprecated: Use MarketUpdateTicketPayload.ProtoReflect.Descriptor instead. +func (*MarketUpdateTicketPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_ticket_proto_rawDescGZIP(), []int{1} +} + +func (x *MarketUpdateTicketPayload) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MarketUpdateTicketPayload) GetStartTs() uint64 { + if x != nil { + return x.StartTs + } + return 0 +} + +func (x *MarketUpdateTicketPayload) GetEndTs() uint64 { + if x != nil { + return x.EndTs + } + return 0 +} + +func (x *MarketUpdateTicketPayload) GetStatus() MarketStatus { + if x != nil { + return x.Status + } + return MarketStatus_MARKET_STATUS_UNSPECIFIED +} + +// MarketResolutionTicketPayload indicates data of the +// resolution of the market ticket. +type MarketResolutionTicketPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier of the market. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // resolution_ts is the resolution timestamp of the market. + ResolutionTs uint64 `protobuf:"varint,2,opt,name=resolution_ts,proto3" json:"resolution_ts,omitempty"` + // winner_odds_uids is the universal unique identifier list of the winner + // odds. + WinnerOddsUids []string `protobuf:"bytes,3,rep,name=winner_odds_uids,proto3" json:"winner_odds_uids,omitempty"` + // status is the status of the resolution. + Status MarketStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` +} + +func (x *MarketResolutionTicketPayload) Reset() { + *x = MarketResolutionTicketPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_ticket_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MarketResolutionTicketPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MarketResolutionTicketPayload) ProtoMessage() {} + +// Deprecated: Use MarketResolutionTicketPayload.ProtoReflect.Descriptor instead. +func (*MarketResolutionTicketPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_ticket_proto_rawDescGZIP(), []int{2} +} + +func (x *MarketResolutionTicketPayload) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MarketResolutionTicketPayload) GetResolutionTs() uint64 { + if x != nil { + return x.ResolutionTs + } + return 0 +} + +func (x *MarketResolutionTicketPayload) GetWinnerOddsUids() []string { + if x != nil { + return x.WinnerOddsUids + } + return nil +} + +func (x *MarketResolutionTicketPayload) GetStatus() MarketStatus { + if x != nil { + return x.Status + } + return MarketStatus_MARKET_STATUS_UNSPECIFIED +} + +var File_sge_legacy_market_v1beta_ticket_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_ticket_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, + 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x23, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6f, 0x64, 0x64, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x22, 0xa4, 0x02, 0x0a, 0x16, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x41, 0x64, + 0x64, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x20, + 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, + 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, + 0x12, 0x33, 0x0a, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x04, 0x42, 0x17, 0xe2, 0xde, 0x1f, 0x07, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x53, 0xea, + 0xde, 0x1f, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x52, 0x08, 0x73, 0x74, 0x61, + 0x72, 0x74, 0x5f, 0x74, 0x73, 0x12, 0x2b, 0x0a, 0x06, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x13, 0xe2, 0xde, 0x1f, 0x05, 0x45, 0x6e, 0x64, 0x54, 0x53, + 0xea, 0xde, 0x1f, 0x06, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x52, 0x06, 0x65, 0x6e, 0x64, 0x5f, + 0x74, 0x73, 0x12, 0x32, 0x0a, 0x04, 0x6f, 0x64, 0x64, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x64, 0x64, 0x73, + 0x52, 0x04, 0x6f, 0x64, 0x64, 0x73, 0x12, 0x3e, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, + 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x22, 0xdf, 0x01, 0x0a, 0x19, 0x4d, + 0x61, 0x72, 0x6b, 0x65, 0x74, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, + 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x33, 0x0a, 0x08, 0x73, 0x74, + 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x17, 0xe2, 0xde, + 0x1f, 0x07, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x08, 0x73, 0x74, 0x61, + 0x72, 0x74, 0x5f, 0x74, 0x73, 0x52, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x12, + 0x2b, 0x0a, 0x06, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, + 0x13, 0xe2, 0xde, 0x1f, 0x05, 0x45, 0x6e, 0x64, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x06, 0x65, 0x6e, + 0x64, 0x5f, 0x74, 0x73, 0x52, 0x06, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x12, 0x3e, 0x0a, 0x06, + 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x26, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x53, 0x74, + 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0x9e, 0x02, 0x0a, + 0x1d, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x52, 0x65, 0x73, 0x6f, 0x6c, 0x75, 0x74, 0x69, 0x6f, + 0x6e, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x20, + 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, + 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, + 0x12, 0x47, 0x0a, 0x0d, 0x72, 0x65, 0x73, 0x6f, 0x6c, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, + 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x21, 0xe2, 0xde, 0x1f, 0x0c, 0x52, 0x65, 0x73, + 0x6f, 0x6c, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x0d, 0x72, 0x65, 0x73, + 0x6f, 0x6c, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x73, 0x52, 0x0d, 0x72, 0x65, 0x73, 0x6f, + 0x6c, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x73, 0x12, 0x52, 0x0a, 0x10, 0x77, 0x69, 0x6e, + 0x6e, 0x65, 0x72, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x73, 0x18, 0x03, 0x20, + 0x03, 0x28, 0x09, 0x42, 0x26, 0xe2, 0xde, 0x1f, 0x0e, 0x57, 0x69, 0x6e, 0x6e, 0x65, 0x72, 0x4f, + 0x64, 0x64, 0x73, 0x55, 0x49, 0x44, 0x73, 0xea, 0xde, 0x1f, 0x10, 0x77, 0x69, 0x6e, 0x6e, 0x65, + 0x72, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x73, 0x52, 0x10, 0x77, 0x69, 0x6e, + 0x6e, 0x65, 0x72, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x73, 0x12, 0x3e, 0x0a, + 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x26, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x53, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x42, 0xf4, 0x01, + 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, + 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, + 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, + 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, + 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4d, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, + 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_market_v1beta_ticket_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_ticket_proto_rawDescData = file_sge_legacy_market_v1beta_ticket_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_ticket_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_ticket_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_ticket_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_ticket_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_ticket_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_ticket_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_sge_legacy_market_v1beta_ticket_proto_goTypes = []interface{}{ + (*MarketAddTicketPayload)(nil), // 0: sge.legacy.market.v1beta.MarketAddTicketPayload + (*MarketUpdateTicketPayload)(nil), // 1: sge.legacy.market.v1beta.MarketUpdateTicketPayload + (*MarketResolutionTicketPayload)(nil), // 2: sge.legacy.market.v1beta.MarketResolutionTicketPayload + (*Odds)(nil), // 3: sge.legacy.market.v1beta.Odds + (MarketStatus)(0), // 4: sge.legacy.market.v1beta.MarketStatus +} +var file_sge_legacy_market_v1beta_ticket_proto_depIdxs = []int32{ + 3, // 0: sge.legacy.market.v1beta.MarketAddTicketPayload.odds:type_name -> sge.legacy.market.v1beta.Odds + 4, // 1: sge.legacy.market.v1beta.MarketAddTicketPayload.status:type_name -> sge.legacy.market.v1beta.MarketStatus + 4, // 2: sge.legacy.market.v1beta.MarketUpdateTicketPayload.status:type_name -> sge.legacy.market.v1beta.MarketStatus + 4, // 3: sge.legacy.market.v1beta.MarketResolutionTicketPayload.status:type_name -> sge.legacy.market.v1beta.MarketStatus + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_ticket_proto_init() } +func file_sge_legacy_market_v1beta_ticket_proto_init() { + if File_sge_legacy_market_v1beta_ticket_proto != nil { + return + } + file_sge_legacy_market_v1beta_market_proto_init() + file_sge_legacy_market_v1beta_odds_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_ticket_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MarketAddTicketPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_ticket_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MarketUpdateTicketPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_ticket_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MarketResolutionTicketPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_ticket_proto_rawDesc, + NumEnums: 0, + NumMessages: 3, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_market_v1beta_ticket_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_ticket_proto_depIdxs, + MessageInfos: file_sge_legacy_market_v1beta_ticket_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_ticket_proto = out.File + file_sge_legacy_market_v1beta_ticket_proto_rawDesc = nil + file_sge_legacy_market_v1beta_ticket_proto_goTypes = nil + file_sge_legacy_market_v1beta_ticket_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/tx.pulsar.go b/api/sge/legacy/market/v1beta/tx.pulsar.go new file mode 100644 index 00000000..1b894786 --- /dev/null +++ b/api/sge/legacy/market/v1beta/tx.pulsar.go @@ -0,0 +1,4474 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package marketv1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_MsgAdd protoreflect.MessageDescriptor + fd_MsgAdd_creator protoreflect.FieldDescriptor + fd_MsgAdd_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgAdd = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgAdd") + fd_MsgAdd_creator = md_MsgAdd.Fields().ByName("creator") + fd_MsgAdd_ticket = md_MsgAdd.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgAdd)(nil) + +type fastReflection_MsgAdd MsgAdd + +func (x *MsgAdd) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgAdd)(x) +} + +func (x *MsgAdd) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgAdd_messageType fastReflection_MsgAdd_messageType +var _ protoreflect.MessageType = fastReflection_MsgAdd_messageType{} + +type fastReflection_MsgAdd_messageType struct{} + +func (x fastReflection_MsgAdd_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgAdd)(nil) +} +func (x fastReflection_MsgAdd_messageType) New() protoreflect.Message { + return new(fastReflection_MsgAdd) +} +func (x fastReflection_MsgAdd_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgAdd +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgAdd) Descriptor() protoreflect.MessageDescriptor { + return md_MsgAdd +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgAdd) Type() protoreflect.MessageType { + return _fastReflection_MsgAdd_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgAdd) New() protoreflect.Message { + return new(fastReflection_MsgAdd) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgAdd) Interface() protoreflect.ProtoMessage { + return (*MsgAdd)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgAdd) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgAdd_creator, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgAdd_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgAdd) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAdd.creator": + return x.Creator != "" + case "sge.legacy.market.v1beta.MsgAdd.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAdd")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAdd does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAdd) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAdd.creator": + x.Creator = "" + case "sge.legacy.market.v1beta.MsgAdd.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAdd")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAdd does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgAdd) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MsgAdd.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MsgAdd.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAdd")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAdd does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAdd) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAdd.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.market.v1beta.MsgAdd.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAdd")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAdd does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAdd) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAdd.creator": + panic(fmt.Errorf("field creator of message sge.legacy.market.v1beta.MsgAdd is not mutable")) + case "sge.legacy.market.v1beta.MsgAdd.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.market.v1beta.MsgAdd is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAdd")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAdd does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgAdd) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAdd.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MsgAdd.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAdd")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAdd does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgAdd) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgAdd", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgAdd) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAdd) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgAdd) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgAdd) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgAdd) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgAdd) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgAdd) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgAdd: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgAdd: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgAddResponse protoreflect.MessageDescriptor + fd_MsgAddResponse_error protoreflect.FieldDescriptor + fd_MsgAddResponse_data protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgAddResponse = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgAddResponse") + fd_MsgAddResponse_error = md_MsgAddResponse.Fields().ByName("error") + fd_MsgAddResponse_data = md_MsgAddResponse.Fields().ByName("data") +} + +var _ protoreflect.Message = (*fastReflection_MsgAddResponse)(nil) + +type fastReflection_MsgAddResponse MsgAddResponse + +func (x *MsgAddResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgAddResponse)(x) +} + +func (x *MsgAddResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgAddResponse_messageType fastReflection_MsgAddResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgAddResponse_messageType{} + +type fastReflection_MsgAddResponse_messageType struct{} + +func (x fastReflection_MsgAddResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgAddResponse)(nil) +} +func (x fastReflection_MsgAddResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgAddResponse) +} +func (x fastReflection_MsgAddResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgAddResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgAddResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgAddResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgAddResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgAddResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgAddResponse) New() protoreflect.Message { + return new(fastReflection_MsgAddResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgAddResponse) Interface() protoreflect.ProtoMessage { + return (*MsgAddResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgAddResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Error != "" { + value := protoreflect.ValueOfString(x.Error) + if !f(fd_MsgAddResponse_error, value) { + return + } + } + if x.Data != nil { + value := protoreflect.ValueOfMessage(x.Data.ProtoReflect()) + if !f(fd_MsgAddResponse_data, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgAddResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAddResponse.error": + return x.Error != "" + case "sge.legacy.market.v1beta.MsgAddResponse.data": + return x.Data != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAddResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAddResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAddResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAddResponse.error": + x.Error = "" + case "sge.legacy.market.v1beta.MsgAddResponse.data": + x.Data = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAddResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAddResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgAddResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MsgAddResponse.error": + value := x.Error + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MsgAddResponse.data": + value := x.Data + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAddResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAddResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAddResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAddResponse.error": + x.Error = value.Interface().(string) + case "sge.legacy.market.v1beta.MsgAddResponse.data": + x.Data = value.Message().Interface().(*Market) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAddResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAddResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAddResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAddResponse.data": + if x.Data == nil { + x.Data = new(Market) + } + return protoreflect.ValueOfMessage(x.Data.ProtoReflect()) + case "sge.legacy.market.v1beta.MsgAddResponse.error": + panic(fmt.Errorf("field error of message sge.legacy.market.v1beta.MsgAddResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAddResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAddResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgAddResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgAddResponse.error": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MsgAddResponse.data": + m := new(Market) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgAddResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgAddResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgAddResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgAddResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgAddResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgAddResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgAddResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgAddResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgAddResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Error) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Data != nil { + l = options.Size(x.Data) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgAddResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Data != nil { + encoded, err := options.Marshal(x.Data) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Error) > 0 { + i -= len(x.Error) + copy(dAtA[i:], x.Error) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Error))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgAddResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgAddResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgAddResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Error", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Error = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Data == nil { + x.Data = &Market{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Data); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgResolve protoreflect.MessageDescriptor + fd_MsgResolve_creator protoreflect.FieldDescriptor + fd_MsgResolve_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgResolve = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgResolve") + fd_MsgResolve_creator = md_MsgResolve.Fields().ByName("creator") + fd_MsgResolve_ticket = md_MsgResolve.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgResolve)(nil) + +type fastReflection_MsgResolve MsgResolve + +func (x *MsgResolve) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgResolve)(x) +} + +func (x *MsgResolve) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgResolve_messageType fastReflection_MsgResolve_messageType +var _ protoreflect.MessageType = fastReflection_MsgResolve_messageType{} + +type fastReflection_MsgResolve_messageType struct{} + +func (x fastReflection_MsgResolve_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgResolve)(nil) +} +func (x fastReflection_MsgResolve_messageType) New() protoreflect.Message { + return new(fastReflection_MsgResolve) +} +func (x fastReflection_MsgResolve_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgResolve +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgResolve) Descriptor() protoreflect.MessageDescriptor { + return md_MsgResolve +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgResolve) Type() protoreflect.MessageType { + return _fastReflection_MsgResolve_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgResolve) New() protoreflect.Message { + return new(fastReflection_MsgResolve) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgResolve) Interface() protoreflect.ProtoMessage { + return (*MsgResolve)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgResolve) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgResolve_creator, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgResolve_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgResolve) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolve.creator": + return x.Creator != "" + case "sge.legacy.market.v1beta.MsgResolve.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolve")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolve does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolve) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolve.creator": + x.Creator = "" + case "sge.legacy.market.v1beta.MsgResolve.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolve")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolve does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgResolve) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MsgResolve.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MsgResolve.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolve")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolve does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolve) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolve.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.market.v1beta.MsgResolve.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolve")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolve does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolve) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolve.creator": + panic(fmt.Errorf("field creator of message sge.legacy.market.v1beta.MsgResolve is not mutable")) + case "sge.legacy.market.v1beta.MsgResolve.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.market.v1beta.MsgResolve is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolve")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolve does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgResolve) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolve.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MsgResolve.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolve")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolve does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgResolve) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgResolve", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgResolve) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolve) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgResolve) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgResolve) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgResolve) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgResolve) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgResolve) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgResolve: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgResolve: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgResolveResponse protoreflect.MessageDescriptor + fd_MsgResolveResponse_error protoreflect.FieldDescriptor + fd_MsgResolveResponse_data protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgResolveResponse = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgResolveResponse") + fd_MsgResolveResponse_error = md_MsgResolveResponse.Fields().ByName("error") + fd_MsgResolveResponse_data = md_MsgResolveResponse.Fields().ByName("data") +} + +var _ protoreflect.Message = (*fastReflection_MsgResolveResponse)(nil) + +type fastReflection_MsgResolveResponse MsgResolveResponse + +func (x *MsgResolveResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgResolveResponse)(x) +} + +func (x *MsgResolveResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgResolveResponse_messageType fastReflection_MsgResolveResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgResolveResponse_messageType{} + +type fastReflection_MsgResolveResponse_messageType struct{} + +func (x fastReflection_MsgResolveResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgResolveResponse)(nil) +} +func (x fastReflection_MsgResolveResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgResolveResponse) +} +func (x fastReflection_MsgResolveResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgResolveResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgResolveResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgResolveResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgResolveResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgResolveResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgResolveResponse) New() protoreflect.Message { + return new(fastReflection_MsgResolveResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgResolveResponse) Interface() protoreflect.ProtoMessage { + return (*MsgResolveResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgResolveResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Error != "" { + value := protoreflect.ValueOfString(x.Error) + if !f(fd_MsgResolveResponse_error, value) { + return + } + } + if x.Data != nil { + value := protoreflect.ValueOfMessage(x.Data.ProtoReflect()) + if !f(fd_MsgResolveResponse_data, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgResolveResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolveResponse.error": + return x.Error != "" + case "sge.legacy.market.v1beta.MsgResolveResponse.data": + return x.Data != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolveResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolveResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolveResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolveResponse.error": + x.Error = "" + case "sge.legacy.market.v1beta.MsgResolveResponse.data": + x.Data = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolveResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolveResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgResolveResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MsgResolveResponse.error": + value := x.Error + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MsgResolveResponse.data": + value := x.Data + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolveResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolveResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolveResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolveResponse.error": + x.Error = value.Interface().(string) + case "sge.legacy.market.v1beta.MsgResolveResponse.data": + x.Data = value.Message().Interface().(*Market) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolveResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolveResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolveResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolveResponse.data": + if x.Data == nil { + x.Data = new(Market) + } + return protoreflect.ValueOfMessage(x.Data.ProtoReflect()) + case "sge.legacy.market.v1beta.MsgResolveResponse.error": + panic(fmt.Errorf("field error of message sge.legacy.market.v1beta.MsgResolveResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolveResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolveResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgResolveResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgResolveResponse.error": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MsgResolveResponse.data": + m := new(Market) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgResolveResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgResolveResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgResolveResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgResolveResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgResolveResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgResolveResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgResolveResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgResolveResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgResolveResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Error) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Data != nil { + l = options.Size(x.Data) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgResolveResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Data != nil { + encoded, err := options.Marshal(x.Data) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Error) > 0 { + i -= len(x.Error) + copy(dAtA[i:], x.Error) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Error))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgResolveResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgResolveResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgResolveResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Error", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Error = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Data == nil { + x.Data = &Market{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Data); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdate protoreflect.MessageDescriptor + fd_MsgUpdate_creator protoreflect.FieldDescriptor + fd_MsgUpdate_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgUpdate = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgUpdate") + fd_MsgUpdate_creator = md_MsgUpdate.Fields().ByName("creator") + fd_MsgUpdate_ticket = md_MsgUpdate.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdate)(nil) + +type fastReflection_MsgUpdate MsgUpdate + +func (x *MsgUpdate) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdate)(x) +} + +func (x *MsgUpdate) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdate_messageType fastReflection_MsgUpdate_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdate_messageType{} + +type fastReflection_MsgUpdate_messageType struct{} + +func (x fastReflection_MsgUpdate_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdate)(nil) +} +func (x fastReflection_MsgUpdate_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdate) +} +func (x fastReflection_MsgUpdate_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdate +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdate) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdate +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdate) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdate_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdate) New() protoreflect.Message { + return new(fastReflection_MsgUpdate) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdate) Interface() protoreflect.ProtoMessage { + return (*MsgUpdate)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdate) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgUpdate_creator, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgUpdate_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdate) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdate.creator": + return x.Creator != "" + case "sge.legacy.market.v1beta.MsgUpdate.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdate")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdate does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdate) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdate.creator": + x.Creator = "" + case "sge.legacy.market.v1beta.MsgUpdate.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdate")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdate does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdate) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MsgUpdate.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MsgUpdate.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdate")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdate does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdate) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdate.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.market.v1beta.MsgUpdate.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdate")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdate does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdate) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdate.creator": + panic(fmt.Errorf("field creator of message sge.legacy.market.v1beta.MsgUpdate is not mutable")) + case "sge.legacy.market.v1beta.MsgUpdate.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.market.v1beta.MsgUpdate is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdate")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdate does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdate) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdate.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MsgUpdate.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdate")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdate does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdate) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgUpdate", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdate) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdate) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdate) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdate) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdate) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdate) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdate) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdate: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdate: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateResponse protoreflect.MessageDescriptor + fd_MsgUpdateResponse_error protoreflect.FieldDescriptor + fd_MsgUpdateResponse_data protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgUpdateResponse = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgUpdateResponse") + fd_MsgUpdateResponse_error = md_MsgUpdateResponse.Fields().ByName("error") + fd_MsgUpdateResponse_data = md_MsgUpdateResponse.Fields().ByName("data") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateResponse)(nil) + +type fastReflection_MsgUpdateResponse MsgUpdateResponse + +func (x *MsgUpdateResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateResponse)(x) +} + +func (x *MsgUpdateResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateResponse_messageType fastReflection_MsgUpdateResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateResponse_messageType{} + +type fastReflection_MsgUpdateResponse_messageType struct{} + +func (x fastReflection_MsgUpdateResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateResponse)(nil) +} +func (x fastReflection_MsgUpdateResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateResponse) +} +func (x fastReflection_MsgUpdateResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Error != "" { + value := protoreflect.ValueOfString(x.Error) + if !f(fd_MsgUpdateResponse_error, value) { + return + } + } + if x.Data != nil { + value := protoreflect.ValueOfMessage(x.Data.ProtoReflect()) + if !f(fd_MsgUpdateResponse_data, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateResponse.error": + return x.Error != "" + case "sge.legacy.market.v1beta.MsgUpdateResponse.data": + return x.Data != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateResponse.error": + x.Error = "" + case "sge.legacy.market.v1beta.MsgUpdateResponse.data": + x.Data = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateResponse.error": + value := x.Error + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MsgUpdateResponse.data": + value := x.Data + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateResponse.error": + x.Error = value.Interface().(string) + case "sge.legacy.market.v1beta.MsgUpdateResponse.data": + x.Data = value.Message().Interface().(*Market) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateResponse.data": + if x.Data == nil { + x.Data = new(Market) + } + return protoreflect.ValueOfMessage(x.Data.ProtoReflect()) + case "sge.legacy.market.v1beta.MsgUpdateResponse.error": + panic(fmt.Errorf("field error of message sge.legacy.market.v1beta.MsgUpdateResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateResponse.error": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MsgUpdateResponse.data": + m := new(Market) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgUpdateResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Error) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Data != nil { + l = options.Size(x.Data) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Data != nil { + encoded, err := options.Marshal(x.Data) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Error) > 0 { + i -= len(x.Error) + copy(dAtA[i:], x.Error) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Error))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Error", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Error = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Data == nil { + x.Data = &Market{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Data); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.legacy.market.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.legacy.market.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.legacy.market.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.legacy.market.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.market.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.legacy.market.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.market.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.legacy.market.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_market_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_legacy_market_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.market.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.market.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.market.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/market/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgAdd is the message type for adding the market into the +// state. +type MsgAdd struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of the creator account of the market. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,2,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgAdd) Reset() { + *x = MsgAdd{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgAdd) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgAdd) ProtoMessage() {} + +// Deprecated: Use MsgAdd.ProtoReflect.Descriptor instead. +func (*MsgAdd) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgAdd) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgAdd) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgAddResponse response for adding market. +type MsgAddResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // error contains an error if adding a market faces any issues. + Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` + // data is the data of market. + Data *Market `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` +} + +func (x *MsgAddResponse) Reset() { + *x = MsgAddResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgAddResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgAddResponse) ProtoMessage() {} + +// Deprecated: Use MsgAddResponse.ProtoReflect.Descriptor instead. +func (*MsgAddResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +func (x *MsgAddResponse) GetError() string { + if x != nil { + return x.Error + } + return "" +} + +func (x *MsgAddResponse) GetData() *Market { + if x != nil { + return x.Data + } + return nil +} + +// MsgResolve is the message type for resolving a market. +type MsgResolve struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of the creator account of the market. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,2,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgResolve) Reset() { + *x = MsgResolve{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgResolve) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgResolve) ProtoMessage() {} + +// Deprecated: Use MsgResolve.ProtoReflect.Descriptor instead. +func (*MsgResolve) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{2} +} + +func (x *MsgResolve) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgResolve) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgResolveResponse response for resolving a market. +type MsgResolveResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // error contains an error if resolving a market faces any issues. + Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` + // data is the data of market. + Data *Market `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` +} + +func (x *MsgResolveResponse) Reset() { + *x = MsgResolveResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgResolveResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgResolveResponse) ProtoMessage() {} + +// Deprecated: Use MsgResolveResponse.ProtoReflect.Descriptor instead. +func (*MsgResolveResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{3} +} + +func (x *MsgResolveResponse) GetError() string { + if x != nil { + return x.Error + } + return "" +} + +func (x *MsgResolveResponse) GetData() *Market { + if x != nil { + return x.Data + } + return nil +} + +// MsgUpdate is the message type for updating market data. +// in the state +type MsgUpdate struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of the creator account of the market. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,2,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgUpdate) Reset() { + *x = MsgUpdate{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdate) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdate) ProtoMessage() {} + +// Deprecated: Use MsgUpdate.ProtoReflect.Descriptor instead. +func (*MsgUpdate) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{4} +} + +func (x *MsgUpdate) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgUpdate) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgUpdateResponse response for updating a market. +type MsgUpdateResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // error contains an error if updating a market faces any issues. + Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` + // data is the data of market + Data *Market `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` +} + +func (x *MsgUpdateResponse) Reset() { + *x = MsgUpdateResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{5} +} + +func (x *MsgUpdateResponse) GetError() string { + if x != nil { + return x.Error + } + return "" +} + +func (x *MsgUpdateResponse) GetData() *Market { + if x != nil { + return x.Data + } + return nil +} + +// MsgUpdateParams is the Msg/UpdateParams request type. +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/bet parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{6} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_market_v1beta_tx_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP(), []int{7} +} + +var File_sge_legacy_market_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_legacy_market_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, + 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, + 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, + 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, + 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x62, 0x0a, 0x06, 0x4d, 0x73, 0x67, 0x41, + 0x64, 0x64, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, 0x0c, + 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x68, 0x0a, 0x0e, + 0x4d, 0x73, 0x67, 0x41, 0x64, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, + 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x01, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x3a, 0x0a, 0x04, 0x64, 0x61, + 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x01, + 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x66, 0x0a, 0x0a, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x73, + 0x6f, 0x6c, 0x76, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, + 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, + 0x65, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, + 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x6c, + 0x0a, 0x12, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x73, 0x6f, 0x6c, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x01, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, + 0x12, 0x3a, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x01, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x65, 0x0a, 0x09, + 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, + 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, + 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, + 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x6f, 0x72, 0x22, 0x6b, 0x0a, 0x11, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, + 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x01, 0x52, 0x05, 0x65, + 0x72, 0x72, 0x6f, 0x72, 0x12, 0x3a, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x01, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, + 0x22, 0xb3, 0x01, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, + 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x43, 0x0a, 0x06, + 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, + 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x3a, 0x23, 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, + 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, 0x30, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x3a, 0x15, 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x32, 0xab, 0x03, 0x0a, 0x03, 0x4d, 0x73, 0x67, + 0x12, 0x56, 0x0a, 0x03, 0x41, 0x64, 0x64, 0x12, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x64, 0x64, 0x1a, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x41, 0x64, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x62, 0x0a, 0x07, 0x52, 0x65, 0x73, 0x6f, + 0x6c, 0x76, 0x65, 0x12, 0x24, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, + 0x73, 0x67, 0x52, 0x65, 0x73, 0x6f, 0x6c, 0x76, 0x65, 0x1a, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x52, 0x65, 0x73, 0x6f, 0x6c, 0x76, 0x65, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x5f, 0x0a, 0x06, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x1a, 0x2b, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x86, 0x01, + 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x29, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x31, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x18, 0xca, 0xb4, + 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, + 0x37, 0x2e, 0x31, 0x88, 0x02, 0x01, 0x42, 0xf0, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, + 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6d, 0x61, + 0x72, 0x6b, 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4d, 0xaa, 0x02, + 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x72, 0x6b, + 0x65, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x4d, 0x61, 0x72, 0x6b, 0x65, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, + 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4d, 0x61, 0x72, 0x6b, 0x65, + 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, +} + +var ( + file_sge_legacy_market_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_legacy_market_v1beta_tx_proto_rawDescData = file_sge_legacy_market_v1beta_tx_proto_rawDesc +) + +func file_sge_legacy_market_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_legacy_market_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_legacy_market_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_market_v1beta_tx_proto_rawDescData) + }) + return file_sge_legacy_market_v1beta_tx_proto_rawDescData +} + +var file_sge_legacy_market_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 8) +var file_sge_legacy_market_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgAdd)(nil), // 0: sge.legacy.market.v1beta.MsgAdd + (*MsgAddResponse)(nil), // 1: sge.legacy.market.v1beta.MsgAddResponse + (*MsgResolve)(nil), // 2: sge.legacy.market.v1beta.MsgResolve + (*MsgResolveResponse)(nil), // 3: sge.legacy.market.v1beta.MsgResolveResponse + (*MsgUpdate)(nil), // 4: sge.legacy.market.v1beta.MsgUpdate + (*MsgUpdateResponse)(nil), // 5: sge.legacy.market.v1beta.MsgUpdateResponse + (*MsgUpdateParams)(nil), // 6: sge.legacy.market.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 7: sge.legacy.market.v1beta.MsgUpdateParamsResponse + (*Market)(nil), // 8: sge.legacy.market.v1beta.Market + (*Params)(nil), // 9: sge.legacy.market.v1beta.Params +} +var file_sge_legacy_market_v1beta_tx_proto_depIdxs = []int32{ + 8, // 0: sge.legacy.market.v1beta.MsgAddResponse.data:type_name -> sge.legacy.market.v1beta.Market + 8, // 1: sge.legacy.market.v1beta.MsgResolveResponse.data:type_name -> sge.legacy.market.v1beta.Market + 8, // 2: sge.legacy.market.v1beta.MsgUpdateResponse.data:type_name -> sge.legacy.market.v1beta.Market + 9, // 3: sge.legacy.market.v1beta.MsgUpdateParams.params:type_name -> sge.legacy.market.v1beta.Params + 0, // 4: sge.legacy.market.v1beta.Msg.Add:input_type -> sge.legacy.market.v1beta.MsgAdd + 2, // 5: sge.legacy.market.v1beta.Msg.Resolve:input_type -> sge.legacy.market.v1beta.MsgResolve + 4, // 6: sge.legacy.market.v1beta.Msg.Update:input_type -> sge.legacy.market.v1beta.MsgUpdate + 6, // 7: sge.legacy.market.v1beta.Msg.UpdateParams:input_type -> sge.legacy.market.v1beta.MsgUpdateParams + 1, // 8: sge.legacy.market.v1beta.Msg.Add:output_type -> sge.legacy.market.v1beta.MsgAddResponse + 3, // 9: sge.legacy.market.v1beta.Msg.Resolve:output_type -> sge.legacy.market.v1beta.MsgResolveResponse + 5, // 10: sge.legacy.market.v1beta.Msg.Update:output_type -> sge.legacy.market.v1beta.MsgUpdateResponse + 7, // 11: sge.legacy.market.v1beta.Msg.UpdateParams:output_type -> sge.legacy.market.v1beta.MsgUpdateParamsResponse + 8, // [8:12] is the sub-list for method output_type + 4, // [4:8] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_sge_legacy_market_v1beta_tx_proto_init() } +func file_sge_legacy_market_v1beta_tx_proto_init() { + if File_sge_legacy_market_v1beta_tx_proto != nil { + return + } + file_sge_legacy_market_v1beta_market_proto_init() + file_sge_legacy_market_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_market_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgAdd); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgAddResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_tx_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgResolve); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_tx_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgResolveResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_tx_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdate); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_tx_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_tx_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_market_v1beta_tx_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_market_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 8, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_market_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_legacy_market_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_legacy_market_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_legacy_market_v1beta_tx_proto = out.File + file_sge_legacy_market_v1beta_tx_proto_rawDesc = nil + file_sge_legacy_market_v1beta_tx_proto_goTypes = nil + file_sge_legacy_market_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/legacy/market/v1beta/tx_grpc.pb.go b/api/sge/legacy/market/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..b1f2ac43 --- /dev/null +++ b/api/sge/legacy/market/v1beta/tx_grpc.pb.go @@ -0,0 +1,242 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/market/v1beta/tx.proto + +package marketv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_Add_FullMethodName = "/sge.legacy.market.v1beta.Msg/Add" + Msg_Resolve_FullMethodName = "/sge.legacy.market.v1beta.Msg/Resolve" + Msg_Update_FullMethodName = "/sge.legacy.market.v1beta.Msg/Update" + Msg_UpdateParams_FullMethodName = "/sge.legacy.market.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // Deprecated: Do not use. + // Add defines a method to add the market with the given data. + Add(ctx context.Context, in *MsgAdd, opts ...grpc.CallOption) (*MsgAddResponse, error) + // Deprecated: Do not use. + // Resolve defines a method to resolve the market. + Resolve(ctx context.Context, in *MsgResolve, opts ...grpc.CallOption) (*MsgResolveResponse, error) + // Deprecated: Do not use. + // Update defines a method to update a market. + Update(ctx context.Context, in *MsgUpdate, opts ...grpc.CallOption) (*MsgUpdateResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/market + // module parameters. The authority is defined in the keeper. + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +// Deprecated: Do not use. +func (c *msgClient) Add(ctx context.Context, in *MsgAdd, opts ...grpc.CallOption) (*MsgAddResponse, error) { + out := new(MsgAddResponse) + err := c.cc.Invoke(ctx, Msg_Add_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) Resolve(ctx context.Context, in *MsgResolve, opts ...grpc.CallOption) (*MsgResolveResponse, error) { + out := new(MsgResolveResponse) + err := c.cc.Invoke(ctx, Msg_Resolve_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) Update(ctx context.Context, in *MsgUpdate, opts ...grpc.CallOption) (*MsgUpdateResponse, error) { + out := new(MsgUpdateResponse) + err := c.cc.Invoke(ctx, Msg_Update_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // Deprecated: Do not use. + // Add defines a method to add the market with the given data. + Add(context.Context, *MsgAdd) (*MsgAddResponse, error) + // Deprecated: Do not use. + // Resolve defines a method to resolve the market. + Resolve(context.Context, *MsgResolve) (*MsgResolveResponse, error) + // Deprecated: Do not use. + // Update defines a method to update a market. + Update(context.Context, *MsgUpdate) (*MsgUpdateResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/market + // module parameters. The authority is defined in the keeper. + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) Add(context.Context, *MsgAdd) (*MsgAddResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Add not implemented") +} +func (UnimplementedMsgServer) Resolve(context.Context, *MsgResolve) (*MsgResolveResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Resolve not implemented") +} +func (UnimplementedMsgServer) Update(context.Context, *MsgUpdate) (*MsgUpdateResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Update not implemented") +} +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_Add_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgAdd) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Add(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Add_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Add(ctx, req.(*MsgAdd)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_Resolve_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgResolve) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Resolve(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Resolve_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Resolve(ctx, req.(*MsgResolve)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_Update_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdate) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Update(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Update_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Update(ctx, req.(*MsgUpdate)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.market.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Add", + Handler: _Msg_Add_Handler, + }, + { + MethodName: "Resolve", + Handler: _Msg_Resolve_Handler, + }, + { + MethodName: "Update", + Handler: _Msg_Update_Handler, + }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/market/v1beta/tx.proto", +} diff --git a/api/sge/legacy/orderbook/module/v1/module.pulsar.go b/api/sge/legacy/orderbook/module/v1/module.pulsar.go new file mode 100644 index 00000000..3d45e01a --- /dev/null +++ b/api/sge/legacy/orderbook/module/v1/module.pulsar.go @@ -0,0 +1,657 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_module_v1_module_proto_init() + md_Module = File_sge_legacy_orderbook_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.legacy.orderbook.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.legacy.orderbook.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.legacy.orderbook.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.legacy.orderbook.module.v1.Module is not mutable")) + case "sge.legacy.orderbook.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.legacy.orderbook.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the orderbook module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_legacy_orderbook_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x2b, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, + 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x20, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, + 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, + 0x6d, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x12, 0x2c, 0x0a, 0x12, 0x66, 0x65, 0x65, + 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x66, 0x65, 0x65, 0x43, 0x6f, 0x6c, 0x6c, 0x65, 0x63, + 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, + 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, + 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, 0x17, 0xba, 0xc0, 0x96, 0xda, 0x01, 0x11, 0x0a, 0x0f, 0x73, + 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x42, 0x96, + 0x02, 0x0a, 0x22, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x6d, 0x6f, 0x64, 0x75, + 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x46, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, + 0x2f, 0x76, 0x31, 0x3b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, 0x31, 0xa2, 0x02, 0x04, 0x53, + 0x4c, 0x4f, 0x4d, 0xaa, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x4d, 0x6f, 0x64, 0x75, + 0x6c, 0x65, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x2a, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x4d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x22, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x3a, 0x3a, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x4d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_module_v1_module_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_module_v1_module_proto_rawDescData = file_sge_legacy_orderbook_module_v1_module_proto_rawDesc +) + +func file_sge_legacy_orderbook_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_module_v1_module_proto_rawDescData) + }) + return file_sge_legacy_orderbook_module_v1_module_proto_rawDescData +} + +var file_sge_legacy_orderbook_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_orderbook_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.legacy.orderbook.module.v1.Module +} +var file_sge_legacy_orderbook_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_module_v1_module_proto_init() } +func file_sge_legacy_orderbook_module_v1_module_proto_init() { + if File_sge_legacy_orderbook_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_orderbook_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_module_v1_module_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_module_v1_module_proto = out.File + file_sge_legacy_orderbook_module_v1_module_proto_rawDesc = nil + file_sge_legacy_orderbook_module_v1_module_proto_goTypes = nil + file_sge_legacy_orderbook_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/exposure.pulsar.go b/api/sge/legacy/orderbook/v1beta/exposure.pulsar.go new file mode 100644 index 00000000..5ee55e58 --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/exposure.pulsar.go @@ -0,0 +1,1756 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_OrderBookOddsExposure_3_list)(nil) + +type _OrderBookOddsExposure_3_list struct { + list *[]uint64 +} + +func (x *_OrderBookOddsExposure_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_OrderBookOddsExposure_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfUint64((*x.list)[i]) +} + +func (x *_OrderBookOddsExposure_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Uint() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_OrderBookOddsExposure_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Uint() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_OrderBookOddsExposure_3_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message OrderBookOddsExposure at list field FulfillmentQueue as it is not of Message kind")) +} + +func (x *_OrderBookOddsExposure_3_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_OrderBookOddsExposure_3_list) NewElement() protoreflect.Value { + v := uint64(0) + return protoreflect.ValueOfUint64(v) +} + +func (x *_OrderBookOddsExposure_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_OrderBookOddsExposure protoreflect.MessageDescriptor + fd_OrderBookOddsExposure_order_book_uid protoreflect.FieldDescriptor + fd_OrderBookOddsExposure_odds_uid protoreflect.FieldDescriptor + fd_OrderBookOddsExposure_fulfillment_queue protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_exposure_proto_init() + md_OrderBookOddsExposure = File_sge_legacy_orderbook_v1beta_exposure_proto.Messages().ByName("OrderBookOddsExposure") + fd_OrderBookOddsExposure_order_book_uid = md_OrderBookOddsExposure.Fields().ByName("order_book_uid") + fd_OrderBookOddsExposure_odds_uid = md_OrderBookOddsExposure.Fields().ByName("odds_uid") + fd_OrderBookOddsExposure_fulfillment_queue = md_OrderBookOddsExposure.Fields().ByName("fulfillment_queue") +} + +var _ protoreflect.Message = (*fastReflection_OrderBookOddsExposure)(nil) + +type fastReflection_OrderBookOddsExposure OrderBookOddsExposure + +func (x *OrderBookOddsExposure) ProtoReflect() protoreflect.Message { + return (*fastReflection_OrderBookOddsExposure)(x) +} + +func (x *OrderBookOddsExposure) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_OrderBookOddsExposure_messageType fastReflection_OrderBookOddsExposure_messageType +var _ protoreflect.MessageType = fastReflection_OrderBookOddsExposure_messageType{} + +type fastReflection_OrderBookOddsExposure_messageType struct{} + +func (x fastReflection_OrderBookOddsExposure_messageType) Zero() protoreflect.Message { + return (*fastReflection_OrderBookOddsExposure)(nil) +} +func (x fastReflection_OrderBookOddsExposure_messageType) New() protoreflect.Message { + return new(fastReflection_OrderBookOddsExposure) +} +func (x fastReflection_OrderBookOddsExposure_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBookOddsExposure +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_OrderBookOddsExposure) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBookOddsExposure +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_OrderBookOddsExposure) Type() protoreflect.MessageType { + return _fastReflection_OrderBookOddsExposure_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_OrderBookOddsExposure) New() protoreflect.Message { + return new(fastReflection_OrderBookOddsExposure) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_OrderBookOddsExposure) Interface() protoreflect.ProtoMessage { + return (*OrderBookOddsExposure)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_OrderBookOddsExposure) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_OrderBookOddsExposure_order_book_uid, value) { + return + } + } + if x.OddsUid != "" { + value := protoreflect.ValueOfString(x.OddsUid) + if !f(fd_OrderBookOddsExposure_odds_uid, value) { + return + } + } + if len(x.FulfillmentQueue) != 0 { + value := protoreflect.ValueOfList(&_OrderBookOddsExposure_3_list{list: &x.FulfillmentQueue}) + if !f(fd_OrderBookOddsExposure_fulfillment_queue, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_OrderBookOddsExposure) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.odds_uid": + return x.OddsUid != "" + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.fulfillment_queue": + return len(x.FulfillmentQueue) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookOddsExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookOddsExposure does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookOddsExposure) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.odds_uid": + x.OddsUid = "" + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.fulfillment_queue": + x.FulfillmentQueue = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookOddsExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookOddsExposure does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_OrderBookOddsExposure) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.odds_uid": + value := x.OddsUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.fulfillment_queue": + if len(x.FulfillmentQueue) == 0 { + return protoreflect.ValueOfList(&_OrderBookOddsExposure_3_list{}) + } + listValue := &_OrderBookOddsExposure_3_list{list: &x.FulfillmentQueue} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookOddsExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookOddsExposure does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookOddsExposure) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.odds_uid": + x.OddsUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.fulfillment_queue": + lv := value.List() + clv := lv.(*_OrderBookOddsExposure_3_list) + x.FulfillmentQueue = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookOddsExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookOddsExposure does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookOddsExposure) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.fulfillment_queue": + if x.FulfillmentQueue == nil { + x.FulfillmentQueue = []uint64{} + } + value := &_OrderBookOddsExposure_3_list{list: &x.FulfillmentQueue} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.OrderBookOddsExposure is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.odds_uid": + panic(fmt.Errorf("field odds_uid of message sge.legacy.orderbook.v1beta.OrderBookOddsExposure is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookOddsExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookOddsExposure does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_OrderBookOddsExposure) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.odds_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookOddsExposure.fulfillment_queue": + list := []uint64{} + return protoreflect.ValueOfList(&_OrderBookOddsExposure_3_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookOddsExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookOddsExposure does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_OrderBookOddsExposure) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.OrderBookOddsExposure", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_OrderBookOddsExposure) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookOddsExposure) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_OrderBookOddsExposure) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_OrderBookOddsExposure) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*OrderBookOddsExposure) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.OddsUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.FulfillmentQueue) > 0 { + l = 0 + for _, e := range x.FulfillmentQueue { + l += runtime.Sov(uint64(e)) + } + n += 1 + runtime.Sov(uint64(l)) + l + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*OrderBookOddsExposure) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.FulfillmentQueue) > 0 { + var pksize2 int + for _, num := range x.FulfillmentQueue { + pksize2 += runtime.Sov(uint64(num)) + } + i -= pksize2 + j1 := i + for _, num := range x.FulfillmentQueue { + for num >= 1<<7 { + dAtA[j1] = uint8(uint64(num)&0x7f | 0x80) + num >>= 7 + j1++ + } + dAtA[j1] = uint8(num) + j1++ + } + i = runtime.EncodeVarint(dAtA, i, uint64(pksize2)) + i-- + dAtA[i] = 0x1a + } + if len(x.OddsUid) > 0 { + i -= len(x.OddsUid) + copy(dAtA[i:], x.OddsUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OddsUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*OrderBookOddsExposure) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBookOddsExposure: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBookOddsExposure: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OddsUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OddsUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType == 0 { + var v uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.FulfillmentQueue = append(x.FulfillmentQueue, v) + } else if wireType == 2 { + var packedLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + packedLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if packedLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + packedLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + var elementCount int + var count int + for _, integer := range dAtA[iNdEx:postIndex] { + if integer < 128 { + count++ + } + } + elementCount = count + if elementCount != 0 && len(x.FulfillmentQueue) == 0 { + x.FulfillmentQueue = make([]uint64, 0, elementCount) + } + for iNdEx < postIndex { + var v uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.FulfillmentQueue = append(x.FulfillmentQueue, v) + } + } else { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FulfillmentQueue", wireType) + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_ParticipationExposure protoreflect.MessageDescriptor + fd_ParticipationExposure_order_book_uid protoreflect.FieldDescriptor + fd_ParticipationExposure_odds_uid protoreflect.FieldDescriptor + fd_ParticipationExposure_participation_index protoreflect.FieldDescriptor + fd_ParticipationExposure_exposure protoreflect.FieldDescriptor + fd_ParticipationExposure_bet_amount protoreflect.FieldDescriptor + fd_ParticipationExposure_is_fulfilled protoreflect.FieldDescriptor + fd_ParticipationExposure_round protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_exposure_proto_init() + md_ParticipationExposure = File_sge_legacy_orderbook_v1beta_exposure_proto.Messages().ByName("ParticipationExposure") + fd_ParticipationExposure_order_book_uid = md_ParticipationExposure.Fields().ByName("order_book_uid") + fd_ParticipationExposure_odds_uid = md_ParticipationExposure.Fields().ByName("odds_uid") + fd_ParticipationExposure_participation_index = md_ParticipationExposure.Fields().ByName("participation_index") + fd_ParticipationExposure_exposure = md_ParticipationExposure.Fields().ByName("exposure") + fd_ParticipationExposure_bet_amount = md_ParticipationExposure.Fields().ByName("bet_amount") + fd_ParticipationExposure_is_fulfilled = md_ParticipationExposure.Fields().ByName("is_fulfilled") + fd_ParticipationExposure_round = md_ParticipationExposure.Fields().ByName("round") +} + +var _ protoreflect.Message = (*fastReflection_ParticipationExposure)(nil) + +type fastReflection_ParticipationExposure ParticipationExposure + +func (x *ParticipationExposure) ProtoReflect() protoreflect.Message { + return (*fastReflection_ParticipationExposure)(x) +} + +func (x *ParticipationExposure) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_ParticipationExposure_messageType fastReflection_ParticipationExposure_messageType +var _ protoreflect.MessageType = fastReflection_ParticipationExposure_messageType{} + +type fastReflection_ParticipationExposure_messageType struct{} + +func (x fastReflection_ParticipationExposure_messageType) Zero() protoreflect.Message { + return (*fastReflection_ParticipationExposure)(nil) +} +func (x fastReflection_ParticipationExposure_messageType) New() protoreflect.Message { + return new(fastReflection_ParticipationExposure) +} +func (x fastReflection_ParticipationExposure_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_ParticipationExposure +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_ParticipationExposure) Descriptor() protoreflect.MessageDescriptor { + return md_ParticipationExposure +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_ParticipationExposure) Type() protoreflect.MessageType { + return _fastReflection_ParticipationExposure_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_ParticipationExposure) New() protoreflect.Message { + return new(fastReflection_ParticipationExposure) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_ParticipationExposure) Interface() protoreflect.ProtoMessage { + return (*ParticipationExposure)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_ParticipationExposure) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_ParticipationExposure_order_book_uid, value) { + return + } + } + if x.OddsUid != "" { + value := protoreflect.ValueOfString(x.OddsUid) + if !f(fd_ParticipationExposure_odds_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_ParticipationExposure_participation_index, value) { + return + } + } + if x.Exposure != "" { + value := protoreflect.ValueOfString(x.Exposure) + if !f(fd_ParticipationExposure_exposure, value) { + return + } + } + if x.BetAmount != "" { + value := protoreflect.ValueOfString(x.BetAmount) + if !f(fd_ParticipationExposure_bet_amount, value) { + return + } + } + if x.IsFulfilled != false { + value := protoreflect.ValueOfBool(x.IsFulfilled) + if !f(fd_ParticipationExposure_is_fulfilled, value) { + return + } + } + if x.Round != uint64(0) { + value := protoreflect.ValueOfUint64(x.Round) + if !f(fd_ParticipationExposure_round, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_ParticipationExposure) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationExposure.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.odds_uid": + return x.OddsUid != "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.exposure": + return x.Exposure != "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.bet_amount": + return x.BetAmount != "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.is_fulfilled": + return x.IsFulfilled != false + case "sge.legacy.orderbook.v1beta.ParticipationExposure.round": + return x.Round != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationExposure does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationExposure) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationExposure.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.odds_uid": + x.OddsUid = "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.exposure": + x.Exposure = "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.bet_amount": + x.BetAmount = "" + case "sge.legacy.orderbook.v1beta.ParticipationExposure.is_fulfilled": + x.IsFulfilled = false + case "sge.legacy.orderbook.v1beta.ParticipationExposure.round": + x.Round = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationExposure does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_ParticipationExposure) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationExposure.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.odds_uid": + value := x.OddsUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.exposure": + value := x.Exposure + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.bet_amount": + value := x.BetAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.is_fulfilled": + value := x.IsFulfilled + return protoreflect.ValueOfBool(value) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.round": + value := x.Round + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationExposure does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationExposure) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationExposure.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.odds_uid": + x.OddsUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.orderbook.v1beta.ParticipationExposure.exposure": + x.Exposure = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.bet_amount": + x.BetAmount = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.is_fulfilled": + x.IsFulfilled = value.Bool() + case "sge.legacy.orderbook.v1beta.ParticipationExposure.round": + x.Round = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationExposure does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationExposure) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationExposure.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.ParticipationExposure is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.odds_uid": + panic(fmt.Errorf("field odds_uid of message sge.legacy.orderbook.v1beta.ParticipationExposure is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.orderbook.v1beta.ParticipationExposure is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.exposure": + panic(fmt.Errorf("field exposure of message sge.legacy.orderbook.v1beta.ParticipationExposure is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.bet_amount": + panic(fmt.Errorf("field bet_amount of message sge.legacy.orderbook.v1beta.ParticipationExposure is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.is_fulfilled": + panic(fmt.Errorf("field is_fulfilled of message sge.legacy.orderbook.v1beta.ParticipationExposure is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.round": + panic(fmt.Errorf("field round of message sge.legacy.orderbook.v1beta.ParticipationExposure is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationExposure does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_ParticipationExposure) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationExposure.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.ParticipationExposure.odds_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.ParticipationExposure.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.exposure": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.ParticipationExposure.bet_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.ParticipationExposure.is_fulfilled": + return protoreflect.ValueOfBool(false) + case "sge.legacy.orderbook.v1beta.ParticipationExposure.round": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationExposure")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationExposure does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_ParticipationExposure) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.ParticipationExposure", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_ParticipationExposure) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationExposure) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_ParticipationExposure) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_ParticipationExposure) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*ParticipationExposure) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.OddsUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + l = len(x.Exposure) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.BetAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.IsFulfilled { + n += 2 + } + if x.Round != 0 { + n += 1 + runtime.Sov(uint64(x.Round)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*ParticipationExposure) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Round != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Round)) + i-- + dAtA[i] = 0x38 + } + if x.IsFulfilled { + i-- + if x.IsFulfilled { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x30 + } + if len(x.BetAmount) > 0 { + i -= len(x.BetAmount) + copy(dAtA[i:], x.BetAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BetAmount))) + i-- + dAtA[i] = 0x2a + } + if len(x.Exposure) > 0 { + i -= len(x.Exposure) + copy(dAtA[i:], x.Exposure) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Exposure))) + i-- + dAtA[i] = 0x22 + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x18 + } + if len(x.OddsUid) > 0 { + i -= len(x.OddsUid) + copy(dAtA[i:], x.OddsUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OddsUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*ParticipationExposure) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ParticipationExposure: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ParticipationExposure: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OddsUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OddsUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Exposure", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Exposure = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BetAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BetAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field IsFulfilled", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.IsFulfilled = bool(v != 0) + case 7: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Round", wireType) + } + x.Round = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Round |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/exposure.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// OrderBookOddsExposure represents the exposures taken on odds. +type OrderBookOddsExposure struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid is the universally unique identifier corresponding to the + // order book. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,proto3" json:"order_book_uid,omitempty"` + // odds_uid is the universally unique identifier of the odds. + OddsUid string `protobuf:"bytes,2,opt,name=odds_uid,proto3" json:"odds_uid,omitempty"` + // fulfillment_queue is the slice of indices of participations to be + // fulfilled. + FulfillmentQueue []uint64 `protobuf:"varint,3,rep,packed,name=fulfillment_queue,json=fulfillmentQueue,proto3" json:"fulfillment_queue,omitempty"` +} + +func (x *OrderBookOddsExposure) Reset() { + *x = OrderBookOddsExposure{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *OrderBookOddsExposure) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*OrderBookOddsExposure) ProtoMessage() {} + +// Deprecated: Use OrderBookOddsExposure.ProtoReflect.Descriptor instead. +func (*OrderBookOddsExposure) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescGZIP(), []int{0} +} + +func (x *OrderBookOddsExposure) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *OrderBookOddsExposure) GetOddsUid() string { + if x != nil { + return x.OddsUid + } + return "" +} + +func (x *OrderBookOddsExposure) GetFulfillmentQueue() []uint64 { + if x != nil { + return x.FulfillmentQueue + } + return nil +} + +// ParticipationExposure represents the exposures taken on odds by +// participations. +type ParticipationExposure struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid is the universally unique identifier of the order book that + // the exposure is being set. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,proto3" json:"order_book_uid,omitempty"` + // odds_uid is the odds universal unique identifier that the exposure is being + // set. + OddsUid string `protobuf:"bytes,2,opt,name=odds_uid,proto3" json:"odds_uid,omitempty"` + // participation_index is the index of participation in the queue. + ParticipationIndex uint64 `protobuf:"varint,3,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // exposure is the total exposure taken on given odds. + Exposure string `protobuf:"bytes,4,opt,name=exposure,proto3" json:"exposure,omitempty"` + // bet_amount is the total bet amount corresponding to the exposure. + BetAmount string `protobuf:"bytes,5,opt,name=bet_amount,json=betAmount,proto3" json:"bet_amount,omitempty"` + // is_fulfilled represents if the participation exposure is fulfilled or not. + IsFulfilled bool `protobuf:"varint,6,opt,name=is_fulfilled,json=isFulfilled,proto3" json:"is_fulfilled,omitempty"` + // round is the current round number in the queue. + Round uint64 `protobuf:"varint,7,opt,name=round,proto3" json:"round,omitempty"` +} + +func (x *ParticipationExposure) Reset() { + *x = ParticipationExposure{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ParticipationExposure) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ParticipationExposure) ProtoMessage() {} + +// Deprecated: Use ParticipationExposure.ProtoReflect.Descriptor instead. +func (*ParticipationExposure) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescGZIP(), []int{1} +} + +func (x *ParticipationExposure) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *ParticipationExposure) GetOddsUid() string { + if x != nil { + return x.OddsUid + } + return "" +} + +func (x *ParticipationExposure) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *ParticipationExposure) GetExposure() string { + if x != nil { + return x.Exposure + } + return "" +} + +func (x *ParticipationExposure) GetBetAmount() string { + if x != nil { + return x.BetAmount + } + return "" +} + +func (x *ParticipationExposure) GetIsFulfilled() bool { + if x != nil { + return x.IsFulfilled + } + return false +} + +func (x *ParticipationExposure) GetRound() uint64 { + if x != nil { + return x.Round + } + return 0 +} + +var File_sge_legacy_orderbook_v1beta_exposure_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_exposure_proto_rawDesc = []byte{ + 0x0a, 0x2a, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x65, 0x78, + 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, + 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, + 0xf1, 0x01, 0x0a, 0x15, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x4f, 0x64, 0x64, + 0x73, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x12, 0x4a, 0x0a, 0x0e, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x22, 0xe2, 0xde, 0x1f, 0x0c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, + 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, + 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, + 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x33, 0x0a, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x17, 0xe2, 0xde, 0x1f, 0x07, 0x4f, 0x64, 0x64, + 0x73, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, + 0x52, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x49, 0x0a, 0x11, 0x66, 0x75, + 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x71, 0x75, 0x65, 0x75, 0x65, 0x18, + 0x03, 0x20, 0x03, 0x28, 0x04, 0x42, 0x1c, 0xf2, 0xde, 0x1f, 0x18, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x66, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x71, 0x75, 0x65, + 0x75, 0x65, 0x22, 0x52, 0x10, 0x66, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x6d, 0x65, 0x6e, 0x74, + 0x51, 0x75, 0x65, 0x75, 0x65, 0x3a, 0x0c, 0x88, 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x00, 0xe8, + 0xa0, 0x1f, 0x00, 0x22, 0xfc, 0x03, 0x0a, 0x15, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x12, 0x4a, 0x0a, + 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x22, 0xe2, 0xde, 0x1f, 0x0c, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x33, 0x0a, 0x08, 0x6f, 0x64, 0x64, + 0x73, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x17, 0xe2, 0xde, 0x1f, + 0x07, 0x4f, 0x64, 0x64, 0x73, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x08, 0x6f, 0x64, 0x64, 0x73, + 0x5f, 0x75, 0x69, 0x64, 0x52, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x4f, + 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, + 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1e, 0xf2, 0xde, 0x1f, + 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, + 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, + 0x4c, 0x0a, 0x08, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x30, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, + 0xf2, 0xde, 0x1f, 0x0f, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, + 0x72, 0x65, 0x22, 0x52, 0x08, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x12, 0x51, 0x0a, + 0x0a, 0x62, 0x65, 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x32, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, + 0xf2, 0xde, 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x62, 0x65, 0x74, 0x5f, 0x61, 0x6d, + 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x09, 0x62, 0x65, 0x74, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, + 0x12, 0x3a, 0x0a, 0x0c, 0x69, 0x73, 0x5f, 0x66, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x42, 0x17, 0xf2, 0xde, 0x1f, 0x13, 0x79, 0x61, 0x6d, 0x6c, + 0x3a, 0x22, 0x69, 0x73, 0x5f, 0x66, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x22, 0x52, + 0x0b, 0x69, 0x73, 0x46, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x12, 0x26, 0x0a, 0x05, + 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x04, 0x42, 0x10, 0xf2, 0xde, 0x1f, + 0x0c, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x22, 0x52, 0x05, 0x72, + 0x6f, 0x75, 0x6e, 0x64, 0x3a, 0x0c, 0x88, 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, + 0x1f, 0x00, 0x42, 0x8b, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0d, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x2e, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, + 0x02, 0x1e, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescData = file_sge_legacy_orderbook_v1beta_exposure_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_exposure_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_orderbook_v1beta_exposure_proto_goTypes = []interface{}{ + (*OrderBookOddsExposure)(nil), // 0: sge.legacy.orderbook.v1beta.OrderBookOddsExposure + (*ParticipationExposure)(nil), // 1: sge.legacy.orderbook.v1beta.ParticipationExposure +} +var file_sge_legacy_orderbook_v1beta_exposure_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_exposure_proto_init() } +func file_sge_legacy_orderbook_v1beta_exposure_proto_init() { + if File_sge_legacy_orderbook_v1beta_exposure_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*OrderBookOddsExposure); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ParticipationExposure); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_exposure_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_exposure_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_exposure_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_v1beta_exposure_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_exposure_proto = out.File + file_sge_legacy_orderbook_v1beta_exposure_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_exposure_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_exposure_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/genesis.pulsar.go b/api/sge/legacy/orderbook/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..107c71a5 --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/genesis.pulsar.go @@ -0,0 +1,1813 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_2_list)(nil) + +type _GenesisState_2_list struct { + list *[]*OrderBook +} + +func (x *_GenesisState_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBook) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBook) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_2_list) AppendMutable() protoreflect.Value { + v := new(OrderBook) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_2_list) NewElement() protoreflect.Value { + v := new(OrderBook) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_3_list)(nil) + +type _GenesisState_3_list struct { + list *[]*OrderBookParticipation +} + +func (x *_GenesisState_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookParticipation) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookParticipation) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_3_list) AppendMutable() protoreflect.Value { + v := new(OrderBookParticipation) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_3_list) NewElement() protoreflect.Value { + v := new(OrderBookParticipation) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_4_list)(nil) + +type _GenesisState_4_list struct { + list *[]*OrderBookOddsExposure +} + +func (x *_GenesisState_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookOddsExposure) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookOddsExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_4_list) AppendMutable() protoreflect.Value { + v := new(OrderBookOddsExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_4_list) NewElement() protoreflect.Value { + v := new(OrderBookOddsExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_4_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_5_list)(nil) + +type _GenesisState_5_list struct { + list *[]*ParticipationExposure +} + +func (x *_GenesisState_5_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_5_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_5_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_5_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_5_list) AppendMutable() protoreflect.Value { + v := new(ParticipationExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_5_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_5_list) NewElement() protoreflect.Value { + v := new(ParticipationExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_5_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_6_list)(nil) + +type _GenesisState_6_list struct { + list *[]*ParticipationExposure +} + +func (x *_GenesisState_6_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_6_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_6_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_6_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_6_list) AppendMutable() protoreflect.Value { + v := new(ParticipationExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_6_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_6_list) NewElement() protoreflect.Value { + v := new(ParticipationExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_6_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_7_list)(nil) + +type _GenesisState_7_list struct { + list *[]*ParticipationExposure +} + +func (x *_GenesisState_7_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_7_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_7_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_7_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_7_list) AppendMutable() protoreflect.Value { + v := new(ParticipationExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_7_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_7_list) NewElement() protoreflect.Value { + v := new(ParticipationExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_7_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_8_list)(nil) + +type _GenesisState_8_list struct { + list *[]*ParticipationBetPair +} + +func (x *_GenesisState_8_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_8_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_8_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationBetPair) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_8_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationBetPair) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_8_list) AppendMutable() protoreflect.Value { + v := new(ParticipationBetPair) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_8_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_8_list) NewElement() protoreflect.Value { + v := new(ParticipationBetPair) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_8_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor + fd_GenesisState_order_book_list protoreflect.FieldDescriptor + fd_GenesisState_order_book_participation_list protoreflect.FieldDescriptor + fd_GenesisState_order_book_exposure_list protoreflect.FieldDescriptor + fd_GenesisState_participation_exposure_list protoreflect.FieldDescriptor + fd_GenesisState_participation_exposure_by_index_list protoreflect.FieldDescriptor + fd_GenesisState_historical_participation_exposure_list protoreflect.FieldDescriptor + fd_GenesisState_participation_bet_pair_exposure_list protoreflect.FieldDescriptor + fd_GenesisState_stats protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_genesis_proto_init() + md_GenesisState = File_sge_legacy_orderbook_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") + fd_GenesisState_order_book_list = md_GenesisState.Fields().ByName("order_book_list") + fd_GenesisState_order_book_participation_list = md_GenesisState.Fields().ByName("order_book_participation_list") + fd_GenesisState_order_book_exposure_list = md_GenesisState.Fields().ByName("order_book_exposure_list") + fd_GenesisState_participation_exposure_list = md_GenesisState.Fields().ByName("participation_exposure_list") + fd_GenesisState_participation_exposure_by_index_list = md_GenesisState.Fields().ByName("participation_exposure_by_index_list") + fd_GenesisState_historical_participation_exposure_list = md_GenesisState.Fields().ByName("historical_participation_exposure_list") + fd_GenesisState_participation_bet_pair_exposure_list = md_GenesisState.Fields().ByName("participation_bet_pair_exposure_list") + fd_GenesisState_stats = md_GenesisState.Fields().ByName("stats") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } + if len(x.OrderBookList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_2_list{list: &x.OrderBookList}) + if !f(fd_GenesisState_order_book_list, value) { + return + } + } + if len(x.OrderBookParticipationList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_3_list{list: &x.OrderBookParticipationList}) + if !f(fd_GenesisState_order_book_participation_list, value) { + return + } + } + if len(x.OrderBookExposureList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_4_list{list: &x.OrderBookExposureList}) + if !f(fd_GenesisState_order_book_exposure_list, value) { + return + } + } + if len(x.ParticipationExposureList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_5_list{list: &x.ParticipationExposureList}) + if !f(fd_GenesisState_participation_exposure_list, value) { + return + } + } + if len(x.ParticipationExposureByIndexList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_6_list{list: &x.ParticipationExposureByIndexList}) + if !f(fd_GenesisState_participation_exposure_by_index_list, value) { + return + } + } + if len(x.HistoricalParticipationExposureList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_7_list{list: &x.HistoricalParticipationExposureList}) + if !f(fd_GenesisState_historical_participation_exposure_list, value) { + return + } + } + if len(x.ParticipationBetPairExposureList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_8_list{list: &x.ParticipationBetPairExposureList}) + if !f(fd_GenesisState_participation_bet_pair_exposure_list, value) { + return + } + } + if x.Stats != nil { + value := protoreflect.ValueOfMessage(x.Stats.ProtoReflect()) + if !f(fd_GenesisState_stats, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.GenesisState.params": + return x.Params != nil + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_list": + return len(x.OrderBookList) != 0 + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_participation_list": + return len(x.OrderBookParticipationList) != 0 + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_exposure_list": + return len(x.OrderBookExposureList) != 0 + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_list": + return len(x.ParticipationExposureList) != 0 + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_by_index_list": + return len(x.ParticipationExposureByIndexList) != 0 + case "sge.legacy.orderbook.v1beta.GenesisState.historical_participation_exposure_list": + return len(x.HistoricalParticipationExposureList) != 0 + case "sge.legacy.orderbook.v1beta.GenesisState.participation_bet_pair_exposure_list": + return len(x.ParticipationBetPairExposureList) != 0 + case "sge.legacy.orderbook.v1beta.GenesisState.stats": + return x.Stats != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.GenesisState.params": + x.Params = nil + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_list": + x.OrderBookList = nil + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_participation_list": + x.OrderBookParticipationList = nil + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_exposure_list": + x.OrderBookExposureList = nil + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_list": + x.ParticipationExposureList = nil + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_by_index_list": + x.ParticipationExposureByIndexList = nil + case "sge.legacy.orderbook.v1beta.GenesisState.historical_participation_exposure_list": + x.HistoricalParticipationExposureList = nil + case "sge.legacy.orderbook.v1beta.GenesisState.participation_bet_pair_exposure_list": + x.ParticipationBetPairExposureList = nil + case "sge.legacy.orderbook.v1beta.GenesisState.stats": + x.Stats = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_list": + if len(x.OrderBookList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_2_list{}) + } + listValue := &_GenesisState_2_list{list: &x.OrderBookList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_participation_list": + if len(x.OrderBookParticipationList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_3_list{}) + } + listValue := &_GenesisState_3_list{list: &x.OrderBookParticipationList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_exposure_list": + if len(x.OrderBookExposureList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_4_list{}) + } + listValue := &_GenesisState_4_list{list: &x.OrderBookExposureList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_list": + if len(x.ParticipationExposureList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_5_list{}) + } + listValue := &_GenesisState_5_list{list: &x.ParticipationExposureList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_by_index_list": + if len(x.ParticipationExposureByIndexList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_6_list{}) + } + listValue := &_GenesisState_6_list{list: &x.ParticipationExposureByIndexList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.GenesisState.historical_participation_exposure_list": + if len(x.HistoricalParticipationExposureList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_7_list{}) + } + listValue := &_GenesisState_7_list{list: &x.HistoricalParticipationExposureList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_bet_pair_exposure_list": + if len(x.ParticipationBetPairExposureList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_8_list{}) + } + listValue := &_GenesisState_8_list{list: &x.ParticipationBetPairExposureList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.GenesisState.stats": + value := x.Stats + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_list": + lv := value.List() + clv := lv.(*_GenesisState_2_list) + x.OrderBookList = *clv.list + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_participation_list": + lv := value.List() + clv := lv.(*_GenesisState_3_list) + x.OrderBookParticipationList = *clv.list + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_exposure_list": + lv := value.List() + clv := lv.(*_GenesisState_4_list) + x.OrderBookExposureList = *clv.list + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_list": + lv := value.List() + clv := lv.(*_GenesisState_5_list) + x.ParticipationExposureList = *clv.list + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_by_index_list": + lv := value.List() + clv := lv.(*_GenesisState_6_list) + x.ParticipationExposureByIndexList = *clv.list + case "sge.legacy.orderbook.v1beta.GenesisState.historical_participation_exposure_list": + lv := value.List() + clv := lv.(*_GenesisState_7_list) + x.HistoricalParticipationExposureList = *clv.list + case "sge.legacy.orderbook.v1beta.GenesisState.participation_bet_pair_exposure_list": + lv := value.List() + clv := lv.(*_GenesisState_8_list) + x.ParticipationBetPairExposureList = *clv.list + case "sge.legacy.orderbook.v1beta.GenesisState.stats": + x.Stats = value.Message().Interface().(*OrderBookStats) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_list": + if x.OrderBookList == nil { + x.OrderBookList = []*OrderBook{} + } + value := &_GenesisState_2_list{list: &x.OrderBookList} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_participation_list": + if x.OrderBookParticipationList == nil { + x.OrderBookParticipationList = []*OrderBookParticipation{} + } + value := &_GenesisState_3_list{list: &x.OrderBookParticipationList} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_exposure_list": + if x.OrderBookExposureList == nil { + x.OrderBookExposureList = []*OrderBookOddsExposure{} + } + value := &_GenesisState_4_list{list: &x.OrderBookExposureList} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_list": + if x.ParticipationExposureList == nil { + x.ParticipationExposureList = []*ParticipationExposure{} + } + value := &_GenesisState_5_list{list: &x.ParticipationExposureList} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_by_index_list": + if x.ParticipationExposureByIndexList == nil { + x.ParticipationExposureByIndexList = []*ParticipationExposure{} + } + value := &_GenesisState_6_list{list: &x.ParticipationExposureByIndexList} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.GenesisState.historical_participation_exposure_list": + if x.HistoricalParticipationExposureList == nil { + x.HistoricalParticipationExposureList = []*ParticipationExposure{} + } + value := &_GenesisState_7_list{list: &x.HistoricalParticipationExposureList} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_bet_pair_exposure_list": + if x.ParticipationBetPairExposureList == nil { + x.ParticipationBetPairExposureList = []*ParticipationBetPair{} + } + value := &_GenesisState_8_list{list: &x.ParticipationBetPairExposureList} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.GenesisState.stats": + if x.Stats == nil { + x.Stats = new(OrderBookStats) + } + return protoreflect.ValueOfMessage(x.Stats.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_list": + list := []*OrderBook{} + return protoreflect.ValueOfList(&_GenesisState_2_list{list: &list}) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_participation_list": + list := []*OrderBookParticipation{} + return protoreflect.ValueOfList(&_GenesisState_3_list{list: &list}) + case "sge.legacy.orderbook.v1beta.GenesisState.order_book_exposure_list": + list := []*OrderBookOddsExposure{} + return protoreflect.ValueOfList(&_GenesisState_4_list{list: &list}) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_list": + list := []*ParticipationExposure{} + return protoreflect.ValueOfList(&_GenesisState_5_list{list: &list}) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_by_index_list": + list := []*ParticipationExposure{} + return protoreflect.ValueOfList(&_GenesisState_6_list{list: &list}) + case "sge.legacy.orderbook.v1beta.GenesisState.historical_participation_exposure_list": + list := []*ParticipationExposure{} + return protoreflect.ValueOfList(&_GenesisState_7_list{list: &list}) + case "sge.legacy.orderbook.v1beta.GenesisState.participation_bet_pair_exposure_list": + list := []*ParticipationBetPair{} + return protoreflect.ValueOfList(&_GenesisState_8_list{list: &list}) + case "sge.legacy.orderbook.v1beta.GenesisState.stats": + m := new(OrderBookStats) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.OrderBookList) > 0 { + for _, e := range x.OrderBookList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.OrderBookParticipationList) > 0 { + for _, e := range x.OrderBookParticipationList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.OrderBookExposureList) > 0 { + for _, e := range x.OrderBookExposureList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.ParticipationExposureList) > 0 { + for _, e := range x.ParticipationExposureList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.ParticipationExposureByIndexList) > 0 { + for _, e := range x.ParticipationExposureByIndexList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.HistoricalParticipationExposureList) > 0 { + for _, e := range x.HistoricalParticipationExposureList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.ParticipationBetPairExposureList) > 0 { + for _, e := range x.ParticipationBetPairExposureList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Stats != nil { + l = options.Size(x.Stats) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Stats != nil { + encoded, err := options.Marshal(x.Stats) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x4a + } + if len(x.ParticipationBetPairExposureList) > 0 { + for iNdEx := len(x.ParticipationBetPairExposureList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ParticipationBetPairExposureList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x42 + } + } + if len(x.HistoricalParticipationExposureList) > 0 { + for iNdEx := len(x.HistoricalParticipationExposureList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.HistoricalParticipationExposureList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x3a + } + } + if len(x.ParticipationExposureByIndexList) > 0 { + for iNdEx := len(x.ParticipationExposureByIndexList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ParticipationExposureByIndexList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x32 + } + } + if len(x.ParticipationExposureList) > 0 { + for iNdEx := len(x.ParticipationExposureList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ParticipationExposureList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x2a + } + } + if len(x.OrderBookExposureList) > 0 { + for iNdEx := len(x.OrderBookExposureList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.OrderBookExposureList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if len(x.OrderBookParticipationList) > 0 { + for iNdEx := len(x.OrderBookParticipationList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.OrderBookParticipationList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if len(x.OrderBookList) > 0 { + for iNdEx := len(x.OrderBookList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.OrderBookList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookList = append(x.OrderBookList, &OrderBook{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBookList[len(x.OrderBookList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookParticipationList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookParticipationList = append(x.OrderBookParticipationList, &OrderBookParticipation{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBookParticipationList[len(x.OrderBookParticipationList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookExposureList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookExposureList = append(x.OrderBookExposureList, &OrderBookOddsExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBookExposureList[len(x.OrderBookExposureList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationExposureList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipationExposureList = append(x.ParticipationExposureList, &ParticipationExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ParticipationExposureList[len(x.ParticipationExposureList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationExposureByIndexList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipationExposureByIndexList = append(x.ParticipationExposureByIndexList, &ParticipationExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ParticipationExposureByIndexList[len(x.ParticipationExposureByIndexList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field HistoricalParticipationExposureList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.HistoricalParticipationExposureList = append(x.HistoricalParticipationExposureList, &ParticipationExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.HistoricalParticipationExposureList[len(x.HistoricalParticipationExposureList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationBetPairExposureList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipationBetPairExposureList = append(x.ParticipationBetPairExposureList, &ParticipationBetPair{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ParticipationBetPairExposureList[len(x.ParticipationBetPairExposureList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 9: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Stats", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Stats == nil { + x.Stats = &OrderBookStats{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Stats); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the orderbook module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params defines all the parameters related to order book. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` + // order_book_list defines the order books available at genesis. + OrderBookList []*OrderBook `protobuf:"bytes,2,rep,name=order_book_list,json=orderBookList,proto3" json:"order_book_list,omitempty"` + // order_book_participation_list defines the book participations available at + // genesis. + OrderBookParticipationList []*OrderBookParticipation `protobuf:"bytes,3,rep,name=order_book_participation_list,json=orderBookParticipationList,proto3" json:"order_book_participation_list,omitempty"` + // order_book_exposure_list defines the order book exposures available at + // genesis. + OrderBookExposureList []*OrderBookOddsExposure `protobuf:"bytes,4,rep,name=order_book_exposure_list,json=orderBookExposureList,proto3" json:"order_book_exposure_list,omitempty"` + // participation_exposure_list defines the participation exposures available + // at genesis. + ParticipationExposureList []*ParticipationExposure `protobuf:"bytes,5,rep,name=participation_exposure_list,json=participationExposureList,proto3" json:"participation_exposure_list,omitempty"` + // participation_exposure_by_index_list defines the participation exposures by + // the indices available at genesis. + ParticipationExposureByIndexList []*ParticipationExposure `protobuf:"bytes,6,rep,name=participation_exposure_by_index_list,json=participationExposureByIndexList,proto3" json:"participation_exposure_by_index_list,omitempty"` + // historical_participation_exposure_list defines the historical participation + // exposures available at genesis. + HistoricalParticipationExposureList []*ParticipationExposure `protobuf:"bytes,7,rep,name=historical_participation_exposure_list,json=historicalParticipationExposureList,proto3" json:"historical_participation_exposure_list,omitempty"` + // historical_participation_exposure_list defines the participation bet pair + // exposures available at genesis. + ParticipationBetPairExposureList []*ParticipationBetPair `protobuf:"bytes,8,rep,name=participation_bet_pair_exposure_list,json=participationBetPairExposureList,proto3" json:"participation_bet_pair_exposure_list,omitempty"` + // stats is the statistics of the order book. + Stats *OrderBookStats `protobuf:"bytes,9,opt,name=stats,proto3" json:"stats,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +func (x *GenesisState) GetOrderBookList() []*OrderBook { + if x != nil { + return x.OrderBookList + } + return nil +} + +func (x *GenesisState) GetOrderBookParticipationList() []*OrderBookParticipation { + if x != nil { + return x.OrderBookParticipationList + } + return nil +} + +func (x *GenesisState) GetOrderBookExposureList() []*OrderBookOddsExposure { + if x != nil { + return x.OrderBookExposureList + } + return nil +} + +func (x *GenesisState) GetParticipationExposureList() []*ParticipationExposure { + if x != nil { + return x.ParticipationExposureList + } + return nil +} + +func (x *GenesisState) GetParticipationExposureByIndexList() []*ParticipationExposure { + if x != nil { + return x.ParticipationExposureByIndexList + } + return nil +} + +func (x *GenesisState) GetHistoricalParticipationExposureList() []*ParticipationExposure { + if x != nil { + return x.HistoricalParticipationExposureList + } + return nil +} + +func (x *GenesisState) GetParticipationBetPairExposureList() []*ParticipationBetPair { + if x != nil { + return x.ParticipationBetPairExposureList + } + return nil +} + +func (x *GenesisState) GetStats() *OrderBookStats { + if x != nil { + return x.Stats + } + return nil +} + +var File_sge_legacy_orderbook_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x29, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x67, 0x65, + 0x6e, 0x65, 0x73, 0x69, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x2a, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x65, 0x78, 0x70, 0x6f, + 0x73, 0x75, 0x72, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x2b, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x28, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, + 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, + 0x73, 0x74, 0x61, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x80, 0x08, 0x0a, 0x0c, + 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x41, 0x0a, 0x06, + 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, + 0x54, 0x0a, 0x0f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x6c, 0x69, + 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, + 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0d, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, + 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x7c, 0x0a, 0x1d, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, + 0x6f, 0x6f, 0x6b, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x33, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x1a, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4c, + 0x69, 0x73, 0x74, 0x12, 0x71, 0x0a, 0x18, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, + 0x6b, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, + 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x4f, 0x64, 0x64, + 0x73, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, + 0x15, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, + 0x72, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x78, 0x0a, 0x1b, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, + 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, + 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x42, + 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x19, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x4c, 0x69, 0x73, 0x74, + 0x12, 0x88, 0x01, 0x0a, 0x24, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x5f, 0x62, 0x79, 0x5f, 0x69, + 0x6e, 0x64, 0x65, 0x78, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, + 0x75, 0x72, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x20, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, + 0x42, 0x79, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x8d, 0x01, 0x0a, 0x26, + 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, + 0x65, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, + 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x23, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, + 0x61, 0x6c, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, + 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x87, 0x01, 0x0a, 0x24, + 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x62, 0x65, + 0x74, 0x5f, 0x70, 0x61, 0x69, 0x72, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x5f, + 0x6c, 0x69, 0x73, 0x74, 0x18, 0x08, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x31, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x65, 0x74, 0x50, 0x61, 0x69, 0x72, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x00, 0x52, 0x20, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x42, 0x65, 0x74, 0x50, 0x61, 0x69, 0x72, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, + 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x47, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x53, 0x74, 0x61, 0x74, + 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x73, 0x42, 0x8a, + 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x50, 0x01, 0x5a, 0x4a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, + 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, + 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1e, 0x53, 0x67, 0x65, + 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescData = file_sge_legacy_orderbook_v1beta_genesis_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_genesis_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_orderbook_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.legacy.orderbook.v1beta.GenesisState + (*Params)(nil), // 1: sge.legacy.orderbook.v1beta.Params + (*OrderBook)(nil), // 2: sge.legacy.orderbook.v1beta.OrderBook + (*OrderBookParticipation)(nil), // 3: sge.legacy.orderbook.v1beta.OrderBookParticipation + (*OrderBookOddsExposure)(nil), // 4: sge.legacy.orderbook.v1beta.OrderBookOddsExposure + (*ParticipationExposure)(nil), // 5: sge.legacy.orderbook.v1beta.ParticipationExposure + (*ParticipationBetPair)(nil), // 6: sge.legacy.orderbook.v1beta.ParticipationBetPair + (*OrderBookStats)(nil), // 7: sge.legacy.orderbook.v1beta.OrderBookStats +} +var file_sge_legacy_orderbook_v1beta_genesis_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.orderbook.v1beta.GenesisState.params:type_name -> sge.legacy.orderbook.v1beta.Params + 2, // 1: sge.legacy.orderbook.v1beta.GenesisState.order_book_list:type_name -> sge.legacy.orderbook.v1beta.OrderBook + 3, // 2: sge.legacy.orderbook.v1beta.GenesisState.order_book_participation_list:type_name -> sge.legacy.orderbook.v1beta.OrderBookParticipation + 4, // 3: sge.legacy.orderbook.v1beta.GenesisState.order_book_exposure_list:type_name -> sge.legacy.orderbook.v1beta.OrderBookOddsExposure + 5, // 4: sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_list:type_name -> sge.legacy.orderbook.v1beta.ParticipationExposure + 5, // 5: sge.legacy.orderbook.v1beta.GenesisState.participation_exposure_by_index_list:type_name -> sge.legacy.orderbook.v1beta.ParticipationExposure + 5, // 6: sge.legacy.orderbook.v1beta.GenesisState.historical_participation_exposure_list:type_name -> sge.legacy.orderbook.v1beta.ParticipationExposure + 6, // 7: sge.legacy.orderbook.v1beta.GenesisState.participation_bet_pair_exposure_list:type_name -> sge.legacy.orderbook.v1beta.ParticipationBetPair + 7, // 8: sge.legacy.orderbook.v1beta.GenesisState.stats:type_name -> sge.legacy.orderbook.v1beta.OrderBookStats + 9, // [9:9] is the sub-list for method output_type + 9, // [9:9] is the sub-list for method input_type + 9, // [9:9] is the sub-list for extension type_name + 9, // [9:9] is the sub-list for extension extendee + 0, // [0:9] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_genesis_proto_init() } +func file_sge_legacy_orderbook_v1beta_genesis_proto_init() { + if File_sge_legacy_orderbook_v1beta_genesis_proto != nil { + return + } + file_sge_legacy_orderbook_v1beta_exposure_proto_init() + file_sge_legacy_orderbook_v1beta_orderbook_proto_init() + file_sge_legacy_orderbook_v1beta_params_proto_init() + file_sge_legacy_orderbook_v1beta_participation_proto_init() + file_sge_legacy_orderbook_v1beta_stats_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_genesis_proto = out.File + file_sge_legacy_orderbook_v1beta_genesis_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_genesis_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/orderbook.pulsar.go b/api/sge/legacy/orderbook/v1beta/orderbook.pulsar.go new file mode 100644 index 00000000..fd36610c --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/orderbook.pulsar.go @@ -0,0 +1,835 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_OrderBook protoreflect.MessageDescriptor + fd_OrderBook_uid protoreflect.FieldDescriptor + fd_OrderBook_participation_count protoreflect.FieldDescriptor + fd_OrderBook_odds_count protoreflect.FieldDescriptor + fd_OrderBook_status protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_orderbook_proto_init() + md_OrderBook = File_sge_legacy_orderbook_v1beta_orderbook_proto.Messages().ByName("OrderBook") + fd_OrderBook_uid = md_OrderBook.Fields().ByName("uid") + fd_OrderBook_participation_count = md_OrderBook.Fields().ByName("participation_count") + fd_OrderBook_odds_count = md_OrderBook.Fields().ByName("odds_count") + fd_OrderBook_status = md_OrderBook.Fields().ByName("status") +} + +var _ protoreflect.Message = (*fastReflection_OrderBook)(nil) + +type fastReflection_OrderBook OrderBook + +func (x *OrderBook) ProtoReflect() protoreflect.Message { + return (*fastReflection_OrderBook)(x) +} + +func (x *OrderBook) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_orderbook_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_OrderBook_messageType fastReflection_OrderBook_messageType +var _ protoreflect.MessageType = fastReflection_OrderBook_messageType{} + +type fastReflection_OrderBook_messageType struct{} + +func (x fastReflection_OrderBook_messageType) Zero() protoreflect.Message { + return (*fastReflection_OrderBook)(nil) +} +func (x fastReflection_OrderBook_messageType) New() protoreflect.Message { + return new(fastReflection_OrderBook) +} +func (x fastReflection_OrderBook_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBook +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_OrderBook) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBook +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_OrderBook) Type() protoreflect.MessageType { + return _fastReflection_OrderBook_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_OrderBook) New() protoreflect.Message { + return new(fastReflection_OrderBook) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_OrderBook) Interface() protoreflect.ProtoMessage { + return (*OrderBook)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_OrderBook) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_OrderBook_uid, value) { + return + } + } + if x.ParticipationCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationCount) + if !f(fd_OrderBook_participation_count, value) { + return + } + } + if x.OddsCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.OddsCount) + if !f(fd_OrderBook_odds_count, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_OrderBook_status, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_OrderBook) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBook.uid": + return x.Uid != "" + case "sge.legacy.orderbook.v1beta.OrderBook.participation_count": + return x.ParticipationCount != uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBook.odds_count": + return x.OddsCount != uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBook.status": + return x.Status != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBook")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBook does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBook) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBook.uid": + x.Uid = "" + case "sge.legacy.orderbook.v1beta.OrderBook.participation_count": + x.ParticipationCount = uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBook.odds_count": + x.OddsCount = uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBook.status": + x.Status = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBook")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBook does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_OrderBook) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBook.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBook.participation_count": + value := x.ParticipationCount + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.OrderBook.odds_count": + value := x.OddsCount + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.OrderBook.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBook")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBook does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBook) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBook.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBook.participation_count": + x.ParticipationCount = value.Uint() + case "sge.legacy.orderbook.v1beta.OrderBook.odds_count": + x.OddsCount = value.Uint() + case "sge.legacy.orderbook.v1beta.OrderBook.status": + x.Status = (OrderBookStatus)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBook")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBook does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBook) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBook.uid": + panic(fmt.Errorf("field uid of message sge.legacy.orderbook.v1beta.OrderBook is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBook.participation_count": + panic(fmt.Errorf("field participation_count of message sge.legacy.orderbook.v1beta.OrderBook is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBook.odds_count": + panic(fmt.Errorf("field odds_count of message sge.legacy.orderbook.v1beta.OrderBook is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBook.status": + panic(fmt.Errorf("field status of message sge.legacy.orderbook.v1beta.OrderBook is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBook")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBook does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_OrderBook) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBook.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBook.participation_count": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.OrderBook.odds_count": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.OrderBook.status": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBook")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBook does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_OrderBook) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.OrderBook", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_OrderBook) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBook) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_OrderBook) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_OrderBook) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*OrderBook) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationCount != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationCount)) + } + if x.OddsCount != 0 { + n += 1 + runtime.Sov(uint64(x.OddsCount)) + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*OrderBook) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x20 + } + if x.OddsCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.OddsCount)) + i-- + dAtA[i] = 0x18 + } + if x.ParticipationCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationCount)) + i-- + dAtA[i] = 0x10 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*OrderBook) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBook: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBook: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationCount", wireType) + } + x.ParticipationCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OddsCount", wireType) + } + x.OddsCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.OddsCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= OrderBookStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/orderbook.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// OrderBookStatus is the enum type for the status of the order book. +type OrderBookStatus int32 + +const ( + // invalid + OrderBookStatus_ORDER_BOOK_STATUS_UNSPECIFIED OrderBookStatus = 0 + // active + OrderBookStatus_ORDER_BOOK_STATUS_STATUS_ACTIVE OrderBookStatus = 1 + // resolved not settled + OrderBookStatus_ORDER_BOOK_STATUS_STATUS_RESOLVED OrderBookStatus = 2 + // resolved and settled + OrderBookStatus_ORDER_BOOK_STATUS_STATUS_SETTLED OrderBookStatus = 3 +) + +// Enum value maps for OrderBookStatus. +var ( + OrderBookStatus_name = map[int32]string{ + 0: "ORDER_BOOK_STATUS_UNSPECIFIED", + 1: "ORDER_BOOK_STATUS_STATUS_ACTIVE", + 2: "ORDER_BOOK_STATUS_STATUS_RESOLVED", + 3: "ORDER_BOOK_STATUS_STATUS_SETTLED", + } + OrderBookStatus_value = map[string]int32{ + "ORDER_BOOK_STATUS_UNSPECIFIED": 0, + "ORDER_BOOK_STATUS_STATUS_ACTIVE": 1, + "ORDER_BOOK_STATUS_STATUS_RESOLVED": 2, + "ORDER_BOOK_STATUS_STATUS_SETTLED": 3, + } +) + +func (x OrderBookStatus) Enum() *OrderBookStatus { + p := new(OrderBookStatus) + *p = x + return p +} + +func (x OrderBookStatus) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (OrderBookStatus) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_orderbook_v1beta_orderbook_proto_enumTypes[0].Descriptor() +} + +func (OrderBookStatus) Type() protoreflect.EnumType { + return &file_sge_legacy_orderbook_v1beta_orderbook_proto_enumTypes[0] +} + +func (x OrderBookStatus) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use OrderBookStatus.Descriptor instead. +func (OrderBookStatus) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescGZIP(), []int{0} +} + +// OrderBook represents the order book maintained against a market. +type OrderBook struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the universal unique identifier of the order book. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // participation_count is the count of participations in the order book. + ParticipationCount uint64 `protobuf:"varint,2,opt,name=participation_count,json=participationCount,proto3" json:"participation_count,omitempty"` + // odds_count is the count of the odds in the order book. + OddsCount uint64 `protobuf:"varint,3,opt,name=odds_count,json=oddsCount,proto3" json:"odds_count,omitempty"` + // status represents the status of the order book. + Status OrderBookStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sge.legacy.orderbook.v1beta.OrderBookStatus" json:"status,omitempty"` +} + +func (x *OrderBook) Reset() { + *x = OrderBook{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_orderbook_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *OrderBook) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*OrderBook) ProtoMessage() {} + +// Deprecated: Use OrderBook.ProtoReflect.Descriptor instead. +func (*OrderBook) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescGZIP(), []int{0} +} + +func (x *OrderBook) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *OrderBook) GetParticipationCount() uint64 { + if x != nil { + return x.ParticipationCount + } + return 0 +} + +func (x *OrderBook) GetOddsCount() uint64 { + if x != nil { + return x.OddsCount + } + return 0 +} + +func (x *OrderBook) GetStatus() OrderBookStatus { + if x != nil { + return x.Status + } + return OrderBookStatus_ORDER_BOOK_STATUS_UNSPECIFIED +} + +var File_sge_legacy_orderbook_v1beta_orderbook_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDesc = []byte{ + 0x0a, 0x2b, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x22, 0x88, 0x02, 0x0a, 0x09, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x12, 0x20, + 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, + 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, + 0x12, 0x4f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1e, 0xf2, + 0xde, 0x1f, 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x12, 0x70, + 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x75, 0x6e, + 0x74, 0x12, 0x34, 0x0a, 0x0a, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x15, 0xf2, 0xde, 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x09, 0x6f, 0x64, + 0x64, 0x73, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x44, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, + 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x53, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x3a, 0x0c, 0x88, + 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x2a, 0xa6, 0x01, 0x0a, 0x0f, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, + 0x21, 0x0a, 0x1d, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x42, 0x4f, 0x4f, 0x4b, 0x5f, 0x53, 0x54, + 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, + 0x10, 0x00, 0x12, 0x23, 0x0a, 0x1f, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x42, 0x4f, 0x4f, 0x4b, + 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, + 0x43, 0x54, 0x49, 0x56, 0x45, 0x10, 0x01, 0x12, 0x25, 0x0a, 0x21, 0x4f, 0x52, 0x44, 0x45, 0x52, + 0x5f, 0x42, 0x4f, 0x4f, 0x4b, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x53, 0x54, 0x41, + 0x54, 0x55, 0x53, 0x5f, 0x52, 0x45, 0x53, 0x4f, 0x4c, 0x56, 0x45, 0x44, 0x10, 0x02, 0x12, 0x24, + 0x0a, 0x20, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x42, 0x4f, 0x4f, 0x4b, 0x5f, 0x53, 0x54, 0x41, + 0x54, 0x55, 0x53, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x53, 0x45, 0x54, 0x54, 0x4c, + 0x45, 0x44, 0x10, 0x03, 0x42, 0x8c, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4a, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x1b, 0x53, + 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, + 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x3a, 0x3a, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescData = file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_orderbook_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_sge_legacy_orderbook_v1beta_orderbook_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_orderbook_v1beta_orderbook_proto_goTypes = []interface{}{ + (OrderBookStatus)(0), // 0: sge.legacy.orderbook.v1beta.OrderBookStatus + (*OrderBook)(nil), // 1: sge.legacy.orderbook.v1beta.OrderBook +} +var file_sge_legacy_orderbook_v1beta_orderbook_proto_depIdxs = []int32{ + 0, // 0: sge.legacy.orderbook.v1beta.OrderBook.status:type_name -> sge.legacy.orderbook.v1beta.OrderBookStatus + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_orderbook_proto_init() } +func file_sge_legacy_orderbook_v1beta_orderbook_proto_init() { + if File_sge_legacy_orderbook_v1beta_orderbook_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_orderbook_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*OrderBook); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDesc, + NumEnums: 1, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_orderbook_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_orderbook_proto_depIdxs, + EnumInfos: file_sge_legacy_orderbook_v1beta_orderbook_proto_enumTypes, + MessageInfos: file_sge_legacy_orderbook_v1beta_orderbook_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_orderbook_proto = out.File + file_sge_legacy_orderbook_v1beta_orderbook_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_orderbook_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_orderbook_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/params.pulsar.go b/api/sge/legacy/orderbook/v1beta/params.pulsar.go new file mode 100644 index 00000000..35a9cfb5 --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/params.pulsar.go @@ -0,0 +1,694 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Params protoreflect.MessageDescriptor + fd_Params_max_order_book_participations protoreflect.FieldDescriptor + fd_Params_batch_settlement_count protoreflect.FieldDescriptor + fd_Params_requeue_threshold protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_params_proto_init() + md_Params = File_sge_legacy_orderbook_v1beta_params_proto.Messages().ByName("Params") + fd_Params_max_order_book_participations = md_Params.Fields().ByName("max_order_book_participations") + fd_Params_batch_settlement_count = md_Params.Fields().ByName("batch_settlement_count") + fd_Params_requeue_threshold = md_Params.Fields().ByName("requeue_threshold") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MaxOrderBookParticipations != uint64(0) { + value := protoreflect.ValueOfUint64(x.MaxOrderBookParticipations) + if !f(fd_Params_max_order_book_participations, value) { + return + } + } + if x.BatchSettlementCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.BatchSettlementCount) + if !f(fd_Params_batch_settlement_count, value) { + return + } + } + if x.RequeueThreshold != uint64(0) { + value := protoreflect.ValueOfUint64(x.RequeueThreshold) + if !f(fd_Params_requeue_threshold, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.Params.max_order_book_participations": + return x.MaxOrderBookParticipations != uint64(0) + case "sge.legacy.orderbook.v1beta.Params.batch_settlement_count": + return x.BatchSettlementCount != uint64(0) + case "sge.legacy.orderbook.v1beta.Params.requeue_threshold": + return x.RequeueThreshold != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.Params.max_order_book_participations": + x.MaxOrderBookParticipations = uint64(0) + case "sge.legacy.orderbook.v1beta.Params.batch_settlement_count": + x.BatchSettlementCount = uint64(0) + case "sge.legacy.orderbook.v1beta.Params.requeue_threshold": + x.RequeueThreshold = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.Params.max_order_book_participations": + value := x.MaxOrderBookParticipations + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.Params.batch_settlement_count": + value := x.BatchSettlementCount + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.Params.requeue_threshold": + value := x.RequeueThreshold + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.Params.max_order_book_participations": + x.MaxOrderBookParticipations = value.Uint() + case "sge.legacy.orderbook.v1beta.Params.batch_settlement_count": + x.BatchSettlementCount = value.Uint() + case "sge.legacy.orderbook.v1beta.Params.requeue_threshold": + x.RequeueThreshold = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.Params.max_order_book_participations": + panic(fmt.Errorf("field max_order_book_participations of message sge.legacy.orderbook.v1beta.Params is not mutable")) + case "sge.legacy.orderbook.v1beta.Params.batch_settlement_count": + panic(fmt.Errorf("field batch_settlement_count of message sge.legacy.orderbook.v1beta.Params is not mutable")) + case "sge.legacy.orderbook.v1beta.Params.requeue_threshold": + panic(fmt.Errorf("field requeue_threshold of message sge.legacy.orderbook.v1beta.Params is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.Params.max_order_book_participations": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.Params.batch_settlement_count": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.Params.requeue_threshold": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.MaxOrderBookParticipations != 0 { + n += 1 + runtime.Sov(uint64(x.MaxOrderBookParticipations)) + } + if x.BatchSettlementCount != 0 { + n += 1 + runtime.Sov(uint64(x.BatchSettlementCount)) + } + if x.RequeueThreshold != 0 { + n += 1 + runtime.Sov(uint64(x.RequeueThreshold)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.RequeueThreshold != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.RequeueThreshold)) + i-- + dAtA[i] = 0x18 + } + if x.BatchSettlementCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.BatchSettlementCount)) + i-- + dAtA[i] = 0x10 + } + if x.MaxOrderBookParticipations != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.MaxOrderBookParticipations)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxOrderBookParticipations", wireType) + } + x.MaxOrderBookParticipations = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.MaxOrderBookParticipations |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BatchSettlementCount", wireType) + } + x.BatchSettlementCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.BatchSettlementCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RequeueThreshold", wireType) + } + x.RequeueThreshold = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.RequeueThreshold |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params defines the parameters for the orderbook module. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // max_order_book_participations is the maximum number of participations per + // book. + MaxOrderBookParticipations uint64 `protobuf:"varint,1,opt,name=max_order_book_participations,json=maxOrderBookParticipations,proto3" json:"max_order_book_participations,omitempty"` + // batch_settlement_count is the batch settlement deposit count. + BatchSettlementCount uint64 `protobuf:"varint,2,opt,name=batch_settlement_count,json=batchSettlementCount,proto3" json:"batch_settlement_count,omitempty"` + // requeue_threshold is the threshold at which a participation is re-queued in + // orderbook. + RequeueThreshold uint64 `protobuf:"varint,3,opt,name=requeue_threshold,json=requeueThreshold,proto3" json:"requeue_threshold,omitempty"` +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +func (x *Params) GetMaxOrderBookParticipations() uint64 { + if x != nil { + return x.MaxOrderBookParticipations + } + return 0 +} + +func (x *Params) GetBatchSettlementCount() uint64 { + if x != nil { + return x.BatchSettlementCount + } + return 0 +} + +func (x *Params) GetRequeueThreshold() uint64 { + if x != nil { + return x.RequeueThreshold + } + return 0 +} + +var File_sge_legacy_orderbook_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x28, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa3, 0x02, + 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x6b, 0x0a, 0x1d, 0x6d, 0x61, 0x78, 0x5f, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x42, + 0x28, 0xf2, 0xde, 0x1f, 0x24, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, 0x61, 0x78, 0x5f, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0x52, 0x1a, 0x6d, 0x61, 0x78, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x57, 0x0a, 0x16, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x73, + 0x65, 0x74, 0x74, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x21, 0xf2, 0xde, 0x1f, 0x1d, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x6d, 0x65, 0x6e, + 0x74, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x14, 0x62, 0x61, 0x74, 0x63, 0x68, 0x53, + 0x65, 0x74, 0x74, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x49, + 0x0a, 0x11, 0x72, 0x65, 0x71, 0x75, 0x65, 0x75, 0x65, 0x5f, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, + 0x6f, 0x6c, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1c, 0xf2, 0xde, 0x1f, 0x18, 0x79, + 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x72, 0x65, 0x71, 0x75, 0x65, 0x75, 0x65, 0x5f, 0x74, 0x68, 0x72, + 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x22, 0x52, 0x10, 0x72, 0x65, 0x71, 0x75, 0x65, 0x75, 0x65, + 0x54, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x3a, 0x08, 0x98, 0xa0, 0x1f, 0x00, 0xe8, + 0xa0, 0x1f, 0x01, 0x42, 0x89, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x50, + 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, + 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x3b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x2e, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x1e, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_params_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_params_proto_rawDescData = file_sge_legacy_orderbook_v1beta_params_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_params_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_params_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_orderbook_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.legacy.orderbook.v1beta.Params +} +var file_sge_legacy_orderbook_v1beta_params_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_params_proto_init() } +func file_sge_legacy_orderbook_v1beta_params_proto_init() { + if File_sge_legacy_orderbook_v1beta_params_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_v1beta_params_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_params_proto = out.File + file_sge_legacy_orderbook_v1beta_params_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_params_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/participation.pulsar.go b/api/sge/legacy/orderbook/v1beta/participation.pulsar.go new file mode 100644 index 00000000..44de0dc7 --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/participation.pulsar.go @@ -0,0 +1,2970 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_OrderBookParticipation protoreflect.MessageDescriptor + fd_OrderBookParticipation_index protoreflect.FieldDescriptor + fd_OrderBookParticipation_order_book_uid protoreflect.FieldDescriptor + fd_OrderBookParticipation_participant_address protoreflect.FieldDescriptor + fd_OrderBookParticipation_liquidity protoreflect.FieldDescriptor + fd_OrderBookParticipation_fee protoreflect.FieldDescriptor + fd_OrderBookParticipation_current_round_liquidity protoreflect.FieldDescriptor + fd_OrderBookParticipation_exposures_not_filled protoreflect.FieldDescriptor + fd_OrderBookParticipation_total_bet_amount protoreflect.FieldDescriptor + fd_OrderBookParticipation_current_round_total_bet_amount protoreflect.FieldDescriptor + fd_OrderBookParticipation_max_loss protoreflect.FieldDescriptor + fd_OrderBookParticipation_current_round_max_loss protoreflect.FieldDescriptor + fd_OrderBookParticipation_current_round_max_loss_odds_uid protoreflect.FieldDescriptor + fd_OrderBookParticipation_actual_profit protoreflect.FieldDescriptor + fd_OrderBookParticipation_is_settled protoreflect.FieldDescriptor + fd_OrderBookParticipation_returned_amount protoreflect.FieldDescriptor + fd_OrderBookParticipation_reimbursed_fee protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_participation_proto_init() + md_OrderBookParticipation = File_sge_legacy_orderbook_v1beta_participation_proto.Messages().ByName("OrderBookParticipation") + fd_OrderBookParticipation_index = md_OrderBookParticipation.Fields().ByName("index") + fd_OrderBookParticipation_order_book_uid = md_OrderBookParticipation.Fields().ByName("order_book_uid") + fd_OrderBookParticipation_participant_address = md_OrderBookParticipation.Fields().ByName("participant_address") + fd_OrderBookParticipation_liquidity = md_OrderBookParticipation.Fields().ByName("liquidity") + fd_OrderBookParticipation_fee = md_OrderBookParticipation.Fields().ByName("fee") + fd_OrderBookParticipation_current_round_liquidity = md_OrderBookParticipation.Fields().ByName("current_round_liquidity") + fd_OrderBookParticipation_exposures_not_filled = md_OrderBookParticipation.Fields().ByName("exposures_not_filled") + fd_OrderBookParticipation_total_bet_amount = md_OrderBookParticipation.Fields().ByName("total_bet_amount") + fd_OrderBookParticipation_current_round_total_bet_amount = md_OrderBookParticipation.Fields().ByName("current_round_total_bet_amount") + fd_OrderBookParticipation_max_loss = md_OrderBookParticipation.Fields().ByName("max_loss") + fd_OrderBookParticipation_current_round_max_loss = md_OrderBookParticipation.Fields().ByName("current_round_max_loss") + fd_OrderBookParticipation_current_round_max_loss_odds_uid = md_OrderBookParticipation.Fields().ByName("current_round_max_loss_odds_uid") + fd_OrderBookParticipation_actual_profit = md_OrderBookParticipation.Fields().ByName("actual_profit") + fd_OrderBookParticipation_is_settled = md_OrderBookParticipation.Fields().ByName("is_settled") + fd_OrderBookParticipation_returned_amount = md_OrderBookParticipation.Fields().ByName("returned_amount") + fd_OrderBookParticipation_reimbursed_fee = md_OrderBookParticipation.Fields().ByName("reimbursed_fee") +} + +var _ protoreflect.Message = (*fastReflection_OrderBookParticipation)(nil) + +type fastReflection_OrderBookParticipation OrderBookParticipation + +func (x *OrderBookParticipation) ProtoReflect() protoreflect.Message { + return (*fastReflection_OrderBookParticipation)(x) +} + +func (x *OrderBookParticipation) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_OrderBookParticipation_messageType fastReflection_OrderBookParticipation_messageType +var _ protoreflect.MessageType = fastReflection_OrderBookParticipation_messageType{} + +type fastReflection_OrderBookParticipation_messageType struct{} + +func (x fastReflection_OrderBookParticipation_messageType) Zero() protoreflect.Message { + return (*fastReflection_OrderBookParticipation)(nil) +} +func (x fastReflection_OrderBookParticipation_messageType) New() protoreflect.Message { + return new(fastReflection_OrderBookParticipation) +} +func (x fastReflection_OrderBookParticipation_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBookParticipation +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_OrderBookParticipation) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBookParticipation +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_OrderBookParticipation) Type() protoreflect.MessageType { + return _fastReflection_OrderBookParticipation_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_OrderBookParticipation) New() protoreflect.Message { + return new(fastReflection_OrderBookParticipation) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_OrderBookParticipation) Interface() protoreflect.ProtoMessage { + return (*OrderBookParticipation)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_OrderBookParticipation) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Index != uint64(0) { + value := protoreflect.ValueOfUint64(x.Index) + if !f(fd_OrderBookParticipation_index, value) { + return + } + } + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_OrderBookParticipation_order_book_uid, value) { + return + } + } + if x.ParticipantAddress != "" { + value := protoreflect.ValueOfString(x.ParticipantAddress) + if !f(fd_OrderBookParticipation_participant_address, value) { + return + } + } + if x.Liquidity != "" { + value := protoreflect.ValueOfString(x.Liquidity) + if !f(fd_OrderBookParticipation_liquidity, value) { + return + } + } + if x.Fee != "" { + value := protoreflect.ValueOfString(x.Fee) + if !f(fd_OrderBookParticipation_fee, value) { + return + } + } + if x.CurrentRoundLiquidity != "" { + value := protoreflect.ValueOfString(x.CurrentRoundLiquidity) + if !f(fd_OrderBookParticipation_current_round_liquidity, value) { + return + } + } + if x.ExposuresNotFilled != uint64(0) { + value := protoreflect.ValueOfUint64(x.ExposuresNotFilled) + if !f(fd_OrderBookParticipation_exposures_not_filled, value) { + return + } + } + if x.TotalBetAmount != "" { + value := protoreflect.ValueOfString(x.TotalBetAmount) + if !f(fd_OrderBookParticipation_total_bet_amount, value) { + return + } + } + if x.CurrentRoundTotalBetAmount != "" { + value := protoreflect.ValueOfString(x.CurrentRoundTotalBetAmount) + if !f(fd_OrderBookParticipation_current_round_total_bet_amount, value) { + return + } + } + if x.MaxLoss != "" { + value := protoreflect.ValueOfString(x.MaxLoss) + if !f(fd_OrderBookParticipation_max_loss, value) { + return + } + } + if x.CurrentRoundMaxLoss != "" { + value := protoreflect.ValueOfString(x.CurrentRoundMaxLoss) + if !f(fd_OrderBookParticipation_current_round_max_loss, value) { + return + } + } + if x.CurrentRoundMaxLossOddsUid != "" { + value := protoreflect.ValueOfString(x.CurrentRoundMaxLossOddsUid) + if !f(fd_OrderBookParticipation_current_round_max_loss_odds_uid, value) { + return + } + } + if x.ActualProfit != "" { + value := protoreflect.ValueOfString(x.ActualProfit) + if !f(fd_OrderBookParticipation_actual_profit, value) { + return + } + } + if x.IsSettled != false { + value := protoreflect.ValueOfBool(x.IsSettled) + if !f(fd_OrderBookParticipation_is_settled, value) { + return + } + } + if x.ReturnedAmount != "" { + value := protoreflect.ValueOfString(x.ReturnedAmount) + if !f(fd_OrderBookParticipation_returned_amount, value) { + return + } + } + if x.ReimbursedFee != "" { + value := protoreflect.ValueOfString(x.ReimbursedFee) + if !f(fd_OrderBookParticipation_reimbursed_fee, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_OrderBookParticipation) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.index": + return x.Index != uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.participant_address": + return x.ParticipantAddress != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.liquidity": + return x.Liquidity != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.fee": + return x.Fee != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_liquidity": + return x.CurrentRoundLiquidity != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.exposures_not_filled": + return x.ExposuresNotFilled != uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.total_bet_amount": + return x.TotalBetAmount != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_total_bet_amount": + return x.CurrentRoundTotalBetAmount != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.max_loss": + return x.MaxLoss != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss": + return x.CurrentRoundMaxLoss != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss_odds_uid": + return x.CurrentRoundMaxLossOddsUid != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.actual_profit": + return x.ActualProfit != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.is_settled": + return x.IsSettled != false + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.returned_amount": + return x.ReturnedAmount != "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.reimbursed_fee": + return x.ReimbursedFee != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookParticipation does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookParticipation) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.index": + x.Index = uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.participant_address": + x.ParticipantAddress = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.liquidity": + x.Liquidity = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.fee": + x.Fee = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_liquidity": + x.CurrentRoundLiquidity = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.exposures_not_filled": + x.ExposuresNotFilled = uint64(0) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.total_bet_amount": + x.TotalBetAmount = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_total_bet_amount": + x.CurrentRoundTotalBetAmount = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.max_loss": + x.MaxLoss = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss": + x.CurrentRoundMaxLoss = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss_odds_uid": + x.CurrentRoundMaxLossOddsUid = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.actual_profit": + x.ActualProfit = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.is_settled": + x.IsSettled = false + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.returned_amount": + x.ReturnedAmount = "" + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.reimbursed_fee": + x.ReimbursedFee = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookParticipation does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_OrderBookParticipation) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.index": + value := x.Index + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.participant_address": + value := x.ParticipantAddress + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.liquidity": + value := x.Liquidity + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.fee": + value := x.Fee + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_liquidity": + value := x.CurrentRoundLiquidity + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.exposures_not_filled": + value := x.ExposuresNotFilled + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.total_bet_amount": + value := x.TotalBetAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_total_bet_amount": + value := x.CurrentRoundTotalBetAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.max_loss": + value := x.MaxLoss + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss": + value := x.CurrentRoundMaxLoss + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss_odds_uid": + value := x.CurrentRoundMaxLossOddsUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.actual_profit": + value := x.ActualProfit + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.is_settled": + value := x.IsSettled + return protoreflect.ValueOfBool(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.returned_amount": + value := x.ReturnedAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.reimbursed_fee": + value := x.ReimbursedFee + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookParticipation does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookParticipation) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.index": + x.Index = value.Uint() + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.participant_address": + x.ParticipantAddress = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.liquidity": + x.Liquidity = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.fee": + x.Fee = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_liquidity": + x.CurrentRoundLiquidity = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.exposures_not_filled": + x.ExposuresNotFilled = value.Uint() + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.total_bet_amount": + x.TotalBetAmount = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_total_bet_amount": + x.CurrentRoundTotalBetAmount = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.max_loss": + x.MaxLoss = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss": + x.CurrentRoundMaxLoss = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss_odds_uid": + x.CurrentRoundMaxLossOddsUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.actual_profit": + x.ActualProfit = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.is_settled": + x.IsSettled = value.Bool() + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.returned_amount": + x.ReturnedAmount = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.reimbursed_fee": + x.ReimbursedFee = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookParticipation does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookParticipation) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.index": + panic(fmt.Errorf("field index of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.participant_address": + panic(fmt.Errorf("field participant_address of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.liquidity": + panic(fmt.Errorf("field liquidity of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.fee": + panic(fmt.Errorf("field fee of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_liquidity": + panic(fmt.Errorf("field current_round_liquidity of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.exposures_not_filled": + panic(fmt.Errorf("field exposures_not_filled of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.total_bet_amount": + panic(fmt.Errorf("field total_bet_amount of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_total_bet_amount": + panic(fmt.Errorf("field current_round_total_bet_amount of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.max_loss": + panic(fmt.Errorf("field max_loss of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss": + panic(fmt.Errorf("field current_round_max_loss of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss_odds_uid": + panic(fmt.Errorf("field current_round_max_loss_odds_uid of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.actual_profit": + panic(fmt.Errorf("field actual_profit of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.is_settled": + panic(fmt.Errorf("field is_settled of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.returned_amount": + panic(fmt.Errorf("field returned_amount of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.reimbursed_fee": + panic(fmt.Errorf("field reimbursed_fee of message sge.legacy.orderbook.v1beta.OrderBookParticipation is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookParticipation does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_OrderBookParticipation) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.participant_address": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.liquidity": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.fee": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_liquidity": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.exposures_not_filled": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.total_bet_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_total_bet_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.max_loss": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.current_round_max_loss_odds_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.actual_profit": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.is_settled": + return protoreflect.ValueOfBool(false) + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.returned_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.OrderBookParticipation.reimbursed_fee": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookParticipation does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_OrderBookParticipation) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.OrderBookParticipation", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_OrderBookParticipation) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookParticipation) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_OrderBookParticipation) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_OrderBookParticipation) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*OrderBookParticipation) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Index != 0 { + n += 1 + runtime.Sov(uint64(x.Index)) + } + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.ParticipantAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Liquidity) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Fee) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CurrentRoundLiquidity) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ExposuresNotFilled != 0 { + n += 1 + runtime.Sov(uint64(x.ExposuresNotFilled)) + } + l = len(x.TotalBetAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CurrentRoundTotalBetAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MaxLoss) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CurrentRoundMaxLoss) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CurrentRoundMaxLossOddsUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.ActualProfit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.IsSettled { + n += 2 + } + l = len(x.ReturnedAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.ReimbursedFee) + if l > 0 { + n += 2 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*OrderBookParticipation) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.ReimbursedFee) > 0 { + i -= len(x.ReimbursedFee) + copy(dAtA[i:], x.ReimbursedFee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ReimbursedFee))) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0x82 + } + if len(x.ReturnedAmount) > 0 { + i -= len(x.ReturnedAmount) + copy(dAtA[i:], x.ReturnedAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ReturnedAmount))) + i-- + dAtA[i] = 0x7a + } + if x.IsSettled { + i-- + if x.IsSettled { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x70 + } + if len(x.ActualProfit) > 0 { + i -= len(x.ActualProfit) + copy(dAtA[i:], x.ActualProfit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ActualProfit))) + i-- + dAtA[i] = 0x6a + } + if len(x.CurrentRoundMaxLossOddsUid) > 0 { + i -= len(x.CurrentRoundMaxLossOddsUid) + copy(dAtA[i:], x.CurrentRoundMaxLossOddsUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CurrentRoundMaxLossOddsUid))) + i-- + dAtA[i] = 0x62 + } + if len(x.CurrentRoundMaxLoss) > 0 { + i -= len(x.CurrentRoundMaxLoss) + copy(dAtA[i:], x.CurrentRoundMaxLoss) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CurrentRoundMaxLoss))) + i-- + dAtA[i] = 0x5a + } + if len(x.MaxLoss) > 0 { + i -= len(x.MaxLoss) + copy(dAtA[i:], x.MaxLoss) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MaxLoss))) + i-- + dAtA[i] = 0x52 + } + if len(x.CurrentRoundTotalBetAmount) > 0 { + i -= len(x.CurrentRoundTotalBetAmount) + copy(dAtA[i:], x.CurrentRoundTotalBetAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CurrentRoundTotalBetAmount))) + i-- + dAtA[i] = 0x4a + } + if len(x.TotalBetAmount) > 0 { + i -= len(x.TotalBetAmount) + copy(dAtA[i:], x.TotalBetAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.TotalBetAmount))) + i-- + dAtA[i] = 0x42 + } + if x.ExposuresNotFilled != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ExposuresNotFilled)) + i-- + dAtA[i] = 0x38 + } + if len(x.CurrentRoundLiquidity) > 0 { + i -= len(x.CurrentRoundLiquidity) + copy(dAtA[i:], x.CurrentRoundLiquidity) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CurrentRoundLiquidity))) + i-- + dAtA[i] = 0x32 + } + if len(x.Fee) > 0 { + i -= len(x.Fee) + copy(dAtA[i:], x.Fee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Fee))) + i-- + dAtA[i] = 0x2a + } + if len(x.Liquidity) > 0 { + i -= len(x.Liquidity) + copy(dAtA[i:], x.Liquidity) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Liquidity))) + i-- + dAtA[i] = 0x22 + } + if len(x.ParticipantAddress) > 0 { + i -= len(x.ParticipantAddress) + copy(dAtA[i:], x.ParticipantAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ParticipantAddress))) + i-- + dAtA[i] = 0x1a + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0x12 + } + if x.Index != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Index)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*OrderBookParticipation) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBookParticipation: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBookParticipation: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) + } + x.Index = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Index |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipantAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipantAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Liquidity", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Liquidity = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Fee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Fee = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CurrentRoundLiquidity", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CurrentRoundLiquidity = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExposuresNotFilled", wireType) + } + x.ExposuresNotFilled = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ExposuresNotFilled |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TotalBetAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.TotalBetAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 9: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CurrentRoundTotalBetAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CurrentRoundTotalBetAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 10: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxLoss", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MaxLoss = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 11: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CurrentRoundMaxLoss", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CurrentRoundMaxLoss = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 12: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CurrentRoundMaxLossOddsUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CurrentRoundMaxLossOddsUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 13: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ActualProfit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ActualProfit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 14: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field IsSettled", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.IsSettled = bool(v != 0) + case 15: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ReturnedAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ReturnedAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 16: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ReimbursedFee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ReimbursedFee = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_ParticipationBetPair protoreflect.MessageDescriptor + fd_ParticipationBetPair_order_book_uid protoreflect.FieldDescriptor + fd_ParticipationBetPair_participation_index protoreflect.FieldDescriptor + fd_ParticipationBetPair_bet_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_participation_proto_init() + md_ParticipationBetPair = File_sge_legacy_orderbook_v1beta_participation_proto.Messages().ByName("ParticipationBetPair") + fd_ParticipationBetPair_order_book_uid = md_ParticipationBetPair.Fields().ByName("order_book_uid") + fd_ParticipationBetPair_participation_index = md_ParticipationBetPair.Fields().ByName("participation_index") + fd_ParticipationBetPair_bet_uid = md_ParticipationBetPair.Fields().ByName("bet_uid") +} + +var _ protoreflect.Message = (*fastReflection_ParticipationBetPair)(nil) + +type fastReflection_ParticipationBetPair ParticipationBetPair + +func (x *ParticipationBetPair) ProtoReflect() protoreflect.Message { + return (*fastReflection_ParticipationBetPair)(x) +} + +func (x *ParticipationBetPair) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_ParticipationBetPair_messageType fastReflection_ParticipationBetPair_messageType +var _ protoreflect.MessageType = fastReflection_ParticipationBetPair_messageType{} + +type fastReflection_ParticipationBetPair_messageType struct{} + +func (x fastReflection_ParticipationBetPair_messageType) Zero() protoreflect.Message { + return (*fastReflection_ParticipationBetPair)(nil) +} +func (x fastReflection_ParticipationBetPair_messageType) New() protoreflect.Message { + return new(fastReflection_ParticipationBetPair) +} +func (x fastReflection_ParticipationBetPair_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_ParticipationBetPair +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_ParticipationBetPair) Descriptor() protoreflect.MessageDescriptor { + return md_ParticipationBetPair +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_ParticipationBetPair) Type() protoreflect.MessageType { + return _fastReflection_ParticipationBetPair_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_ParticipationBetPair) New() protoreflect.Message { + return new(fastReflection_ParticipationBetPair) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_ParticipationBetPair) Interface() protoreflect.ProtoMessage { + return (*ParticipationBetPair)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_ParticipationBetPair) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_ParticipationBetPair_order_book_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_ParticipationBetPair_participation_index, value) { + return + } + } + if x.BetUid != "" { + value := protoreflect.ValueOfString(x.BetUid) + if !f(fd_ParticipationBetPair_bet_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_ParticipationBetPair) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.bet_uid": + return x.BetUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationBetPair")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationBetPair does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationBetPair) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.bet_uid": + x.BetUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationBetPair")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationBetPair does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_ParticipationBetPair) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.bet_uid": + value := x.BetUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationBetPair")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationBetPair does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationBetPair) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.bet_uid": + x.BetUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationBetPair")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationBetPair does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationBetPair) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.ParticipationBetPair is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.orderbook.v1beta.ParticipationBetPair is not mutable")) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.bet_uid": + panic(fmt.Errorf("field bet_uid of message sge.legacy.orderbook.v1beta.ParticipationBetPair is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationBetPair")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationBetPair does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_ParticipationBetPair) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.ParticipationBetPair.bet_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.ParticipationBetPair")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.ParticipationBetPair does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_ParticipationBetPair) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.ParticipationBetPair", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_ParticipationBetPair) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ParticipationBetPair) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_ParticipationBetPair) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_ParticipationBetPair) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*ParticipationBetPair) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + l = len(x.BetUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*ParticipationBetPair) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.BetUid) > 0 { + i -= len(x.BetUid) + copy(dAtA[i:], x.BetUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BetUid))) + i-- + dAtA[i] = 0x1a + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x10 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*ParticipationBetPair) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ParticipationBetPair: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ParticipationBetPair: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BetUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BetUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_SettledOrderbookParticipation protoreflect.MessageDescriptor + fd_SettledOrderbookParticipation_index protoreflect.FieldDescriptor + fd_SettledOrderbookParticipation_order_book_uid protoreflect.FieldDescriptor + fd_SettledOrderbookParticipation_participant_address protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_participation_proto_init() + md_SettledOrderbookParticipation = File_sge_legacy_orderbook_v1beta_participation_proto.Messages().ByName("SettledOrderbookParticipation") + fd_SettledOrderbookParticipation_index = md_SettledOrderbookParticipation.Fields().ByName("index") + fd_SettledOrderbookParticipation_order_book_uid = md_SettledOrderbookParticipation.Fields().ByName("order_book_uid") + fd_SettledOrderbookParticipation_participant_address = md_SettledOrderbookParticipation.Fields().ByName("participant_address") +} + +var _ protoreflect.Message = (*fastReflection_SettledOrderbookParticipation)(nil) + +type fastReflection_SettledOrderbookParticipation SettledOrderbookParticipation + +func (x *SettledOrderbookParticipation) ProtoReflect() protoreflect.Message { + return (*fastReflection_SettledOrderbookParticipation)(x) +} + +func (x *SettledOrderbookParticipation) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_SettledOrderbookParticipation_messageType fastReflection_SettledOrderbookParticipation_messageType +var _ protoreflect.MessageType = fastReflection_SettledOrderbookParticipation_messageType{} + +type fastReflection_SettledOrderbookParticipation_messageType struct{} + +func (x fastReflection_SettledOrderbookParticipation_messageType) Zero() protoreflect.Message { + return (*fastReflection_SettledOrderbookParticipation)(nil) +} +func (x fastReflection_SettledOrderbookParticipation_messageType) New() protoreflect.Message { + return new(fastReflection_SettledOrderbookParticipation) +} +func (x fastReflection_SettledOrderbookParticipation_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_SettledOrderbookParticipation +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_SettledOrderbookParticipation) Descriptor() protoreflect.MessageDescriptor { + return md_SettledOrderbookParticipation +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_SettledOrderbookParticipation) Type() protoreflect.MessageType { + return _fastReflection_SettledOrderbookParticipation_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_SettledOrderbookParticipation) New() protoreflect.Message { + return new(fastReflection_SettledOrderbookParticipation) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_SettledOrderbookParticipation) Interface() protoreflect.ProtoMessage { + return (*SettledOrderbookParticipation)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_SettledOrderbookParticipation) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Index != uint64(0) { + value := protoreflect.ValueOfUint64(x.Index) + if !f(fd_SettledOrderbookParticipation_index, value) { + return + } + } + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_SettledOrderbookParticipation_order_book_uid, value) { + return + } + } + if x.ParticipantAddress != "" { + value := protoreflect.ValueOfString(x.ParticipantAddress) + if !f(fd_SettledOrderbookParticipation_participant_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_SettledOrderbookParticipation) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.index": + return x.Index != uint64(0) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.participant_address": + return x.ParticipantAddress != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.SettledOrderbookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledOrderbookParticipation) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.index": + x.Index = uint64(0) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.participant_address": + x.ParticipantAddress = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.SettledOrderbookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_SettledOrderbookParticipation) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.index": + value := x.Index + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.participant_address": + value := x.ParticipantAddress + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.SettledOrderbookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledOrderbookParticipation) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.index": + x.Index = value.Uint() + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.participant_address": + x.ParticipantAddress = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.SettledOrderbookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledOrderbookParticipation) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.index": + panic(fmt.Errorf("field index of message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation is not mutable")) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.participant_address": + panic(fmt.Errorf("field participant_address of message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.SettledOrderbookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_SettledOrderbookParticipation) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation.participant_address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.SettledOrderbookParticipation")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.SettledOrderbookParticipation does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_SettledOrderbookParticipation) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.SettledOrderbookParticipation", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_SettledOrderbookParticipation) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SettledOrderbookParticipation) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_SettledOrderbookParticipation) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_SettledOrderbookParticipation) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*SettledOrderbookParticipation) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Index != 0 { + n += 1 + runtime.Sov(uint64(x.Index)) + } + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.ParticipantAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*SettledOrderbookParticipation) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.ParticipantAddress) > 0 { + i -= len(x.ParticipantAddress) + copy(dAtA[i:], x.ParticipantAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ParticipantAddress))) + i-- + dAtA[i] = 0x1a + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0x12 + } + if x.Index != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Index)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*SettledOrderbookParticipation) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SettledOrderbookParticipation: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SettledOrderbookParticipation: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) + } + x.Index = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Index |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipantAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipantAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/participation.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// OrderBookParticipation represents the participants of an order book. +type OrderBookParticipation struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // index is the index of the participation in the participation queue. + Index uint64 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"` + // order_book_uid is the unique identifier corresponding to the order book. + OrderBookUid string `protobuf:"bytes,2,opt,name=order_book_uid,proto3" json:"order_book_uid,omitempty"` + // participant_address is the bech32-encoded address of the participant. + ParticipantAddress string `protobuf:"bytes,3,opt,name=participant_address,json=participantAddress,proto3" json:"participant_address,omitempty"` + // liquidity is the total initial liquidity provided. + Liquidity string `protobuf:"bytes,4,opt,name=liquidity,proto3" json:"liquidity,omitempty"` + // fee is the amount of fee to be paid if participation happens. + Fee string `protobuf:"bytes,5,opt,name=fee,proto3" json:"fee,omitempty"` + // current_round_liquidity is the liquidity provided for the current round. + CurrentRoundLiquidity string `protobuf:"bytes,6,opt,name=current_round_liquidity,json=currentRoundLiquidity,proto3" json:"current_round_liquidity,omitempty"` + // exposures_not_filled represents if all of the exposures of the + // participation are filled or not. + ExposuresNotFilled uint64 `protobuf:"varint,7,opt,name=exposures_not_filled,json=exposuresNotFilled,proto3" json:"exposures_not_filled,omitempty"` + // total_bet_amount is the total bet amount corresponding to all exposures. + TotalBetAmount string `protobuf:"bytes,8,opt,name=total_bet_amount,json=totalBetAmount,proto3" json:"total_bet_amount,omitempty"` + // current_round_total_bet_amount is the total bet amount corresponding to all + // exposures in the current round. + CurrentRoundTotalBetAmount string `protobuf:"bytes,9,opt,name=current_round_total_bet_amount,json=currentRoundTotalBetAmount,proto3" json:"current_round_total_bet_amount,omitempty"` + // max_loss is the total bet amount corresponding to all exposure. + MaxLoss string `protobuf:"bytes,10,opt,name=max_loss,json=maxLoss,proto3" json:"max_loss,omitempty"` + // current_round_max_loss is the current round max loss. + CurrentRoundMaxLoss string `protobuf:"bytes,11,opt,name=current_round_max_loss,json=currentRoundMaxLoss,proto3" json:"current_round_max_loss,omitempty"` + // current_round_max_loss_odds_uid is the total max loss corresponding to + // all exposures. + CurrentRoundMaxLossOddsUid string `protobuf:"bytes,12,opt,name=current_round_max_loss_odds_uid,proto3" json:"current_round_max_loss_odds_uid,omitempty"` + // actual_profit is the actual profit of the participation fulfillment. + ActualProfit string `protobuf:"bytes,13,opt,name=actual_profit,json=actualProfit,proto3" json:"actual_profit,omitempty"` + // is_settled represents if the participation is settled or not. + IsSettled bool `protobuf:"varint,14,opt,name=is_settled,json=isSettled,proto3" json:"is_settled,omitempty"` + // returned_amount is the total returned amount to the user's account + // including reimbursed fees. + ReturnedAmount string `protobuf:"bytes,15,opt,name=returned_amount,json=returnedAmount,proto3" json:"returned_amount,omitempty"` + // reimbursed_fee is the fee reimbursed because of reasons such as market + // calcellation. + ReimbursedFee string `protobuf:"bytes,16,opt,name=reimbursed_fee,json=reimbursedFee,proto3" json:"reimbursed_fee,omitempty"` +} + +func (x *OrderBookParticipation) Reset() { + *x = OrderBookParticipation{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *OrderBookParticipation) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*OrderBookParticipation) ProtoMessage() {} + +// Deprecated: Use OrderBookParticipation.ProtoReflect.Descriptor instead. +func (*OrderBookParticipation) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_participation_proto_rawDescGZIP(), []int{0} +} + +func (x *OrderBookParticipation) GetIndex() uint64 { + if x != nil { + return x.Index + } + return 0 +} + +func (x *OrderBookParticipation) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *OrderBookParticipation) GetParticipantAddress() string { + if x != nil { + return x.ParticipantAddress + } + return "" +} + +func (x *OrderBookParticipation) GetLiquidity() string { + if x != nil { + return x.Liquidity + } + return "" +} + +func (x *OrderBookParticipation) GetFee() string { + if x != nil { + return x.Fee + } + return "" +} + +func (x *OrderBookParticipation) GetCurrentRoundLiquidity() string { + if x != nil { + return x.CurrentRoundLiquidity + } + return "" +} + +func (x *OrderBookParticipation) GetExposuresNotFilled() uint64 { + if x != nil { + return x.ExposuresNotFilled + } + return 0 +} + +func (x *OrderBookParticipation) GetTotalBetAmount() string { + if x != nil { + return x.TotalBetAmount + } + return "" +} + +func (x *OrderBookParticipation) GetCurrentRoundTotalBetAmount() string { + if x != nil { + return x.CurrentRoundTotalBetAmount + } + return "" +} + +func (x *OrderBookParticipation) GetMaxLoss() string { + if x != nil { + return x.MaxLoss + } + return "" +} + +func (x *OrderBookParticipation) GetCurrentRoundMaxLoss() string { + if x != nil { + return x.CurrentRoundMaxLoss + } + return "" +} + +func (x *OrderBookParticipation) GetCurrentRoundMaxLossOddsUid() string { + if x != nil { + return x.CurrentRoundMaxLossOddsUid + } + return "" +} + +func (x *OrderBookParticipation) GetActualProfit() string { + if x != nil { + return x.ActualProfit + } + return "" +} + +func (x *OrderBookParticipation) GetIsSettled() bool { + if x != nil { + return x.IsSettled + } + return false +} + +func (x *OrderBookParticipation) GetReturnedAmount() string { + if x != nil { + return x.ReturnedAmount + } + return "" +} + +func (x *OrderBookParticipation) GetReimbursedFee() string { + if x != nil { + return x.ReimbursedFee + } + return "" +} + +// ParticipationBetPair represents the book participation and bet bond. +type ParticipationBetPair struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid is the unique identifier corresponding to the order book + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,proto3" json:"order_book_uid,omitempty"` + // participation_index is the index of participation corresponding to the bet + // fulfillment. + ParticipationIndex uint64 `protobuf:"varint,2,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // bet_uid is the bet universal unique identifier of the bet that is + // fulfilled. + BetUid string `protobuf:"bytes,3,opt,name=bet_uid,proto3" json:"bet_uid,omitempty"` +} + +func (x *ParticipationBetPair) Reset() { + *x = ParticipationBetPair{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ParticipationBetPair) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ParticipationBetPair) ProtoMessage() {} + +// Deprecated: Use ParticipationBetPair.ProtoReflect.Descriptor instead. +func (*ParticipationBetPair) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_participation_proto_rawDescGZIP(), []int{1} +} + +func (x *ParticipationBetPair) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *ParticipationBetPair) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *ParticipationBetPair) GetBetUid() string { + if x != nil { + return x.BetUid + } + return "" +} + +// SettledOrderbookParticipation is the type for a settled orderbook +// participation. +type SettledOrderbookParticipation struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // index is the index of the participation in the participation queue. + Index uint64 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"` + // order_book_uid is the unique identifier corresponding to the order book. + OrderBookUid string `protobuf:"bytes,2,opt,name=order_book_uid,proto3" json:"order_book_uid,omitempty"` + // participant_address is the bech32-encoded address of the participant. + ParticipantAddress string `protobuf:"bytes,3,opt,name=participant_address,json=participantAddress,proto3" json:"participant_address,omitempty"` +} + +func (x *SettledOrderbookParticipation) Reset() { + *x = SettledOrderbookParticipation{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SettledOrderbookParticipation) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SettledOrderbookParticipation) ProtoMessage() {} + +// Deprecated: Use SettledOrderbookParticipation.ProtoReflect.Descriptor instead. +func (*SettledOrderbookParticipation) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_participation_proto_rawDescGZIP(), []int{2} +} + +func (x *SettledOrderbookParticipation) GetIndex() uint64 { + if x != nil { + return x.Index + } + return 0 +} + +func (x *SettledOrderbookParticipation) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *SettledOrderbookParticipation) GetParticipantAddress() string { + if x != nil { + return x.ParticipantAddress + } + return "" +} + +var File_sge_legacy_orderbook_v1beta_participation_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_participation_proto_rawDesc = []byte{ + 0x0a, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, + 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, + 0x9d, 0x0c, 0x0a, 0x16, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, + 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x05, 0x69, 0x6e, + 0x64, 0x65, 0x78, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x42, 0x10, 0xf2, 0xde, 0x1f, 0x0c, 0x79, + 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x05, 0x69, 0x6e, 0x64, + 0x65, 0x78, 0x12, 0x4a, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, + 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x22, 0xe2, 0xde, 0x1f, 0x0c, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0e, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0e, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x67, + 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x6e, 0x74, 0x5f, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x36, 0xf2, 0xde, 0x1f, + 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x6e, 0x74, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x4f, 0x0a, 0x09, 0x6c, 0x69, 0x71, 0x75, 0x69, + 0x64, 0x69, 0x74, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x31, 0xc8, 0xde, 0x1f, 0x00, + 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, + 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x10, 0x79, 0x61, 0x6d, + 0x6c, 0x3a, 0x22, 0x6c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x22, 0x52, 0x09, 0x6c, + 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x12, 0x3d, 0x0a, 0x03, 0x66, 0x65, 0x65, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2b, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, + 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x0a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x66, 0x65, + 0x65, 0x22, 0x52, 0x03, 0x66, 0x65, 0x65, 0x12, 0x77, 0x0a, 0x17, 0x63, 0x75, 0x72, 0x72, 0x65, + 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x6c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, + 0x74, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x42, 0x3f, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, + 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, + 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x1e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x6c, + 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, 0x22, 0x52, 0x15, 0x63, 0x75, 0x72, 0x72, 0x65, + 0x6e, 0x74, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x4c, 0x69, 0x71, 0x75, 0x69, 0x64, 0x69, 0x74, 0x79, + 0x12, 0x51, 0x0a, 0x14, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x5f, 0x6e, 0x6f, + 0x74, 0x5f, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1f, + 0xf2, 0xde, 0x1f, 0x1b, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, + 0x72, 0x65, 0x73, 0x5f, 0x6e, 0x6f, 0x74, 0x5f, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x22, 0x52, + 0x12, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x4e, 0x6f, 0x74, 0x46, 0x69, 0x6c, + 0x6c, 0x65, 0x64, 0x12, 0x62, 0x0a, 0x10, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x62, 0x65, 0x74, + 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x38, 0xc8, + 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x17, + 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x62, 0x65, 0x74, 0x5f, + 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x0e, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x42, 0x65, + 0x74, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x8a, 0x01, 0x0a, 0x1e, 0x63, 0x75, 0x72, 0x72, + 0x65, 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, + 0x62, 0x65, 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x46, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, + 0xde, 0x1f, 0x25, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, + 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x62, 0x65, 0x74, + 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x1a, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, + 0x74, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x42, 0x65, 0x74, 0x41, 0x6d, + 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x4b, 0x0a, 0x08, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, + 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x42, 0x30, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, + 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x0f, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, + 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x22, 0x52, 0x07, 0x6d, 0x61, 0x78, 0x4c, 0x6f, 0x73, + 0x73, 0x12, 0x73, 0x0a, 0x16, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, + 0x6e, 0x64, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x18, 0x0b, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x3e, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, + 0xf2, 0xde, 0x1f, 0x1d, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, + 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, + 0x22, 0x52, 0x13, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x52, 0x6f, 0x75, 0x6e, 0x64, 0x4d, + 0x61, 0x78, 0x4c, 0x6f, 0x73, 0x73, 0x12, 0xb5, 0x01, 0x0a, 0x1f, 0x63, 0x75, 0x72, 0x72, 0x65, + 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, + 0x73, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x6b, 0xe2, 0xde, 0x1f, 0x1a, 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x52, 0x6f, 0x75, + 0x6e, 0x64, 0x4d, 0x61, 0x78, 0x4c, 0x6f, 0x73, 0x73, 0x4f, 0x64, 0x64, 0x73, 0x55, 0x49, 0x44, + 0xea, 0xde, 0x1f, 0x1f, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, + 0x64, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, + 0x75, 0x69, 0x64, 0xf2, 0xde, 0x1f, 0x26, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x63, 0x75, 0x72, + 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x6c, + 0x6f, 0x73, 0x73, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x22, 0x52, 0x1f, 0x63, + 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x5f, 0x6d, 0x61, 0x78, + 0x5f, 0x6c, 0x6f, 0x73, 0x73, 0x5f, 0x6f, 0x64, 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x5a, + 0x0a, 0x0d, 0x61, 0x63, 0x74, 0x75, 0x61, 0x6c, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x74, 0x18, + 0x0d, 0x20, 0x01, 0x28, 0x09, 0x42, 0x35, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, + 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x14, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x61, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x74, 0x22, 0x52, 0x0c, 0x61, 0x63, + 0x74, 0x75, 0x61, 0x6c, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x74, 0x12, 0x34, 0x0a, 0x0a, 0x69, 0x73, + 0x5f, 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x42, 0x15, + 0xf2, 0xde, 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x69, 0x73, 0x5f, 0x73, 0x65, 0x74, + 0x74, 0x6c, 0x65, 0x64, 0x22, 0x52, 0x09, 0x69, 0x73, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, + 0x12, 0x60, 0x0a, 0x0f, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x65, 0x64, 0x5f, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x42, 0x37, 0xc8, 0xde, 0x1f, 0x00, 0xda, + 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x16, 0x79, 0x61, 0x6d, 0x6c, + 0x3a, 0x22, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x65, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, + 0x74, 0x22, 0x52, 0x0e, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x65, 0x64, 0x41, 0x6d, 0x6f, 0x75, + 0x6e, 0x74, 0x12, 0x5d, 0x0a, 0x0e, 0x72, 0x65, 0x69, 0x6d, 0x62, 0x75, 0x72, 0x73, 0x65, 0x64, + 0x5f, 0x66, 0x65, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x42, 0x36, 0xc8, 0xde, 0x1f, 0x00, + 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, + 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x15, 0x79, 0x61, 0x6d, + 0x6c, 0x3a, 0x22, 0x72, 0x65, 0x69, 0x6d, 0x62, 0x75, 0x72, 0x73, 0x65, 0x64, 0x5f, 0x66, 0x65, + 0x65, 0x22, 0x52, 0x0d, 0x72, 0x65, 0x69, 0x6d, 0x62, 0x75, 0x72, 0x73, 0x65, 0x64, 0x46, 0x65, + 0x65, 0x3a, 0x0c, 0x88, 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x00, 0x22, + 0xe4, 0x01, 0x0a, 0x14, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x42, 0x65, 0x74, 0x50, 0x61, 0x69, 0x72, 0x12, 0x4a, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x22, 0xe2, 0xde, 0x1f, 0x0c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, + 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, + 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, + 0x5f, 0x75, 0x69, 0x64, 0x12, 0x4f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x04, 0x42, 0x1e, 0xf2, 0xde, 0x1f, 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, + 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, + 0x22, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x2f, 0x0a, 0x07, 0x62, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x15, 0xe2, 0xde, 0x1f, 0x06, 0x42, 0x65, 0x74, 0x55, + 0x49, 0x44, 0xea, 0xde, 0x1f, 0x07, 0x62, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x07, 0x62, + 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x22, 0xfc, 0x01, 0x0a, 0x1d, 0x53, 0x65, 0x74, 0x74, 0x6c, + 0x65, 0x64, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x05, 0x69, 0x6e, 0x64, 0x65, + 0x78, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x42, 0x10, 0xf2, 0xde, 0x1f, 0x0c, 0x79, 0x61, 0x6d, + 0x6c, 0x3a, 0x22, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x52, 0x05, 0x69, 0x6e, 0x64, 0x65, 0x78, + 0x12, 0x4a, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, + 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x22, 0xe2, 0xde, 0x1f, 0x0c, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0e, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0e, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x67, 0x0a, 0x13, + 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x36, 0xf2, 0xde, 0x1f, 0x1a, 0x79, + 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x6e, 0x74, + 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, + 0x67, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x6e, 0x74, 0x41, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x42, 0x90, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, + 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x12, 0x50, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x4a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, + 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, + 0x4f, 0xaa, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, + 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x27, + 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_participation_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_participation_proto_rawDescData = file_sge_legacy_orderbook_v1beta_participation_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_participation_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_participation_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_participation_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_participation_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_participation_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_sge_legacy_orderbook_v1beta_participation_proto_goTypes = []interface{}{ + (*OrderBookParticipation)(nil), // 0: sge.legacy.orderbook.v1beta.OrderBookParticipation + (*ParticipationBetPair)(nil), // 1: sge.legacy.orderbook.v1beta.ParticipationBetPair + (*SettledOrderbookParticipation)(nil), // 2: sge.legacy.orderbook.v1beta.SettledOrderbookParticipation +} +var file_sge_legacy_orderbook_v1beta_participation_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_participation_proto_init() } +func file_sge_legacy_orderbook_v1beta_participation_proto_init() { + if File_sge_legacy_orderbook_v1beta_participation_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*OrderBookParticipation); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ParticipationBetPair); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SettledOrderbookParticipation); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_participation_proto_rawDesc, + NumEnums: 0, + NumMessages: 3, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_participation_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_participation_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_v1beta_participation_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_participation_proto = out.File + file_sge_legacy_orderbook_v1beta_participation_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_participation_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_participation_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/query.pulsar.go b/api/sge/legacy/orderbook/v1beta/query.pulsar.go new file mode 100644 index 00000000..f93ef5c6 --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/query.pulsar.go @@ -0,0 +1,14104 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + v1beta1 "cosmossdk.io/api/cosmos/base/query/v1beta1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBooksRequest protoreflect.MessageDescriptor + fd_QueryOrderBooksRequest_status protoreflect.FieldDescriptor + fd_QueryOrderBooksRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBooksRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBooksRequest") + fd_QueryOrderBooksRequest_status = md_QueryOrderBooksRequest.Fields().ByName("status") + fd_QueryOrderBooksRequest_pagination = md_QueryOrderBooksRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBooksRequest)(nil) + +type fastReflection_QueryOrderBooksRequest QueryOrderBooksRequest + +func (x *QueryOrderBooksRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBooksRequest)(x) +} + +func (x *QueryOrderBooksRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBooksRequest_messageType fastReflection_QueryOrderBooksRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBooksRequest_messageType{} + +type fastReflection_QueryOrderBooksRequest_messageType struct{} + +func (x fastReflection_QueryOrderBooksRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBooksRequest)(nil) +} +func (x fastReflection_QueryOrderBooksRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBooksRequest) +} +func (x fastReflection_QueryOrderBooksRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBooksRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBooksRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBooksRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBooksRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBooksRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBooksRequest) New() protoreflect.Message { + return new(fastReflection_QueryOrderBooksRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBooksRequest) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBooksRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBooksRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Status != "" { + value := protoreflect.ValueOfString(x.Status) + if !f(fd_QueryOrderBooksRequest_status, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBooksRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBooksRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.status": + return x.Status != "" + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.status": + x.Status = "" + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBooksRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.status": + value := x.Status + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.status": + x.Status = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.status": + panic(fmt.Errorf("field status of message sge.legacy.orderbook.v1beta.QueryOrderBooksRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBooksRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.status": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBooksRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBooksRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBooksRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBooksRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBooksRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBooksRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Status) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBooksRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Status) > 0 { + i -= len(x.Status) + copy(dAtA[i:], x.Status) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Status))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBooksRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBooksRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBooksRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Status = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryOrderBooksResponse_1_list)(nil) + +type _QueryOrderBooksResponse_1_list struct { + list *[]*OrderBook +} + +func (x *_QueryOrderBooksResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryOrderBooksResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryOrderBooksResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBook) + (*x.list)[i] = concreteValue +} + +func (x *_QueryOrderBooksResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBook) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryOrderBooksResponse_1_list) AppendMutable() protoreflect.Value { + v := new(OrderBook) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBooksResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryOrderBooksResponse_1_list) NewElement() protoreflect.Value { + v := new(OrderBook) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBooksResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryOrderBooksResponse protoreflect.MessageDescriptor + fd_QueryOrderBooksResponse_orderbooks protoreflect.FieldDescriptor + fd_QueryOrderBooksResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBooksResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBooksResponse") + fd_QueryOrderBooksResponse_orderbooks = md_QueryOrderBooksResponse.Fields().ByName("orderbooks") + fd_QueryOrderBooksResponse_pagination = md_QueryOrderBooksResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBooksResponse)(nil) + +type fastReflection_QueryOrderBooksResponse QueryOrderBooksResponse + +func (x *QueryOrderBooksResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBooksResponse)(x) +} + +func (x *QueryOrderBooksResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBooksResponse_messageType fastReflection_QueryOrderBooksResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBooksResponse_messageType{} + +type fastReflection_QueryOrderBooksResponse_messageType struct{} + +func (x fastReflection_QueryOrderBooksResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBooksResponse)(nil) +} +func (x fastReflection_QueryOrderBooksResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBooksResponse) +} +func (x fastReflection_QueryOrderBooksResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBooksResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBooksResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBooksResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBooksResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBooksResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBooksResponse) New() protoreflect.Message { + return new(fastReflection_QueryOrderBooksResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBooksResponse) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBooksResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBooksResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Orderbooks) != 0 { + value := protoreflect.ValueOfList(&_QueryOrderBooksResponse_1_list{list: &x.Orderbooks}) + if !f(fd_QueryOrderBooksResponse_orderbooks, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBooksResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBooksResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.orderbooks": + return len(x.Orderbooks) != 0 + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.orderbooks": + x.Orderbooks = nil + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBooksResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.orderbooks": + if len(x.Orderbooks) == 0 { + return protoreflect.ValueOfList(&_QueryOrderBooksResponse_1_list{}) + } + listValue := &_QueryOrderBooksResponse_1_list{list: &x.Orderbooks} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.orderbooks": + lv := value.List() + clv := lv.(*_QueryOrderBooksResponse_1_list) + x.Orderbooks = *clv.list + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.orderbooks": + if x.Orderbooks == nil { + x.Orderbooks = []*OrderBook{} + } + value := &_QueryOrderBooksResponse_1_list{list: &x.Orderbooks} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBooksResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.orderbooks": + list := []*OrderBook{} + return protoreflect.ValueOfList(&_QueryOrderBooksResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBooksResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBooksResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBooksResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBooksResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBooksResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBooksResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBooksResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBooksResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Orderbooks) > 0 { + for _, e := range x.Orderbooks { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBooksResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Orderbooks) > 0 { + for iNdEx := len(x.Orderbooks) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Orderbooks[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBooksResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBooksResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBooksResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Orderbooks", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Orderbooks = append(x.Orderbooks, &OrderBook{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Orderbooks[len(x.Orderbooks)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookRequest protoreflect.MessageDescriptor + fd_QueryOrderBookRequest_order_book_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookRequest") + fd_QueryOrderBookRequest_order_book_uid = md_QueryOrderBookRequest.Fields().ByName("order_book_uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookRequest)(nil) + +type fastReflection_QueryOrderBookRequest QueryOrderBookRequest + +func (x *QueryOrderBookRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookRequest)(x) +} + +func (x *QueryOrderBookRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookRequest_messageType fastReflection_QueryOrderBookRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookRequest_messageType{} + +type fastReflection_QueryOrderBookRequest_messageType struct{} + +func (x fastReflection_QueryOrderBookRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookRequest)(nil) +} +func (x fastReflection_QueryOrderBookRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookRequest) +} +func (x fastReflection_QueryOrderBookRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookRequest) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookRequest) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryOrderBookRequest_order_book_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookRequest.order_book_uid": + return x.OrderBookUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookRequest.order_book_uid": + x.OrderBookUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryOrderBookRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookRequest.order_book_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookResponse protoreflect.MessageDescriptor + fd_QueryOrderBookResponse_order_book protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookResponse") + fd_QueryOrderBookResponse_order_book = md_QueryOrderBookResponse.Fields().ByName("order_book") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookResponse)(nil) + +type fastReflection_QueryOrderBookResponse QueryOrderBookResponse + +func (x *QueryOrderBookResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookResponse)(x) +} + +func (x *QueryOrderBookResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookResponse_messageType fastReflection_QueryOrderBookResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookResponse_messageType{} + +type fastReflection_QueryOrderBookResponse_messageType struct{} + +func (x fastReflection_QueryOrderBookResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookResponse)(nil) +} +func (x fastReflection_QueryOrderBookResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookResponse) +} +func (x fastReflection_QueryOrderBookResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookResponse) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookResponse) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBook != nil { + value := protoreflect.ValueOfMessage(x.OrderBook.ProtoReflect()) + if !f(fd_QueryOrderBookResponse_order_book, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookResponse.order_book": + return x.OrderBook != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookResponse.order_book": + x.OrderBook = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookResponse.order_book": + value := x.OrderBook + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookResponse.order_book": + x.OrderBook = value.Message().Interface().(*OrderBook) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookResponse.order_book": + if x.OrderBook == nil { + x.OrderBook = new(OrderBook) + } + return protoreflect.ValueOfMessage(x.OrderBook.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookResponse.order_book": + m := new(OrderBook) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.OrderBook != nil { + l = options.Size(x.OrderBook) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.OrderBook != nil { + encoded, err := options.Marshal(x.OrderBook) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBook", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.OrderBook == nil { + x.OrderBook = &OrderBook{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBook); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookParticipationsRequest protoreflect.MessageDescriptor + fd_QueryOrderBookParticipationsRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryOrderBookParticipationsRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookParticipationsRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookParticipationsRequest") + fd_QueryOrderBookParticipationsRequest_order_book_uid = md_QueryOrderBookParticipationsRequest.Fields().ByName("order_book_uid") + fd_QueryOrderBookParticipationsRequest_pagination = md_QueryOrderBookParticipationsRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookParticipationsRequest)(nil) + +type fastReflection_QueryOrderBookParticipationsRequest QueryOrderBookParticipationsRequest + +func (x *QueryOrderBookParticipationsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationsRequest)(x) +} + +func (x *QueryOrderBookParticipationsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookParticipationsRequest_messageType fastReflection_QueryOrderBookParticipationsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookParticipationsRequest_messageType{} + +type fastReflection_QueryOrderBookParticipationsRequest_messageType struct{} + +func (x fastReflection_QueryOrderBookParticipationsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationsRequest)(nil) +} +func (x fastReflection_QueryOrderBookParticipationsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationsRequest) +} +func (x fastReflection_QueryOrderBookParticipationsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookParticipationsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookParticipationsRequest) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookParticipationsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryOrderBookParticipationsRequest_order_book_uid, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBookParticipationsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookParticipationsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookParticipationsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookParticipationsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookParticipationsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookParticipationsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookParticipationsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryOrderBookParticipationsResponse_1_list)(nil) + +type _QueryOrderBookParticipationsResponse_1_list struct { + list *[]*OrderBookParticipation +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookParticipation) + (*x.list)[i] = concreteValue +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookParticipation) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(OrderBookParticipation) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) NewElement() protoreflect.Value { + v := new(OrderBookParticipation) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBookParticipationsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryOrderBookParticipationsResponse protoreflect.MessageDescriptor + fd_QueryOrderBookParticipationsResponse_order_book_participations protoreflect.FieldDescriptor + fd_QueryOrderBookParticipationsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookParticipationsResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookParticipationsResponse") + fd_QueryOrderBookParticipationsResponse_order_book_participations = md_QueryOrderBookParticipationsResponse.Fields().ByName("order_book_participations") + fd_QueryOrderBookParticipationsResponse_pagination = md_QueryOrderBookParticipationsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookParticipationsResponse)(nil) + +type fastReflection_QueryOrderBookParticipationsResponse QueryOrderBookParticipationsResponse + +func (x *QueryOrderBookParticipationsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationsResponse)(x) +} + +func (x *QueryOrderBookParticipationsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookParticipationsResponse_messageType fastReflection_QueryOrderBookParticipationsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookParticipationsResponse_messageType{} + +type fastReflection_QueryOrderBookParticipationsResponse_messageType struct{} + +func (x fastReflection_QueryOrderBookParticipationsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationsResponse)(nil) +} +func (x fastReflection_QueryOrderBookParticipationsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationsResponse) +} +func (x fastReflection_QueryOrderBookParticipationsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookParticipationsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookParticipationsResponse) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookParticipationsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.OrderBookParticipations) != 0 { + value := protoreflect.ValueOfList(&_QueryOrderBookParticipationsResponse_1_list{list: &x.OrderBookParticipations}) + if !f(fd_QueryOrderBookParticipationsResponse_order_book_participations, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBookParticipationsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.order_book_participations": + return len(x.OrderBookParticipations) != 0 + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.order_book_participations": + x.OrderBookParticipations = nil + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.order_book_participations": + if len(x.OrderBookParticipations) == 0 { + return protoreflect.ValueOfList(&_QueryOrderBookParticipationsResponse_1_list{}) + } + listValue := &_QueryOrderBookParticipationsResponse_1_list{list: &x.OrderBookParticipations} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.order_book_participations": + lv := value.List() + clv := lv.(*_QueryOrderBookParticipationsResponse_1_list) + x.OrderBookParticipations = *clv.list + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.order_book_participations": + if x.OrderBookParticipations == nil { + x.OrderBookParticipations = []*OrderBookParticipation{} + } + value := &_QueryOrderBookParticipationsResponse_1_list{list: &x.OrderBookParticipations} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookParticipationsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.order_book_participations": + list := []*OrderBookParticipation{} + return protoreflect.ValueOfList(&_QueryOrderBookParticipationsResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookParticipationsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookParticipationsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookParticipationsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookParticipationsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookParticipationsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.OrderBookParticipations) > 0 { + for _, e := range x.OrderBookParticipations { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookParticipations) > 0 { + for iNdEx := len(x.OrderBookParticipations) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.OrderBookParticipations[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookParticipations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookParticipations = append(x.OrderBookParticipations, &OrderBookParticipation{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBookParticipations[len(x.OrderBookParticipations)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookParticipationRequest protoreflect.MessageDescriptor + fd_QueryOrderBookParticipationRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryOrderBookParticipationRequest_participation_index protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookParticipationRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookParticipationRequest") + fd_QueryOrderBookParticipationRequest_order_book_uid = md_QueryOrderBookParticipationRequest.Fields().ByName("order_book_uid") + fd_QueryOrderBookParticipationRequest_participation_index = md_QueryOrderBookParticipationRequest.Fields().ByName("participation_index") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookParticipationRequest)(nil) + +type fastReflection_QueryOrderBookParticipationRequest QueryOrderBookParticipationRequest + +func (x *QueryOrderBookParticipationRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationRequest)(x) +} + +func (x *QueryOrderBookParticipationRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookParticipationRequest_messageType fastReflection_QueryOrderBookParticipationRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookParticipationRequest_messageType{} + +type fastReflection_QueryOrderBookParticipationRequest_messageType struct{} + +func (x fastReflection_QueryOrderBookParticipationRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationRequest)(nil) +} +func (x fastReflection_QueryOrderBookParticipationRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationRequest) +} +func (x fastReflection_QueryOrderBookParticipationRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookParticipationRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookParticipationRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookParticipationRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookParticipationRequest) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookParticipationRequest) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookParticipationRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookParticipationRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryOrderBookParticipationRequest_order_book_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_QueryOrderBookParticipationRequest_participation_index, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookParticipationRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.participation_index": + return x.ParticipationIndex != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.participation_index": + x.ParticipationIndex = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookParticipationRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.participation_index": + x.ParticipationIndex = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest is not mutable")) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookParticipationRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookParticipationRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookParticipationRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookParticipationRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookParticipationRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookParticipationRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x10 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookParticipationResponse protoreflect.MessageDescriptor + fd_QueryOrderBookParticipationResponse_order_book_participation protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookParticipationResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookParticipationResponse") + fd_QueryOrderBookParticipationResponse_order_book_participation = md_QueryOrderBookParticipationResponse.Fields().ByName("order_book_participation") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookParticipationResponse)(nil) + +type fastReflection_QueryOrderBookParticipationResponse QueryOrderBookParticipationResponse + +func (x *QueryOrderBookParticipationResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationResponse)(x) +} + +func (x *QueryOrderBookParticipationResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookParticipationResponse_messageType fastReflection_QueryOrderBookParticipationResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookParticipationResponse_messageType{} + +type fastReflection_QueryOrderBookParticipationResponse_messageType struct{} + +func (x fastReflection_QueryOrderBookParticipationResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationResponse)(nil) +} +func (x fastReflection_QueryOrderBookParticipationResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationResponse) +} +func (x fastReflection_QueryOrderBookParticipationResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookParticipationResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookParticipationResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookParticipationResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookParticipationResponse) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookParticipationResponse) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookParticipationResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookParticipationResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookParticipation != nil { + value := protoreflect.ValueOfMessage(x.OrderBookParticipation.ProtoReflect()) + if !f(fd_QueryOrderBookParticipationResponse_order_book_participation, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookParticipationResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse.order_book_participation": + return x.OrderBookParticipation != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse.order_book_participation": + x.OrderBookParticipation = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookParticipationResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse.order_book_participation": + value := x.OrderBookParticipation + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse.order_book_participation": + x.OrderBookParticipation = value.Message().Interface().(*OrderBookParticipation) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse.order_book_participation": + if x.OrderBookParticipation == nil { + x.OrderBookParticipation = new(OrderBookParticipation) + } + return protoreflect.ValueOfMessage(x.OrderBookParticipation.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookParticipationResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse.order_book_participation": + m := new(OrderBookParticipation) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookParticipationResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookParticipationResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookParticipationResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookParticipationResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookParticipationResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.OrderBookParticipation != nil { + l = options.Size(x.OrderBookParticipation) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.OrderBookParticipation != nil { + encoded, err := options.Marshal(x.OrderBookParticipation) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookParticipation", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.OrderBookParticipation == nil { + x.OrderBookParticipation = &OrderBookParticipation{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBookParticipation); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookExposuresRequest protoreflect.MessageDescriptor + fd_QueryOrderBookExposuresRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryOrderBookExposuresRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookExposuresRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookExposuresRequest") + fd_QueryOrderBookExposuresRequest_order_book_uid = md_QueryOrderBookExposuresRequest.Fields().ByName("order_book_uid") + fd_QueryOrderBookExposuresRequest_pagination = md_QueryOrderBookExposuresRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookExposuresRequest)(nil) + +type fastReflection_QueryOrderBookExposuresRequest QueryOrderBookExposuresRequest + +func (x *QueryOrderBookExposuresRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposuresRequest)(x) +} + +func (x *QueryOrderBookExposuresRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookExposuresRequest_messageType fastReflection_QueryOrderBookExposuresRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookExposuresRequest_messageType{} + +type fastReflection_QueryOrderBookExposuresRequest_messageType struct{} + +func (x fastReflection_QueryOrderBookExposuresRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposuresRequest)(nil) +} +func (x fastReflection_QueryOrderBookExposuresRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposuresRequest) +} +func (x fastReflection_QueryOrderBookExposuresRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposuresRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookExposuresRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposuresRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookExposuresRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookExposuresRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookExposuresRequest) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposuresRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookExposuresRequest) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookExposuresRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookExposuresRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryOrderBookExposuresRequest_order_book_uid, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBookExposuresRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookExposuresRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookExposuresRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookExposuresRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookExposuresRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookExposuresRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookExposuresRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookExposuresRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookExposuresRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposuresRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposuresRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposuresRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposuresRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryOrderBookExposuresResponse_1_list)(nil) + +type _QueryOrderBookExposuresResponse_1_list struct { + list *[]*OrderBookOddsExposure +} + +func (x *_QueryOrderBookExposuresResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryOrderBookExposuresResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryOrderBookExposuresResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookOddsExposure) + (*x.list)[i] = concreteValue +} + +func (x *_QueryOrderBookExposuresResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookOddsExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryOrderBookExposuresResponse_1_list) AppendMutable() protoreflect.Value { + v := new(OrderBookOddsExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBookExposuresResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryOrderBookExposuresResponse_1_list) NewElement() protoreflect.Value { + v := new(OrderBookOddsExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBookExposuresResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryOrderBookExposuresResponse protoreflect.MessageDescriptor + fd_QueryOrderBookExposuresResponse_order_book_exposures protoreflect.FieldDescriptor + fd_QueryOrderBookExposuresResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookExposuresResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookExposuresResponse") + fd_QueryOrderBookExposuresResponse_order_book_exposures = md_QueryOrderBookExposuresResponse.Fields().ByName("order_book_exposures") + fd_QueryOrderBookExposuresResponse_pagination = md_QueryOrderBookExposuresResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookExposuresResponse)(nil) + +type fastReflection_QueryOrderBookExposuresResponse QueryOrderBookExposuresResponse + +func (x *QueryOrderBookExposuresResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposuresResponse)(x) +} + +func (x *QueryOrderBookExposuresResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookExposuresResponse_messageType fastReflection_QueryOrderBookExposuresResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookExposuresResponse_messageType{} + +type fastReflection_QueryOrderBookExposuresResponse_messageType struct{} + +func (x fastReflection_QueryOrderBookExposuresResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposuresResponse)(nil) +} +func (x fastReflection_QueryOrderBookExposuresResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposuresResponse) +} +func (x fastReflection_QueryOrderBookExposuresResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposuresResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookExposuresResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposuresResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookExposuresResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookExposuresResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookExposuresResponse) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposuresResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookExposuresResponse) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookExposuresResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookExposuresResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.OrderBookExposures) != 0 { + value := protoreflect.ValueOfList(&_QueryOrderBookExposuresResponse_1_list{list: &x.OrderBookExposures}) + if !f(fd_QueryOrderBookExposuresResponse_order_book_exposures, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBookExposuresResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookExposuresResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.order_book_exposures": + return len(x.OrderBookExposures) != 0 + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.order_book_exposures": + x.OrderBookExposures = nil + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookExposuresResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.order_book_exposures": + if len(x.OrderBookExposures) == 0 { + return protoreflect.ValueOfList(&_QueryOrderBookExposuresResponse_1_list{}) + } + listValue := &_QueryOrderBookExposuresResponse_1_list{list: &x.OrderBookExposures} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.order_book_exposures": + lv := value.List() + clv := lv.(*_QueryOrderBookExposuresResponse_1_list) + x.OrderBookExposures = *clv.list + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.order_book_exposures": + if x.OrderBookExposures == nil { + x.OrderBookExposures = []*OrderBookOddsExposure{} + } + value := &_QueryOrderBookExposuresResponse_1_list{list: &x.OrderBookExposures} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookExposuresResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.order_book_exposures": + list := []*OrderBookOddsExposure{} + return protoreflect.ValueOfList(&_QueryOrderBookExposuresResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookExposuresResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookExposuresResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposuresResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookExposuresResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookExposuresResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookExposuresResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.OrderBookExposures) > 0 { + for _, e := range x.OrderBookExposures { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposuresResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookExposures) > 0 { + for iNdEx := len(x.OrderBookExposures) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.OrderBookExposures[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposuresResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposuresResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposuresResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookExposures", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookExposures = append(x.OrderBookExposures, &OrderBookOddsExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBookExposures[len(x.OrderBookExposures)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookExposureRequest protoreflect.MessageDescriptor + fd_QueryOrderBookExposureRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryOrderBookExposureRequest_odds_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookExposureRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookExposureRequest") + fd_QueryOrderBookExposureRequest_order_book_uid = md_QueryOrderBookExposureRequest.Fields().ByName("order_book_uid") + fd_QueryOrderBookExposureRequest_odds_uid = md_QueryOrderBookExposureRequest.Fields().ByName("odds_uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookExposureRequest)(nil) + +type fastReflection_QueryOrderBookExposureRequest QueryOrderBookExposureRequest + +func (x *QueryOrderBookExposureRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposureRequest)(x) +} + +func (x *QueryOrderBookExposureRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookExposureRequest_messageType fastReflection_QueryOrderBookExposureRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookExposureRequest_messageType{} + +type fastReflection_QueryOrderBookExposureRequest_messageType struct{} + +func (x fastReflection_QueryOrderBookExposureRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposureRequest)(nil) +} +func (x fastReflection_QueryOrderBookExposureRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposureRequest) +} +func (x fastReflection_QueryOrderBookExposureRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposureRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookExposureRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposureRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookExposureRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookExposureRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookExposureRequest) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposureRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookExposureRequest) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookExposureRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookExposureRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryOrderBookExposureRequest_order_book_uid, value) { + return + } + } + if x.OddsUid != "" { + value := protoreflect.ValueOfString(x.OddsUid) + if !f(fd_QueryOrderBookExposureRequest_odds_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookExposureRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.odds_uid": + return x.OddsUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.odds_uid": + x.OddsUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookExposureRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.odds_uid": + value := x.OddsUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.odds_uid": + x.OddsUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest is not mutable")) + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.odds_uid": + panic(fmt.Errorf("field odds_uid of message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookExposureRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest.odds_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookExposureRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookExposureRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookExposureRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookExposureRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookExposureRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.OddsUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposureRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.OddsUid) > 0 { + i -= len(x.OddsUid) + copy(dAtA[i:], x.OddsUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OddsUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposureRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposureRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposureRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OddsUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OddsUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookExposureResponse protoreflect.MessageDescriptor + fd_QueryOrderBookExposureResponse_order_book_exposure protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookExposureResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookExposureResponse") + fd_QueryOrderBookExposureResponse_order_book_exposure = md_QueryOrderBookExposureResponse.Fields().ByName("order_book_exposure") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookExposureResponse)(nil) + +type fastReflection_QueryOrderBookExposureResponse QueryOrderBookExposureResponse + +func (x *QueryOrderBookExposureResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposureResponse)(x) +} + +func (x *QueryOrderBookExposureResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookExposureResponse_messageType fastReflection_QueryOrderBookExposureResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookExposureResponse_messageType{} + +type fastReflection_QueryOrderBookExposureResponse_messageType struct{} + +func (x fastReflection_QueryOrderBookExposureResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookExposureResponse)(nil) +} +func (x fastReflection_QueryOrderBookExposureResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposureResponse) +} +func (x fastReflection_QueryOrderBookExposureResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposureResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookExposureResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookExposureResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookExposureResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookExposureResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookExposureResponse) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookExposureResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookExposureResponse) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookExposureResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookExposureResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookExposure != nil { + value := protoreflect.ValueOfMessage(x.OrderBookExposure.ProtoReflect()) + if !f(fd_QueryOrderBookExposureResponse_order_book_exposure, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookExposureResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse.order_book_exposure": + return x.OrderBookExposure != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse.order_book_exposure": + x.OrderBookExposure = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookExposureResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse.order_book_exposure": + value := x.OrderBookExposure + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse.order_book_exposure": + x.OrderBookExposure = value.Message().Interface().(*OrderBookOddsExposure) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse.order_book_exposure": + if x.OrderBookExposure == nil { + x.OrderBookExposure = new(OrderBookOddsExposure) + } + return protoreflect.ValueOfMessage(x.OrderBookExposure.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookExposureResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse.order_book_exposure": + m := new(OrderBookOddsExposure) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookExposureResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookExposureResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookExposureResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookExposureResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookExposureResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookExposureResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.OrderBookExposure != nil { + l = options.Size(x.OrderBookExposure) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposureResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.OrderBookExposure != nil { + encoded, err := options.Marshal(x.OrderBookExposure) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookExposureResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposureResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookExposureResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookExposure", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.OrderBookExposure == nil { + x.OrderBookExposure = &OrderBookOddsExposure{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.OrderBookExposure); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryOrderBookParticipationExposuresRequest protoreflect.MessageDescriptor + fd_QueryOrderBookParticipationExposuresRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryOrderBookParticipationExposuresRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookParticipationExposuresRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookParticipationExposuresRequest") + fd_QueryOrderBookParticipationExposuresRequest_order_book_uid = md_QueryOrderBookParticipationExposuresRequest.Fields().ByName("order_book_uid") + fd_QueryOrderBookParticipationExposuresRequest_pagination = md_QueryOrderBookParticipationExposuresRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookParticipationExposuresRequest)(nil) + +type fastReflection_QueryOrderBookParticipationExposuresRequest QueryOrderBookParticipationExposuresRequest + +func (x *QueryOrderBookParticipationExposuresRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationExposuresRequest)(x) +} + +func (x *QueryOrderBookParticipationExposuresRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[14] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookParticipationExposuresRequest_messageType fastReflection_QueryOrderBookParticipationExposuresRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookParticipationExposuresRequest_messageType{} + +type fastReflection_QueryOrderBookParticipationExposuresRequest_messageType struct{} + +func (x fastReflection_QueryOrderBookParticipationExposuresRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationExposuresRequest)(nil) +} +func (x fastReflection_QueryOrderBookParticipationExposuresRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationExposuresRequest) +} +func (x fastReflection_QueryOrderBookParticipationExposuresRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationExposuresRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationExposuresRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookParticipationExposuresRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationExposuresRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookParticipationExposuresRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryOrderBookParticipationExposuresRequest_order_book_uid, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBookParticipationExposuresRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookParticipationExposuresRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookParticipationExposuresRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationExposuresRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationExposuresRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationExposuresRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationExposuresRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryOrderBookParticipationExposuresResponse_1_list)(nil) + +type _QueryOrderBookParticipationExposuresResponse_1_list struct { + list *[]*ParticipationExposure +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + (*x.list)[i] = concreteValue +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) AppendMutable() protoreflect.Value { + v := new(ParticipationExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) NewElement() protoreflect.Value { + v := new(ParticipationExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryOrderBookParticipationExposuresResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryOrderBookParticipationExposuresResponse protoreflect.MessageDescriptor + fd_QueryOrderBookParticipationExposuresResponse_participation_exposures protoreflect.FieldDescriptor + fd_QueryOrderBookParticipationExposuresResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryOrderBookParticipationExposuresResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryOrderBookParticipationExposuresResponse") + fd_QueryOrderBookParticipationExposuresResponse_participation_exposures = md_QueryOrderBookParticipationExposuresResponse.Fields().ByName("participation_exposures") + fd_QueryOrderBookParticipationExposuresResponse_pagination = md_QueryOrderBookParticipationExposuresResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryOrderBookParticipationExposuresResponse)(nil) + +type fastReflection_QueryOrderBookParticipationExposuresResponse QueryOrderBookParticipationExposuresResponse + +func (x *QueryOrderBookParticipationExposuresResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationExposuresResponse)(x) +} + +func (x *QueryOrderBookParticipationExposuresResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[15] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryOrderBookParticipationExposuresResponse_messageType fastReflection_QueryOrderBookParticipationExposuresResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryOrderBookParticipationExposuresResponse_messageType{} + +type fastReflection_QueryOrderBookParticipationExposuresResponse_messageType struct{} + +func (x fastReflection_QueryOrderBookParticipationExposuresResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryOrderBookParticipationExposuresResponse)(nil) +} +func (x fastReflection_QueryOrderBookParticipationExposuresResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationExposuresResponse) +} +func (x fastReflection_QueryOrderBookParticipationExposuresResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationExposuresResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryOrderBookParticipationExposuresResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryOrderBookParticipationExposuresResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) New() protoreflect.Message { + return new(fastReflection_QueryOrderBookParticipationExposuresResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Interface() protoreflect.ProtoMessage { + return (*QueryOrderBookParticipationExposuresResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.ParticipationExposures) != 0 { + value := protoreflect.ValueOfList(&_QueryOrderBookParticipationExposuresResponse_1_list{list: &x.ParticipationExposures}) + if !f(fd_QueryOrderBookParticipationExposuresResponse_participation_exposures, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryOrderBookParticipationExposuresResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.participation_exposures": + return len(x.ParticipationExposures) != 0 + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.participation_exposures": + x.ParticipationExposures = nil + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.participation_exposures": + if len(x.ParticipationExposures) == 0 { + return protoreflect.ValueOfList(&_QueryOrderBookParticipationExposuresResponse_1_list{}) + } + listValue := &_QueryOrderBookParticipationExposuresResponse_1_list{list: &x.ParticipationExposures} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.participation_exposures": + lv := value.List() + clv := lv.(*_QueryOrderBookParticipationExposuresResponse_1_list) + x.ParticipationExposures = *clv.list + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.participation_exposures": + if x.ParticipationExposures == nil { + x.ParticipationExposures = []*ParticipationExposure{} + } + value := &_QueryOrderBookParticipationExposuresResponse_1_list{list: &x.ParticipationExposures} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.participation_exposures": + list := []*ParticipationExposure{} + return protoreflect.ValueOfList(&_QueryOrderBookParticipationExposuresResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryOrderBookParticipationExposuresResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryOrderBookParticipationExposuresResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.ParticipationExposures) > 0 { + for _, e := range x.ParticipationExposures { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationExposuresResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.ParticipationExposures) > 0 { + for iNdEx := len(x.ParticipationExposures) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ParticipationExposures[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryOrderBookParticipationExposuresResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationExposuresResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryOrderBookParticipationExposuresResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationExposures", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipationExposures = append(x.ParticipationExposures, &ParticipationExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ParticipationExposures[len(x.ParticipationExposures)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParticipationExposuresRequest protoreflect.MessageDescriptor + fd_QueryParticipationExposuresRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryParticipationExposuresRequest_participation_index protoreflect.FieldDescriptor + fd_QueryParticipationExposuresRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryParticipationExposuresRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryParticipationExposuresRequest") + fd_QueryParticipationExposuresRequest_order_book_uid = md_QueryParticipationExposuresRequest.Fields().ByName("order_book_uid") + fd_QueryParticipationExposuresRequest_participation_index = md_QueryParticipationExposuresRequest.Fields().ByName("participation_index") + fd_QueryParticipationExposuresRequest_pagination = md_QueryParticipationExposuresRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryParticipationExposuresRequest)(nil) + +type fastReflection_QueryParticipationExposuresRequest QueryParticipationExposuresRequest + +func (x *QueryParticipationExposuresRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParticipationExposuresRequest)(x) +} + +func (x *QueryParticipationExposuresRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[16] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParticipationExposuresRequest_messageType fastReflection_QueryParticipationExposuresRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParticipationExposuresRequest_messageType{} + +type fastReflection_QueryParticipationExposuresRequest_messageType struct{} + +func (x fastReflection_QueryParticipationExposuresRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParticipationExposuresRequest)(nil) +} +func (x fastReflection_QueryParticipationExposuresRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParticipationExposuresRequest) +} +func (x fastReflection_QueryParticipationExposuresRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationExposuresRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParticipationExposuresRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationExposuresRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParticipationExposuresRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParticipationExposuresRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParticipationExposuresRequest) New() protoreflect.Message { + return new(fastReflection_QueryParticipationExposuresRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParticipationExposuresRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParticipationExposuresRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParticipationExposuresRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryParticipationExposuresRequest_order_book_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_QueryParticipationExposuresRequest_participation_index, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryParticipationExposuresRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParticipationExposuresRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParticipationExposuresRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest is not mutable")) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParticipationExposuresRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParticipationExposuresRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParticipationExposuresRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParticipationExposuresRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParticipationExposuresRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParticipationExposuresRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationExposuresRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x10 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationExposuresRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationExposuresRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationExposuresRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryParticipationExposuresResponse_1_list)(nil) + +type _QueryParticipationExposuresResponse_1_list struct { + list *[]*ParticipationExposure +} + +func (x *_QueryParticipationExposuresResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryParticipationExposuresResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryParticipationExposuresResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + (*x.list)[i] = concreteValue +} + +func (x *_QueryParticipationExposuresResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryParticipationExposuresResponse_1_list) AppendMutable() protoreflect.Value { + v := new(ParticipationExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryParticipationExposuresResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryParticipationExposuresResponse_1_list) NewElement() protoreflect.Value { + v := new(ParticipationExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryParticipationExposuresResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryParticipationExposuresResponse protoreflect.MessageDescriptor + fd_QueryParticipationExposuresResponse_participation_exposures protoreflect.FieldDescriptor + fd_QueryParticipationExposuresResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryParticipationExposuresResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryParticipationExposuresResponse") + fd_QueryParticipationExposuresResponse_participation_exposures = md_QueryParticipationExposuresResponse.Fields().ByName("participation_exposures") + fd_QueryParticipationExposuresResponse_pagination = md_QueryParticipationExposuresResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryParticipationExposuresResponse)(nil) + +type fastReflection_QueryParticipationExposuresResponse QueryParticipationExposuresResponse + +func (x *QueryParticipationExposuresResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParticipationExposuresResponse)(x) +} + +func (x *QueryParticipationExposuresResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[17] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParticipationExposuresResponse_messageType fastReflection_QueryParticipationExposuresResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParticipationExposuresResponse_messageType{} + +type fastReflection_QueryParticipationExposuresResponse_messageType struct{} + +func (x fastReflection_QueryParticipationExposuresResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParticipationExposuresResponse)(nil) +} +func (x fastReflection_QueryParticipationExposuresResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParticipationExposuresResponse) +} +func (x fastReflection_QueryParticipationExposuresResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationExposuresResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParticipationExposuresResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationExposuresResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParticipationExposuresResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParticipationExposuresResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParticipationExposuresResponse) New() protoreflect.Message { + return new(fastReflection_QueryParticipationExposuresResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParticipationExposuresResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParticipationExposuresResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParticipationExposuresResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.ParticipationExposures) != 0 { + value := protoreflect.ValueOfList(&_QueryParticipationExposuresResponse_1_list{list: &x.ParticipationExposures}) + if !f(fd_QueryParticipationExposuresResponse_participation_exposures, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryParticipationExposuresResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParticipationExposuresResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.participation_exposures": + return len(x.ParticipationExposures) != 0 + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.participation_exposures": + x.ParticipationExposures = nil + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParticipationExposuresResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.participation_exposures": + if len(x.ParticipationExposures) == 0 { + return protoreflect.ValueOfList(&_QueryParticipationExposuresResponse_1_list{}) + } + listValue := &_QueryParticipationExposuresResponse_1_list{list: &x.ParticipationExposures} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.participation_exposures": + lv := value.List() + clv := lv.(*_QueryParticipationExposuresResponse_1_list) + x.ParticipationExposures = *clv.list + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.participation_exposures": + if x.ParticipationExposures == nil { + x.ParticipationExposures = []*ParticipationExposure{} + } + value := &_QueryParticipationExposuresResponse_1_list{list: &x.ParticipationExposures} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParticipationExposuresResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.participation_exposures": + list := []*ParticipationExposure{} + return protoreflect.ValueOfList(&_QueryParticipationExposuresResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParticipationExposuresResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParticipationExposuresResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationExposuresResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParticipationExposuresResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParticipationExposuresResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParticipationExposuresResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.ParticipationExposures) > 0 { + for _, e := range x.ParticipationExposures { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationExposuresResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.ParticipationExposures) > 0 { + for iNdEx := len(x.ParticipationExposures) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ParticipationExposures[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationExposuresResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationExposuresResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationExposuresResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationExposures", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipationExposures = append(x.ParticipationExposures, &ParticipationExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ParticipationExposures[len(x.ParticipationExposures)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryHistoricalParticipationExposuresRequest protoreflect.MessageDescriptor + fd_QueryHistoricalParticipationExposuresRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryHistoricalParticipationExposuresRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryHistoricalParticipationExposuresRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryHistoricalParticipationExposuresRequest") + fd_QueryHistoricalParticipationExposuresRequest_order_book_uid = md_QueryHistoricalParticipationExposuresRequest.Fields().ByName("order_book_uid") + fd_QueryHistoricalParticipationExposuresRequest_pagination = md_QueryHistoricalParticipationExposuresRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryHistoricalParticipationExposuresRequest)(nil) + +type fastReflection_QueryHistoricalParticipationExposuresRequest QueryHistoricalParticipationExposuresRequest + +func (x *QueryHistoricalParticipationExposuresRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryHistoricalParticipationExposuresRequest)(x) +} + +func (x *QueryHistoricalParticipationExposuresRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[18] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryHistoricalParticipationExposuresRequest_messageType fastReflection_QueryHistoricalParticipationExposuresRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryHistoricalParticipationExposuresRequest_messageType{} + +type fastReflection_QueryHistoricalParticipationExposuresRequest_messageType struct{} + +func (x fastReflection_QueryHistoricalParticipationExposuresRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryHistoricalParticipationExposuresRequest)(nil) +} +func (x fastReflection_QueryHistoricalParticipationExposuresRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryHistoricalParticipationExposuresRequest) +} +func (x fastReflection_QueryHistoricalParticipationExposuresRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryHistoricalParticipationExposuresRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryHistoricalParticipationExposuresRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryHistoricalParticipationExposuresRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) New() protoreflect.Message { + return new(fastReflection_QueryHistoricalParticipationExposuresRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Interface() protoreflect.ProtoMessage { + return (*QueryHistoricalParticipationExposuresRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryHistoricalParticipationExposuresRequest_order_book_uid, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryHistoricalParticipationExposuresRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryHistoricalParticipationExposuresRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryHistoricalParticipationExposuresRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryHistoricalParticipationExposuresRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryHistoricalParticipationExposuresRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryHistoricalParticipationExposuresRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryHistoricalParticipationExposuresRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryHistoricalParticipationExposuresResponse_1_list)(nil) + +type _QueryHistoricalParticipationExposuresResponse_1_list struct { + list *[]*ParticipationExposure +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + (*x.list)[i] = concreteValue +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationExposure) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) AppendMutable() protoreflect.Value { + v := new(ParticipationExposure) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) NewElement() protoreflect.Value { + v := new(ParticipationExposure) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryHistoricalParticipationExposuresResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryHistoricalParticipationExposuresResponse protoreflect.MessageDescriptor + fd_QueryHistoricalParticipationExposuresResponse_participation_exposures protoreflect.FieldDescriptor + fd_QueryHistoricalParticipationExposuresResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryHistoricalParticipationExposuresResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryHistoricalParticipationExposuresResponse") + fd_QueryHistoricalParticipationExposuresResponse_participation_exposures = md_QueryHistoricalParticipationExposuresResponse.Fields().ByName("participation_exposures") + fd_QueryHistoricalParticipationExposuresResponse_pagination = md_QueryHistoricalParticipationExposuresResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryHistoricalParticipationExposuresResponse)(nil) + +type fastReflection_QueryHistoricalParticipationExposuresResponse QueryHistoricalParticipationExposuresResponse + +func (x *QueryHistoricalParticipationExposuresResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryHistoricalParticipationExposuresResponse)(x) +} + +func (x *QueryHistoricalParticipationExposuresResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[19] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryHistoricalParticipationExposuresResponse_messageType fastReflection_QueryHistoricalParticipationExposuresResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryHistoricalParticipationExposuresResponse_messageType{} + +type fastReflection_QueryHistoricalParticipationExposuresResponse_messageType struct{} + +func (x fastReflection_QueryHistoricalParticipationExposuresResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryHistoricalParticipationExposuresResponse)(nil) +} +func (x fastReflection_QueryHistoricalParticipationExposuresResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryHistoricalParticipationExposuresResponse) +} +func (x fastReflection_QueryHistoricalParticipationExposuresResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryHistoricalParticipationExposuresResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryHistoricalParticipationExposuresResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryHistoricalParticipationExposuresResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) New() protoreflect.Message { + return new(fastReflection_QueryHistoricalParticipationExposuresResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Interface() protoreflect.ProtoMessage { + return (*QueryHistoricalParticipationExposuresResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.ParticipationExposures) != 0 { + value := protoreflect.ValueOfList(&_QueryHistoricalParticipationExposuresResponse_1_list{list: &x.ParticipationExposures}) + if !f(fd_QueryHistoricalParticipationExposuresResponse_participation_exposures, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryHistoricalParticipationExposuresResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.participation_exposures": + return len(x.ParticipationExposures) != 0 + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.participation_exposures": + x.ParticipationExposures = nil + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.participation_exposures": + if len(x.ParticipationExposures) == 0 { + return protoreflect.ValueOfList(&_QueryHistoricalParticipationExposuresResponse_1_list{}) + } + listValue := &_QueryHistoricalParticipationExposuresResponse_1_list{list: &x.ParticipationExposures} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.participation_exposures": + lv := value.List() + clv := lv.(*_QueryHistoricalParticipationExposuresResponse_1_list) + x.ParticipationExposures = *clv.list + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.participation_exposures": + if x.ParticipationExposures == nil { + x.ParticipationExposures = []*ParticipationExposure{} + } + value := &_QueryHistoricalParticipationExposuresResponse_1_list{list: &x.ParticipationExposures} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.participation_exposures": + list := []*ParticipationExposure{} + return protoreflect.ValueOfList(&_QueryHistoricalParticipationExposuresResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryHistoricalParticipationExposuresResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryHistoricalParticipationExposuresResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.ParticipationExposures) > 0 { + for _, e := range x.ParticipationExposures { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryHistoricalParticipationExposuresResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.ParticipationExposures) > 0 { + for iNdEx := len(x.ParticipationExposures) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ParticipationExposures[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryHistoricalParticipationExposuresResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryHistoricalParticipationExposuresResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryHistoricalParticipationExposuresResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationExposures", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipationExposures = append(x.ParticipationExposures, &ParticipationExposure{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ParticipationExposures[len(x.ParticipationExposures)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParticipationFulfilledBetsRequest protoreflect.MessageDescriptor + fd_QueryParticipationFulfilledBetsRequest_order_book_uid protoreflect.FieldDescriptor + fd_QueryParticipationFulfilledBetsRequest_participation_index protoreflect.FieldDescriptor + fd_QueryParticipationFulfilledBetsRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryParticipationFulfilledBetsRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryParticipationFulfilledBetsRequest") + fd_QueryParticipationFulfilledBetsRequest_order_book_uid = md_QueryParticipationFulfilledBetsRequest.Fields().ByName("order_book_uid") + fd_QueryParticipationFulfilledBetsRequest_participation_index = md_QueryParticipationFulfilledBetsRequest.Fields().ByName("participation_index") + fd_QueryParticipationFulfilledBetsRequest_pagination = md_QueryParticipationFulfilledBetsRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryParticipationFulfilledBetsRequest)(nil) + +type fastReflection_QueryParticipationFulfilledBetsRequest QueryParticipationFulfilledBetsRequest + +func (x *QueryParticipationFulfilledBetsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParticipationFulfilledBetsRequest)(x) +} + +func (x *QueryParticipationFulfilledBetsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[20] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParticipationFulfilledBetsRequest_messageType fastReflection_QueryParticipationFulfilledBetsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParticipationFulfilledBetsRequest_messageType{} + +type fastReflection_QueryParticipationFulfilledBetsRequest_messageType struct{} + +func (x fastReflection_QueryParticipationFulfilledBetsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParticipationFulfilledBetsRequest)(nil) +} +func (x fastReflection_QueryParticipationFulfilledBetsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParticipationFulfilledBetsRequest) +} +func (x fastReflection_QueryParticipationFulfilledBetsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationFulfilledBetsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationFulfilledBetsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParticipationFulfilledBetsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParticipationFulfilledBetsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParticipationFulfilledBetsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.OrderBookUid != "" { + value := protoreflect.ValueOfString(x.OrderBookUid) + if !f(fd_QueryParticipationFulfilledBetsRequest_order_book_uid, value) { + return + } + } + if x.ParticipationIndex != uint64(0) { + value := protoreflect.ValueOfUint64(x.ParticipationIndex) + if !f(fd_QueryParticipationFulfilledBetsRequest_participation_index, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryParticipationFulfilledBetsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.order_book_uid": + return x.OrderBookUid != "" + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.participation_index": + return x.ParticipationIndex != uint64(0) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.order_book_uid": + x.OrderBookUid = "" + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.participation_index": + x.ParticipationIndex = uint64(0) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.order_book_uid": + value := x.OrderBookUid + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.participation_index": + value := x.ParticipationIndex + return protoreflect.ValueOfUint64(value) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.order_book_uid": + x.OrderBookUid = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.participation_index": + x.ParticipationIndex = value.Uint() + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.order_book_uid": + panic(fmt.Errorf("field order_book_uid of message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest is not mutable")) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.participation_index": + panic(fmt.Errorf("field participation_index of message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.order_book_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.participation_index": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParticipationFulfilledBetsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParticipationFulfilledBetsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.OrderBookUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.ParticipationIndex != 0 { + n += 1 + runtime.Sov(uint64(x.ParticipationIndex)) + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationFulfilledBetsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if x.ParticipationIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ParticipationIndex)) + i-- + dAtA[i] = 0x10 + } + if len(x.OrderBookUid) > 0 { + i -= len(x.OrderBookUid) + copy(dAtA[i:], x.OrderBookUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderBookUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationFulfilledBetsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationFulfilledBetsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationFulfilledBetsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderBookUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderBookUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationIndex", wireType) + } + x.ParticipationIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ParticipationIndex |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryParticipationFulfilledBetsResponse_1_list)(nil) + +type _QueryParticipationFulfilledBetsResponse_1_list struct { + list *[]*ParticipationBetPair +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationBetPair) + (*x.list)[i] = concreteValue +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*ParticipationBetPair) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(ParticipationBetPair) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) NewElement() protoreflect.Value { + v := new(ParticipationBetPair) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryParticipationFulfilledBetsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryParticipationFulfilledBetsResponse protoreflect.MessageDescriptor + fd_QueryParticipationFulfilledBetsResponse_participation_bets protoreflect.FieldDescriptor + fd_QueryParticipationFulfilledBetsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QueryParticipationFulfilledBetsResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QueryParticipationFulfilledBetsResponse") + fd_QueryParticipationFulfilledBetsResponse_participation_bets = md_QueryParticipationFulfilledBetsResponse.Fields().ByName("participation_bets") + fd_QueryParticipationFulfilledBetsResponse_pagination = md_QueryParticipationFulfilledBetsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryParticipationFulfilledBetsResponse)(nil) + +type fastReflection_QueryParticipationFulfilledBetsResponse QueryParticipationFulfilledBetsResponse + +func (x *QueryParticipationFulfilledBetsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParticipationFulfilledBetsResponse)(x) +} + +func (x *QueryParticipationFulfilledBetsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[21] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParticipationFulfilledBetsResponse_messageType fastReflection_QueryParticipationFulfilledBetsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParticipationFulfilledBetsResponse_messageType{} + +type fastReflection_QueryParticipationFulfilledBetsResponse_messageType struct{} + +func (x fastReflection_QueryParticipationFulfilledBetsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParticipationFulfilledBetsResponse)(nil) +} +func (x fastReflection_QueryParticipationFulfilledBetsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParticipationFulfilledBetsResponse) +} +func (x fastReflection_QueryParticipationFulfilledBetsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationFulfilledBetsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParticipationFulfilledBetsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParticipationFulfilledBetsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParticipationFulfilledBetsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParticipationFulfilledBetsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.ParticipationBets) != 0 { + value := protoreflect.ValueOfList(&_QueryParticipationFulfilledBetsResponse_1_list{list: &x.ParticipationBets}) + if !f(fd_QueryParticipationFulfilledBetsResponse_participation_bets, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryParticipationFulfilledBetsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.participation_bets": + return len(x.ParticipationBets) != 0 + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.participation_bets": + x.ParticipationBets = nil + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.participation_bets": + if len(x.ParticipationBets) == 0 { + return protoreflect.ValueOfList(&_QueryParticipationFulfilledBetsResponse_1_list{}) + } + listValue := &_QueryParticipationFulfilledBetsResponse_1_list{list: &x.ParticipationBets} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.participation_bets": + lv := value.List() + clv := lv.(*_QueryParticipationFulfilledBetsResponse_1_list) + x.ParticipationBets = *clv.list + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.participation_bets": + if x.ParticipationBets == nil { + x.ParticipationBets = []*ParticipationBetPair{} + } + value := &_QueryParticipationFulfilledBetsResponse_1_list{list: &x.ParticipationBets} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.participation_bets": + list := []*ParticipationBetPair{} + return protoreflect.ValueOfList(&_QueryParticipationFulfilledBetsResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParticipationFulfilledBetsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParticipationFulfilledBetsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.ParticipationBets) > 0 { + for _, e := range x.ParticipationBets { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationFulfilledBetsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.ParticipationBets) > 0 { + for iNdEx := len(x.ParticipationBets) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.ParticipationBets[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParticipationFulfilledBetsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationFulfilledBetsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParticipationFulfilledBetsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ParticipationBets", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ParticipationBets = append(x.ParticipationBets, &ParticipationBetPair{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ParticipationBets[len(x.ParticipationBets)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QuerySettledOrderBookParticipationsOfHeightRequest protoreflect.MessageDescriptor + fd_QuerySettledOrderBookParticipationsOfHeightRequest_pagination protoreflect.FieldDescriptor + fd_QuerySettledOrderBookParticipationsOfHeightRequest_block_height protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QuerySettledOrderBookParticipationsOfHeightRequest = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QuerySettledOrderBookParticipationsOfHeightRequest") + fd_QuerySettledOrderBookParticipationsOfHeightRequest_pagination = md_QuerySettledOrderBookParticipationsOfHeightRequest.Fields().ByName("pagination") + fd_QuerySettledOrderBookParticipationsOfHeightRequest_block_height = md_QuerySettledOrderBookParticipationsOfHeightRequest.Fields().ByName("block_height") +} + +var _ protoreflect.Message = (*fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest)(nil) + +type fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest QuerySettledOrderBookParticipationsOfHeightRequest + +func (x *QuerySettledOrderBookParticipationsOfHeightRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest)(x) +} + +func (x *QuerySettledOrderBookParticipationsOfHeightRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[22] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType +var _ protoreflect.MessageType = fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType{} + +type fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType struct{} + +func (x fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest)(nil) +} +func (x fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) +} +func (x fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledOrderBookParticipationsOfHeightRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledOrderBookParticipationsOfHeightRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Type() protoreflect.MessageType { + return _fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) New() protoreflect.Message { + return new(fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Interface() protoreflect.ProtoMessage { + return (*QuerySettledOrderBookParticipationsOfHeightRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QuerySettledOrderBookParticipationsOfHeightRequest_pagination, value) { + return + } + } + if x.BlockHeight != int64(0) { + value := protoreflect.ValueOfInt64(x.BlockHeight) + if !f(fd_QuerySettledOrderBookParticipationsOfHeightRequest_block_height, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.pagination": + return x.Pagination != nil + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.block_height": + return x.BlockHeight != int64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.pagination": + x.Pagination = nil + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.block_height": + x.BlockHeight = int64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.block_height": + value := x.BlockHeight + return protoreflect.ValueOfInt64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.block_height": + x.BlockHeight = value.Int() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.block_height": + panic(fmt.Errorf("field block_height of message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.block_height": + return protoreflect.ValueOfInt64(int64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QuerySettledOrderBookParticipationsOfHeightRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.BlockHeight != 0 { + n += 1 + runtime.Sov(uint64(x.BlockHeight)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledOrderBookParticipationsOfHeightRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.BlockHeight != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.BlockHeight)) + i-- + dAtA[i] = 0x10 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledOrderBookParticipationsOfHeightRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledOrderBookParticipationsOfHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledOrderBookParticipationsOfHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlockHeight", wireType) + } + x.BlockHeight = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.BlockHeight |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QuerySettledOrderBookParticipationsOfHeightResponse_1_list)(nil) + +type _QuerySettledOrderBookParticipationsOfHeightResponse_1_list struct { + list *[]*OrderBookParticipation +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookParticipation) + (*x.list)[i] = concreteValue +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*OrderBookParticipation) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) AppendMutable() protoreflect.Value { + v := new(OrderBookParticipation) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) NewElement() protoreflect.Value { + v := new(OrderBookParticipation) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QuerySettledOrderBookParticipationsOfHeightResponse protoreflect.MessageDescriptor + fd_QuerySettledOrderBookParticipationsOfHeightResponse_participations protoreflect.FieldDescriptor + fd_QuerySettledOrderBookParticipationsOfHeightResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_query_proto_init() + md_QuerySettledOrderBookParticipationsOfHeightResponse = File_sge_legacy_orderbook_v1beta_query_proto.Messages().ByName("QuerySettledOrderBookParticipationsOfHeightResponse") + fd_QuerySettledOrderBookParticipationsOfHeightResponse_participations = md_QuerySettledOrderBookParticipationsOfHeightResponse.Fields().ByName("participations") + fd_QuerySettledOrderBookParticipationsOfHeightResponse_pagination = md_QuerySettledOrderBookParticipationsOfHeightResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse)(nil) + +type fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse QuerySettledOrderBookParticipationsOfHeightResponse + +func (x *QuerySettledOrderBookParticipationsOfHeightResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse)(x) +} + +func (x *QuerySettledOrderBookParticipationsOfHeightResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[23] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType +var _ protoreflect.MessageType = fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType{} + +type fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType struct{} + +func (x fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse)(nil) +} +func (x fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) +} +func (x fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledOrderBookParticipationsOfHeightResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySettledOrderBookParticipationsOfHeightResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Type() protoreflect.MessageType { + return _fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) New() protoreflect.Message { + return new(fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Interface() protoreflect.ProtoMessage { + return (*QuerySettledOrderBookParticipationsOfHeightResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Participations) != 0 { + value := protoreflect.ValueOfList(&_QuerySettledOrderBookParticipationsOfHeightResponse_1_list{list: &x.Participations}) + if !f(fd_QuerySettledOrderBookParticipationsOfHeightResponse_participations, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QuerySettledOrderBookParticipationsOfHeightResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.participations": + return len(x.Participations) != 0 + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.participations": + x.Participations = nil + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.participations": + if len(x.Participations) == 0 { + return protoreflect.ValueOfList(&_QuerySettledOrderBookParticipationsOfHeightResponse_1_list{}) + } + listValue := &_QuerySettledOrderBookParticipationsOfHeightResponse_1_list{list: &x.Participations} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.participations": + lv := value.List() + clv := lv.(*_QuerySettledOrderBookParticipationsOfHeightResponse_1_list) + x.Participations = *clv.list + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.participations": + if x.Participations == nil { + x.Participations = []*OrderBookParticipation{} + } + value := &_QuerySettledOrderBookParticipationsOfHeightResponse_1_list{list: &x.Participations} + return protoreflect.ValueOfList(value) + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.participations": + list := []*OrderBookParticipation{} + return protoreflect.ValueOfList(&_QuerySettledOrderBookParticipationsOfHeightResponse_1_list{list: &list}) + case "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QuerySettledOrderBookParticipationsOfHeightResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QuerySettledOrderBookParticipationsOfHeightResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Participations) > 0 { + for _, e := range x.Participations { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledOrderBookParticipationsOfHeightResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Participations) > 0 { + for iNdEx := len(x.Participations) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Participations[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QuerySettledOrderBookParticipationsOfHeightResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledOrderBookParticipationsOfHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySettledOrderBookParticipationsOfHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Participations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Participations = append(x.Participations, &OrderBookParticipation{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Participations[len(x.Participations)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is the request type for the Query/Params RPC method +// Query/Params RPC method. +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is the response type for the Query/Params RPC method +// Query/Params RPC method. +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params holds all the parameters of this module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QueryOrderBooksRequest is the request type for the Query/OrderBooks RPC +// method. +type QueryOrderBooksRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // status enables query for order books matching a given status. + Status string `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` + // pagination defines optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBooksRequest) Reset() { + *x = QueryOrderBooksRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBooksRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBooksRequest) ProtoMessage() {} + +// Deprecated: Use QueryOrderBooksRequest.ProtoReflect.Descriptor instead. +func (*QueryOrderBooksRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +func (x *QueryOrderBooksRequest) GetStatus() string { + if x != nil { + return x.Status + } + return "" +} + +func (x *QueryOrderBooksRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryOrderBooksResponse is the response type for the Query/OrderBooks RPC +// method. +type QueryOrderBooksResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // orderbooks contains all the queried order books. + Orderbooks []*OrderBook `protobuf:"bytes,1,rep,name=orderbooks,proto3" json:"orderbooks,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBooksResponse) Reset() { + *x = QueryOrderBooksResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBooksResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBooksResponse) ProtoMessage() {} + +// Deprecated: Use QueryOrderBooksResponse.ProtoReflect.Descriptor instead. +func (*QueryOrderBooksResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QueryOrderBooksResponse) GetOrderbooks() []*OrderBook { + if x != nil { + return x.Orderbooks + } + return nil +} + +func (x *QueryOrderBooksResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryOrderBookRequest is the request type for the Query/OrderBook RPC method. +type QueryOrderBookRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book uid to query for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` +} + +func (x *QueryOrderBookRequest) Reset() { + *x = QueryOrderBookRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookRequest) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookRequest.ProtoReflect.Descriptor instead. +func (*QueryOrderBookRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{4} +} + +func (x *QueryOrderBookRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +// QueryOrderBookResponse is the response type for the Query/OrderBook RPC +// method. +type QueryOrderBookResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // orderBook defines the order book info. + OrderBook *OrderBook `protobuf:"bytes,1,opt,name=order_book,json=orderBook,proto3" json:"order_book,omitempty"` +} + +func (x *QueryOrderBookResponse) Reset() { + *x = QueryOrderBookResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookResponse) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookResponse.ProtoReflect.Descriptor instead. +func (*QueryOrderBookResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{5} +} + +func (x *QueryOrderBookResponse) GetOrderBook() *OrderBook { + if x != nil { + return x.OrderBook + } + return nil +} + +// QueryOrderBookParticipationsRequest is the request type for the +// Query/OrderBookParticipations RPC method +type QueryOrderBookParticipationsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book universal unique identifier to query + // for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // pagination defines optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBookParticipationsRequest) Reset() { + *x = QueryOrderBookParticipationsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookParticipationsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookParticipationsRequest) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookParticipationsRequest.ProtoReflect.Descriptor instead. +func (*QueryOrderBookParticipationsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{6} +} + +func (x *QueryOrderBookParticipationsRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryOrderBookParticipationsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryOrderBookParticipationsResponse is the response type for the +// Query/OrderBookParticipations RPC method +type QueryOrderBookParticipationsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + OrderBookParticipations []*OrderBookParticipation `protobuf:"bytes,1,rep,name=order_book_participations,json=orderBookParticipations,proto3" json:"order_book_participations,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBookParticipationsResponse) Reset() { + *x = QueryOrderBookParticipationsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookParticipationsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookParticipationsResponse) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookParticipationsResponse.ProtoReflect.Descriptor instead. +func (*QueryOrderBookParticipationsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{7} +} + +func (x *QueryOrderBookParticipationsResponse) GetOrderBookParticipations() []*OrderBookParticipation { + if x != nil { + return x.OrderBookParticipations + } + return nil +} + +func (x *QueryOrderBookParticipationsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryOrderBookParticipationRequest is the request type for the +// Query/OrderBookParticipation RPC method. +type QueryOrderBookParticipationRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book universal unique identifier to query + // for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // participation_index defines the participation index to query for. + ParticipationIndex uint64 `protobuf:"varint,2,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` +} + +func (x *QueryOrderBookParticipationRequest) Reset() { + *x = QueryOrderBookParticipationRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookParticipationRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookParticipationRequest) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookParticipationRequest.ProtoReflect.Descriptor instead. +func (*QueryOrderBookParticipationRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{8} +} + +func (x *QueryOrderBookParticipationRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryOrderBookParticipationRequest) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +// QueryOrderBookParticipationResponse is the response type for the +// Query/OrderBookParticipation RPC method. +type QueryOrderBookParticipationResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_participation defines the book participation info. + OrderBookParticipation *OrderBookParticipation `protobuf:"bytes,1,opt,name=order_book_participation,json=orderBookParticipation,proto3" json:"order_book_participation,omitempty"` +} + +func (x *QueryOrderBookParticipationResponse) Reset() { + *x = QueryOrderBookParticipationResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookParticipationResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookParticipationResponse) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookParticipationResponse.ProtoReflect.Descriptor instead. +func (*QueryOrderBookParticipationResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{9} +} + +func (x *QueryOrderBookParticipationResponse) GetOrderBookParticipation() *OrderBookParticipation { + if x != nil { + return x.OrderBookParticipation + } + return nil +} + +// QueryOrderBookExposuresRequest is the request type for the +// Query/OrderBookExposures RPC method +type QueryOrderBookExposuresRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book uid to query for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // pagination defines optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBookExposuresRequest) Reset() { + *x = QueryOrderBookExposuresRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookExposuresRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookExposuresRequest) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookExposuresRequest.ProtoReflect.Descriptor instead. +func (*QueryOrderBookExposuresRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{10} +} + +func (x *QueryOrderBookExposuresRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryOrderBookExposuresRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryOrderBookExposuresResponse is the response type for the +// Query/OrderBookExposures RPC method. +type QueryOrderBookExposuresResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + OrderBookExposures []*OrderBookOddsExposure `protobuf:"bytes,1,rep,name=order_book_exposures,json=orderBookExposures,proto3" json:"order_book_exposures,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBookExposuresResponse) Reset() { + *x = QueryOrderBookExposuresResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookExposuresResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookExposuresResponse) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookExposuresResponse.ProtoReflect.Descriptor instead. +func (*QueryOrderBookExposuresResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{11} +} + +func (x *QueryOrderBookExposuresResponse) GetOrderBookExposures() []*OrderBookOddsExposure { + if x != nil { + return x.OrderBookExposures + } + return nil +} + +func (x *QueryOrderBookExposuresResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryOrderBookExposureRequest is the request type for the +// Query/OrderBookExposure RPC method. +type QueryOrderBookExposureRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book uid to query for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // odds_uid defines the odds id to query for. + OddsUid string `protobuf:"bytes,2,opt,name=odds_uid,json=oddsUid,proto3" json:"odds_uid,omitempty"` +} + +func (x *QueryOrderBookExposureRequest) Reset() { + *x = QueryOrderBookExposureRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookExposureRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookExposureRequest) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookExposureRequest.ProtoReflect.Descriptor instead. +func (*QueryOrderBookExposureRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{12} +} + +func (x *QueryOrderBookExposureRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryOrderBookExposureRequest) GetOddsUid() string { + if x != nil { + return x.OddsUid + } + return "" +} + +// QueryOrderBookExposureResponse is the response type for the +// Query/OrderBookExposure RPC method. +type QueryOrderBookExposureResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_exposure defines the order book exposure info. + OrderBookExposure *OrderBookOddsExposure `protobuf:"bytes,1,opt,name=order_book_exposure,json=orderBookExposure,proto3" json:"order_book_exposure,omitempty"` +} + +func (x *QueryOrderBookExposureResponse) Reset() { + *x = QueryOrderBookExposureResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookExposureResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookExposureResponse) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookExposureResponse.ProtoReflect.Descriptor instead. +func (*QueryOrderBookExposureResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{13} +} + +func (x *QueryOrderBookExposureResponse) GetOrderBookExposure() *OrderBookOddsExposure { + if x != nil { + return x.OrderBookExposure + } + return nil +} + +// QueryOrderBookParticipationExposuresRequest is the request type for the +// Query/OrderBookParticipationExposures RPC method +type QueryOrderBookParticipationExposuresRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book uid to query for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // pagination defines optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBookParticipationExposuresRequest) Reset() { + *x = QueryOrderBookParticipationExposuresRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookParticipationExposuresRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookParticipationExposuresRequest) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookParticipationExposuresRequest.ProtoReflect.Descriptor instead. +func (*QueryOrderBookParticipationExposuresRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{14} +} + +func (x *QueryOrderBookParticipationExposuresRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryOrderBookParticipationExposuresRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryOrderBookParticipationExposuresResponse is the response type for the +// Query/OrderBookParticipationExposures RPC method. +type QueryOrderBookParticipationExposuresResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + ParticipationExposures []*ParticipationExposure `protobuf:"bytes,1,rep,name=participation_exposures,json=participationExposures,proto3" json:"participation_exposures,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryOrderBookParticipationExposuresResponse) Reset() { + *x = QueryOrderBookParticipationExposuresResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryOrderBookParticipationExposuresResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryOrderBookParticipationExposuresResponse) ProtoMessage() {} + +// Deprecated: Use QueryOrderBookParticipationExposuresResponse.ProtoReflect.Descriptor instead. +func (*QueryOrderBookParticipationExposuresResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{15} +} + +func (x *QueryOrderBookParticipationExposuresResponse) GetParticipationExposures() []*ParticipationExposure { + if x != nil { + return x.ParticipationExposures + } + return nil +} + +func (x *QueryOrderBookParticipationExposuresResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryParticipationExposuresRequest is the request type for the +// Query/ParticipationExposures RPC method. +type QueryParticipationExposuresRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book id to query for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // participation_index is the index of participation to query for. + ParticipationIndex uint64 `protobuf:"varint,2,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageRequest `protobuf:"bytes,3,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryParticipationExposuresRequest) Reset() { + *x = QueryParticipationExposuresRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParticipationExposuresRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParticipationExposuresRequest) ProtoMessage() {} + +// Deprecated: Use QueryParticipationExposuresRequest.ProtoReflect.Descriptor instead. +func (*QueryParticipationExposuresRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{16} +} + +func (x *QueryParticipationExposuresRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryParticipationExposuresRequest) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *QueryParticipationExposuresRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryParticipationExposureResponse is the response type for the +// Query/ParticipationExposures RPC method. +type QueryParticipationExposuresResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // participation_exposure defines the participation exposure info. + ParticipationExposures []*ParticipationExposure `protobuf:"bytes,1,rep,name=participation_exposures,json=participationExposures,proto3" json:"participation_exposures,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryParticipationExposuresResponse) Reset() { + *x = QueryParticipationExposuresResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParticipationExposuresResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParticipationExposuresResponse) ProtoMessage() {} + +// Deprecated: Use QueryParticipationExposuresResponse.ProtoReflect.Descriptor instead. +func (*QueryParticipationExposuresResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{17} +} + +func (x *QueryParticipationExposuresResponse) GetParticipationExposures() []*ParticipationExposure { + if x != nil { + return x.ParticipationExposures + } + return nil +} + +func (x *QueryParticipationExposuresResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryHistoricalParticipationExposuresRequest is the request type for the +// Query/HistoricalParticipationExposures RPC method +type QueryHistoricalParticipationExposuresRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book uid to query for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // pagination defines optional pagination for the request. + Pagination *v1beta1.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryHistoricalParticipationExposuresRequest) Reset() { + *x = QueryHistoricalParticipationExposuresRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryHistoricalParticipationExposuresRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryHistoricalParticipationExposuresRequest) ProtoMessage() {} + +// Deprecated: Use QueryHistoricalParticipationExposuresRequest.ProtoReflect.Descriptor instead. +func (*QueryHistoricalParticipationExposuresRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{18} +} + +func (x *QueryHistoricalParticipationExposuresRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryHistoricalParticipationExposuresRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryHistoricalParticipationExposuresResponse is the response type for the +// Query/HistoricalParticipationExposures RPC method. +type QueryHistoricalParticipationExposuresResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + ParticipationExposures []*ParticipationExposure `protobuf:"bytes,1,rep,name=participation_exposures,json=participationExposures,proto3" json:"participation_exposures,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryHistoricalParticipationExposuresResponse) Reset() { + *x = QueryHistoricalParticipationExposuresResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryHistoricalParticipationExposuresResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryHistoricalParticipationExposuresResponse) ProtoMessage() {} + +// Deprecated: Use QueryHistoricalParticipationExposuresResponse.ProtoReflect.Descriptor instead. +func (*QueryHistoricalParticipationExposuresResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{19} +} + +func (x *QueryHistoricalParticipationExposuresResponse) GetParticipationExposures() []*ParticipationExposure { + if x != nil { + return x.ParticipationExposures + } + return nil +} + +func (x *QueryHistoricalParticipationExposuresResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryParticipationFulfilledBetsRequest is the request type for the +// Query/ParticipationFulfilledBets RPC method. +type QueryParticipationFulfilledBetsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // order_book_uid defines the order book uid to query for. + OrderBookUid string `protobuf:"bytes,1,opt,name=order_book_uid,json=orderBookUid,proto3" json:"order_book_uid,omitempty"` + // participation_index is the index of participation to query for. + ParticipationIndex uint64 `protobuf:"varint,2,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageRequest `protobuf:"bytes,3,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryParticipationFulfilledBetsRequest) Reset() { + *x = QueryParticipationFulfilledBetsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParticipationFulfilledBetsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParticipationFulfilledBetsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParticipationFulfilledBetsRequest.ProtoReflect.Descriptor instead. +func (*QueryParticipationFulfilledBetsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{20} +} + +func (x *QueryParticipationFulfilledBetsRequest) GetOrderBookUid() string { + if x != nil { + return x.OrderBookUid + } + return "" +} + +func (x *QueryParticipationFulfilledBetsRequest) GetParticipationIndex() uint64 { + if x != nil { + return x.ParticipationIndex + } + return 0 +} + +func (x *QueryParticipationFulfilledBetsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryParticipationFulfilledBetsResponse is the response type for the +// Query/ParticipationFulfilledBets RPC method. +type QueryParticipationFulfilledBetsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // participation_bets is the bets of the participation. + ParticipationBets []*ParticipationBetPair `protobuf:"bytes,1,rep,name=participation_bets,json=participationBets,proto3" json:"participation_bets,omitempty"` + // pagination defines the pagination in the response. + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryParticipationFulfilledBetsResponse) Reset() { + *x = QueryParticipationFulfilledBetsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParticipationFulfilledBetsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParticipationFulfilledBetsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParticipationFulfilledBetsResponse.ProtoReflect.Descriptor instead. +func (*QueryParticipationFulfilledBetsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{21} +} + +func (x *QueryParticipationFulfilledBetsResponse) GetParticipationBets() []*ParticipationBetPair { + if x != nil { + return x.ParticipationBets + } + return nil +} + +func (x *QueryParticipationFulfilledBetsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QuerySettledOrderBookParticipationsOfHeightRequest is the request type for +// the settled orderbook participations of a certain height list query. +type QuerySettledOrderBookParticipationsOfHeightRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + BlockHeight int64 `protobuf:"varint,2,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"` +} + +func (x *QuerySettledOrderBookParticipationsOfHeightRequest) Reset() { + *x = QuerySettledOrderBookParticipationsOfHeightRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QuerySettledOrderBookParticipationsOfHeightRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QuerySettledOrderBookParticipationsOfHeightRequest) ProtoMessage() {} + +// Deprecated: Use QuerySettledOrderBookParticipationsOfHeightRequest.ProtoReflect.Descriptor instead. +func (*QuerySettledOrderBookParticipationsOfHeightRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{22} +} + +func (x *QuerySettledOrderBookParticipationsOfHeightRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QuerySettledOrderBookParticipationsOfHeightRequest) GetBlockHeight() int64 { + if x != nil { + return x.BlockHeight + } + return 0 +} + +// QuerySettledOrderBookParticipationsOfHeightResponse is the response type for +// the settled orderbook participations of a certain height list query. +type QuerySettledOrderBookParticipationsOfHeightResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Participations []*OrderBookParticipation `protobuf:"bytes,1,rep,name=participations,proto3" json:"participations,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QuerySettledOrderBookParticipationsOfHeightResponse) Reset() { + *x = QuerySettledOrderBookParticipationsOfHeightResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QuerySettledOrderBookParticipationsOfHeightResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QuerySettledOrderBookParticipationsOfHeightResponse) ProtoMessage() {} + +// Deprecated: Use QuerySettledOrderBookParticipationsOfHeightResponse.ProtoReflect.Descriptor instead. +func (*QuerySettledOrderBookParticipationsOfHeightResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP(), []int{23} +} + +func (x *QuerySettledOrderBookParticipationsOfHeightResponse) GetParticipations() []*OrderBookParticipation { + if x != nil { + return x.Participations + } + return nil +} + +func (x *QuerySettledOrderBookParticipationsOfHeightResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +var File_sge_legacy_orderbook_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x2a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, + 0x61, 0x73, 0x65, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x2f, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, + 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x2a, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x2b, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, + 0x28, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x14, 0x0a, 0x12, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x22, 0x58, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x41, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x78, 0x0a, 0x16, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x46, 0x0a, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, + 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xb0, 0x01, 0x0a, 0x17, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x4c, 0x0a, 0x0a, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x73, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x0a, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x73, 0x12, 0x47, + 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, + 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, + 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, + 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x3d, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, + 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, + 0x6f, 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x22, 0x65, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, + 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x4b, 0x0a, 0x0a, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x09, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x22, 0x93, 0x01, + 0x0a, 0x23, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, + 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, + 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x12, 0x46, 0x0a, 0x0a, 0x70, + 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x22, 0xe6, 0x01, 0x0a, 0x24, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, + 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x75, 0x0a, 0x19, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x17, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x7b, 0x0a, 0x22, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, + 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x12, 0x2f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, + 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x22, 0x9a, 0x01, 0x0a, 0x23, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, + 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x73, 0x0a, 0x18, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, + 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x16, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x8e, 0x01, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, + 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x12, + 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, + 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, + 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, + 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xd6, 0x01, 0x0a, 0x1f, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, + 0x72, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x6a, 0x0a, 0x14, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, + 0x72, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, + 0x6b, 0x4f, 0x64, 0x64, 0x73, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x00, 0x52, 0x12, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, + 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0x60, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, + 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x64, 0x64, 0x73, 0x5f, + 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6f, 0x64, 0x64, 0x73, 0x55, + 0x69, 0x64, 0x22, 0x8a, 0x01, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, + 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x68, 0x0a, 0x13, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, + 0x6f, 0x6f, 0x6b, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x4f, 0x64, 0x64, 0x73, 0x45, 0x78, + 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x11, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x22, + 0x9b, 0x01, 0x0a, 0x2b, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, + 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xea, 0x01, + 0x0a, 0x2c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, + 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, + 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x71, + 0x0a, 0x17, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, + 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, + 0x75, 0x72, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x16, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, + 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, + 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xc3, 0x01, 0x0a, 0x22, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, + 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x12, 0x2f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x04, 0x52, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0xe1, 0x01, 0x0a, 0x23, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x71, 0x0a, 0x17, 0x70, 0x61, 0x72, 0x74, + 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, + 0x72, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x42, 0x04, 0xc8, + 0xde, 0x1f, 0x00, 0x52, 0x16, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, + 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9c, 0x01, 0x0a, 0x2c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x48, 0x69, + 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, + 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, 0x69, 0x64, 0x12, 0x46, 0x0a, 0x0a, 0x70, + 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x22, 0xeb, 0x01, 0x0a, 0x2d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x48, 0x69, 0x73, + 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x71, 0x0a, 0x17, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, + 0x52, 0x16, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, + 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x22, 0xc7, 0x01, 0x0a, 0x26, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x46, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, + 0x64, 0x42, 0x65, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x24, 0x0a, 0x0e, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x55, + 0x69, 0x64, 0x12, 0x2f, 0x0a, 0x13, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, + 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, + 0x64, 0x65, 0x78, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xda, 0x01, 0x0a, 0x27, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x46, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x66, 0x0a, 0x12, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x62, 0x65, 0x74, 0x73, 0x18, 0x01, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x31, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, + 0x65, 0x74, 0x50, 0x61, 0x69, 0x72, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x11, 0x70, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x65, 0x74, 0x73, 0x12, + 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, + 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, + 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, + 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x9f, 0x01, 0x0a, 0x32, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, + 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, + 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, + 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, + 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, + 0x5f, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x62, + 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, 0xe1, 0x01, 0x0a, 0x33, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x61, 0x0a, 0x0e, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x33, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, + 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0e, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x32, 0xb0, + 0x14, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x8a, 0x01, 0x0a, 0x06, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x12, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x30, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x17, 0x12, 0x15, + 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x98, 0x01, 0x0a, 0x0a, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, + 0x6f, 0x6f, 0x6b, 0x73, 0x12, 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, + 0x6b, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x34, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, + 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x1f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x19, 0x12, 0x17, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x7b, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x7d, + 0x12, 0x9d, 0x01, 0x0a, 0x09, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x12, 0x32, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x12, + 0x1f, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, + 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x7d, + 0x12, 0xd6, 0x01, 0x0a, 0x17, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, + 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x40, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x41, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x36, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x30, 0x12, 0x2e, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x7d, 0x2f, 0x70, 0x61, 0x72, 0x74, 0x69, + 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0xe9, 0x01, 0x0a, 0x16, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, + 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x40, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x4c, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x46, 0x12, + 0x44, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, + 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x7d, + 0x2f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2f, + 0x7b, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, + 0x6e, 0x64, 0x65, 0x78, 0x7d, 0x12, 0xc2, 0x01, 0x0a, 0x12, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, + 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x3b, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, + 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3c, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, + 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x31, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x2b, 0x12, + 0x29, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, + 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x7d, + 0x2f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0xca, 0x01, 0x0a, 0x11, 0x4f, + 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, + 0x12, 0x3a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, + 0x6f, 0x73, 0x75, 0x72, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3b, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, + 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x3c, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x36, 0x12, 0x34, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x2f, 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, + 0x64, 0x7d, 0x2f, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x2f, 0x7b, 0x6f, 0x64, + 0x64, 0x73, 0x5f, 0x75, 0x69, 0x64, 0x7d, 0x12, 0xf7, 0x01, 0x0a, 0x1f, 0x4f, 0x72, 0x64, 0x65, + 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x48, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, + 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, + 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x49, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, + 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, + 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x3f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x39, 0x12, 0x37, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, + 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x7d, 0x2f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2d, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, + 0x73, 0x12, 0xf2, 0x01, 0x0a, 0x16, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x3f, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, + 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x40, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, + 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x55, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x4f, 0x12, 0x4d, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, + 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x7d, 0x2f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2d, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, + 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, + 0x69, 0x6e, 0x64, 0x65, 0x78, 0x7d, 0x12, 0x85, 0x02, 0x0a, 0x20, 0x48, 0x69, 0x73, 0x74, 0x6f, + 0x72, 0x69, 0x63, 0x61, 0x6c, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x49, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, + 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x48, + 0x69, 0x73, 0x74, 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, + 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x4a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, + 0x69, 0x63, 0x61, 0x6c, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x45, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x4a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x44, 0x12, 0x42, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x7b, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x7d, 0x2f, 0x68, 0x69, 0x73, 0x74, + 0x6f, 0x72, 0x69, 0x63, 0x61, 0x6c, 0x2d, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x2d, 0x65, 0x78, 0x70, 0x6f, 0x73, 0x75, 0x72, 0x65, 0x73, 0x12, 0x84, + 0x02, 0x0a, 0x1a, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x46, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x73, 0x12, 0x43, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x46, 0x75, + 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x44, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x46, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x42, 0x65, 0x74, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x5b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x55, + 0x12, 0x53, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2f, 0x7b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x6f, 0x6b, 0x5f, 0x75, 0x69, 0x64, + 0x7d, 0x2f, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, + 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, + 0x69, 0x6e, 0x64, 0x65, 0x78, 0x7d, 0x2f, 0x66, 0x75, 0x6c, 0x66, 0x69, 0x6c, 0x6c, 0x65, 0x64, + 0x5f, 0x62, 0x65, 0x74, 0x73, 0x12, 0x89, 0x02, 0x0a, 0x26, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, + 0x64, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, + 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, + 0x12, 0x4f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, + 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x50, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x4f, 0x72, 0x64, 0x65, + 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x50, 0x61, 0x72, 0x74, 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x4f, 0x66, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x3c, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x36, 0x12, 0x34, 0x2f, 0x73, 0x67, + 0x65, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x70, 0x61, 0x72, 0x74, + 0x69, 0x63, 0x69, 0x70, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2f, 0x73, 0x65, 0x74, 0x74, 0x6c, + 0x65, 0x64, 0x2f, 0x7b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, + 0x7d, 0x42, 0x88, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x4a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, + 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, + 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1e, 0x53, 0x67, + 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_query_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_query_proto_rawDescData = file_sge_legacy_orderbook_v1beta_query_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_query_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_query_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 24) +var file_sge_legacy_orderbook_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.legacy.orderbook.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.legacy.orderbook.v1beta.QueryParamsResponse + (*QueryOrderBooksRequest)(nil), // 2: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest + (*QueryOrderBooksResponse)(nil), // 3: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse + (*QueryOrderBookRequest)(nil), // 4: sge.legacy.orderbook.v1beta.QueryOrderBookRequest + (*QueryOrderBookResponse)(nil), // 5: sge.legacy.orderbook.v1beta.QueryOrderBookResponse + (*QueryOrderBookParticipationsRequest)(nil), // 6: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest + (*QueryOrderBookParticipationsResponse)(nil), // 7: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse + (*QueryOrderBookParticipationRequest)(nil), // 8: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest + (*QueryOrderBookParticipationResponse)(nil), // 9: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse + (*QueryOrderBookExposuresRequest)(nil), // 10: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest + (*QueryOrderBookExposuresResponse)(nil), // 11: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse + (*QueryOrderBookExposureRequest)(nil), // 12: sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest + (*QueryOrderBookExposureResponse)(nil), // 13: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse + (*QueryOrderBookParticipationExposuresRequest)(nil), // 14: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest + (*QueryOrderBookParticipationExposuresResponse)(nil), // 15: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse + (*QueryParticipationExposuresRequest)(nil), // 16: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest + (*QueryParticipationExposuresResponse)(nil), // 17: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse + (*QueryHistoricalParticipationExposuresRequest)(nil), // 18: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest + (*QueryHistoricalParticipationExposuresResponse)(nil), // 19: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse + (*QueryParticipationFulfilledBetsRequest)(nil), // 20: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest + (*QueryParticipationFulfilledBetsResponse)(nil), // 21: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse + (*QuerySettledOrderBookParticipationsOfHeightRequest)(nil), // 22: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest + (*QuerySettledOrderBookParticipationsOfHeightResponse)(nil), // 23: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse + (*Params)(nil), // 24: sge.legacy.orderbook.v1beta.Params + (*v1beta1.PageRequest)(nil), // 25: cosmos.base.query.v1beta1.PageRequest + (*OrderBook)(nil), // 26: sge.legacy.orderbook.v1beta.OrderBook + (*v1beta1.PageResponse)(nil), // 27: cosmos.base.query.v1beta1.PageResponse + (*OrderBookParticipation)(nil), // 28: sge.legacy.orderbook.v1beta.OrderBookParticipation + (*OrderBookOddsExposure)(nil), // 29: sge.legacy.orderbook.v1beta.OrderBookOddsExposure + (*ParticipationExposure)(nil), // 30: sge.legacy.orderbook.v1beta.ParticipationExposure + (*ParticipationBetPair)(nil), // 31: sge.legacy.orderbook.v1beta.ParticipationBetPair +} +var file_sge_legacy_orderbook_v1beta_query_proto_depIdxs = []int32{ + 24, // 0: sge.legacy.orderbook.v1beta.QueryParamsResponse.params:type_name -> sge.legacy.orderbook.v1beta.Params + 25, // 1: sge.legacy.orderbook.v1beta.QueryOrderBooksRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 26, // 2: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.orderbooks:type_name -> sge.legacy.orderbook.v1beta.OrderBook + 27, // 3: sge.legacy.orderbook.v1beta.QueryOrderBooksResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 26, // 4: sge.legacy.orderbook.v1beta.QueryOrderBookResponse.order_book:type_name -> sge.legacy.orderbook.v1beta.OrderBook + 25, // 5: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 28, // 6: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.order_book_participations:type_name -> sge.legacy.orderbook.v1beta.OrderBookParticipation + 27, // 7: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 28, // 8: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse.order_book_participation:type_name -> sge.legacy.orderbook.v1beta.OrderBookParticipation + 25, // 9: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 29, // 10: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.order_book_exposures:type_name -> sge.legacy.orderbook.v1beta.OrderBookOddsExposure + 27, // 11: sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 29, // 12: sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse.order_book_exposure:type_name -> sge.legacy.orderbook.v1beta.OrderBookOddsExposure + 25, // 13: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 30, // 14: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.participation_exposures:type_name -> sge.legacy.orderbook.v1beta.ParticipationExposure + 27, // 15: sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 25, // 16: sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 30, // 17: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.participation_exposures:type_name -> sge.legacy.orderbook.v1beta.ParticipationExposure + 27, // 18: sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 25, // 19: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 30, // 20: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.participation_exposures:type_name -> sge.legacy.orderbook.v1beta.ParticipationExposure + 27, // 21: sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 25, // 22: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 31, // 23: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.participation_bets:type_name -> sge.legacy.orderbook.v1beta.ParticipationBetPair + 27, // 24: sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 25, // 25: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 28, // 26: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.participations:type_name -> sge.legacy.orderbook.v1beta.OrderBookParticipation + 27, // 27: sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 0, // 28: sge.legacy.orderbook.v1beta.Query.Params:input_type -> sge.legacy.orderbook.v1beta.QueryParamsRequest + 2, // 29: sge.legacy.orderbook.v1beta.Query.OrderBooks:input_type -> sge.legacy.orderbook.v1beta.QueryOrderBooksRequest + 4, // 30: sge.legacy.orderbook.v1beta.Query.OrderBook:input_type -> sge.legacy.orderbook.v1beta.QueryOrderBookRequest + 6, // 31: sge.legacy.orderbook.v1beta.Query.OrderBookParticipations:input_type -> sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest + 8, // 32: sge.legacy.orderbook.v1beta.Query.OrderBookParticipation:input_type -> sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest + 10, // 33: sge.legacy.orderbook.v1beta.Query.OrderBookExposures:input_type -> sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest + 12, // 34: sge.legacy.orderbook.v1beta.Query.OrderBookExposure:input_type -> sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest + 14, // 35: sge.legacy.orderbook.v1beta.Query.OrderBookParticipationExposures:input_type -> sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest + 16, // 36: sge.legacy.orderbook.v1beta.Query.ParticipationExposures:input_type -> sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest + 18, // 37: sge.legacy.orderbook.v1beta.Query.HistoricalParticipationExposures:input_type -> sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest + 20, // 38: sge.legacy.orderbook.v1beta.Query.ParticipationFulfilledBets:input_type -> sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest + 22, // 39: sge.legacy.orderbook.v1beta.Query.SettledOrderBookParticipationsOfHeight:input_type -> sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest + 1, // 40: sge.legacy.orderbook.v1beta.Query.Params:output_type -> sge.legacy.orderbook.v1beta.QueryParamsResponse + 3, // 41: sge.legacy.orderbook.v1beta.Query.OrderBooks:output_type -> sge.legacy.orderbook.v1beta.QueryOrderBooksResponse + 5, // 42: sge.legacy.orderbook.v1beta.Query.OrderBook:output_type -> sge.legacy.orderbook.v1beta.QueryOrderBookResponse + 7, // 43: sge.legacy.orderbook.v1beta.Query.OrderBookParticipations:output_type -> sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse + 9, // 44: sge.legacy.orderbook.v1beta.Query.OrderBookParticipation:output_type -> sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse + 11, // 45: sge.legacy.orderbook.v1beta.Query.OrderBookExposures:output_type -> sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse + 13, // 46: sge.legacy.orderbook.v1beta.Query.OrderBookExposure:output_type -> sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse + 15, // 47: sge.legacy.orderbook.v1beta.Query.OrderBookParticipationExposures:output_type -> sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse + 17, // 48: sge.legacy.orderbook.v1beta.Query.ParticipationExposures:output_type -> sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse + 19, // 49: sge.legacy.orderbook.v1beta.Query.HistoricalParticipationExposures:output_type -> sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse + 21, // 50: sge.legacy.orderbook.v1beta.Query.ParticipationFulfilledBets:output_type -> sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse + 23, // 51: sge.legacy.orderbook.v1beta.Query.SettledOrderBookParticipationsOfHeight:output_type -> sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse + 40, // [40:52] is the sub-list for method output_type + 28, // [28:40] is the sub-list for method input_type + 28, // [28:28] is the sub-list for extension type_name + 28, // [28:28] is the sub-list for extension extendee + 0, // [0:28] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_query_proto_init() } +func file_sge_legacy_orderbook_v1beta_query_proto_init() { + if File_sge_legacy_orderbook_v1beta_query_proto != nil { + return + } + file_sge_legacy_orderbook_v1beta_exposure_proto_init() + file_sge_legacy_orderbook_v1beta_orderbook_proto_init() + file_sge_legacy_orderbook_v1beta_params_proto_init() + file_sge_legacy_orderbook_v1beta_participation_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBooksRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBooksResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookParticipationsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookParticipationsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookParticipationRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookParticipationResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookExposuresRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookExposuresResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookExposureRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookExposureResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookParticipationExposuresRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryOrderBookParticipationExposuresResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParticipationExposuresRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParticipationExposuresResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryHistoricalParticipationExposuresRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryHistoricalParticipationExposuresResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParticipationFulfilledBetsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParticipationFulfilledBetsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QuerySettledOrderBookParticipationsOfHeightRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_query_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QuerySettledOrderBookParticipationsOfHeightResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 24, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_v1beta_query_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_query_proto = out.File + file_sge_legacy_orderbook_v1beta_query_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_query_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/query_grpc.pb.go b/api/sge/legacy/orderbook/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..d750495e --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/query_grpc.pb.go @@ -0,0 +1,554 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/orderbook/v1beta/query.proto + +package orderbookv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Params_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/Params" + Query_OrderBooks_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/OrderBooks" + Query_OrderBook_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/OrderBook" + Query_OrderBookParticipations_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipations" + Query_OrderBookParticipation_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipation" + Query_OrderBookExposures_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/OrderBookExposures" + Query_OrderBookExposure_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/OrderBookExposure" + Query_OrderBookParticipationExposures_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipationExposures" + Query_ParticipationExposures_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/ParticipationExposures" + Query_HistoricalParticipationExposures_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/HistoricalParticipationExposures" + Query_ParticipationFulfilledBets_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/ParticipationFulfilledBets" + Query_SettledOrderBookParticipationsOfHeight_FullMethodName = "/sge.legacy.orderbook.v1beta.Query/SettledOrderBookParticipationsOfHeight" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Params queries the parameters of the module. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) + // OrderBooks queries all order books that match the given status. + OrderBooks(ctx context.Context, in *QueryOrderBooksRequest, opts ...grpc.CallOption) (*QueryOrderBooksResponse, error) + // OrderBook queries order book info for given order book universal unique + // identifier. + OrderBook(ctx context.Context, in *QueryOrderBookRequest, opts ...grpc.CallOption) (*QueryOrderBookResponse, error) + // OrderBookParticipations queries participation info for given order book. + OrderBookParticipations(ctx context.Context, in *QueryOrderBookParticipationsRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationsResponse, error) + // OrderBookParticipation queries participation info for given order book and + // participation index. + OrderBookParticipation(ctx context.Context, in *QueryOrderBookParticipationRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationResponse, error) + // OrderBookExposures queries exposures info for the given order book. + OrderBookExposures(ctx context.Context, in *QueryOrderBookExposuresRequest, opts ...grpc.CallOption) (*QueryOrderBookExposuresResponse, error) + // OrderBookExposure queries exposure info for the given order book and odds + // universal unique identifier. + OrderBookExposure(ctx context.Context, in *QueryOrderBookExposureRequest, opts ...grpc.CallOption) (*QueryOrderBookExposureResponse, error) + // OrderBookParticipationExposures queries exposures info for given order book + // participations. + OrderBookParticipationExposures(ctx context.Context, in *QueryOrderBookParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationExposuresResponse, error) + // ParticipationExposures queries exposure info for given order book + // participation. + ParticipationExposures(ctx context.Context, in *QueryParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryParticipationExposuresResponse, error) + // HistoricalParticipationExposures queries historical exposures info for + // the given order book participation. + HistoricalParticipationExposures(ctx context.Context, in *QueryHistoricalParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryHistoricalParticipationExposuresResponse, error) + // ParticipationFulfilledBets queries fulfilled bets for given order book + // participation. + ParticipationFulfilledBets(ctx context.Context, in *QueryParticipationFulfilledBetsRequest, opts ...grpc.CallOption) (*QueryParticipationFulfilledBetsResponse, error) + // Queries list of settled Orderbook Participation items of a certain height. + SettledOrderBookParticipationsOfHeight(ctx context.Context, in *QuerySettledOrderBookParticipationsOfHeightRequest, opts ...grpc.CallOption) (*QuerySettledOrderBookParticipationsOfHeightResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) OrderBooks(ctx context.Context, in *QueryOrderBooksRequest, opts ...grpc.CallOption) (*QueryOrderBooksResponse, error) { + out := new(QueryOrderBooksResponse) + err := c.cc.Invoke(ctx, Query_OrderBooks_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) OrderBook(ctx context.Context, in *QueryOrderBookRequest, opts ...grpc.CallOption) (*QueryOrderBookResponse, error) { + out := new(QueryOrderBookResponse) + err := c.cc.Invoke(ctx, Query_OrderBook_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) OrderBookParticipations(ctx context.Context, in *QueryOrderBookParticipationsRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationsResponse, error) { + out := new(QueryOrderBookParticipationsResponse) + err := c.cc.Invoke(ctx, Query_OrderBookParticipations_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) OrderBookParticipation(ctx context.Context, in *QueryOrderBookParticipationRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationResponse, error) { + out := new(QueryOrderBookParticipationResponse) + err := c.cc.Invoke(ctx, Query_OrderBookParticipation_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) OrderBookExposures(ctx context.Context, in *QueryOrderBookExposuresRequest, opts ...grpc.CallOption) (*QueryOrderBookExposuresResponse, error) { + out := new(QueryOrderBookExposuresResponse) + err := c.cc.Invoke(ctx, Query_OrderBookExposures_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) OrderBookExposure(ctx context.Context, in *QueryOrderBookExposureRequest, opts ...grpc.CallOption) (*QueryOrderBookExposureResponse, error) { + out := new(QueryOrderBookExposureResponse) + err := c.cc.Invoke(ctx, Query_OrderBookExposure_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) OrderBookParticipationExposures(ctx context.Context, in *QueryOrderBookParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationExposuresResponse, error) { + out := new(QueryOrderBookParticipationExposuresResponse) + err := c.cc.Invoke(ctx, Query_OrderBookParticipationExposures_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) ParticipationExposures(ctx context.Context, in *QueryParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryParticipationExposuresResponse, error) { + out := new(QueryParticipationExposuresResponse) + err := c.cc.Invoke(ctx, Query_ParticipationExposures_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) HistoricalParticipationExposures(ctx context.Context, in *QueryHistoricalParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryHistoricalParticipationExposuresResponse, error) { + out := new(QueryHistoricalParticipationExposuresResponse) + err := c.cc.Invoke(ctx, Query_HistoricalParticipationExposures_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) ParticipationFulfilledBets(ctx context.Context, in *QueryParticipationFulfilledBetsRequest, opts ...grpc.CallOption) (*QueryParticipationFulfilledBetsResponse, error) { + out := new(QueryParticipationFulfilledBetsResponse) + err := c.cc.Invoke(ctx, Query_ParticipationFulfilledBets_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) SettledOrderBookParticipationsOfHeight(ctx context.Context, in *QuerySettledOrderBookParticipationsOfHeightRequest, opts ...grpc.CallOption) (*QuerySettledOrderBookParticipationsOfHeightResponse, error) { + out := new(QuerySettledOrderBookParticipationsOfHeightResponse) + err := c.cc.Invoke(ctx, Query_SettledOrderBookParticipationsOfHeight_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Params queries the parameters of the module. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + // OrderBooks queries all order books that match the given status. + OrderBooks(context.Context, *QueryOrderBooksRequest) (*QueryOrderBooksResponse, error) + // OrderBook queries order book info for given order book universal unique + // identifier. + OrderBook(context.Context, *QueryOrderBookRequest) (*QueryOrderBookResponse, error) + // OrderBookParticipations queries participation info for given order book. + OrderBookParticipations(context.Context, *QueryOrderBookParticipationsRequest) (*QueryOrderBookParticipationsResponse, error) + // OrderBookParticipation queries participation info for given order book and + // participation index. + OrderBookParticipation(context.Context, *QueryOrderBookParticipationRequest) (*QueryOrderBookParticipationResponse, error) + // OrderBookExposures queries exposures info for the given order book. + OrderBookExposures(context.Context, *QueryOrderBookExposuresRequest) (*QueryOrderBookExposuresResponse, error) + // OrderBookExposure queries exposure info for the given order book and odds + // universal unique identifier. + OrderBookExposure(context.Context, *QueryOrderBookExposureRequest) (*QueryOrderBookExposureResponse, error) + // OrderBookParticipationExposures queries exposures info for given order book + // participations. + OrderBookParticipationExposures(context.Context, *QueryOrderBookParticipationExposuresRequest) (*QueryOrderBookParticipationExposuresResponse, error) + // ParticipationExposures queries exposure info for given order book + // participation. + ParticipationExposures(context.Context, *QueryParticipationExposuresRequest) (*QueryParticipationExposuresResponse, error) + // HistoricalParticipationExposures queries historical exposures info for + // the given order book participation. + HistoricalParticipationExposures(context.Context, *QueryHistoricalParticipationExposuresRequest) (*QueryHistoricalParticipationExposuresResponse, error) + // ParticipationFulfilledBets queries fulfilled bets for given order book + // participation. + ParticipationFulfilledBets(context.Context, *QueryParticipationFulfilledBetsRequest) (*QueryParticipationFulfilledBetsResponse, error) + // Queries list of settled Orderbook Participation items of a certain height. + SettledOrderBookParticipationsOfHeight(context.Context, *QuerySettledOrderBookParticipationsOfHeightRequest) (*QuerySettledOrderBookParticipationsOfHeightResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) OrderBooks(context.Context, *QueryOrderBooksRequest) (*QueryOrderBooksResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method OrderBooks not implemented") +} +func (UnimplementedQueryServer) OrderBook(context.Context, *QueryOrderBookRequest) (*QueryOrderBookResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method OrderBook not implemented") +} +func (UnimplementedQueryServer) OrderBookParticipations(context.Context, *QueryOrderBookParticipationsRequest) (*QueryOrderBookParticipationsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method OrderBookParticipations not implemented") +} +func (UnimplementedQueryServer) OrderBookParticipation(context.Context, *QueryOrderBookParticipationRequest) (*QueryOrderBookParticipationResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method OrderBookParticipation not implemented") +} +func (UnimplementedQueryServer) OrderBookExposures(context.Context, *QueryOrderBookExposuresRequest) (*QueryOrderBookExposuresResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method OrderBookExposures not implemented") +} +func (UnimplementedQueryServer) OrderBookExposure(context.Context, *QueryOrderBookExposureRequest) (*QueryOrderBookExposureResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method OrderBookExposure not implemented") +} +func (UnimplementedQueryServer) OrderBookParticipationExposures(context.Context, *QueryOrderBookParticipationExposuresRequest) (*QueryOrderBookParticipationExposuresResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method OrderBookParticipationExposures not implemented") +} +func (UnimplementedQueryServer) ParticipationExposures(context.Context, *QueryParticipationExposuresRequest) (*QueryParticipationExposuresResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ParticipationExposures not implemented") +} +func (UnimplementedQueryServer) HistoricalParticipationExposures(context.Context, *QueryHistoricalParticipationExposuresRequest) (*QueryHistoricalParticipationExposuresResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method HistoricalParticipationExposures not implemented") +} +func (UnimplementedQueryServer) ParticipationFulfilledBets(context.Context, *QueryParticipationFulfilledBetsRequest) (*QueryParticipationFulfilledBetsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ParticipationFulfilledBets not implemented") +} +func (UnimplementedQueryServer) SettledOrderBookParticipationsOfHeight(context.Context, *QuerySettledOrderBookParticipationsOfHeightRequest) (*QuerySettledOrderBookParticipationsOfHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SettledOrderBookParticipationsOfHeight not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_OrderBooks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryOrderBooksRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).OrderBooks(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_OrderBooks_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).OrderBooks(ctx, req.(*QueryOrderBooksRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_OrderBook_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryOrderBookRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).OrderBook(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_OrderBook_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).OrderBook(ctx, req.(*QueryOrderBookRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_OrderBookParticipations_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryOrderBookParticipationsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).OrderBookParticipations(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_OrderBookParticipations_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).OrderBookParticipations(ctx, req.(*QueryOrderBookParticipationsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_OrderBookParticipation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryOrderBookParticipationRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).OrderBookParticipation(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_OrderBookParticipation_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).OrderBookParticipation(ctx, req.(*QueryOrderBookParticipationRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_OrderBookExposures_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryOrderBookExposuresRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).OrderBookExposures(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_OrderBookExposures_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).OrderBookExposures(ctx, req.(*QueryOrderBookExposuresRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_OrderBookExposure_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryOrderBookExposureRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).OrderBookExposure(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_OrderBookExposure_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).OrderBookExposure(ctx, req.(*QueryOrderBookExposureRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_OrderBookParticipationExposures_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryOrderBookParticipationExposuresRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).OrderBookParticipationExposures(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_OrderBookParticipationExposures_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).OrderBookParticipationExposures(ctx, req.(*QueryOrderBookParticipationExposuresRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_ParticipationExposures_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParticipationExposuresRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).ParticipationExposures(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_ParticipationExposures_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).ParticipationExposures(ctx, req.(*QueryParticipationExposuresRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_HistoricalParticipationExposures_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryHistoricalParticipationExposuresRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).HistoricalParticipationExposures(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_HistoricalParticipationExposures_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).HistoricalParticipationExposures(ctx, req.(*QueryHistoricalParticipationExposuresRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_ParticipationFulfilledBets_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParticipationFulfilledBetsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).ParticipationFulfilledBets(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_ParticipationFulfilledBets_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).ParticipationFulfilledBets(ctx, req.(*QueryParticipationFulfilledBetsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_SettledOrderBookParticipationsOfHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QuerySettledOrderBookParticipationsOfHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).SettledOrderBookParticipationsOfHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_SettledOrderBookParticipationsOfHeight_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).SettledOrderBookParticipationsOfHeight(ctx, req.(*QuerySettledOrderBookParticipationsOfHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.orderbook.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + { + MethodName: "OrderBooks", + Handler: _Query_OrderBooks_Handler, + }, + { + MethodName: "OrderBook", + Handler: _Query_OrderBook_Handler, + }, + { + MethodName: "OrderBookParticipations", + Handler: _Query_OrderBookParticipations_Handler, + }, + { + MethodName: "OrderBookParticipation", + Handler: _Query_OrderBookParticipation_Handler, + }, + { + MethodName: "OrderBookExposures", + Handler: _Query_OrderBookExposures_Handler, + }, + { + MethodName: "OrderBookExposure", + Handler: _Query_OrderBookExposure_Handler, + }, + { + MethodName: "OrderBookParticipationExposures", + Handler: _Query_OrderBookParticipationExposures_Handler, + }, + { + MethodName: "ParticipationExposures", + Handler: _Query_ParticipationExposures_Handler, + }, + { + MethodName: "HistoricalParticipationExposures", + Handler: _Query_HistoricalParticipationExposures_Handler, + }, + { + MethodName: "ParticipationFulfilledBets", + Handler: _Query_ParticipationFulfilledBets_Handler, + }, + { + MethodName: "SettledOrderBookParticipationsOfHeight", + Handler: _Query_SettledOrderBookParticipationsOfHeight_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/orderbook/v1beta/query.proto", +} diff --git a/api/sge/legacy/orderbook/v1beta/stats.pulsar.go b/api/sge/legacy/orderbook/v1beta/stats.pulsar.go new file mode 100644 index 00000000..fc29b34b --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/stats.pulsar.go @@ -0,0 +1,638 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_OrderBookStats_1_list)(nil) + +type _OrderBookStats_1_list struct { + list *[]string +} + +func (x *_OrderBookStats_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_OrderBookStats_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_OrderBookStats_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_OrderBookStats_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_OrderBookStats_1_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message OrderBookStats at list field ResolvedUnsettled as it is not of Message kind")) +} + +func (x *_OrderBookStats_1_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_OrderBookStats_1_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_OrderBookStats_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_OrderBookStats protoreflect.MessageDescriptor + fd_OrderBookStats_resolved_unsettled protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_stats_proto_init() + md_OrderBookStats = File_sge_legacy_orderbook_v1beta_stats_proto.Messages().ByName("OrderBookStats") + fd_OrderBookStats_resolved_unsettled = md_OrderBookStats.Fields().ByName("resolved_unsettled") +} + +var _ protoreflect.Message = (*fastReflection_OrderBookStats)(nil) + +type fastReflection_OrderBookStats OrderBookStats + +func (x *OrderBookStats) ProtoReflect() protoreflect.Message { + return (*fastReflection_OrderBookStats)(x) +} + +func (x *OrderBookStats) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_stats_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_OrderBookStats_messageType fastReflection_OrderBookStats_messageType +var _ protoreflect.MessageType = fastReflection_OrderBookStats_messageType{} + +type fastReflection_OrderBookStats_messageType struct{} + +func (x fastReflection_OrderBookStats_messageType) Zero() protoreflect.Message { + return (*fastReflection_OrderBookStats)(nil) +} +func (x fastReflection_OrderBookStats_messageType) New() protoreflect.Message { + return new(fastReflection_OrderBookStats) +} +func (x fastReflection_OrderBookStats_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBookStats +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_OrderBookStats) Descriptor() protoreflect.MessageDescriptor { + return md_OrderBookStats +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_OrderBookStats) Type() protoreflect.MessageType { + return _fastReflection_OrderBookStats_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_OrderBookStats) New() protoreflect.Message { + return new(fastReflection_OrderBookStats) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_OrderBookStats) Interface() protoreflect.ProtoMessage { + return (*OrderBookStats)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_OrderBookStats) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.ResolvedUnsettled) != 0 { + value := protoreflect.ValueOfList(&_OrderBookStats_1_list{list: &x.ResolvedUnsettled}) + if !f(fd_OrderBookStats_resolved_unsettled, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_OrderBookStats) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookStats.resolved_unsettled": + return len(x.ResolvedUnsettled) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookStats")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookStats does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookStats) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookStats.resolved_unsettled": + x.ResolvedUnsettled = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookStats")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookStats does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_OrderBookStats) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookStats.resolved_unsettled": + if len(x.ResolvedUnsettled) == 0 { + return protoreflect.ValueOfList(&_OrderBookStats_1_list{}) + } + listValue := &_OrderBookStats_1_list{list: &x.ResolvedUnsettled} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookStats")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookStats does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookStats) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookStats.resolved_unsettled": + lv := value.List() + clv := lv.(*_OrderBookStats_1_list) + x.ResolvedUnsettled = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookStats")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookStats does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookStats) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookStats.resolved_unsettled": + if x.ResolvedUnsettled == nil { + x.ResolvedUnsettled = []string{} + } + value := &_OrderBookStats_1_list{list: &x.ResolvedUnsettled} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookStats")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookStats does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_OrderBookStats) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.OrderBookStats.resolved_unsettled": + list := []string{} + return protoreflect.ValueOfList(&_OrderBookStats_1_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.OrderBookStats")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.OrderBookStats does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_OrderBookStats) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.OrderBookStats", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_OrderBookStats) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_OrderBookStats) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_OrderBookStats) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_OrderBookStats) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*OrderBookStats) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.ResolvedUnsettled) > 0 { + for _, s := range x.ResolvedUnsettled { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*OrderBookStats) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.ResolvedUnsettled) > 0 { + for iNdEx := len(x.ResolvedUnsettled) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.ResolvedUnsettled[iNdEx]) + copy(dAtA[i:], x.ResolvedUnsettled[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ResolvedUnsettled[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*OrderBookStats) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBookStats: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: OrderBookStats: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ResolvedUnsettled", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ResolvedUnsettled = append(x.ResolvedUnsettled, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/stats.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// OrderBookStats holds statistics on the order book. +type OrderBookStats struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // resolved_unsettled is the list of order book universal unique identifiers + // that needs to be settled. + ResolvedUnsettled []string `protobuf:"bytes,1,rep,name=resolved_unsettled,json=resolvedUnsettled,proto3" json:"resolved_unsettled,omitempty"` +} + +func (x *OrderBookStats) Reset() { + *x = OrderBookStats{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_stats_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *OrderBookStats) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*OrderBookStats) ProtoMessage() {} + +// Deprecated: Use OrderBookStats.ProtoReflect.Descriptor instead. +func (*OrderBookStats) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_stats_proto_rawDescGZIP(), []int{0} +} + +func (x *OrderBookStats) GetResolvedUnsettled() []string { + if x != nil { + return x.ResolvedUnsettled + } + return nil +} + +var File_sge_legacy_orderbook_v1beta_stats_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_stats_proto_rawDesc = []byte{ + 0x0a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x73, 0x74, + 0x61, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x22, 0x3f, 0x0a, 0x0e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x42, + 0x6f, 0x6f, 0x6b, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x2d, 0x0a, 0x12, 0x72, 0x65, 0x73, 0x6f, + 0x6c, 0x76, 0x65, 0x64, 0x5f, 0x75, 0x6e, 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, 0x72, 0x65, 0x73, 0x6f, 0x6c, 0x76, 0x65, 0x64, 0x55, 0x6e, + 0x73, 0x65, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x42, 0x88, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4a, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, + 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x1b, 0x53, 0x67, + 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, + 0x6f, 0x6b, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0xea, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, + 0x3a, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_stats_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_stats_proto_rawDescData = file_sge_legacy_orderbook_v1beta_stats_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_stats_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_stats_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_stats_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_stats_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_stats_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_stats_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_orderbook_v1beta_stats_proto_goTypes = []interface{}{ + (*OrderBookStats)(nil), // 0: sge.legacy.orderbook.v1beta.OrderBookStats +} +var file_sge_legacy_orderbook_v1beta_stats_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_stats_proto_init() } +func file_sge_legacy_orderbook_v1beta_stats_proto_init() { + if File_sge_legacy_orderbook_v1beta_stats_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_stats_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*OrderBookStats); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_stats_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_stats_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_stats_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_v1beta_stats_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_stats_proto = out.File + file_sge_legacy_orderbook_v1beta_stats_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_stats_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_stats_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/tx.pulsar.go b/api/sge/legacy/orderbook/v1beta/tx.pulsar.go new file mode 100644 index 00000000..78273187 --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/tx.pulsar.go @@ -0,0 +1,1100 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package orderbookv1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_legacy_orderbook_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.legacy.orderbook.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.legacy.orderbook.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_orderbook_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_legacy_orderbook_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/orderbook/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgUpdateParams is the Msg/UpdateParams request type. +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/bet parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_orderbook_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +var File_sge_legacy_orderbook_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_legacy_orderbook_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, + 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, + 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x28, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, + 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb6, 0x01, 0x0a, 0x0f, 0x4d, + 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, + 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, + 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x46, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, + 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x3a, 0x23, + 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, + 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, + 0x69, 0x74, 0x79, 0x22, 0x30, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x3a, 0x15, + 0xd2, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, + 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x32, 0x94, 0x01, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x8c, 0x01, + 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x2c, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x34, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, + 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x18, 0xca, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x88, 0x02, 0x01, 0x42, 0x85, 0x02, 0x0a, + 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4a, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, + 0x6b, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x1b, + 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x62, 0x6f, 0x6f, 0x6b, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1b, 0x53, 0x67, + 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, + 0x6f, 0x6b, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x3a, 0x3a, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x62, 0x6f, 0x6f, 0x6b, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_orderbook_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_legacy_orderbook_v1beta_tx_proto_rawDescData = file_sge_legacy_orderbook_v1beta_tx_proto_rawDesc +) + +func file_sge_legacy_orderbook_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_legacy_orderbook_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_legacy_orderbook_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_orderbook_v1beta_tx_proto_rawDescData) + }) + return file_sge_legacy_orderbook_v1beta_tx_proto_rawDescData +} + +var file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_orderbook_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgUpdateParams)(nil), // 0: sge.legacy.orderbook.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 1: sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse + (*Params)(nil), // 2: sge.legacy.orderbook.v1beta.Params +} +var file_sge_legacy_orderbook_v1beta_tx_proto_depIdxs = []int32{ + 2, // 0: sge.legacy.orderbook.v1beta.MsgUpdateParams.params:type_name -> sge.legacy.orderbook.v1beta.Params + 0, // 1: sge.legacy.orderbook.v1beta.Msg.UpdateParams:input_type -> sge.legacy.orderbook.v1beta.MsgUpdateParams + 1, // 2: sge.legacy.orderbook.v1beta.Msg.UpdateParams:output_type -> sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse + 2, // [2:3] is the sub-list for method output_type + 1, // [1:2] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_orderbook_v1beta_tx_proto_init() } +func file_sge_legacy_orderbook_v1beta_tx_proto_init() { + if File_sge_legacy_orderbook_v1beta_tx_proto != nil { + return + } + file_sge_legacy_orderbook_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_orderbook_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_orderbook_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_legacy_orderbook_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_legacy_orderbook_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_legacy_orderbook_v1beta_tx_proto = out.File + file_sge_legacy_orderbook_v1beta_tx_proto_rawDesc = nil + file_sge_legacy_orderbook_v1beta_tx_proto_goTypes = nil + file_sge_legacy_orderbook_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/legacy/orderbook/v1beta/tx_grpc.pb.go b/api/sge/legacy/orderbook/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..42b01d66 --- /dev/null +++ b/api/sge/legacy/orderbook/v1beta/tx_grpc.pb.go @@ -0,0 +1,116 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/orderbook/v1beta/tx.proto + +package orderbookv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_UpdateParams_FullMethodName = "/sge.legacy.orderbook.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/market + // module parameters. The authority is defined in the keeper. + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/market + // module parameters. The authority is defined in the keeper. + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.orderbook.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/orderbook/v1beta/tx.proto", +} diff --git a/api/sge/legacy/ovm/module/v1/module.pulsar.go b/api/sge/legacy/ovm/module/v1/module.pulsar.go new file mode 100644 index 00000000..a4862f68 --- /dev/null +++ b/api/sge/legacy/ovm/module/v1/module.pulsar.go @@ -0,0 +1,654 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_module_v1_module_proto_init() + md_Module = File_sge_legacy_ovm_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.legacy.ovm.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.ovm.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.legacy.ovm.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.ovm.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.ovm.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.legacy.ovm.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.ovm.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.legacy.ovm.module.v1.Module is not mutable")) + case "sge.legacy.ovm.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.legacy.ovm.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.ovm.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.ovm.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the ovm module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_legacy_ovm_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, + 0x31, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, + 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x22, 0x67, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x12, 0x2c, 0x0a, + 0x12, 0x66, 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x5f, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x66, 0x65, 0x65, 0x43, 0x6f, + 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, + 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, 0x11, 0xba, 0xc0, 0x96, 0xda, 0x01, + 0x0b, 0x0a, 0x09, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x6f, 0x76, 0x6d, 0x42, 0xf2, 0x01, 0x0a, + 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x76, 0x6d, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, + 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x40, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, + 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x6d, 0x6f, 0x64, 0x75, + 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, 0x31, 0xa2, 0x02, + 0x04, 0x53, 0x4c, 0x4f, 0x4d, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x4f, 0x76, 0x6d, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x56, 0x31, + 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, + 0x6d, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x24, 0x53, 0x67, + 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x4d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, 0x3a, 0x56, + 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_module_v1_module_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_module_v1_module_proto_rawDescData = file_sge_legacy_ovm_module_v1_module_proto_rawDesc +) + +func file_sge_legacy_ovm_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_module_v1_module_proto_rawDescData) + }) + return file_sge_legacy_ovm_module_v1_module_proto_rawDescData +} + +var file_sge_legacy_ovm_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_ovm_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.legacy.ovm.module.v1.Module +} +var file_sge_legacy_ovm_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_module_v1_module_proto_init() } +func file_sge_legacy_ovm_module_v1_module_proto_init() { + if File_sge_legacy_ovm_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_module_v1_module_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_module_v1_module_proto = out.File + file_sge_legacy_ovm_module_v1_module_proto_rawDesc = nil + file_sge_legacy_ovm_module_v1_module_proto_goTypes = nil + file_sge_legacy_ovm_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/genesis.pulsar.go b/api/sge/legacy/ovm/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..df85ec28 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/genesis.pulsar.go @@ -0,0 +1,954 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_3_list)(nil) + +type _GenesisState_3_list struct { + list *[]*PublicKeysChangeProposal +} + +func (x *_GenesisState_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PublicKeysChangeProposal) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PublicKeysChangeProposal) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_3_list) AppendMutable() protoreflect.Value { + v := new(PublicKeysChangeProposal) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_3_list) NewElement() protoreflect.Value { + v := new(PublicKeysChangeProposal) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor + fd_GenesisState_key_vault protoreflect.FieldDescriptor + fd_GenesisState_pubkeys_change_proposals protoreflect.FieldDescriptor + fd_GenesisState_proposal_stats protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_genesis_proto_init() + md_GenesisState = File_sge_legacy_ovm_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") + fd_GenesisState_key_vault = md_GenesisState.Fields().ByName("key_vault") + fd_GenesisState_pubkeys_change_proposals = md_GenesisState.Fields().ByName("pubkeys_change_proposals") + fd_GenesisState_proposal_stats = md_GenesisState.Fields().ByName("proposal_stats") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } + if x.KeyVault != nil { + value := protoreflect.ValueOfMessage(x.KeyVault.ProtoReflect()) + if !f(fd_GenesisState_key_vault, value) { + return + } + } + if len(x.PubkeysChangeProposals) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_3_list{list: &x.PubkeysChangeProposals}) + if !f(fd_GenesisState_pubkeys_change_proposals, value) { + return + } + } + if x.ProposalStats != nil { + value := protoreflect.ValueOfMessage(x.ProposalStats.ProtoReflect()) + if !f(fd_GenesisState_proposal_stats, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.GenesisState.params": + return x.Params != nil + case "sge.legacy.ovm.v1beta.GenesisState.key_vault": + return x.KeyVault != nil + case "sge.legacy.ovm.v1beta.GenesisState.pubkeys_change_proposals": + return len(x.PubkeysChangeProposals) != 0 + case "sge.legacy.ovm.v1beta.GenesisState.proposal_stats": + return x.ProposalStats != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.GenesisState.params": + x.Params = nil + case "sge.legacy.ovm.v1beta.GenesisState.key_vault": + x.KeyVault = nil + case "sge.legacy.ovm.v1beta.GenesisState.pubkeys_change_proposals": + x.PubkeysChangeProposals = nil + case "sge.legacy.ovm.v1beta.GenesisState.proposal_stats": + x.ProposalStats = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.ovm.v1beta.GenesisState.key_vault": + value := x.KeyVault + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.ovm.v1beta.GenesisState.pubkeys_change_proposals": + if len(x.PubkeysChangeProposals) == 0 { + return protoreflect.ValueOfList(&_GenesisState_3_list{}) + } + listValue := &_GenesisState_3_list{list: &x.PubkeysChangeProposals} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.ovm.v1beta.GenesisState.proposal_stats": + value := x.ProposalStats + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + case "sge.legacy.ovm.v1beta.GenesisState.key_vault": + x.KeyVault = value.Message().Interface().(*KeyVault) + case "sge.legacy.ovm.v1beta.GenesisState.pubkeys_change_proposals": + lv := value.List() + clv := lv.(*_GenesisState_3_list) + x.PubkeysChangeProposals = *clv.list + case "sge.legacy.ovm.v1beta.GenesisState.proposal_stats": + x.ProposalStats = value.Message().Interface().(*ProposalStats) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.ovm.v1beta.GenesisState.key_vault": + if x.KeyVault == nil { + x.KeyVault = new(KeyVault) + } + return protoreflect.ValueOfMessage(x.KeyVault.ProtoReflect()) + case "sge.legacy.ovm.v1beta.GenesisState.pubkeys_change_proposals": + if x.PubkeysChangeProposals == nil { + x.PubkeysChangeProposals = []*PublicKeysChangeProposal{} + } + value := &_GenesisState_3_list{list: &x.PubkeysChangeProposals} + return protoreflect.ValueOfList(value) + case "sge.legacy.ovm.v1beta.GenesisState.proposal_stats": + if x.ProposalStats == nil { + x.ProposalStats = new(ProposalStats) + } + return protoreflect.ValueOfMessage(x.ProposalStats.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.ovm.v1beta.GenesisState.key_vault": + m := new(KeyVault) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.ovm.v1beta.GenesisState.pubkeys_change_proposals": + list := []*PublicKeysChangeProposal{} + return protoreflect.ValueOfList(&_GenesisState_3_list{list: &list}) + case "sge.legacy.ovm.v1beta.GenesisState.proposal_stats": + m := new(ProposalStats) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.KeyVault != nil { + l = options.Size(x.KeyVault) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.PubkeysChangeProposals) > 0 { + for _, e := range x.PubkeysChangeProposals { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.ProposalStats != nil { + l = options.Size(x.ProposalStats) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.ProposalStats != nil { + encoded, err := options.Marshal(x.ProposalStats) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + if len(x.PubkeysChangeProposals) > 0 { + for iNdEx := len(x.PubkeysChangeProposals) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.PubkeysChangeProposals[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if x.KeyVault != nil { + encoded, err := options.Marshal(x.KeyVault) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field KeyVault", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.KeyVault == nil { + x.KeyVault = &KeyVault{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.KeyVault); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PubkeysChangeProposals", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PubkeysChangeProposals = append(x.PubkeysChangeProposals, &PublicKeysChangeProposal{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.PubkeysChangeProposals[len(x.PubkeysChangeProposals)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalStats", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.ProposalStats == nil { + x.ProposalStats = &ProposalStats{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ProposalStats); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the ovm module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params contains parameters of ovm module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` + // key_vault trusted keys from genesis file. + KeyVault *KeyVault `protobuf:"bytes,2,opt,name=key_vault,json=keyVault,proto3" json:"key_vault,omitempty"` + // pubkeys_change_proposals is the finished proposal list for the + // public keys change. + PubkeysChangeProposals []*PublicKeysChangeProposal `protobuf:"bytes,3,rep,name=pubkeys_change_proposals,json=pubkeysChangeProposals,proto3" json:"pubkeys_change_proposals,omitempty"` + // proposal_stats holds the proposal statistics. + ProposalStats *ProposalStats `protobuf:"bytes,4,opt,name=proposal_stats,json=proposalStats,proto3" json:"proposal_stats,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +func (x *GenesisState) GetKeyVault() *KeyVault { + if x != nil { + return x.KeyVault + } + return nil +} + +func (x *GenesisState) GetPubkeysChangeProposals() []*PublicKeysChangeProposal { + if x != nil { + return x.PubkeysChangeProposals + } + return nil +} + +func (x *GenesisState) GetProposalStats() *ProposalStats { + if x != nil { + return x.ProposalStats + } + return nil +} + +var File_sge_legacy_ovm_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x23, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, + 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6b, 0x65, 0x79, 0x5f, 0x76, 0x61, + 0x75, 0x6c, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x24, 0x73, + 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xd3, 0x02, 0x0a, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, + 0x69, 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x3b, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x12, 0x42, 0x0a, 0x09, 0x6b, 0x65, 0x79, 0x5f, 0x76, 0x61, 0x75, 0x6c, + 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x4b, 0x65, 0x79, 0x56, 0x61, 0x75, 0x6c, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x08, + 0x6b, 0x65, 0x79, 0x56, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x6f, 0x0a, 0x18, 0x70, 0x75, 0x62, 0x6b, + 0x65, 0x79, 0x73, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x70, 0x6f, + 0x73, 0x61, 0x6c, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x42, 0x04, 0xc8, 0xde, 0x1f, + 0x00, 0x52, 0x16, 0x70, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, + 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x12, 0x51, 0x0a, 0x0e, 0x70, 0x72, 0x6f, + 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, + 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, + 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0d, 0x70, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x73, 0x42, 0xe0, 0x01, 0x0a, + 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, + 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, + 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x76, + 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, + 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_genesis_proto_rawDescData = file_sge_legacy_ovm_v1beta_genesis_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_genesis_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_genesis_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_ovm_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.legacy.ovm.v1beta.GenesisState + (*Params)(nil), // 1: sge.legacy.ovm.v1beta.Params + (*KeyVault)(nil), // 2: sge.legacy.ovm.v1beta.KeyVault + (*PublicKeysChangeProposal)(nil), // 3: sge.legacy.ovm.v1beta.PublicKeysChangeProposal + (*ProposalStats)(nil), // 4: sge.legacy.ovm.v1beta.ProposalStats +} +var file_sge_legacy_ovm_v1beta_genesis_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.ovm.v1beta.GenesisState.params:type_name -> sge.legacy.ovm.v1beta.Params + 2, // 1: sge.legacy.ovm.v1beta.GenesisState.key_vault:type_name -> sge.legacy.ovm.v1beta.KeyVault + 3, // 2: sge.legacy.ovm.v1beta.GenesisState.pubkeys_change_proposals:type_name -> sge.legacy.ovm.v1beta.PublicKeysChangeProposal + 4, // 3: sge.legacy.ovm.v1beta.GenesisState.proposal_stats:type_name -> sge.legacy.ovm.v1beta.ProposalStats + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_genesis_proto_init() } +func file_sge_legacy_ovm_v1beta_genesis_proto_init() { + if File_sge_legacy_ovm_v1beta_genesis_proto != nil { + return + } + file_sge_legacy_ovm_v1beta_key_vault_proto_init() + file_sge_legacy_ovm_v1beta_params_proto_init() + file_sge_legacy_ovm_v1beta_proposal_proto_init() + file_sge_legacy_ovm_v1beta_stats_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_genesis_proto = out.File + file_sge_legacy_ovm_v1beta_genesis_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_genesis_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/key_vault.pulsar.go b/api/sge/legacy/ovm/v1beta/key_vault.pulsar.go new file mode 100644 index 00000000..e90171c3 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/key_vault.pulsar.go @@ -0,0 +1,633 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_KeyVault_1_list)(nil) + +type _KeyVault_1_list struct { + list *[]string +} + +func (x *_KeyVault_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_KeyVault_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_KeyVault_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_KeyVault_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_KeyVault_1_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message KeyVault at list field PublicKeys as it is not of Message kind")) +} + +func (x *_KeyVault_1_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_KeyVault_1_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_KeyVault_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_KeyVault protoreflect.MessageDescriptor + fd_KeyVault_public_keys protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_key_vault_proto_init() + md_KeyVault = File_sge_legacy_ovm_v1beta_key_vault_proto.Messages().ByName("KeyVault") + fd_KeyVault_public_keys = md_KeyVault.Fields().ByName("public_keys") +} + +var _ protoreflect.Message = (*fastReflection_KeyVault)(nil) + +type fastReflection_KeyVault KeyVault + +func (x *KeyVault) ProtoReflect() protoreflect.Message { + return (*fastReflection_KeyVault)(x) +} + +func (x *KeyVault) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_key_vault_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_KeyVault_messageType fastReflection_KeyVault_messageType +var _ protoreflect.MessageType = fastReflection_KeyVault_messageType{} + +type fastReflection_KeyVault_messageType struct{} + +func (x fastReflection_KeyVault_messageType) Zero() protoreflect.Message { + return (*fastReflection_KeyVault)(nil) +} +func (x fastReflection_KeyVault_messageType) New() protoreflect.Message { + return new(fastReflection_KeyVault) +} +func (x fastReflection_KeyVault_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_KeyVault +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_KeyVault) Descriptor() protoreflect.MessageDescriptor { + return md_KeyVault +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_KeyVault) Type() protoreflect.MessageType { + return _fastReflection_KeyVault_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_KeyVault) New() protoreflect.Message { + return new(fastReflection_KeyVault) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_KeyVault) Interface() protoreflect.ProtoMessage { + return (*KeyVault)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_KeyVault) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.PublicKeys) != 0 { + value := protoreflect.ValueOfList(&_KeyVault_1_list{list: &x.PublicKeys}) + if !f(fd_KeyVault_public_keys, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_KeyVault) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.KeyVault.public_keys": + return len(x.PublicKeys) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.KeyVault")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.KeyVault does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KeyVault) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.KeyVault.public_keys": + x.PublicKeys = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.KeyVault")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.KeyVault does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_KeyVault) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.KeyVault.public_keys": + if len(x.PublicKeys) == 0 { + return protoreflect.ValueOfList(&_KeyVault_1_list{}) + } + listValue := &_KeyVault_1_list{list: &x.PublicKeys} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.KeyVault")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.KeyVault does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KeyVault) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.KeyVault.public_keys": + lv := value.List() + clv := lv.(*_KeyVault_1_list) + x.PublicKeys = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.KeyVault")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.KeyVault does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KeyVault) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.KeyVault.public_keys": + if x.PublicKeys == nil { + x.PublicKeys = []string{} + } + value := &_KeyVault_1_list{list: &x.PublicKeys} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.KeyVault")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.KeyVault does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_KeyVault) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.KeyVault.public_keys": + list := []string{} + return protoreflect.ValueOfList(&_KeyVault_1_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.KeyVault")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.KeyVault does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_KeyVault) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.KeyVault", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_KeyVault) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KeyVault) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_KeyVault) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_KeyVault) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*KeyVault) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.PublicKeys) > 0 { + for _, s := range x.PublicKeys { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*KeyVault) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.PublicKeys) > 0 { + for iNdEx := len(x.PublicKeys) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.PublicKeys[iNdEx]) + copy(dAtA[i:], x.PublicKeys[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PublicKeys[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*KeyVault) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: KeyVault: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: KeyVault: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PublicKeys", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PublicKeys = append(x.PublicKeys, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/key_vault.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// KeyVault is the information of important keys stored in ovm state. +type KeyVault struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // public_keys contains allowed public keys. + PublicKeys []string `protobuf:"bytes,1,rep,name=public_keys,json=publicKeys,proto3" json:"public_keys,omitempty"` +} + +func (x *KeyVault) Reset() { + *x = KeyVault{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_key_vault_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *KeyVault) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*KeyVault) ProtoMessage() {} + +// Deprecated: Use KeyVault.ProtoReflect.Descriptor instead. +func (*KeyVault) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescGZIP(), []int{0} +} + +func (x *KeyVault) GetPublicKeys() []string { + if x != nil { + return x.PublicKeys + } + return nil +} + +var File_sge_legacy_ovm_v1beta_key_vault_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_key_vault_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6b, 0x65, 0x79, 0x5f, 0x76, 0x61, 0x75, 0x6c, + 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x22, 0x2b, + 0x0a, 0x08, 0x4b, 0x65, 0x79, 0x56, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, + 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x42, 0xe1, 0x01, 0x0a, 0x19, + 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, + 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0d, 0x4b, 0x65, 0x79, 0x56, 0x61, + 0x75, 0x6c, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, + 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x76, + 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, + 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescData = file_sge_legacy_ovm_v1beta_key_vault_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_key_vault_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_key_vault_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_ovm_v1beta_key_vault_proto_goTypes = []interface{}{ + (*KeyVault)(nil), // 0: sge.legacy.ovm.v1beta.KeyVault +} +var file_sge_legacy_ovm_v1beta_key_vault_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_key_vault_proto_init() } +func file_sge_legacy_ovm_v1beta_key_vault_proto_init() { + if File_sge_legacy_ovm_v1beta_key_vault_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_key_vault_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*KeyVault); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_key_vault_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_v1beta_key_vault_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_key_vault_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_v1beta_key_vault_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_key_vault_proto = out.File + file_sge_legacy_ovm_v1beta_key_vault_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_key_vault_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_key_vault_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/params.pulsar.go b/api/sge/legacy/ovm/v1beta/params.pulsar.go new file mode 100644 index 00000000..0cc55498 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/params.pulsar.go @@ -0,0 +1,499 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Params protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_params_proto_init() + md_Params = File_sge_legacy_ovm_v1beta_params_proto.Messages().ByName("Params") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params defines the parameters for the module. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +var File_sge_legacy_ovm_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, + 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x22, 0x0e, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x3a, 0x04, 0x98, 0xa0, 0x1f, + 0x00, 0x42, 0xdf, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, + 0x0b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, + 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x4f, 0x76, 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_params_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_params_proto_rawDescData = file_sge_legacy_ovm_v1beta_params_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_params_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_params_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_ovm_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.legacy.ovm.v1beta.Params +} +var file_sge_legacy_ovm_v1beta_params_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_params_proto_init() } +func file_sge_legacy_ovm_v1beta_params_proto_init() { + if File_sge_legacy_ovm_v1beta_params_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_v1beta_params_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_params_proto = out.File + file_sge_legacy_ovm_v1beta_params_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_params_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/proposal.pulsar.go b/api/sge/legacy/ovm/v1beta/proposal.pulsar.go new file mode 100644 index 00000000..2d8c754f --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/proposal.pulsar.go @@ -0,0 +1,1343 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_PublicKeysChangeProposal_4_list)(nil) + +type _PublicKeysChangeProposal_4_list struct { + list *[]*Vote +} + +func (x *_PublicKeysChangeProposal_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_PublicKeysChangeProposal_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_PublicKeysChangeProposal_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Vote) + (*x.list)[i] = concreteValue +} + +func (x *_PublicKeysChangeProposal_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Vote) + *x.list = append(*x.list, concreteValue) +} + +func (x *_PublicKeysChangeProposal_4_list) AppendMutable() protoreflect.Value { + v := new(Vote) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_PublicKeysChangeProposal_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_PublicKeysChangeProposal_4_list) NewElement() protoreflect.Value { + v := new(Vote) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_PublicKeysChangeProposal_4_list) IsValid() bool { + return x.list != nil +} + +var ( + md_PublicKeysChangeProposal protoreflect.MessageDescriptor + fd_PublicKeysChangeProposal_id protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_creator protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_modifications protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_votes protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_start_ts protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_result protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_result_meta protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_finish_ts protoreflect.FieldDescriptor + fd_PublicKeysChangeProposal_status protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_proposal_proto_init() + md_PublicKeysChangeProposal = File_sge_legacy_ovm_v1beta_proposal_proto.Messages().ByName("PublicKeysChangeProposal") + fd_PublicKeysChangeProposal_id = md_PublicKeysChangeProposal.Fields().ByName("id") + fd_PublicKeysChangeProposal_creator = md_PublicKeysChangeProposal.Fields().ByName("creator") + fd_PublicKeysChangeProposal_modifications = md_PublicKeysChangeProposal.Fields().ByName("modifications") + fd_PublicKeysChangeProposal_votes = md_PublicKeysChangeProposal.Fields().ByName("votes") + fd_PublicKeysChangeProposal_start_ts = md_PublicKeysChangeProposal.Fields().ByName("start_ts") + fd_PublicKeysChangeProposal_result = md_PublicKeysChangeProposal.Fields().ByName("result") + fd_PublicKeysChangeProposal_result_meta = md_PublicKeysChangeProposal.Fields().ByName("result_meta") + fd_PublicKeysChangeProposal_finish_ts = md_PublicKeysChangeProposal.Fields().ByName("finish_ts") + fd_PublicKeysChangeProposal_status = md_PublicKeysChangeProposal.Fields().ByName("status") +} + +var _ protoreflect.Message = (*fastReflection_PublicKeysChangeProposal)(nil) + +type fastReflection_PublicKeysChangeProposal PublicKeysChangeProposal + +func (x *PublicKeysChangeProposal) ProtoReflect() protoreflect.Message { + return (*fastReflection_PublicKeysChangeProposal)(x) +} + +func (x *PublicKeysChangeProposal) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_proposal_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_PublicKeysChangeProposal_messageType fastReflection_PublicKeysChangeProposal_messageType +var _ protoreflect.MessageType = fastReflection_PublicKeysChangeProposal_messageType{} + +type fastReflection_PublicKeysChangeProposal_messageType struct{} + +func (x fastReflection_PublicKeysChangeProposal_messageType) Zero() protoreflect.Message { + return (*fastReflection_PublicKeysChangeProposal)(nil) +} +func (x fastReflection_PublicKeysChangeProposal_messageType) New() protoreflect.Message { + return new(fastReflection_PublicKeysChangeProposal) +} +func (x fastReflection_PublicKeysChangeProposal_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_PublicKeysChangeProposal +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_PublicKeysChangeProposal) Descriptor() protoreflect.MessageDescriptor { + return md_PublicKeysChangeProposal +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_PublicKeysChangeProposal) Type() protoreflect.MessageType { + return _fastReflection_PublicKeysChangeProposal_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_PublicKeysChangeProposal) New() protoreflect.Message { + return new(fastReflection_PublicKeysChangeProposal) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_PublicKeysChangeProposal) Interface() protoreflect.ProtoMessage { + return (*PublicKeysChangeProposal)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_PublicKeysChangeProposal) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Id != uint64(0) { + value := protoreflect.ValueOfUint64(x.Id) + if !f(fd_PublicKeysChangeProposal_id, value) { + return + } + } + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_PublicKeysChangeProposal_creator, value) { + return + } + } + if x.Modifications != nil { + value := protoreflect.ValueOfMessage(x.Modifications.ProtoReflect()) + if !f(fd_PublicKeysChangeProposal_modifications, value) { + return + } + } + if len(x.Votes) != 0 { + value := protoreflect.ValueOfList(&_PublicKeysChangeProposal_4_list{list: &x.Votes}) + if !f(fd_PublicKeysChangeProposal_votes, value) { + return + } + } + if x.StartTs != int64(0) { + value := protoreflect.ValueOfInt64(x.StartTs) + if !f(fd_PublicKeysChangeProposal_start_ts, value) { + return + } + } + if x.Result != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Result)) + if !f(fd_PublicKeysChangeProposal_result, value) { + return + } + } + if x.ResultMeta != "" { + value := protoreflect.ValueOfString(x.ResultMeta) + if !f(fd_PublicKeysChangeProposal_result_meta, value) { + return + } + } + if x.FinishTs != int64(0) { + value := protoreflect.ValueOfInt64(x.FinishTs) + if !f(fd_PublicKeysChangeProposal_finish_ts, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_PublicKeysChangeProposal_status, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_PublicKeysChangeProposal) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.id": + return x.Id != uint64(0) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.creator": + return x.Creator != "" + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.modifications": + return x.Modifications != nil + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.votes": + return len(x.Votes) != 0 + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.start_ts": + return x.StartTs != int64(0) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result": + return x.Result != 0 + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result_meta": + return x.ResultMeta != "" + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.finish_ts": + return x.FinishTs != int64(0) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.status": + return x.Status != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PublicKeysChangeProposal")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PublicKeysChangeProposal does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PublicKeysChangeProposal) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.id": + x.Id = uint64(0) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.creator": + x.Creator = "" + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.modifications": + x.Modifications = nil + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.votes": + x.Votes = nil + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.start_ts": + x.StartTs = int64(0) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result": + x.Result = 0 + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result_meta": + x.ResultMeta = "" + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.finish_ts": + x.FinishTs = int64(0) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.status": + x.Status = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PublicKeysChangeProposal")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PublicKeysChangeProposal does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_PublicKeysChangeProposal) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.id": + value := x.Id + return protoreflect.ValueOfUint64(value) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.modifications": + value := x.Modifications + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.votes": + if len(x.Votes) == 0 { + return protoreflect.ValueOfList(&_PublicKeysChangeProposal_4_list{}) + } + listValue := &_PublicKeysChangeProposal_4_list{list: &x.Votes} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.start_ts": + value := x.StartTs + return protoreflect.ValueOfInt64(value) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result": + value := x.Result + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result_meta": + value := x.ResultMeta + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.finish_ts": + value := x.FinishTs + return protoreflect.ValueOfInt64(value) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PublicKeysChangeProposal")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PublicKeysChangeProposal does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PublicKeysChangeProposal) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.id": + x.Id = value.Uint() + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.modifications": + x.Modifications = value.Message().Interface().(*PubkeysChangeProposalPayload) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.votes": + lv := value.List() + clv := lv.(*_PublicKeysChangeProposal_4_list) + x.Votes = *clv.list + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.start_ts": + x.StartTs = value.Int() + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result": + x.Result = (ProposalResult)(value.Enum()) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result_meta": + x.ResultMeta = value.Interface().(string) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.finish_ts": + x.FinishTs = value.Int() + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.status": + x.Status = (ProposalStatus)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PublicKeysChangeProposal")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PublicKeysChangeProposal does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PublicKeysChangeProposal) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.modifications": + if x.Modifications == nil { + x.Modifications = new(PubkeysChangeProposalPayload) + } + return protoreflect.ValueOfMessage(x.Modifications.ProtoReflect()) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.votes": + if x.Votes == nil { + x.Votes = []*Vote{} + } + value := &_PublicKeysChangeProposal_4_list{list: &x.Votes} + return protoreflect.ValueOfList(value) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.id": + panic(fmt.Errorf("field id of message sge.legacy.ovm.v1beta.PublicKeysChangeProposal is not mutable")) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.creator": + panic(fmt.Errorf("field creator of message sge.legacy.ovm.v1beta.PublicKeysChangeProposal is not mutable")) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.start_ts": + panic(fmt.Errorf("field start_ts of message sge.legacy.ovm.v1beta.PublicKeysChangeProposal is not mutable")) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result": + panic(fmt.Errorf("field result of message sge.legacy.ovm.v1beta.PublicKeysChangeProposal is not mutable")) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result_meta": + panic(fmt.Errorf("field result_meta of message sge.legacy.ovm.v1beta.PublicKeysChangeProposal is not mutable")) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.finish_ts": + panic(fmt.Errorf("field finish_ts of message sge.legacy.ovm.v1beta.PublicKeysChangeProposal is not mutable")) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.status": + panic(fmt.Errorf("field status of message sge.legacy.ovm.v1beta.PublicKeysChangeProposal is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PublicKeysChangeProposal")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PublicKeysChangeProposal does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_PublicKeysChangeProposal) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.id": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.modifications": + m := new(PubkeysChangeProposalPayload) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.votes": + list := []*Vote{} + return protoreflect.ValueOfList(&_PublicKeysChangeProposal_4_list{list: &list}) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.start_ts": + return protoreflect.ValueOfInt64(int64(0)) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result_meta": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.finish_ts": + return protoreflect.ValueOfInt64(int64(0)) + case "sge.legacy.ovm.v1beta.PublicKeysChangeProposal.status": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PublicKeysChangeProposal")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PublicKeysChangeProposal does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_PublicKeysChangeProposal) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.PublicKeysChangeProposal", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_PublicKeysChangeProposal) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PublicKeysChangeProposal) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_PublicKeysChangeProposal) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_PublicKeysChangeProposal) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*PublicKeysChangeProposal) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Id != 0 { + n += 1 + runtime.Sov(uint64(x.Id)) + } + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Modifications != nil { + l = options.Size(x.Modifications) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.Votes) > 0 { + for _, e := range x.Votes { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.StartTs != 0 { + n += 1 + runtime.Sov(uint64(x.StartTs)) + } + if x.Result != 0 { + n += 1 + runtime.Sov(uint64(x.Result)) + } + l = len(x.ResultMeta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.FinishTs != 0 { + n += 1 + runtime.Sov(uint64(x.FinishTs)) + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*PublicKeysChangeProposal) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x48 + } + if x.FinishTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.FinishTs)) + i-- + dAtA[i] = 0x40 + } + if len(x.ResultMeta) > 0 { + i -= len(x.ResultMeta) + copy(dAtA[i:], x.ResultMeta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ResultMeta))) + i-- + dAtA[i] = 0x3a + } + if x.Result != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Result)) + i-- + dAtA[i] = 0x30 + } + if x.StartTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.StartTs)) + i-- + dAtA[i] = 0x28 + } + if len(x.Votes) > 0 { + for iNdEx := len(x.Votes) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Votes[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if x.Modifications != nil { + encoded, err := options.Marshal(x.Modifications) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0x12 + } + if x.Id != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Id)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*PublicKeysChangeProposal) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PublicKeysChangeProposal: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PublicKeysChangeProposal: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + x.Id = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Id |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Modifications", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Modifications == nil { + x.Modifications = &PubkeysChangeProposalPayload{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Modifications); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Votes", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Votes = append(x.Votes, &Vote{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Votes[len(x.Votes)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field StartTs", wireType) + } + x.StartTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.StartTs |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) + } + x.Result = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Result |= ProposalResult(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ResultMeta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ResultMeta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 8: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FinishTs", wireType) + } + x.FinishTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.FinishTs |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 9: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= ProposalStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/proposal.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// ProposalResult is the enum type for the proposal result. +type ProposalResult int32 + +const ( + // unchosen value + ProposalResult_PROPOSAL_RESULT_UNSPECIFIED ProposalResult = 0 + // approved + ProposalResult_PROPOSAL_RESULT_APPROVED ProposalResult = 1 + // rejected + ProposalResult_PROPOSAL_RESULT_REJECTED ProposalResult = 2 + // expired + ProposalResult_PROPOSAL_RESULT_EXPIRED ProposalResult = 3 +) + +// Enum value maps for ProposalResult. +var ( + ProposalResult_name = map[int32]string{ + 0: "PROPOSAL_RESULT_UNSPECIFIED", + 1: "PROPOSAL_RESULT_APPROVED", + 2: "PROPOSAL_RESULT_REJECTED", + 3: "PROPOSAL_RESULT_EXPIRED", + } + ProposalResult_value = map[string]int32{ + "PROPOSAL_RESULT_UNSPECIFIED": 0, + "PROPOSAL_RESULT_APPROVED": 1, + "PROPOSAL_RESULT_REJECTED": 2, + "PROPOSAL_RESULT_EXPIRED": 3, + } +) + +func (x ProposalResult) Enum() *ProposalResult { + p := new(ProposalResult) + *p = x + return p +} + +func (x ProposalResult) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (ProposalResult) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_ovm_v1beta_proposal_proto_enumTypes[0].Descriptor() +} + +func (ProposalResult) Type() protoreflect.EnumType { + return &file_sge_legacy_ovm_v1beta_proposal_proto_enumTypes[0] +} + +func (x ProposalResult) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use ProposalResult.Descriptor instead. +func (ProposalResult) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_proposal_proto_rawDescGZIP(), []int{0} +} + +// ProposalStatus is the enum type for the proposal status. +type ProposalStatus int32 + +const ( + // unchosen value + ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED ProposalStatus = 0 + // active + ProposalStatus_PROPOSAL_STATUS_ACTIVE ProposalStatus = 1 + // finished + ProposalStatus_PROPOSAL_STATUS_FINISHED ProposalStatus = 2 +) + +// Enum value maps for ProposalStatus. +var ( + ProposalStatus_name = map[int32]string{ + 0: "PROPOSAL_STATUS_UNSPECIFIED", + 1: "PROPOSAL_STATUS_ACTIVE", + 2: "PROPOSAL_STATUS_FINISHED", + } + ProposalStatus_value = map[string]int32{ + "PROPOSAL_STATUS_UNSPECIFIED": 0, + "PROPOSAL_STATUS_ACTIVE": 1, + "PROPOSAL_STATUS_FINISHED": 2, + } +) + +func (x ProposalStatus) Enum() *ProposalStatus { + p := new(ProposalStatus) + *p = x + return p +} + +func (x ProposalStatus) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (ProposalStatus) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_ovm_v1beta_proposal_proto_enumTypes[1].Descriptor() +} + +func (ProposalStatus) Type() protoreflect.EnumType { + return &file_sge_legacy_ovm_v1beta_proposal_proto_enumTypes[1] +} + +func (x ProposalStatus) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use ProposalStatus.Descriptor instead. +func (ProposalStatus) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_proposal_proto_rawDescGZIP(), []int{1} +} + +// PublicKeysChangeProposal is the type for the proposal for additions and +// removals of pub keys. +type PublicKeysChangeProposal struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // id is the sequential id of the proposal generated by the blockchain. + Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + // creator is the account address of the proposal creator. + Creator string `protobuf:"bytes,2,opt,name=creator,proto3" json:"creator,omitempty"` + // modifications contain the ticket payload of the proposal. + Modifications *PubkeysChangeProposalPayload `protobuf:"bytes,3,opt,name=modifications,proto3" json:"modifications,omitempty"` + // votes contains the votes of the proposal. + Votes []*Vote `protobuf:"bytes,4,rep,name=votes,proto3" json:"votes,omitempty"` + // start_ts is the block time that the proposal is set. + StartTs int64 `protobuf:"varint,5,opt,name=start_ts,proto3" json:"start_ts,omitempty"` + // result is the result of the finished proposal. + Result ProposalResult `protobuf:"varint,6,opt,name=result,proto3,enum=sge.legacy.ovm.v1beta.ProposalResult" json:"result,omitempty"` + // result_meta is the metadata related to the result of the finished proposal. + ResultMeta string `protobuf:"bytes,7,opt,name=result_meta,json=resultMeta,proto3" json:"result_meta,omitempty"` + // finish_ts is the block time that the proposal is set as finished. + FinishTs int64 `protobuf:"varint,8,opt,name=finish_ts,proto3" json:"finish_ts,omitempty"` + // status is the status of a proposal. + Status ProposalStatus `protobuf:"varint,9,opt,name=status,proto3,enum=sge.legacy.ovm.v1beta.ProposalStatus" json:"status,omitempty"` +} + +func (x *PublicKeysChangeProposal) Reset() { + *x = PublicKeysChangeProposal{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_proposal_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PublicKeysChangeProposal) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PublicKeysChangeProposal) ProtoMessage() {} + +// Deprecated: Use PublicKeysChangeProposal.ProtoReflect.Descriptor instead. +func (*PublicKeysChangeProposal) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_proposal_proto_rawDescGZIP(), []int{0} +} + +func (x *PublicKeysChangeProposal) GetId() uint64 { + if x != nil { + return x.Id + } + return 0 +} + +func (x *PublicKeysChangeProposal) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *PublicKeysChangeProposal) GetModifications() *PubkeysChangeProposalPayload { + if x != nil { + return x.Modifications + } + return nil +} + +func (x *PublicKeysChangeProposal) GetVotes() []*Vote { + if x != nil { + return x.Votes + } + return nil +} + +func (x *PublicKeysChangeProposal) GetStartTs() int64 { + if x != nil { + return x.StartTs + } + return 0 +} + +func (x *PublicKeysChangeProposal) GetResult() ProposalResult { + if x != nil { + return x.Result + } + return ProposalResult_PROPOSAL_RESULT_UNSPECIFIED +} + +func (x *PublicKeysChangeProposal) GetResultMeta() string { + if x != nil { + return x.ResultMeta + } + return "" +} + +func (x *PublicKeysChangeProposal) GetFinishTs() int64 { + if x != nil { + return x.FinishTs + } + return 0 +} + +func (x *PublicKeysChangeProposal) GetStatus() ProposalStatus { + if x != nil { + return x.Status + } + return ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED +} + +var File_sge_legacy_ovm_v1beta_proposal_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_proposal_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x19, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x22, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x20, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, + 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x76, 0x6f, 0x74, 0x65, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xff, 0x03, 0x0a, 0x18, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, + 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, + 0x6c, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x02, 0x69, + 0x64, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, + 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x5f, 0x0a, 0x0d, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x69, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x33, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, + 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, + 0x64, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0d, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x69, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x31, 0x0a, 0x05, 0x76, 0x6f, 0x74, 0x65, 0x73, 0x18, + 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x56, 0x6f, + 0x74, 0x65, 0x52, 0x05, 0x76, 0x6f, 0x74, 0x65, 0x73, 0x12, 0x33, 0x0a, 0x08, 0x73, 0x74, 0x61, + 0x72, 0x74, 0x5f, 0x74, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x42, 0x17, 0xe2, 0xde, 0x1f, + 0x07, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x08, 0x73, 0x74, 0x61, 0x72, + 0x74, 0x5f, 0x74, 0x73, 0x52, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x12, 0x3d, + 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x25, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1f, 0x0a, + 0x0b, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x07, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x37, + 0x0a, 0x09, 0x66, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x5f, 0x74, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x03, 0x42, 0x19, 0xe2, 0xde, 0x1f, 0x08, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x54, 0x53, 0xea, + 0xde, 0x1f, 0x09, 0x66, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x5f, 0x74, 0x73, 0x52, 0x09, 0x66, 0x69, + 0x6e, 0x69, 0x73, 0x68, 0x5f, 0x74, 0x73, 0x12, 0x3d, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, + 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x25, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, + 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x2a, 0x8a, 0x01, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x70, 0x6f, + 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1f, 0x0a, 0x1b, 0x50, 0x52, 0x4f, + 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x55, 0x4e, 0x53, + 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, + 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x41, 0x50, + 0x50, 0x52, 0x4f, 0x56, 0x45, 0x44, 0x10, 0x01, 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, 0x4f, 0x50, + 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x52, 0x45, 0x4a, 0x45, + 0x43, 0x54, 0x45, 0x44, 0x10, 0x02, 0x12, 0x1b, 0x0a, 0x17, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, + 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x45, 0x58, 0x50, 0x49, 0x52, 0x45, + 0x44, 0x10, 0x03, 0x2a, 0x6b, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1f, 0x0a, 0x1b, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, + 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, + 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1a, 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, + 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, 0x43, 0x54, 0x49, 0x56, 0x45, + 0x10, 0x01, 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, + 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x46, 0x49, 0x4e, 0x49, 0x53, 0x48, 0x45, 0x44, 0x10, 0x02, + 0x42, 0xe1, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0d, + 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, + 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, + 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x4f, 0x76, 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, + 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, + 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_proposal_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_proposal_proto_rawDescData = file_sge_legacy_ovm_v1beta_proposal_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_proposal_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_proposal_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_proposal_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_proposal_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_proposal_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_proposal_proto_enumTypes = make([]protoimpl.EnumInfo, 2) +var file_sge_legacy_ovm_v1beta_proposal_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_ovm_v1beta_proposal_proto_goTypes = []interface{}{ + (ProposalResult)(0), // 0: sge.legacy.ovm.v1beta.ProposalResult + (ProposalStatus)(0), // 1: sge.legacy.ovm.v1beta.ProposalStatus + (*PublicKeysChangeProposal)(nil), // 2: sge.legacy.ovm.v1beta.PublicKeysChangeProposal + (*PubkeysChangeProposalPayload)(nil), // 3: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload + (*Vote)(nil), // 4: sge.legacy.ovm.v1beta.Vote +} +var file_sge_legacy_ovm_v1beta_proposal_proto_depIdxs = []int32{ + 3, // 0: sge.legacy.ovm.v1beta.PublicKeysChangeProposal.modifications:type_name -> sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload + 4, // 1: sge.legacy.ovm.v1beta.PublicKeysChangeProposal.votes:type_name -> sge.legacy.ovm.v1beta.Vote + 0, // 2: sge.legacy.ovm.v1beta.PublicKeysChangeProposal.result:type_name -> sge.legacy.ovm.v1beta.ProposalResult + 1, // 3: sge.legacy.ovm.v1beta.PublicKeysChangeProposal.status:type_name -> sge.legacy.ovm.v1beta.ProposalStatus + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_proposal_proto_init() } +func file_sge_legacy_ovm_v1beta_proposal_proto_init() { + if File_sge_legacy_ovm_v1beta_proposal_proto != nil { + return + } + file_sge_legacy_ovm_v1beta_ticket_proto_init() + file_sge_legacy_ovm_v1beta_vote_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_proposal_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PublicKeysChangeProposal); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_proposal_proto_rawDesc, + NumEnums: 2, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_v1beta_proposal_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_proposal_proto_depIdxs, + EnumInfos: file_sge_legacy_ovm_v1beta_proposal_proto_enumTypes, + MessageInfos: file_sge_legacy_ovm_v1beta_proposal_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_proposal_proto = out.File + file_sge_legacy_ovm_v1beta_proposal_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_proposal_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_proposal_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/query.pulsar.go b/api/sge/legacy/ovm/v1beta/query.pulsar.go new file mode 100644 index 00000000..4113e0b7 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/query.pulsar.go @@ -0,0 +1,4206 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + v1beta1 "cosmossdk.io/api/cosmos/base/query/v1beta1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPubKeysRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryPubKeysRequest = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryPubKeysRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryPubKeysRequest)(nil) + +type fastReflection_QueryPubKeysRequest QueryPubKeysRequest + +func (x *QueryPubKeysRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPubKeysRequest)(x) +} + +func (x *QueryPubKeysRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPubKeysRequest_messageType fastReflection_QueryPubKeysRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPubKeysRequest_messageType{} + +type fastReflection_QueryPubKeysRequest_messageType struct{} + +func (x fastReflection_QueryPubKeysRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPubKeysRequest)(nil) +} +func (x fastReflection_QueryPubKeysRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPubKeysRequest) +} +func (x fastReflection_QueryPubKeysRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPubKeysRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPubKeysRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPubKeysRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPubKeysRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPubKeysRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPubKeysRequest) New() protoreflect.Message { + return new(fastReflection_QueryPubKeysRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPubKeysRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPubKeysRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPubKeysRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPubKeysRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPubKeysRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPubKeysRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPubKeysRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryPubKeysRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPubKeysRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPubKeysRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPubKeysRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPubKeysRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPubKeysRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPubKeysRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPubKeysRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPubKeysRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryPubKeysResponse_1_list)(nil) + +type _QueryPubKeysResponse_1_list struct { + list *[]string +} + +func (x *_QueryPubKeysResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryPubKeysResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_QueryPubKeysResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_QueryPubKeysResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryPubKeysResponse_1_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message QueryPubKeysResponse at list field List as it is not of Message kind")) +} + +func (x *_QueryPubKeysResponse_1_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_QueryPubKeysResponse_1_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_QueryPubKeysResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryPubKeysResponse protoreflect.MessageDescriptor + fd_QueryPubKeysResponse_list protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryPubKeysResponse = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryPubKeysResponse") + fd_QueryPubKeysResponse_list = md_QueryPubKeysResponse.Fields().ByName("list") +} + +var _ protoreflect.Message = (*fastReflection_QueryPubKeysResponse)(nil) + +type fastReflection_QueryPubKeysResponse QueryPubKeysResponse + +func (x *QueryPubKeysResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPubKeysResponse)(x) +} + +func (x *QueryPubKeysResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPubKeysResponse_messageType fastReflection_QueryPubKeysResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPubKeysResponse_messageType{} + +type fastReflection_QueryPubKeysResponse_messageType struct{} + +func (x fastReflection_QueryPubKeysResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPubKeysResponse)(nil) +} +func (x fastReflection_QueryPubKeysResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPubKeysResponse) +} +func (x fastReflection_QueryPubKeysResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPubKeysResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPubKeysResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPubKeysResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPubKeysResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPubKeysResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPubKeysResponse) New() protoreflect.Message { + return new(fastReflection_QueryPubKeysResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPubKeysResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPubKeysResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPubKeysResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.List) != 0 { + value := protoreflect.ValueOfList(&_QueryPubKeysResponse_1_list{list: &x.List}) + if !f(fd_QueryPubKeysResponse_list, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPubKeysResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPubKeysResponse.list": + return len(x.List) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPubKeysResponse.list": + x.List = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPubKeysResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.QueryPubKeysResponse.list": + if len(x.List) == 0 { + return protoreflect.ValueOfList(&_QueryPubKeysResponse_1_list{}) + } + listValue := &_QueryPubKeysResponse_1_list{list: &x.List} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPubKeysResponse.list": + lv := value.List() + clv := lv.(*_QueryPubKeysResponse_1_list) + x.List = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPubKeysResponse.list": + if x.List == nil { + x.List = []string{} + } + value := &_QueryPubKeysResponse_1_list{list: &x.List} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPubKeysResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPubKeysResponse.list": + list := []string{} + return protoreflect.ValueOfList(&_QueryPubKeysResponse_1_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPubKeysResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPubKeysResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPubKeysResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryPubKeysResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPubKeysResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPubKeysResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPubKeysResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPubKeysResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPubKeysResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.List) > 0 { + for _, s := range x.List { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPubKeysResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.List) > 0 { + for iNdEx := len(x.List) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.List[iNdEx]) + copy(dAtA[i:], x.List[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.List[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPubKeysResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPubKeysResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPubKeysResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field List", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.List = append(x.List, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPublicKeysChangeProposalRequest protoreflect.MessageDescriptor + fd_QueryPublicKeysChangeProposalRequest_id protoreflect.FieldDescriptor + fd_QueryPublicKeysChangeProposalRequest_status protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryPublicKeysChangeProposalRequest = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryPublicKeysChangeProposalRequest") + fd_QueryPublicKeysChangeProposalRequest_id = md_QueryPublicKeysChangeProposalRequest.Fields().ByName("id") + fd_QueryPublicKeysChangeProposalRequest_status = md_QueryPublicKeysChangeProposalRequest.Fields().ByName("status") +} + +var _ protoreflect.Message = (*fastReflection_QueryPublicKeysChangeProposalRequest)(nil) + +type fastReflection_QueryPublicKeysChangeProposalRequest QueryPublicKeysChangeProposalRequest + +func (x *QueryPublicKeysChangeProposalRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalRequest)(x) +} + +func (x *QueryPublicKeysChangeProposalRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPublicKeysChangeProposalRequest_messageType fastReflection_QueryPublicKeysChangeProposalRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPublicKeysChangeProposalRequest_messageType{} + +type fastReflection_QueryPublicKeysChangeProposalRequest_messageType struct{} + +func (x fastReflection_QueryPublicKeysChangeProposalRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalRequest)(nil) +} +func (x fastReflection_QueryPublicKeysChangeProposalRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalRequest) +} +func (x fastReflection_QueryPublicKeysChangeProposalRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPublicKeysChangeProposalRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPublicKeysChangeProposalRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Id != uint64(0) { + value := protoreflect.ValueOfUint64(x.Id) + if !f(fd_QueryPublicKeysChangeProposalRequest_id, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_QueryPublicKeysChangeProposalRequest_status, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.id": + return x.Id != uint64(0) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.status": + return x.Status != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.id": + x.Id = uint64(0) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.status": + x.Status = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.id": + value := x.Id + return protoreflect.ValueOfUint64(value) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.id": + x.Id = value.Uint() + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.status": + x.Status = (ProposalStatus)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.id": + panic(fmt.Errorf("field id of message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest is not mutable")) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.status": + panic(fmt.Errorf("field status of message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.id": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.status": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPublicKeysChangeProposalRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Id != 0 { + n += 1 + runtime.Sov(uint64(x.Id)) + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x10 + } + if x.Id != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Id)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + x.Id = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Id |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= ProposalStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPublicKeysChangeProposalResponse protoreflect.MessageDescriptor + fd_QueryPublicKeysChangeProposalResponse_proposal protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryPublicKeysChangeProposalResponse = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryPublicKeysChangeProposalResponse") + fd_QueryPublicKeysChangeProposalResponse_proposal = md_QueryPublicKeysChangeProposalResponse.Fields().ByName("proposal") +} + +var _ protoreflect.Message = (*fastReflection_QueryPublicKeysChangeProposalResponse)(nil) + +type fastReflection_QueryPublicKeysChangeProposalResponse QueryPublicKeysChangeProposalResponse + +func (x *QueryPublicKeysChangeProposalResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalResponse)(x) +} + +func (x *QueryPublicKeysChangeProposalResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPublicKeysChangeProposalResponse_messageType fastReflection_QueryPublicKeysChangeProposalResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPublicKeysChangeProposalResponse_messageType{} + +type fastReflection_QueryPublicKeysChangeProposalResponse_messageType struct{} + +func (x fastReflection_QueryPublicKeysChangeProposalResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalResponse)(nil) +} +func (x fastReflection_QueryPublicKeysChangeProposalResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalResponse) +} +func (x fastReflection_QueryPublicKeysChangeProposalResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPublicKeysChangeProposalResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPublicKeysChangeProposalResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Proposal != nil { + value := protoreflect.ValueOfMessage(x.Proposal.ProtoReflect()) + if !f(fd_QueryPublicKeysChangeProposalResponse_proposal, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse.proposal": + return x.Proposal != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse.proposal": + x.Proposal = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse.proposal": + value := x.Proposal + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse.proposal": + x.Proposal = value.Message().Interface().(*PublicKeysChangeProposal) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse.proposal": + if x.Proposal == nil { + x.Proposal = new(PublicKeysChangeProposal) + } + return protoreflect.ValueOfMessage(x.Proposal.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse.proposal": + m := new(PublicKeysChangeProposal) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPublicKeysChangeProposalResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Proposal != nil { + l = options.Size(x.Proposal) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Proposal != nil { + encoded, err := options.Marshal(x.Proposal) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Proposal", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Proposal == nil { + x.Proposal = &PublicKeysChangeProposal{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Proposal); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPublicKeysChangeProposalsRequest protoreflect.MessageDescriptor + fd_QueryPublicKeysChangeProposalsRequest_pagination protoreflect.FieldDescriptor + fd_QueryPublicKeysChangeProposalsRequest_status protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryPublicKeysChangeProposalsRequest = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryPublicKeysChangeProposalsRequest") + fd_QueryPublicKeysChangeProposalsRequest_pagination = md_QueryPublicKeysChangeProposalsRequest.Fields().ByName("pagination") + fd_QueryPublicKeysChangeProposalsRequest_status = md_QueryPublicKeysChangeProposalsRequest.Fields().ByName("status") +} + +var _ protoreflect.Message = (*fastReflection_QueryPublicKeysChangeProposalsRequest)(nil) + +type fastReflection_QueryPublicKeysChangeProposalsRequest QueryPublicKeysChangeProposalsRequest + +func (x *QueryPublicKeysChangeProposalsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalsRequest)(x) +} + +func (x *QueryPublicKeysChangeProposalsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPublicKeysChangeProposalsRequest_messageType fastReflection_QueryPublicKeysChangeProposalsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPublicKeysChangeProposalsRequest_messageType{} + +type fastReflection_QueryPublicKeysChangeProposalsRequest_messageType struct{} + +func (x fastReflection_QueryPublicKeysChangeProposalsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalsRequest)(nil) +} +func (x fastReflection_QueryPublicKeysChangeProposalsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalsRequest) +} +func (x fastReflection_QueryPublicKeysChangeProposalsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPublicKeysChangeProposalsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPublicKeysChangeProposalsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryPublicKeysChangeProposalsRequest_pagination, value) { + return + } + } + if x.Status != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status)) + if !f(fd_QueryPublicKeysChangeProposalsRequest_status, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.pagination": + return x.Pagination != nil + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.status": + return x.Status != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.pagination": + x.Pagination = nil + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.status": + x.Status = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.status": + value := x.Status + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.status": + x.Status = (ProposalStatus)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.status": + panic(fmt.Errorf("field status of message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.status": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPublicKeysChangeProposalsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Status != 0 { + n += 1 + runtime.Sov(uint64(x.Status)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Status != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) + i-- + dAtA[i] = 0x10 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + x.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Status |= ProposalStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryPublicKeysChangeProposalsResponse_1_list)(nil) + +type _QueryPublicKeysChangeProposalsResponse_1_list struct { + list *[]*PublicKeysChangeProposal +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PublicKeysChangeProposal) + (*x.list)[i] = concreteValue +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PublicKeysChangeProposal) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(PublicKeysChangeProposal) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) NewElement() protoreflect.Value { + v := new(PublicKeysChangeProposal) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryPublicKeysChangeProposalsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryPublicKeysChangeProposalsResponse protoreflect.MessageDescriptor + fd_QueryPublicKeysChangeProposalsResponse_proposals protoreflect.FieldDescriptor + fd_QueryPublicKeysChangeProposalsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_query_proto_init() + md_QueryPublicKeysChangeProposalsResponse = File_sge_legacy_ovm_v1beta_query_proto.Messages().ByName("QueryPublicKeysChangeProposalsResponse") + fd_QueryPublicKeysChangeProposalsResponse_proposals = md_QueryPublicKeysChangeProposalsResponse.Fields().ByName("proposals") + fd_QueryPublicKeysChangeProposalsResponse_pagination = md_QueryPublicKeysChangeProposalsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryPublicKeysChangeProposalsResponse)(nil) + +type fastReflection_QueryPublicKeysChangeProposalsResponse QueryPublicKeysChangeProposalsResponse + +func (x *QueryPublicKeysChangeProposalsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalsResponse)(x) +} + +func (x *QueryPublicKeysChangeProposalsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPublicKeysChangeProposalsResponse_messageType fastReflection_QueryPublicKeysChangeProposalsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPublicKeysChangeProposalsResponse_messageType{} + +type fastReflection_QueryPublicKeysChangeProposalsResponse_messageType struct{} + +func (x fastReflection_QueryPublicKeysChangeProposalsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPublicKeysChangeProposalsResponse)(nil) +} +func (x fastReflection_QueryPublicKeysChangeProposalsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalsResponse) +} +func (x fastReflection_QueryPublicKeysChangeProposalsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPublicKeysChangeProposalsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPublicKeysChangeProposalsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) New() protoreflect.Message { + return new(fastReflection_QueryPublicKeysChangeProposalsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPublicKeysChangeProposalsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Proposals) != 0 { + value := protoreflect.ValueOfList(&_QueryPublicKeysChangeProposalsResponse_1_list{list: &x.Proposals}) + if !f(fd_QueryPublicKeysChangeProposalsResponse_proposals, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryPublicKeysChangeProposalsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.proposals": + return len(x.Proposals) != 0 + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.proposals": + x.Proposals = nil + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.proposals": + if len(x.Proposals) == 0 { + return protoreflect.ValueOfList(&_QueryPublicKeysChangeProposalsResponse_1_list{}) + } + listValue := &_QueryPublicKeysChangeProposalsResponse_1_list{list: &x.Proposals} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.proposals": + lv := value.List() + clv := lv.(*_QueryPublicKeysChangeProposalsResponse_1_list) + x.Proposals = *clv.list + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.proposals": + if x.Proposals == nil { + x.Proposals = []*PublicKeysChangeProposal{} + } + value := &_QueryPublicKeysChangeProposalsResponse_1_list{list: &x.Proposals} + return protoreflect.ValueOfList(value) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.proposals": + list := []*PublicKeysChangeProposal{} + return protoreflect.ValueOfList(&_QueryPublicKeysChangeProposalsResponse_1_list{list: &list}) + case "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPublicKeysChangeProposalsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Proposals) > 0 { + for _, e := range x.Proposals { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Proposals) > 0 { + for iNdEx := len(x.Proposals) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Proposals[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPublicKeysChangeProposalsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPublicKeysChangeProposalsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Proposals", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Proposals = append(x.Proposals, &PublicKeysChangeProposal{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Proposals[len(x.Proposals)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is the request type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is the response type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params holds all the parameters of this module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QueryPubKeysRequest is the request type for the public keys list query. +// Query/PubKeys RPC method. +type QueryPubKeysRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryPubKeysRequest) Reset() { + *x = QueryPubKeysRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPubKeysRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPubKeysRequest) ProtoMessage() {} + +// Deprecated: Use QueryPubKeysRequest.ProtoReflect.Descriptor instead. +func (*QueryPubKeysRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +// QueryPubKeysResponse is the response type for the public keys list query. +// Query/PubKeys RPC method. +type QueryPubKeysResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // list is the list of allowed public keys. + List []string `protobuf:"bytes,1,rep,name=list,proto3" json:"list,omitempty"` +} + +func (x *QueryPubKeysResponse) Reset() { + *x = QueryPubKeysResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPubKeysResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPubKeysResponse) ProtoMessage() {} + +// Deprecated: Use QueryPubKeysResponse.ProtoReflect.Descriptor instead. +func (*QueryPubKeysResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QueryPubKeysResponse) GetList() []string { + if x != nil { + return x.List + } + return nil +} + +// QueryPublicKeysChangeProposalRequest is the request type for the +// Query/PublicKeysChangeProposal RPC method. +type QueryPublicKeysChangeProposalRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + Status ProposalStatus `protobuf:"varint,2,opt,name=status,proto3,enum=sge.legacy.ovm.v1beta.ProposalStatus" json:"status,omitempty"` +} + +func (x *QueryPublicKeysChangeProposalRequest) Reset() { + *x = QueryPublicKeysChangeProposalRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPublicKeysChangeProposalRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPublicKeysChangeProposalRequest) ProtoMessage() {} + +// Deprecated: Use QueryPublicKeysChangeProposalRequest.ProtoReflect.Descriptor instead. +func (*QueryPublicKeysChangeProposalRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{4} +} + +func (x *QueryPublicKeysChangeProposalRequest) GetId() uint64 { + if x != nil { + return x.Id + } + return 0 +} + +func (x *QueryPublicKeysChangeProposalRequest) GetStatus() ProposalStatus { + if x != nil { + return x.Status + } + return ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED +} + +// QueryPublicKeysChangeProposalResponse is the response type for the +// Query/PublicKeysChangeProposal RPC method. +type QueryPublicKeysChangeProposalResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // proposal holds the proposal. + Proposal *PublicKeysChangeProposal `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal,omitempty"` +} + +func (x *QueryPublicKeysChangeProposalResponse) Reset() { + *x = QueryPublicKeysChangeProposalResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPublicKeysChangeProposalResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPublicKeysChangeProposalResponse) ProtoMessage() {} + +// Deprecated: Use QueryPublicKeysChangeProposalResponse.ProtoReflect.Descriptor instead. +func (*QueryPublicKeysChangeProposalResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{5} +} + +func (x *QueryPublicKeysChangeProposalResponse) GetProposal() *PublicKeysChangeProposal { + if x != nil { + return x.Proposal + } + return nil +} + +// QueryPublicKeysChangeProposalsRequest is the request type for the +// Query/PublicKeysChangeProposals RPC method. +type QueryPublicKeysChangeProposalsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + Status ProposalStatus `protobuf:"varint,2,opt,name=status,proto3,enum=sge.legacy.ovm.v1beta.ProposalStatus" json:"status,omitempty"` +} + +func (x *QueryPublicKeysChangeProposalsRequest) Reset() { + *x = QueryPublicKeysChangeProposalsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPublicKeysChangeProposalsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPublicKeysChangeProposalsRequest) ProtoMessage() {} + +// Deprecated: Use QueryPublicKeysChangeProposalsRequest.ProtoReflect.Descriptor instead. +func (*QueryPublicKeysChangeProposalsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{6} +} + +func (x *QueryPublicKeysChangeProposalsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QueryPublicKeysChangeProposalsRequest) GetStatus() ProposalStatus { + if x != nil { + return x.Status + } + return ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED +} + +// QueryPublicKeysChangeProposalsResponse is the response type for the +// Query/PublicKeysChangeProposals RPC method. +type QueryPublicKeysChangeProposalsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // proposals hold the proposals. + Proposals []*PublicKeysChangeProposal `protobuf:"bytes,1,rep,name=proposals,proto3" json:"proposals,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryPublicKeysChangeProposalsResponse) Reset() { + *x = QueryPublicKeysChangeProposalsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPublicKeysChangeProposalsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPublicKeysChangeProposalsResponse) ProtoMessage() {} + +// Deprecated: Use QueryPublicKeysChangeProposalsResponse.ProtoReflect.Descriptor instead. +func (*QueryPublicKeysChangeProposalsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP(), []int{7} +} + +func (x *QueryPublicKeysChangeProposalsResponse) GetProposals() []*PublicKeysChangeProposal { + if x != nil { + return x.Proposals + } + return nil +} + +func (x *QueryPublicKeysChangeProposalsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +var File_sge_legacy_ovm_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x2a, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, + 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x22, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x24, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x14, 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x52, 0x0a, 0x13, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x3b, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, + 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x15, + 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x2a, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, + 0x62, 0x4b, 0x65, 0x79, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x04, 0x6c, 0x69, 0x73, + 0x74, 0x22, 0x75, 0x0a, 0x24, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, + 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, + 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x02, 0x69, 0x64, 0x12, 0x3d, 0x0a, 0x06, 0x73, 0x74, 0x61, + 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x25, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, + 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0x7a, 0x0a, 0x25, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, + 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x51, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x22, 0xae, 0x01, 0x0a, 0x25, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, + 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, + 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, + 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, + 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, + 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3d, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x25, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0xc6, 0x01, 0x0a, 0x26, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, + 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x53, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x18, 0x01, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x32, 0x91, + 0x05, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x78, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x12, 0x29, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2a, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x17, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x11, 0x12, 0x0f, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x12, 0x7d, 0x0a, 0x07, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x73, 0x12, 0x2a, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x4b, 0x65, + 0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x19, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x13, 0x12, 0x11, + 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x70, 0x75, 0x62, 0x5f, 0x6b, 0x65, 0x79, + 0x73, 0x12, 0xc6, 0x01, 0x0a, 0x18, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, + 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x3b, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3c, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, + 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, + 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2f, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x29, 0x12, 0x27, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x70, 0x75, 0x62, 0x6b, + 0x65, 0x79, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x2f, 0x7b, 0x73, 0x74, + 0x61, 0x74, 0x75, 0x73, 0x7d, 0x2f, 0x7b, 0x69, 0x64, 0x7d, 0x12, 0xc5, 0x01, 0x0a, 0x19, 0x50, + 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x12, 0x3c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, + 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x43, 0x68, + 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x12, 0x23, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x70, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x5f, + 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x73, 0x2f, 0x7b, 0x73, 0x74, 0x61, 0x74, 0x75, + 0x73, 0x7d, 0x42, 0xde, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, + 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x4f, 0x76, 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_query_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_query_proto_rawDescData = file_sge_legacy_ovm_v1beta_query_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_query_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_query_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 8) +var file_sge_legacy_ovm_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.legacy.ovm.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.legacy.ovm.v1beta.QueryParamsResponse + (*QueryPubKeysRequest)(nil), // 2: sge.legacy.ovm.v1beta.QueryPubKeysRequest + (*QueryPubKeysResponse)(nil), // 3: sge.legacy.ovm.v1beta.QueryPubKeysResponse + (*QueryPublicKeysChangeProposalRequest)(nil), // 4: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest + (*QueryPublicKeysChangeProposalResponse)(nil), // 5: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse + (*QueryPublicKeysChangeProposalsRequest)(nil), // 6: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest + (*QueryPublicKeysChangeProposalsResponse)(nil), // 7: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse + (*Params)(nil), // 8: sge.legacy.ovm.v1beta.Params + (ProposalStatus)(0), // 9: sge.legacy.ovm.v1beta.ProposalStatus + (*PublicKeysChangeProposal)(nil), // 10: sge.legacy.ovm.v1beta.PublicKeysChangeProposal + (*v1beta1.PageRequest)(nil), // 11: cosmos.base.query.v1beta1.PageRequest + (*v1beta1.PageResponse)(nil), // 12: cosmos.base.query.v1beta1.PageResponse +} +var file_sge_legacy_ovm_v1beta_query_proto_depIdxs = []int32{ + 8, // 0: sge.legacy.ovm.v1beta.QueryParamsResponse.params:type_name -> sge.legacy.ovm.v1beta.Params + 9, // 1: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest.status:type_name -> sge.legacy.ovm.v1beta.ProposalStatus + 10, // 2: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse.proposal:type_name -> sge.legacy.ovm.v1beta.PublicKeysChangeProposal + 11, // 3: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 9, // 4: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest.status:type_name -> sge.legacy.ovm.v1beta.ProposalStatus + 10, // 5: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.proposals:type_name -> sge.legacy.ovm.v1beta.PublicKeysChangeProposal + 12, // 6: sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 0, // 7: sge.legacy.ovm.v1beta.Query.Params:input_type -> sge.legacy.ovm.v1beta.QueryParamsRequest + 2, // 8: sge.legacy.ovm.v1beta.Query.PubKeys:input_type -> sge.legacy.ovm.v1beta.QueryPubKeysRequest + 4, // 9: sge.legacy.ovm.v1beta.Query.PublicKeysChangeProposal:input_type -> sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest + 6, // 10: sge.legacy.ovm.v1beta.Query.PublicKeysChangeProposals:input_type -> sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest + 1, // 11: sge.legacy.ovm.v1beta.Query.Params:output_type -> sge.legacy.ovm.v1beta.QueryParamsResponse + 3, // 12: sge.legacy.ovm.v1beta.Query.PubKeys:output_type -> sge.legacy.ovm.v1beta.QueryPubKeysResponse + 5, // 13: sge.legacy.ovm.v1beta.Query.PublicKeysChangeProposal:output_type -> sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse + 7, // 14: sge.legacy.ovm.v1beta.Query.PublicKeysChangeProposals:output_type -> sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse + 11, // [11:15] is the sub-list for method output_type + 7, // [7:11] is the sub-list for method input_type + 7, // [7:7] is the sub-list for extension type_name + 7, // [7:7] is the sub-list for extension extendee + 0, // [0:7] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_query_proto_init() } +func file_sge_legacy_ovm_v1beta_query_proto_init() { + if File_sge_legacy_ovm_v1beta_query_proto != nil { + return + } + file_sge_legacy_ovm_v1beta_params_proto_init() + file_sge_legacy_ovm_v1beta_proposal_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPubKeysRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPubKeysResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPublicKeysChangeProposalRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPublicKeysChangeProposalResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPublicKeysChangeProposalsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPublicKeysChangeProposalsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 8, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_ovm_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_v1beta_query_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_query_proto = out.File + file_sge_legacy_ovm_v1beta_query_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_query_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/query_grpc.pb.go b/api/sge/legacy/ovm/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..8b7ac99d --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/query_grpc.pb.go @@ -0,0 +1,228 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/ovm/v1beta/query.proto + +package ovmv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Params_FullMethodName = "/sge.legacy.ovm.v1beta.Query/Params" + Query_PubKeys_FullMethodName = "/sge.legacy.ovm.v1beta.Query/PubKeys" + Query_PublicKeysChangeProposal_FullMethodName = "/sge.legacy.ovm.v1beta.Query/PublicKeysChangeProposal" + Query_PublicKeysChangeProposals_FullMethodName = "/sge.legacy.ovm.v1beta.Query/PublicKeysChangeProposals" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Params queries the parameters of the module. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) + // Queries a list of PubKeys items. + PubKeys(ctx context.Context, in *QueryPubKeysRequest, opts ...grpc.CallOption) (*QueryPubKeysResponse, error) + // Queries an proposal by id and status. + PublicKeysChangeProposal(ctx context.Context, in *QueryPublicKeysChangeProposalRequest, opts ...grpc.CallOption) (*QueryPublicKeysChangeProposalResponse, error) + // Queries a list of proposal items by status. + PublicKeysChangeProposals(ctx context.Context, in *QueryPublicKeysChangeProposalsRequest, opts ...grpc.CallOption) (*QueryPublicKeysChangeProposalsResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) PubKeys(ctx context.Context, in *QueryPubKeysRequest, opts ...grpc.CallOption) (*QueryPubKeysResponse, error) { + out := new(QueryPubKeysResponse) + err := c.cc.Invoke(ctx, Query_PubKeys_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) PublicKeysChangeProposal(ctx context.Context, in *QueryPublicKeysChangeProposalRequest, opts ...grpc.CallOption) (*QueryPublicKeysChangeProposalResponse, error) { + out := new(QueryPublicKeysChangeProposalResponse) + err := c.cc.Invoke(ctx, Query_PublicKeysChangeProposal_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) PublicKeysChangeProposals(ctx context.Context, in *QueryPublicKeysChangeProposalsRequest, opts ...grpc.CallOption) (*QueryPublicKeysChangeProposalsResponse, error) { + out := new(QueryPublicKeysChangeProposalsResponse) + err := c.cc.Invoke(ctx, Query_PublicKeysChangeProposals_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Params queries the parameters of the module. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + // Queries a list of PubKeys items. + PubKeys(context.Context, *QueryPubKeysRequest) (*QueryPubKeysResponse, error) + // Queries an proposal by id and status. + PublicKeysChangeProposal(context.Context, *QueryPublicKeysChangeProposalRequest) (*QueryPublicKeysChangeProposalResponse, error) + // Queries a list of proposal items by status. + PublicKeysChangeProposals(context.Context, *QueryPublicKeysChangeProposalsRequest) (*QueryPublicKeysChangeProposalsResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) PubKeys(context.Context, *QueryPubKeysRequest) (*QueryPubKeysResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PubKeys not implemented") +} +func (UnimplementedQueryServer) PublicKeysChangeProposal(context.Context, *QueryPublicKeysChangeProposalRequest) (*QueryPublicKeysChangeProposalResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PublicKeysChangeProposal not implemented") +} +func (UnimplementedQueryServer) PublicKeysChangeProposals(context.Context, *QueryPublicKeysChangeProposalsRequest) (*QueryPublicKeysChangeProposalsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PublicKeysChangeProposals not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_PubKeys_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPubKeysRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).PubKeys(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_PubKeys_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).PubKeys(ctx, req.(*QueryPubKeysRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_PublicKeysChangeProposal_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPublicKeysChangeProposalRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).PublicKeysChangeProposal(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_PublicKeysChangeProposal_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).PublicKeysChangeProposal(ctx, req.(*QueryPublicKeysChangeProposalRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_PublicKeysChangeProposals_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPublicKeysChangeProposalsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).PublicKeysChangeProposals(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_PublicKeysChangeProposals_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).PublicKeysChangeProposals(ctx, req.(*QueryPublicKeysChangeProposalsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.ovm.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + { + MethodName: "PubKeys", + Handler: _Query_PubKeys_Handler, + }, + { + MethodName: "PublicKeysChangeProposal", + Handler: _Query_PublicKeysChangeProposal_Handler, + }, + { + MethodName: "PublicKeysChangeProposals", + Handler: _Query_PublicKeysChangeProposals_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/ovm/v1beta/query.proto", +} diff --git a/api/sge/legacy/ovm/v1beta/stats.pulsar.go b/api/sge/legacy/ovm/v1beta/stats.pulsar.go new file mode 100644 index 00000000..cebea9c7 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/stats.pulsar.go @@ -0,0 +1,558 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_ProposalStats protoreflect.MessageDescriptor + fd_ProposalStats_pubkeys_change_count protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_stats_proto_init() + md_ProposalStats = File_sge_legacy_ovm_v1beta_stats_proto.Messages().ByName("ProposalStats") + fd_ProposalStats_pubkeys_change_count = md_ProposalStats.Fields().ByName("pubkeys_change_count") +} + +var _ protoreflect.Message = (*fastReflection_ProposalStats)(nil) + +type fastReflection_ProposalStats ProposalStats + +func (x *ProposalStats) ProtoReflect() protoreflect.Message { + return (*fastReflection_ProposalStats)(x) +} + +func (x *ProposalStats) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_stats_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_ProposalStats_messageType fastReflection_ProposalStats_messageType +var _ protoreflect.MessageType = fastReflection_ProposalStats_messageType{} + +type fastReflection_ProposalStats_messageType struct{} + +func (x fastReflection_ProposalStats_messageType) Zero() protoreflect.Message { + return (*fastReflection_ProposalStats)(nil) +} +func (x fastReflection_ProposalStats_messageType) New() protoreflect.Message { + return new(fastReflection_ProposalStats) +} +func (x fastReflection_ProposalStats_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_ProposalStats +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_ProposalStats) Descriptor() protoreflect.MessageDescriptor { + return md_ProposalStats +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_ProposalStats) Type() protoreflect.MessageType { + return _fastReflection_ProposalStats_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_ProposalStats) New() protoreflect.Message { + return new(fastReflection_ProposalStats) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_ProposalStats) Interface() protoreflect.ProtoMessage { + return (*ProposalStats)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_ProposalStats) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.PubkeysChangeCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.PubkeysChangeCount) + if !f(fd_ProposalStats_pubkeys_change_count, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_ProposalStats) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalStats.pubkeys_change_count": + return x.PubkeysChangeCount != uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalStats")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalStats does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalStats) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalStats.pubkeys_change_count": + x.PubkeysChangeCount = uint64(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalStats")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalStats does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_ProposalStats) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.ProposalStats.pubkeys_change_count": + value := x.PubkeysChangeCount + return protoreflect.ValueOfUint64(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalStats")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalStats does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalStats) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalStats.pubkeys_change_count": + x.PubkeysChangeCount = value.Uint() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalStats")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalStats does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalStats) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalStats.pubkeys_change_count": + panic(fmt.Errorf("field pubkeys_change_count of message sge.legacy.ovm.v1beta.ProposalStats is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalStats")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalStats does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_ProposalStats) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalStats.pubkeys_change_count": + return protoreflect.ValueOfUint64(uint64(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalStats")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalStats does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_ProposalStats) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.ProposalStats", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_ProposalStats) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalStats) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_ProposalStats) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_ProposalStats) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*ProposalStats) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.PubkeysChangeCount != 0 { + n += 1 + runtime.Sov(uint64(x.PubkeysChangeCount)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*ProposalStats) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.PubkeysChangeCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.PubkeysChangeCount)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*ProposalStats) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ProposalStats: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ProposalStats: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PubkeysChangeCount", wireType) + } + x.PubkeysChangeCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.PubkeysChangeCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/stats.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// ProposalStats is the type for the proposal statistics. +type ProposalStats struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // pubkeys_change_count is the pubkeys change proposals count. + PubkeysChangeCount uint64 `protobuf:"varint,1,opt,name=pubkeys_change_count,json=pubkeysChangeCount,proto3" json:"pubkeys_change_count,omitempty"` +} + +func (x *ProposalStats) Reset() { + *x = ProposalStats{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_stats_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ProposalStats) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ProposalStats) ProtoMessage() {} + +// Deprecated: Use ProposalStats.ProtoReflect.Descriptor instead. +func (*ProposalStats) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_stats_proto_rawDescGZIP(), []int{0} +} + +func (x *ProposalStats) GetPubkeysChangeCount() uint64 { + if x != nil { + return x.PubkeysChangeCount + } + return 0 +} + +var File_sge_legacy_ovm_v1beta_stats_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_stats_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x22, 0x41, 0x0a, 0x0d, 0x50, 0x72, + 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x30, 0x0a, 0x14, 0x70, + 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x5f, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x12, 0x70, 0x75, 0x62, 0x6b, 0x65, + 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0xde, 0x01, + 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x53, 0x74, 0x61, + 0x74, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, + 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, + 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, + 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x76, 0x6d, + 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, + 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_stats_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_stats_proto_rawDescData = file_sge_legacy_ovm_v1beta_stats_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_stats_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_stats_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_stats_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_stats_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_stats_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_stats_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_ovm_v1beta_stats_proto_goTypes = []interface{}{ + (*ProposalStats)(nil), // 0: sge.legacy.ovm.v1beta.ProposalStats +} +var file_sge_legacy_ovm_v1beta_stats_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_stats_proto_init() } +func file_sge_legacy_ovm_v1beta_stats_proto_init() { + if File_sge_legacy_ovm_v1beta_stats_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_stats_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ProposalStats); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_stats_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_v1beta_stats_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_stats_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_v1beta_stats_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_stats_proto = out.File + file_sge_legacy_ovm_v1beta_stats_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_stats_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_stats_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/ticket.pulsar.go b/api/sge/legacy/ovm/v1beta/ticket.pulsar.go new file mode 100644 index 00000000..811c1a05 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/ticket.pulsar.go @@ -0,0 +1,1217 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_PubkeysChangeProposalPayload_1_list)(nil) + +type _PubkeysChangeProposalPayload_1_list struct { + list *[]string +} + +func (x *_PubkeysChangeProposalPayload_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_PubkeysChangeProposalPayload_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_PubkeysChangeProposalPayload_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_PubkeysChangeProposalPayload_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_PubkeysChangeProposalPayload_1_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message PubkeysChangeProposalPayload at list field PublicKeys as it is not of Message kind")) +} + +func (x *_PubkeysChangeProposalPayload_1_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_PubkeysChangeProposalPayload_1_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_PubkeysChangeProposalPayload_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_PubkeysChangeProposalPayload protoreflect.MessageDescriptor + fd_PubkeysChangeProposalPayload_public_keys protoreflect.FieldDescriptor + fd_PubkeysChangeProposalPayload_leader_index protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_ticket_proto_init() + md_PubkeysChangeProposalPayload = File_sge_legacy_ovm_v1beta_ticket_proto.Messages().ByName("PubkeysChangeProposalPayload") + fd_PubkeysChangeProposalPayload_public_keys = md_PubkeysChangeProposalPayload.Fields().ByName("public_keys") + fd_PubkeysChangeProposalPayload_leader_index = md_PubkeysChangeProposalPayload.Fields().ByName("leader_index") +} + +var _ protoreflect.Message = (*fastReflection_PubkeysChangeProposalPayload)(nil) + +type fastReflection_PubkeysChangeProposalPayload PubkeysChangeProposalPayload + +func (x *PubkeysChangeProposalPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_PubkeysChangeProposalPayload)(x) +} + +func (x *PubkeysChangeProposalPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_PubkeysChangeProposalPayload_messageType fastReflection_PubkeysChangeProposalPayload_messageType +var _ protoreflect.MessageType = fastReflection_PubkeysChangeProposalPayload_messageType{} + +type fastReflection_PubkeysChangeProposalPayload_messageType struct{} + +func (x fastReflection_PubkeysChangeProposalPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_PubkeysChangeProposalPayload)(nil) +} +func (x fastReflection_PubkeysChangeProposalPayload_messageType) New() protoreflect.Message { + return new(fastReflection_PubkeysChangeProposalPayload) +} +func (x fastReflection_PubkeysChangeProposalPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_PubkeysChangeProposalPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_PubkeysChangeProposalPayload) Descriptor() protoreflect.MessageDescriptor { + return md_PubkeysChangeProposalPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_PubkeysChangeProposalPayload) Type() protoreflect.MessageType { + return _fastReflection_PubkeysChangeProposalPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_PubkeysChangeProposalPayload) New() protoreflect.Message { + return new(fastReflection_PubkeysChangeProposalPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_PubkeysChangeProposalPayload) Interface() protoreflect.ProtoMessage { + return (*PubkeysChangeProposalPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_PubkeysChangeProposalPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.PublicKeys) != 0 { + value := protoreflect.ValueOfList(&_PubkeysChangeProposalPayload_1_list{list: &x.PublicKeys}) + if !f(fd_PubkeysChangeProposalPayload_public_keys, value) { + return + } + } + if x.LeaderIndex != uint32(0) { + value := protoreflect.ValueOfUint32(x.LeaderIndex) + if !f(fd_PubkeysChangeProposalPayload_leader_index, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_PubkeysChangeProposalPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.public_keys": + return len(x.PublicKeys) != 0 + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.leader_index": + return x.LeaderIndex != uint32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PubkeysChangeProposalPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.public_keys": + x.PublicKeys = nil + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.leader_index": + x.LeaderIndex = uint32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_PubkeysChangeProposalPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.public_keys": + if len(x.PublicKeys) == 0 { + return protoreflect.ValueOfList(&_PubkeysChangeProposalPayload_1_list{}) + } + listValue := &_PubkeysChangeProposalPayload_1_list{list: &x.PublicKeys} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.leader_index": + value := x.LeaderIndex + return protoreflect.ValueOfUint32(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PubkeysChangeProposalPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.public_keys": + lv := value.List() + clv := lv.(*_PubkeysChangeProposalPayload_1_list) + x.PublicKeys = *clv.list + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.leader_index": + x.LeaderIndex = uint32(value.Uint()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PubkeysChangeProposalPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.public_keys": + if x.PublicKeys == nil { + x.PublicKeys = []string{} + } + value := &_PubkeysChangeProposalPayload_1_list{list: &x.PublicKeys} + return protoreflect.ValueOfList(value) + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.leader_index": + panic(fmt.Errorf("field leader_index of message sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_PubkeysChangeProposalPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.public_keys": + list := []string{} + return protoreflect.ValueOfList(&_PubkeysChangeProposalPayload_1_list{list: &list}) + case "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload.leader_index": + return protoreflect.ValueOfUint32(uint32(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_PubkeysChangeProposalPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_PubkeysChangeProposalPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PubkeysChangeProposalPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_PubkeysChangeProposalPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_PubkeysChangeProposalPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*PubkeysChangeProposalPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.PublicKeys) > 0 { + for _, s := range x.PublicKeys { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.LeaderIndex != 0 { + n += 1 + runtime.Sov(uint64(x.LeaderIndex)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*PubkeysChangeProposalPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.LeaderIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.LeaderIndex)) + i-- + dAtA[i] = 0x10 + } + if len(x.PublicKeys) > 0 { + for iNdEx := len(x.PublicKeys) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.PublicKeys[iNdEx]) + copy(dAtA[i:], x.PublicKeys[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PublicKeys[iNdEx]))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*PubkeysChangeProposalPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PubkeysChangeProposalPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PubkeysChangeProposalPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PublicKeys", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PublicKeys = append(x.PublicKeys, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field LeaderIndex", wireType) + } + x.LeaderIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.LeaderIndex |= uint32(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_ProposalVotePayload protoreflect.MessageDescriptor + fd_ProposalVotePayload_proposal_id protoreflect.FieldDescriptor + fd_ProposalVotePayload_vote protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_ticket_proto_init() + md_ProposalVotePayload = File_sge_legacy_ovm_v1beta_ticket_proto.Messages().ByName("ProposalVotePayload") + fd_ProposalVotePayload_proposal_id = md_ProposalVotePayload.Fields().ByName("proposal_id") + fd_ProposalVotePayload_vote = md_ProposalVotePayload.Fields().ByName("vote") +} + +var _ protoreflect.Message = (*fastReflection_ProposalVotePayload)(nil) + +type fastReflection_ProposalVotePayload ProposalVotePayload + +func (x *ProposalVotePayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_ProposalVotePayload)(x) +} + +func (x *ProposalVotePayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_ProposalVotePayload_messageType fastReflection_ProposalVotePayload_messageType +var _ protoreflect.MessageType = fastReflection_ProposalVotePayload_messageType{} + +type fastReflection_ProposalVotePayload_messageType struct{} + +func (x fastReflection_ProposalVotePayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_ProposalVotePayload)(nil) +} +func (x fastReflection_ProposalVotePayload_messageType) New() protoreflect.Message { + return new(fastReflection_ProposalVotePayload) +} +func (x fastReflection_ProposalVotePayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_ProposalVotePayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_ProposalVotePayload) Descriptor() protoreflect.MessageDescriptor { + return md_ProposalVotePayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_ProposalVotePayload) Type() protoreflect.MessageType { + return _fastReflection_ProposalVotePayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_ProposalVotePayload) New() protoreflect.Message { + return new(fastReflection_ProposalVotePayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_ProposalVotePayload) Interface() protoreflect.ProtoMessage { + return (*ProposalVotePayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_ProposalVotePayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.ProposalId != uint64(0) { + value := protoreflect.ValueOfUint64(x.ProposalId) + if !f(fd_ProposalVotePayload_proposal_id, value) { + return + } + } + if x.Vote != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Vote)) + if !f(fd_ProposalVotePayload_vote, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_ProposalVotePayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalVotePayload.proposal_id": + return x.ProposalId != uint64(0) + case "sge.legacy.ovm.v1beta.ProposalVotePayload.vote": + return x.Vote != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalVotePayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalVotePayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalVotePayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalVotePayload.proposal_id": + x.ProposalId = uint64(0) + case "sge.legacy.ovm.v1beta.ProposalVotePayload.vote": + x.Vote = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalVotePayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalVotePayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_ProposalVotePayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.ProposalVotePayload.proposal_id": + value := x.ProposalId + return protoreflect.ValueOfUint64(value) + case "sge.legacy.ovm.v1beta.ProposalVotePayload.vote": + value := x.Vote + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalVotePayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalVotePayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalVotePayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalVotePayload.proposal_id": + x.ProposalId = value.Uint() + case "sge.legacy.ovm.v1beta.ProposalVotePayload.vote": + x.Vote = (ProposalVote)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalVotePayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalVotePayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalVotePayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalVotePayload.proposal_id": + panic(fmt.Errorf("field proposal_id of message sge.legacy.ovm.v1beta.ProposalVotePayload is not mutable")) + case "sge.legacy.ovm.v1beta.ProposalVotePayload.vote": + panic(fmt.Errorf("field vote of message sge.legacy.ovm.v1beta.ProposalVotePayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalVotePayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalVotePayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_ProposalVotePayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.ProposalVotePayload.proposal_id": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.ovm.v1beta.ProposalVotePayload.vote": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.ProposalVotePayload")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.ProposalVotePayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_ProposalVotePayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.ProposalVotePayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_ProposalVotePayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_ProposalVotePayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_ProposalVotePayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_ProposalVotePayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*ProposalVotePayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.ProposalId != 0 { + n += 1 + runtime.Sov(uint64(x.ProposalId)) + } + if x.Vote != 0 { + n += 1 + runtime.Sov(uint64(x.Vote)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*ProposalVotePayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Vote != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Vote)) + i-- + dAtA[i] = 0x10 + } + if x.ProposalId != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.ProposalId)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*ProposalVotePayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ProposalVotePayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ProposalVotePayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalId", wireType) + } + x.ProposalId = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.ProposalId |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Vote", wireType) + } + x.Vote = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Vote |= ProposalVote(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/ticket.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// PubkeysChangeProposalPayload indicates data of public keys changes proposal +// ticket. +type PubkeysChangeProposalPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // public_keys contain new pub keys to be added to public keys. + PublicKeys []string `protobuf:"bytes,1,rep,name=public_keys,json=publicKeys,proto3" json:"public_keys,omitempty"` + // leader_index is the universal unique identifier of the public key. + LeaderIndex uint32 `protobuf:"varint,2,opt,name=leader_index,json=leaderIndex,proto3" json:"leader_index,omitempty"` +} + +func (x *PubkeysChangeProposalPayload) Reset() { + *x = PubkeysChangeProposalPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PubkeysChangeProposalPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PubkeysChangeProposalPayload) ProtoMessage() {} + +// Deprecated: Use PubkeysChangeProposalPayload.ProtoReflect.Descriptor instead. +func (*PubkeysChangeProposalPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_ticket_proto_rawDescGZIP(), []int{0} +} + +func (x *PubkeysChangeProposalPayload) GetPublicKeys() []string { + if x != nil { + return x.PublicKeys + } + return nil +} + +func (x *PubkeysChangeProposalPayload) GetLeaderIndex() uint32 { + if x != nil { + return x.LeaderIndex + } + return 0 +} + +// ProposalVotePayload indicates vote data ticket. +type ProposalVotePayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // proposal_id is the id of the proposal. + ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` + // vote is the chosen option for the vote. + Vote ProposalVote `protobuf:"varint,2,opt,name=vote,proto3,enum=sge.legacy.ovm.v1beta.ProposalVote" json:"vote,omitempty"` +} + +func (x *ProposalVotePayload) Reset() { + *x = ProposalVotePayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ProposalVotePayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ProposalVotePayload) ProtoMessage() {} + +// Deprecated: Use ProposalVotePayload.ProtoReflect.Descriptor instead. +func (*ProposalVotePayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_ticket_proto_rawDescGZIP(), []int{1} +} + +func (x *ProposalVotePayload) GetProposalId() uint64 { + if x != nil { + return x.ProposalId + } + return 0 +} + +func (x *ProposalVotePayload) GetVote() ProposalVote { + if x != nil { + return x.Vote + } + return ProposalVote_PROPOSAL_VOTE_UNSPECIFIED +} + +var File_sge_legacy_ovm_v1beta_ticket_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_ticket_proto_rawDesc = []byte{ + 0x0a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x20, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2f, 0x76, 0x6f, 0x74, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x62, 0x0a, + 0x1c, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, + 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x1f, 0x0a, + 0x0b, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x01, 0x20, 0x03, + 0x28, 0x09, 0x52, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x73, 0x12, 0x21, + 0x0a, 0x0c, 0x6c, 0x65, 0x61, 0x64, 0x65, 0x72, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0b, 0x6c, 0x65, 0x61, 0x64, 0x65, 0x72, 0x49, 0x6e, 0x64, 0x65, + 0x78, 0x22, 0x6f, 0x0a, 0x13, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x56, 0x6f, 0x74, + 0x65, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x49, 0x64, 0x12, 0x37, 0x0a, 0x04, 0x76, 0x6f, 0x74, + 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x56, 0x6f, 0x74, 0x65, 0x52, 0x04, 0x76, 0x6f, + 0x74, 0x65, 0x42, 0xdf, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x42, 0x0b, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, + 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, + 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x4f, 0x76, 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, + 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, + 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_ticket_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_ticket_proto_rawDescData = file_sge_legacy_ovm_v1beta_ticket_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_ticket_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_ticket_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_ticket_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_ticket_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_ticket_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_ovm_v1beta_ticket_proto_goTypes = []interface{}{ + (*PubkeysChangeProposalPayload)(nil), // 0: sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload + (*ProposalVotePayload)(nil), // 1: sge.legacy.ovm.v1beta.ProposalVotePayload + (ProposalVote)(0), // 2: sge.legacy.ovm.v1beta.ProposalVote +} +var file_sge_legacy_ovm_v1beta_ticket_proto_depIdxs = []int32{ + 2, // 0: sge.legacy.ovm.v1beta.ProposalVotePayload.vote:type_name -> sge.legacy.ovm.v1beta.ProposalVote + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_ticket_proto_init() } +func file_sge_legacy_ovm_v1beta_ticket_proto_init() { + if File_sge_legacy_ovm_v1beta_ticket_proto != nil { + return + } + file_sge_legacy_ovm_v1beta_vote_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PubkeysChangeProposalPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ProposalVotePayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_ticket_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_v1beta_ticket_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_ticket_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_v1beta_ticket_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_ticket_proto = out.File + file_sge_legacy_ovm_v1beta_ticket_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_ticket_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_ticket_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/tx.pulsar.go b/api/sge/legacy/ovm/v1beta/tx.pulsar.go new file mode 100644 index 00000000..bec2e4e0 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/tx.pulsar.go @@ -0,0 +1,3210 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_MsgSubmitPubkeysChangeProposalRequest protoreflect.MessageDescriptor + fd_MsgSubmitPubkeysChangeProposalRequest_creator protoreflect.FieldDescriptor + fd_MsgSubmitPubkeysChangeProposalRequest_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_tx_proto_init() + md_MsgSubmitPubkeysChangeProposalRequest = File_sge_legacy_ovm_v1beta_tx_proto.Messages().ByName("MsgSubmitPubkeysChangeProposalRequest") + fd_MsgSubmitPubkeysChangeProposalRequest_creator = md_MsgSubmitPubkeysChangeProposalRequest.Fields().ByName("creator") + fd_MsgSubmitPubkeysChangeProposalRequest_ticket = md_MsgSubmitPubkeysChangeProposalRequest.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgSubmitPubkeysChangeProposalRequest)(nil) + +type fastReflection_MsgSubmitPubkeysChangeProposalRequest MsgSubmitPubkeysChangeProposalRequest + +func (x *MsgSubmitPubkeysChangeProposalRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgSubmitPubkeysChangeProposalRequest)(x) +} + +func (x *MsgSubmitPubkeysChangeProposalRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType +var _ protoreflect.MessageType = fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType{} + +type fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType struct{} + +func (x fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgSubmitPubkeysChangeProposalRequest)(nil) +} +func (x fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType) New() protoreflect.Message { + return new(fastReflection_MsgSubmitPubkeysChangeProposalRequest) +} +func (x fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitPubkeysChangeProposalRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitPubkeysChangeProposalRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Type() protoreflect.MessageType { + return _fastReflection_MsgSubmitPubkeysChangeProposalRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) New() protoreflect.Message { + return new(fastReflection_MsgSubmitPubkeysChangeProposalRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Interface() protoreflect.ProtoMessage { + return (*MsgSubmitPubkeysChangeProposalRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgSubmitPubkeysChangeProposalRequest_creator, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgSubmitPubkeysChangeProposalRequest_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.creator": + return x.Creator != "" + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.creator": + x.Creator = "" + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.creator": + panic(fmt.Errorf("field creator of message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest is not mutable")) + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgSubmitPubkeysChangeProposalRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitPubkeysChangeProposalRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitPubkeysChangeProposalRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitPubkeysChangeProposalRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitPubkeysChangeProposalRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgSubmitPubkeysChangeProposalResponse protoreflect.MessageDescriptor + fd_MsgSubmitPubkeysChangeProposalResponse_success protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_tx_proto_init() + md_MsgSubmitPubkeysChangeProposalResponse = File_sge_legacy_ovm_v1beta_tx_proto.Messages().ByName("MsgSubmitPubkeysChangeProposalResponse") + fd_MsgSubmitPubkeysChangeProposalResponse_success = md_MsgSubmitPubkeysChangeProposalResponse.Fields().ByName("success") +} + +var _ protoreflect.Message = (*fastReflection_MsgSubmitPubkeysChangeProposalResponse)(nil) + +type fastReflection_MsgSubmitPubkeysChangeProposalResponse MsgSubmitPubkeysChangeProposalResponse + +func (x *MsgSubmitPubkeysChangeProposalResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgSubmitPubkeysChangeProposalResponse)(x) +} + +func (x *MsgSubmitPubkeysChangeProposalResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType{} + +type fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType struct{} + +func (x fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgSubmitPubkeysChangeProposalResponse)(nil) +} +func (x fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgSubmitPubkeysChangeProposalResponse) +} +func (x fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitPubkeysChangeProposalResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSubmitPubkeysChangeProposalResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgSubmitPubkeysChangeProposalResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) New() protoreflect.Message { + return new(fastReflection_MsgSubmitPubkeysChangeProposalResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Interface() protoreflect.ProtoMessage { + return (*MsgSubmitPubkeysChangeProposalResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Success != false { + value := protoreflect.ValueOfBool(x.Success) + if !f(fd_MsgSubmitPubkeysChangeProposalResponse_success, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse.success": + return x.Success != false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse.success": + x.Success = false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse.success": + value := x.Success + return protoreflect.ValueOfBool(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse.success": + x.Success = value.Bool() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse.success": + panic(fmt.Errorf("field success of message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse.success": + return protoreflect.ValueOfBool(false) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgSubmitPubkeysChangeProposalResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgSubmitPubkeysChangeProposalResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Success { + n += 2 + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitPubkeysChangeProposalResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Success { + i-- + if x.Success { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgSubmitPubkeysChangeProposalResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitPubkeysChangeProposalResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSubmitPubkeysChangeProposalResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Success", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.Success = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgVotePubkeysChangeRequest protoreflect.MessageDescriptor + fd_MsgVotePubkeysChangeRequest_creator protoreflect.FieldDescriptor + fd_MsgVotePubkeysChangeRequest_ticket protoreflect.FieldDescriptor + fd_MsgVotePubkeysChangeRequest_voter_key_index protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_tx_proto_init() + md_MsgVotePubkeysChangeRequest = File_sge_legacy_ovm_v1beta_tx_proto.Messages().ByName("MsgVotePubkeysChangeRequest") + fd_MsgVotePubkeysChangeRequest_creator = md_MsgVotePubkeysChangeRequest.Fields().ByName("creator") + fd_MsgVotePubkeysChangeRequest_ticket = md_MsgVotePubkeysChangeRequest.Fields().ByName("ticket") + fd_MsgVotePubkeysChangeRequest_voter_key_index = md_MsgVotePubkeysChangeRequest.Fields().ByName("voter_key_index") +} + +var _ protoreflect.Message = (*fastReflection_MsgVotePubkeysChangeRequest)(nil) + +type fastReflection_MsgVotePubkeysChangeRequest MsgVotePubkeysChangeRequest + +func (x *MsgVotePubkeysChangeRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgVotePubkeysChangeRequest)(x) +} + +func (x *MsgVotePubkeysChangeRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgVotePubkeysChangeRequest_messageType fastReflection_MsgVotePubkeysChangeRequest_messageType +var _ protoreflect.MessageType = fastReflection_MsgVotePubkeysChangeRequest_messageType{} + +type fastReflection_MsgVotePubkeysChangeRequest_messageType struct{} + +func (x fastReflection_MsgVotePubkeysChangeRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgVotePubkeysChangeRequest)(nil) +} +func (x fastReflection_MsgVotePubkeysChangeRequest_messageType) New() protoreflect.Message { + return new(fastReflection_MsgVotePubkeysChangeRequest) +} +func (x fastReflection_MsgVotePubkeysChangeRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgVotePubkeysChangeRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Descriptor() protoreflect.MessageDescriptor { + return md_MsgVotePubkeysChangeRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Type() protoreflect.MessageType { + return _fastReflection_MsgVotePubkeysChangeRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgVotePubkeysChangeRequest) New() protoreflect.Message { + return new(fastReflection_MsgVotePubkeysChangeRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Interface() protoreflect.ProtoMessage { + return (*MsgVotePubkeysChangeRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgVotePubkeysChangeRequest_creator, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgVotePubkeysChangeRequest_ticket, value) { + return + } + } + if x.VoterKeyIndex != uint32(0) { + value := protoreflect.ValueOfUint32(x.VoterKeyIndex) + if !f(fd_MsgVotePubkeysChangeRequest_voter_key_index, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.creator": + return x.Creator != "" + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.ticket": + return x.Ticket != "" + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.voter_key_index": + return x.VoterKeyIndex != uint32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.creator": + x.Creator = "" + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.ticket": + x.Ticket = "" + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.voter_key_index": + x.VoterKeyIndex = uint32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.voter_key_index": + value := x.VoterKeyIndex + return protoreflect.ValueOfUint32(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.ticket": + x.Ticket = value.Interface().(string) + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.voter_key_index": + x.VoterKeyIndex = uint32(value.Uint()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.creator": + panic(fmt.Errorf("field creator of message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest is not mutable")) + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest is not mutable")) + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.voter_key_index": + panic(fmt.Errorf("field voter_key_index of message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgVotePubkeysChangeRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.ticket": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest.voter_key_index": + return protoreflect.ValueOfUint32(uint32(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgVotePubkeysChangeRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgVotePubkeysChangeRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgVotePubkeysChangeRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgVotePubkeysChangeRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgVotePubkeysChangeRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.VoterKeyIndex != 0 { + n += 1 + runtime.Sov(uint64(x.VoterKeyIndex)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgVotePubkeysChangeRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.VoterKeyIndex != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.VoterKeyIndex)) + i-- + dAtA[i] = 0x18 + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgVotePubkeysChangeRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgVotePubkeysChangeRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgVotePubkeysChangeRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VoterKeyIndex", wireType) + } + x.VoterKeyIndex = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.VoterKeyIndex |= uint32(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgVotePubkeysChangeResponse protoreflect.MessageDescriptor + fd_MsgVotePubkeysChangeResponse_success protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_tx_proto_init() + md_MsgVotePubkeysChangeResponse = File_sge_legacy_ovm_v1beta_tx_proto.Messages().ByName("MsgVotePubkeysChangeResponse") + fd_MsgVotePubkeysChangeResponse_success = md_MsgVotePubkeysChangeResponse.Fields().ByName("success") +} + +var _ protoreflect.Message = (*fastReflection_MsgVotePubkeysChangeResponse)(nil) + +type fastReflection_MsgVotePubkeysChangeResponse MsgVotePubkeysChangeResponse + +func (x *MsgVotePubkeysChangeResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgVotePubkeysChangeResponse)(x) +} + +func (x *MsgVotePubkeysChangeResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgVotePubkeysChangeResponse_messageType fastReflection_MsgVotePubkeysChangeResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgVotePubkeysChangeResponse_messageType{} + +type fastReflection_MsgVotePubkeysChangeResponse_messageType struct{} + +func (x fastReflection_MsgVotePubkeysChangeResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgVotePubkeysChangeResponse)(nil) +} +func (x fastReflection_MsgVotePubkeysChangeResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgVotePubkeysChangeResponse) +} +func (x fastReflection_MsgVotePubkeysChangeResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgVotePubkeysChangeResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgVotePubkeysChangeResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgVotePubkeysChangeResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgVotePubkeysChangeResponse) New() protoreflect.Message { + return new(fastReflection_MsgVotePubkeysChangeResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Interface() protoreflect.ProtoMessage { + return (*MsgVotePubkeysChangeResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Success != false { + value := protoreflect.ValueOfBool(x.Success) + if !f(fd_MsgVotePubkeysChangeResponse_success, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse.success": + return x.Success != false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse.success": + x.Success = false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse.success": + value := x.Success + return protoreflect.ValueOfBool(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse.success": + x.Success = value.Bool() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse.success": + panic(fmt.Errorf("field success of message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgVotePubkeysChangeResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse.success": + return protoreflect.ValueOfBool(false) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgVotePubkeysChangeResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgVotePubkeysChangeResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgVotePubkeysChangeResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgVotePubkeysChangeResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgVotePubkeysChangeResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgVotePubkeysChangeResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Success { + n += 2 + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgVotePubkeysChangeResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Success { + i-- + if x.Success { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgVotePubkeysChangeResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgVotePubkeysChangeResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgVotePubkeysChangeResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Success", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.Success = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_legacy_ovm_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.legacy.ovm.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.legacy.ovm.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.legacy.ovm.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.ovm.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.legacy.ovm.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_legacy_ovm_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgPubkeysChangeProposalRequest is the type of request for modification of +// public keys. +type MsgSubmitPubkeysChangeProposalRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the account address of the creator. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,2,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgSubmitPubkeysChangeProposalRequest) Reset() { + *x = MsgSubmitPubkeysChangeProposalRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgSubmitPubkeysChangeProposalRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgSubmitPubkeysChangeProposalRequest) ProtoMessage() {} + +// Deprecated: Use MsgSubmitPubkeysChangeProposalRequest.ProtoReflect.Descriptor instead. +func (*MsgSubmitPubkeysChangeProposalRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgSubmitPubkeysChangeProposalRequest) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgSubmitPubkeysChangeProposalRequest) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgPubkeysChangeProposalResponse is the type of response for modification of +// public keys. +type MsgSubmitPubkeysChangeProposalResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` +} + +func (x *MsgSubmitPubkeysChangeProposalResponse) Reset() { + *x = MsgSubmitPubkeysChangeProposalResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgSubmitPubkeysChangeProposalResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgSubmitPubkeysChangeProposalResponse) ProtoMessage() {} + +// Deprecated: Use MsgSubmitPubkeysChangeProposalResponse.ProtoReflect.Descriptor instead. +func (*MsgSubmitPubkeysChangeProposalResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +func (x *MsgSubmitPubkeysChangeProposalResponse) GetSuccess() bool { + if x != nil { + return x.Success + } + return false +} + +// MsgVotePubkeysChangeRequest is the type of request to vote on the +// modification of public keys proposal. +type MsgVotePubkeysChangeRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the account address of the creator. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,2,opt,name=ticket,proto3" json:"ticket,omitempty"` + // voter_key_index is the public key index of the voter in the current list + // of public keys in the vault. + VoterKeyIndex uint32 `protobuf:"varint,3,opt,name=voter_key_index,json=voterKeyIndex,proto3" json:"voter_key_index,omitempty"` +} + +func (x *MsgVotePubkeysChangeRequest) Reset() { + *x = MsgVotePubkeysChangeRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgVotePubkeysChangeRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgVotePubkeysChangeRequest) ProtoMessage() {} + +// Deprecated: Use MsgVotePubkeysChangeRequest.ProtoReflect.Descriptor instead. +func (*MsgVotePubkeysChangeRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_tx_proto_rawDescGZIP(), []int{2} +} + +func (x *MsgVotePubkeysChangeRequest) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgVotePubkeysChangeRequest) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +func (x *MsgVotePubkeysChangeRequest) GetVoterKeyIndex() uint32 { + if x != nil { + return x.VoterKeyIndex + } + return 0 +} + +// MsgVotePubkeysChangeResponse is the type of response vote for public keys +// modification. +type MsgVotePubkeysChangeResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` +} + +func (x *MsgVotePubkeysChangeResponse) Reset() { + *x = MsgVotePubkeysChangeResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgVotePubkeysChangeResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgVotePubkeysChangeResponse) ProtoMessage() {} + +// Deprecated: Use MsgVotePubkeysChangeResponse.ProtoReflect.Descriptor instead. +func (*MsgVotePubkeysChangeResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_tx_proto_rawDescGZIP(), []int{3} +} + +func (x *MsgVotePubkeysChangeResponse) GetSuccess() bool { + if x != nil { + return x.Success + } + return false +} + +// MsgUpdateParams is the Msg/UpdateParams request type. +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/bet parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_tx_proto_rawDescGZIP(), []int{4} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_tx_proto_rawDescGZIP(), []int{5} +} + +var File_sge_legacy_ovm_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x1e, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, + 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, + 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x22, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x81, 0x01, 0x0a, 0x25, 0x4d, 0x73, 0x67, + 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, 0x0c, + 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x42, 0x0a, 0x26, + 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, + 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, + 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, + 0x22, 0x9f, 0x01, 0x0a, 0x1b, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x50, 0x75, 0x62, 0x6b, + 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x26, 0x0a, 0x0f, + 0x76, 0x6f, 0x74, 0x65, 0x72, 0x5f, 0x6b, 0x65, 0x79, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0d, 0x76, 0x6f, 0x74, 0x65, 0x72, 0x4b, 0x65, 0x79, 0x49, + 0x6e, 0x64, 0x65, 0x78, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, + 0x6f, 0x72, 0x22, 0x38, 0x0a, 0x1c, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x50, 0x75, 0x62, + 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x22, 0xb0, 0x01, 0x0a, + 0x0f, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, + 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x40, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, + 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x3a, 0x23, 0xd2, 0xb4, 0x2d, 0x11, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, + 0x31, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, + 0x30, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x3a, 0x15, 0xd2, 0xb4, 0x2d, 0x11, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, + 0x31, 0x32, 0xae, 0x03, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x9f, 0x01, 0x0a, 0x1b, 0x53, 0x75, + 0x62, 0x6d, 0x69, 0x74, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, + 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x3c, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x75, 0x62, 0x6b, 0x65, + 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, + 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x81, 0x01, 0x0a, 0x11, + 0x56, 0x6f, 0x74, 0x65, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, + 0x65, 0x12, 0x32, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, + 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, + 0x65, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, + 0x67, 0x56, 0x6f, 0x74, 0x65, 0x50, 0x75, 0x62, 0x6b, 0x65, 0x79, 0x73, 0x43, 0x68, 0x61, 0x6e, + 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, + 0x80, 0x01, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x12, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, + 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x2e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x18, 0xca, 0xb4, 0x2d, 0x11, 0x73, 0x67, + 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x88, + 0x02, 0x01, 0x42, 0xdb, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, + 0x4f, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x4f, + 0x76, 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x15, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, + 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_tx_proto_rawDescData = file_sge_legacy_ovm_v1beta_tx_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_tx_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_tx_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 6) +var file_sge_legacy_ovm_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgSubmitPubkeysChangeProposalRequest)(nil), // 0: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest + (*MsgSubmitPubkeysChangeProposalResponse)(nil), // 1: sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse + (*MsgVotePubkeysChangeRequest)(nil), // 2: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest + (*MsgVotePubkeysChangeResponse)(nil), // 3: sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse + (*MsgUpdateParams)(nil), // 4: sge.legacy.ovm.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 5: sge.legacy.ovm.v1beta.MsgUpdateParamsResponse + (*Params)(nil), // 6: sge.legacy.ovm.v1beta.Params +} +var file_sge_legacy_ovm_v1beta_tx_proto_depIdxs = []int32{ + 6, // 0: sge.legacy.ovm.v1beta.MsgUpdateParams.params:type_name -> sge.legacy.ovm.v1beta.Params + 0, // 1: sge.legacy.ovm.v1beta.Msg.SubmitPubkeysChangeProposal:input_type -> sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest + 2, // 2: sge.legacy.ovm.v1beta.Msg.VotePubkeysChange:input_type -> sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest + 4, // 3: sge.legacy.ovm.v1beta.Msg.UpdateParams:input_type -> sge.legacy.ovm.v1beta.MsgUpdateParams + 1, // 4: sge.legacy.ovm.v1beta.Msg.SubmitPubkeysChangeProposal:output_type -> sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse + 3, // 5: sge.legacy.ovm.v1beta.Msg.VotePubkeysChange:output_type -> sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse + 5, // 6: sge.legacy.ovm.v1beta.Msg.UpdateParams:output_type -> sge.legacy.ovm.v1beta.MsgUpdateParamsResponse + 4, // [4:7] is the sub-list for method output_type + 1, // [1:4] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_tx_proto_init() } +func file_sge_legacy_ovm_v1beta_tx_proto_init() { + if File_sge_legacy_ovm_v1beta_tx_proto != nil { + return + } + file_sge_legacy_ovm_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgSubmitPubkeysChangeProposalRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgSubmitPubkeysChangeProposalResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgVotePubkeysChangeRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgVotePubkeysChangeResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_ovm_v1beta_tx_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 6, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_ovm_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_legacy_ovm_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_tx_proto = out.File + file_sge_legacy_ovm_v1beta_tx_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_tx_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/legacy/ovm/v1beta/tx_grpc.pb.go b/api/sge/legacy/ovm/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..64381158 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/tx_grpc.pb.go @@ -0,0 +1,204 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/ovm/v1beta/tx.proto + +package ovmv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_SubmitPubkeysChangeProposal_FullMethodName = "/sge.legacy.ovm.v1beta.Msg/SubmitPubkeysChangeProposal" + Msg_VotePubkeysChange_FullMethodName = "/sge.legacy.ovm.v1beta.Msg/VotePubkeysChange" + Msg_UpdateParams_FullMethodName = "/sge.legacy.ovm.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // Deprecated: Do not use. + // PubkeysChangeProposal defines a method to submit a proposal for changing + // the allowed public keys. + SubmitPubkeysChangeProposal(ctx context.Context, in *MsgSubmitPubkeysChangeProposalRequest, opts ...grpc.CallOption) (*MsgSubmitPubkeysChangeProposalResponse, error) + // Deprecated: Do not use. + // VotePubkeysChange defines a method to vote for a proposal for changing the + // allowed public keys. + VotePubkeysChange(ctx context.Context, in *MsgVotePubkeysChangeRequest, opts ...grpc.CallOption) (*MsgVotePubkeysChangeResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/ovm module + // parameters. The authority is defined in the keeper. + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +// Deprecated: Do not use. +func (c *msgClient) SubmitPubkeysChangeProposal(ctx context.Context, in *MsgSubmitPubkeysChangeProposalRequest, opts ...grpc.CallOption) (*MsgSubmitPubkeysChangeProposalResponse, error) { + out := new(MsgSubmitPubkeysChangeProposalResponse) + err := c.cc.Invoke(ctx, Msg_SubmitPubkeysChangeProposal_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) VotePubkeysChange(ctx context.Context, in *MsgVotePubkeysChangeRequest, opts ...grpc.CallOption) (*MsgVotePubkeysChangeResponse, error) { + out := new(MsgVotePubkeysChangeResponse) + err := c.cc.Invoke(ctx, Msg_VotePubkeysChange_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // Deprecated: Do not use. + // PubkeysChangeProposal defines a method to submit a proposal for changing + // the allowed public keys. + SubmitPubkeysChangeProposal(context.Context, *MsgSubmitPubkeysChangeProposalRequest) (*MsgSubmitPubkeysChangeProposalResponse, error) + // Deprecated: Do not use. + // VotePubkeysChange defines a method to vote for a proposal for changing the + // allowed public keys. + VotePubkeysChange(context.Context, *MsgVotePubkeysChangeRequest) (*MsgVotePubkeysChangeResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/ovm module + // parameters. The authority is defined in the keeper. + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) SubmitPubkeysChangeProposal(context.Context, *MsgSubmitPubkeysChangeProposalRequest) (*MsgSubmitPubkeysChangeProposalResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SubmitPubkeysChangeProposal not implemented") +} +func (UnimplementedMsgServer) VotePubkeysChange(context.Context, *MsgVotePubkeysChangeRequest) (*MsgVotePubkeysChangeResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method VotePubkeysChange not implemented") +} +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_SubmitPubkeysChangeProposal_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgSubmitPubkeysChangeProposalRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).SubmitPubkeysChangeProposal(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_SubmitPubkeysChangeProposal_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).SubmitPubkeysChangeProposal(ctx, req.(*MsgSubmitPubkeysChangeProposalRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_VotePubkeysChange_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgVotePubkeysChangeRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).VotePubkeysChange(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_VotePubkeysChange_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).VotePubkeysChange(ctx, req.(*MsgVotePubkeysChangeRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.ovm.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "SubmitPubkeysChangeProposal", + Handler: _Msg_SubmitPubkeysChangeProposal_Handler, + }, + { + MethodName: "VotePubkeysChange", + Handler: _Msg_VotePubkeysChange_Handler, + }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/ovm/v1beta/tx.proto", +} diff --git a/api/sge/legacy/ovm/v1beta/vote.pulsar.go b/api/sge/legacy/ovm/v1beta/vote.pulsar.go new file mode 100644 index 00000000..8c2cf4c7 --- /dev/null +++ b/api/sge/legacy/ovm/v1beta/vote.pulsar.go @@ -0,0 +1,695 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package ovmv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Vote protoreflect.MessageDescriptor + fd_Vote_public_key protoreflect.FieldDescriptor + fd_Vote_vote protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_ovm_v1beta_vote_proto_init() + md_Vote = File_sge_legacy_ovm_v1beta_vote_proto.Messages().ByName("Vote") + fd_Vote_public_key = md_Vote.Fields().ByName("public_key") + fd_Vote_vote = md_Vote.Fields().ByName("vote") +} + +var _ protoreflect.Message = (*fastReflection_Vote)(nil) + +type fastReflection_Vote Vote + +func (x *Vote) ProtoReflect() protoreflect.Message { + return (*fastReflection_Vote)(x) +} + +func (x *Vote) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_ovm_v1beta_vote_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Vote_messageType fastReflection_Vote_messageType +var _ protoreflect.MessageType = fastReflection_Vote_messageType{} + +type fastReflection_Vote_messageType struct{} + +func (x fastReflection_Vote_messageType) Zero() protoreflect.Message { + return (*fastReflection_Vote)(nil) +} +func (x fastReflection_Vote_messageType) New() protoreflect.Message { + return new(fastReflection_Vote) +} +func (x fastReflection_Vote_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Vote +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Vote) Descriptor() protoreflect.MessageDescriptor { + return md_Vote +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Vote) Type() protoreflect.MessageType { + return _fastReflection_Vote_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Vote) New() protoreflect.Message { + return new(fastReflection_Vote) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Vote) Interface() protoreflect.ProtoMessage { + return (*Vote)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Vote) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.PublicKey != "" { + value := protoreflect.ValueOfString(x.PublicKey) + if !f(fd_Vote_public_key, value) { + return + } + } + if x.Vote != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Vote)) + if !f(fd_Vote_vote, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Vote) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.Vote.public_key": + return x.PublicKey != "" + case "sge.legacy.ovm.v1beta.Vote.vote": + return x.Vote != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Vote")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Vote does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Vote) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.Vote.public_key": + x.PublicKey = "" + case "sge.legacy.ovm.v1beta.Vote.vote": + x.Vote = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Vote")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Vote does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Vote) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.ovm.v1beta.Vote.public_key": + value := x.PublicKey + return protoreflect.ValueOfString(value) + case "sge.legacy.ovm.v1beta.Vote.vote": + value := x.Vote + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Vote")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Vote does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Vote) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.Vote.public_key": + x.PublicKey = value.Interface().(string) + case "sge.legacy.ovm.v1beta.Vote.vote": + x.Vote = (ProposalVote)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Vote")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Vote does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Vote) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.Vote.public_key": + panic(fmt.Errorf("field public_key of message sge.legacy.ovm.v1beta.Vote is not mutable")) + case "sge.legacy.ovm.v1beta.Vote.vote": + panic(fmt.Errorf("field vote of message sge.legacy.ovm.v1beta.Vote is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Vote")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Vote does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Vote) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.ovm.v1beta.Vote.public_key": + return protoreflect.ValueOfString("") + case "sge.legacy.ovm.v1beta.Vote.vote": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.ovm.v1beta.Vote")) + } + panic(fmt.Errorf("message sge.legacy.ovm.v1beta.Vote does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Vote) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.ovm.v1beta.Vote", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Vote) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Vote) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Vote) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Vote) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Vote) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.PublicKey) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Vote != 0 { + n += 1 + runtime.Sov(uint64(x.Vote)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Vote) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Vote != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Vote)) + i-- + dAtA[i] = 0x10 + } + if len(x.PublicKey) > 0 { + i -= len(x.PublicKey) + copy(dAtA[i:], x.PublicKey) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PublicKey))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Vote) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Vote: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Vote: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PublicKey", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PublicKey = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Vote", wireType) + } + x.Vote = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Vote |= ProposalVote(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/ovm/v1beta/vote.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// ProposalVote is the enum type for the proposal vote. +type ProposalVote int32 + +const ( + // unchosen value + ProposalVote_PROPOSAL_VOTE_UNSPECIFIED ProposalVote = 0 + // no + ProposalVote_PROPOSAL_VOTE_NO ProposalVote = 1 + // yes + ProposalVote_PROPOSAL_VOTE_YES ProposalVote = 2 +) + +// Enum value maps for ProposalVote. +var ( + ProposalVote_name = map[int32]string{ + 0: "PROPOSAL_VOTE_UNSPECIFIED", + 1: "PROPOSAL_VOTE_NO", + 2: "PROPOSAL_VOTE_YES", + } + ProposalVote_value = map[string]int32{ + "PROPOSAL_VOTE_UNSPECIFIED": 0, + "PROPOSAL_VOTE_NO": 1, + "PROPOSAL_VOTE_YES": 2, + } +) + +func (x ProposalVote) Enum() *ProposalVote { + p := new(ProposalVote) + *p = x + return p +} + +func (x ProposalVote) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (ProposalVote) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_ovm_v1beta_vote_proto_enumTypes[0].Descriptor() +} + +func (ProposalVote) Type() protoreflect.EnumType { + return &file_sge_legacy_ovm_v1beta_vote_proto_enumTypes[0] +} + +func (x ProposalVote) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use ProposalVote.Descriptor instead. +func (ProposalVote) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_vote_proto_rawDescGZIP(), []int{0} +} + +// Vote is the type for the proposal vote. +type Vote struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // public_key is the public key of the voter. + PublicKey string `protobuf:"bytes,1,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` + // vote is the vote enum value. + Vote ProposalVote `protobuf:"varint,2,opt,name=vote,proto3,enum=sge.legacy.ovm.v1beta.ProposalVote" json:"vote,omitempty"` +} + +func (x *Vote) Reset() { + *x = Vote{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_ovm_v1beta_vote_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Vote) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Vote) ProtoMessage() {} + +// Deprecated: Use Vote.ProtoReflect.Descriptor instead. +func (*Vote) Descriptor() ([]byte, []int) { + return file_sge_legacy_ovm_v1beta_vote_proto_rawDescGZIP(), []int{0} +} + +func (x *Vote) GetPublicKey() string { + if x != nil { + return x.PublicKey + } + return "" +} + +func (x *Vote) GetVote() ProposalVote { + if x != nil { + return x.Vote + } + return ProposalVote_PROPOSAL_VOTE_UNSPECIFIED +} + +var File_sge_legacy_ovm_v1beta_vote_proto protoreflect.FileDescriptor + +var file_sge_legacy_ovm_v1beta_vote_proto_rawDesc = []byte{ + 0x0a, 0x20, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, + 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x76, 0x6f, 0x74, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x12, 0x15, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, + 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x22, 0x5e, 0x0a, 0x04, 0x56, 0x6f, 0x74, + 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, + 0x12, 0x37, 0x0a, 0x04, 0x76, 0x6f, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x23, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x56, + 0x6f, 0x74, 0x65, 0x52, 0x04, 0x76, 0x6f, 0x74, 0x65, 0x2a, 0x5a, 0x0a, 0x0c, 0x50, 0x72, 0x6f, + 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x56, 0x6f, 0x74, 0x65, 0x12, 0x1d, 0x0a, 0x19, 0x50, 0x52, 0x4f, + 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, + 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x14, 0x0a, 0x10, 0x50, 0x52, 0x4f, 0x50, + 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4e, 0x4f, 0x10, 0x01, 0x12, 0x15, + 0x0a, 0x11, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x56, 0x4f, 0x54, 0x45, 0x5f, + 0x59, 0x45, 0x53, 0x10, 0x02, 0x42, 0xdd, 0x01, 0x0a, 0x19, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x6f, 0x76, 0x6d, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x42, 0x09, 0x56, 0x6f, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, + 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, + 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, + 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x6f, 0x76, 0x6d, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6f, 0x76, 0x6d, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x4f, 0xaa, 0x02, 0x15, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x4f, 0x76, 0x6d, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, + 0x15, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x21, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x4f, 0x76, 0x6d, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, + 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x18, 0x53, 0x67, 0x65, + 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x4f, 0x76, 0x6d, 0x3a, 0x3a, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_ovm_v1beta_vote_proto_rawDescOnce sync.Once + file_sge_legacy_ovm_v1beta_vote_proto_rawDescData = file_sge_legacy_ovm_v1beta_vote_proto_rawDesc +) + +func file_sge_legacy_ovm_v1beta_vote_proto_rawDescGZIP() []byte { + file_sge_legacy_ovm_v1beta_vote_proto_rawDescOnce.Do(func() { + file_sge_legacy_ovm_v1beta_vote_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_ovm_v1beta_vote_proto_rawDescData) + }) + return file_sge_legacy_ovm_v1beta_vote_proto_rawDescData +} + +var file_sge_legacy_ovm_v1beta_vote_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_sge_legacy_ovm_v1beta_vote_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_ovm_v1beta_vote_proto_goTypes = []interface{}{ + (ProposalVote)(0), // 0: sge.legacy.ovm.v1beta.ProposalVote + (*Vote)(nil), // 1: sge.legacy.ovm.v1beta.Vote +} +var file_sge_legacy_ovm_v1beta_vote_proto_depIdxs = []int32{ + 0, // 0: sge.legacy.ovm.v1beta.Vote.vote:type_name -> sge.legacy.ovm.v1beta.ProposalVote + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_ovm_v1beta_vote_proto_init() } +func file_sge_legacy_ovm_v1beta_vote_proto_init() { + if File_sge_legacy_ovm_v1beta_vote_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_ovm_v1beta_vote_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Vote); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_ovm_v1beta_vote_proto_rawDesc, + NumEnums: 1, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_ovm_v1beta_vote_proto_goTypes, + DependencyIndexes: file_sge_legacy_ovm_v1beta_vote_proto_depIdxs, + EnumInfos: file_sge_legacy_ovm_v1beta_vote_proto_enumTypes, + MessageInfos: file_sge_legacy_ovm_v1beta_vote_proto_msgTypes, + }.Build() + File_sge_legacy_ovm_v1beta_vote_proto = out.File + file_sge_legacy_ovm_v1beta_vote_proto_rawDesc = nil + file_sge_legacy_ovm_v1beta_vote_proto_goTypes = nil + file_sge_legacy_ovm_v1beta_vote_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/module/v1/module.pulsar.go b/api/sge/legacy/reward/module/v1/module.pulsar.go new file mode 100644 index 00000000..8895402e --- /dev/null +++ b/api/sge/legacy/reward/module/v1/module.pulsar.go @@ -0,0 +1,656 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_module_v1_module_proto_init() + md_Module = File_sge_legacy_reward_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.legacy.reward.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.reward.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.legacy.reward.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.reward.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.reward.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.legacy.reward.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.reward.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.legacy.reward.module.v1.Module is not mutable")) + case "sge.legacy.reward.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.legacy.reward.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.reward.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.reward.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the reward module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_legacy_reward_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x28, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x6f, + 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1b, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x6d, 0x6f, + 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x6a, 0x0a, 0x06, 0x4d, 0x6f, 0x64, + 0x75, 0x6c, 0x65, 0x12, 0x2c, 0x0a, 0x12, 0x66, 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, + 0x63, 0x74, 0x6f, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x10, 0x66, 0x65, 0x65, 0x43, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, + 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, + 0x14, 0xba, 0xc0, 0x96, 0xda, 0x01, 0x0e, 0x0a, 0x0c, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x84, 0x02, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x43, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, + 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, + 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, 0x31, 0xa2, 0x02, 0x04, + 0x53, 0x4c, 0x52, 0x4d, 0xaa, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, + 0x56, 0x31, 0xca, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, + 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, + 0xe2, 0x02, 0x27, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, + 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1f, 0x53, 0x67, 0x65, + 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_module_v1_module_proto_rawDescOnce sync.Once + file_sge_legacy_reward_module_v1_module_proto_rawDescData = file_sge_legacy_reward_module_v1_module_proto_rawDesc +) + +func file_sge_legacy_reward_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_module_v1_module_proto_rawDescData) + }) + return file_sge_legacy_reward_module_v1_module_proto_rawDescData +} + +var file_sge_legacy_reward_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_reward_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.legacy.reward.module.v1.Module +} +var file_sge_legacy_reward_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_module_v1_module_proto_init() } +func file_sge_legacy_reward_module_v1_module_proto_init() { + if File_sge_legacy_reward_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_module_v1_module_proto_msgTypes, + }.Build() + File_sge_legacy_reward_module_v1_module_proto = out.File + file_sge_legacy_reward_module_v1_module_proto_rawDesc = nil + file_sge_legacy_reward_module_v1_module_proto_goTypes = nil + file_sge_legacy_reward_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/authz.pulsar.go b/api/sge/legacy/reward/v1beta/authz.pulsar.go new file mode 100644 index 00000000..55473a40 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/authz.pulsar.go @@ -0,0 +1,1533 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_CreateCampaignAuthorization protoreflect.MessageDescriptor + fd_CreateCampaignAuthorization_spend_limit protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_authz_proto_init() + md_CreateCampaignAuthorization = File_sge_legacy_reward_v1beta_authz_proto.Messages().ByName("CreateCampaignAuthorization") + fd_CreateCampaignAuthorization_spend_limit = md_CreateCampaignAuthorization.Fields().ByName("spend_limit") +} + +var _ protoreflect.Message = (*fastReflection_CreateCampaignAuthorization)(nil) + +type fastReflection_CreateCampaignAuthorization CreateCampaignAuthorization + +func (x *CreateCampaignAuthorization) ProtoReflect() protoreflect.Message { + return (*fastReflection_CreateCampaignAuthorization)(x) +} + +func (x *CreateCampaignAuthorization) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_authz_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_CreateCampaignAuthorization_messageType fastReflection_CreateCampaignAuthorization_messageType +var _ protoreflect.MessageType = fastReflection_CreateCampaignAuthorization_messageType{} + +type fastReflection_CreateCampaignAuthorization_messageType struct{} + +func (x fastReflection_CreateCampaignAuthorization_messageType) Zero() protoreflect.Message { + return (*fastReflection_CreateCampaignAuthorization)(nil) +} +func (x fastReflection_CreateCampaignAuthorization_messageType) New() protoreflect.Message { + return new(fastReflection_CreateCampaignAuthorization) +} +func (x fastReflection_CreateCampaignAuthorization_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_CreateCampaignAuthorization +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_CreateCampaignAuthorization) Descriptor() protoreflect.MessageDescriptor { + return md_CreateCampaignAuthorization +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_CreateCampaignAuthorization) Type() protoreflect.MessageType { + return _fastReflection_CreateCampaignAuthorization_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_CreateCampaignAuthorization) New() protoreflect.Message { + return new(fastReflection_CreateCampaignAuthorization) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_CreateCampaignAuthorization) Interface() protoreflect.ProtoMessage { + return (*CreateCampaignAuthorization)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_CreateCampaignAuthorization) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.SpendLimit != "" { + value := protoreflect.ValueOfString(x.SpendLimit) + if !f(fd_CreateCampaignAuthorization_spend_limit, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_CreateCampaignAuthorization) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignAuthorization.spend_limit": + return x.SpendLimit != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignAuthorization) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignAuthorization.spend_limit": + x.SpendLimit = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_CreateCampaignAuthorization) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignAuthorization.spend_limit": + value := x.SpendLimit + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignAuthorization does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignAuthorization) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignAuthorization.spend_limit": + x.SpendLimit = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignAuthorization) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignAuthorization.spend_limit": + panic(fmt.Errorf("field spend_limit of message sge.legacy.reward.v1beta.CreateCampaignAuthorization is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_CreateCampaignAuthorization) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignAuthorization.spend_limit": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_CreateCampaignAuthorization) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.CreateCampaignAuthorization", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_CreateCampaignAuthorization) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignAuthorization) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_CreateCampaignAuthorization) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_CreateCampaignAuthorization) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*CreateCampaignAuthorization) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.SpendLimit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*CreateCampaignAuthorization) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.SpendLimit) > 0 { + i -= len(x.SpendLimit) + copy(dAtA[i:], x.SpendLimit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SpendLimit))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*CreateCampaignAuthorization) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CreateCampaignAuthorization: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CreateCampaignAuthorization: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SpendLimit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SpendLimit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_UpdateCampaignAuthorization protoreflect.MessageDescriptor + fd_UpdateCampaignAuthorization_spend_limit protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_authz_proto_init() + md_UpdateCampaignAuthorization = File_sge_legacy_reward_v1beta_authz_proto.Messages().ByName("UpdateCampaignAuthorization") + fd_UpdateCampaignAuthorization_spend_limit = md_UpdateCampaignAuthorization.Fields().ByName("spend_limit") +} + +var _ protoreflect.Message = (*fastReflection_UpdateCampaignAuthorization)(nil) + +type fastReflection_UpdateCampaignAuthorization UpdateCampaignAuthorization + +func (x *UpdateCampaignAuthorization) ProtoReflect() protoreflect.Message { + return (*fastReflection_UpdateCampaignAuthorization)(x) +} + +func (x *UpdateCampaignAuthorization) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_authz_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_UpdateCampaignAuthorization_messageType fastReflection_UpdateCampaignAuthorization_messageType +var _ protoreflect.MessageType = fastReflection_UpdateCampaignAuthorization_messageType{} + +type fastReflection_UpdateCampaignAuthorization_messageType struct{} + +func (x fastReflection_UpdateCampaignAuthorization_messageType) Zero() protoreflect.Message { + return (*fastReflection_UpdateCampaignAuthorization)(nil) +} +func (x fastReflection_UpdateCampaignAuthorization_messageType) New() protoreflect.Message { + return new(fastReflection_UpdateCampaignAuthorization) +} +func (x fastReflection_UpdateCampaignAuthorization_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_UpdateCampaignAuthorization +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_UpdateCampaignAuthorization) Descriptor() protoreflect.MessageDescriptor { + return md_UpdateCampaignAuthorization +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_UpdateCampaignAuthorization) Type() protoreflect.MessageType { + return _fastReflection_UpdateCampaignAuthorization_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_UpdateCampaignAuthorization) New() protoreflect.Message { + return new(fastReflection_UpdateCampaignAuthorization) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_UpdateCampaignAuthorization) Interface() protoreflect.ProtoMessage { + return (*UpdateCampaignAuthorization)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_UpdateCampaignAuthorization) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.SpendLimit != "" { + value := protoreflect.ValueOfString(x.SpendLimit) + if !f(fd_UpdateCampaignAuthorization_spend_limit, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_UpdateCampaignAuthorization) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignAuthorization.spend_limit": + return x.SpendLimit != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignAuthorization) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignAuthorization.spend_limit": + x.SpendLimit = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_UpdateCampaignAuthorization) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignAuthorization.spend_limit": + value := x.SpendLimit + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignAuthorization does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignAuthorization) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignAuthorization.spend_limit": + x.SpendLimit = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignAuthorization) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignAuthorization.spend_limit": + panic(fmt.Errorf("field spend_limit of message sge.legacy.reward.v1beta.UpdateCampaignAuthorization is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_UpdateCampaignAuthorization) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignAuthorization.spend_limit": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_UpdateCampaignAuthorization) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.UpdateCampaignAuthorization", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_UpdateCampaignAuthorization) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignAuthorization) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_UpdateCampaignAuthorization) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_UpdateCampaignAuthorization) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*UpdateCampaignAuthorization) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.SpendLimit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*UpdateCampaignAuthorization) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.SpendLimit) > 0 { + i -= len(x.SpendLimit) + copy(dAtA[i:], x.SpendLimit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SpendLimit))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*UpdateCampaignAuthorization) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: UpdateCampaignAuthorization: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: UpdateCampaignAuthorization: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SpendLimit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SpendLimit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_WithdrawCampaignAuthorization protoreflect.MessageDescriptor + fd_WithdrawCampaignAuthorization_withdraw_limit protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_authz_proto_init() + md_WithdrawCampaignAuthorization = File_sge_legacy_reward_v1beta_authz_proto.Messages().ByName("WithdrawCampaignAuthorization") + fd_WithdrawCampaignAuthorization_withdraw_limit = md_WithdrawCampaignAuthorization.Fields().ByName("withdraw_limit") +} + +var _ protoreflect.Message = (*fastReflection_WithdrawCampaignAuthorization)(nil) + +type fastReflection_WithdrawCampaignAuthorization WithdrawCampaignAuthorization + +func (x *WithdrawCampaignAuthorization) ProtoReflect() protoreflect.Message { + return (*fastReflection_WithdrawCampaignAuthorization)(x) +} + +func (x *WithdrawCampaignAuthorization) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_authz_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_WithdrawCampaignAuthorization_messageType fastReflection_WithdrawCampaignAuthorization_messageType +var _ protoreflect.MessageType = fastReflection_WithdrawCampaignAuthorization_messageType{} + +type fastReflection_WithdrawCampaignAuthorization_messageType struct{} + +func (x fastReflection_WithdrawCampaignAuthorization_messageType) Zero() protoreflect.Message { + return (*fastReflection_WithdrawCampaignAuthorization)(nil) +} +func (x fastReflection_WithdrawCampaignAuthorization_messageType) New() protoreflect.Message { + return new(fastReflection_WithdrawCampaignAuthorization) +} +func (x fastReflection_WithdrawCampaignAuthorization_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawCampaignAuthorization +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_WithdrawCampaignAuthorization) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawCampaignAuthorization +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_WithdrawCampaignAuthorization) Type() protoreflect.MessageType { + return _fastReflection_WithdrawCampaignAuthorization_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_WithdrawCampaignAuthorization) New() protoreflect.Message { + return new(fastReflection_WithdrawCampaignAuthorization) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_WithdrawCampaignAuthorization) Interface() protoreflect.ProtoMessage { + return (*WithdrawCampaignAuthorization)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_WithdrawCampaignAuthorization) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.WithdrawLimit != "" { + value := protoreflect.ValueOfString(x.WithdrawLimit) + if !f(fd_WithdrawCampaignAuthorization_withdraw_limit, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_WithdrawCampaignAuthorization) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawCampaignAuthorization.withdraw_limit": + return x.WithdrawLimit != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawCampaignAuthorization) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawCampaignAuthorization.withdraw_limit": + x.WithdrawLimit = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_WithdrawCampaignAuthorization) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.WithdrawCampaignAuthorization.withdraw_limit": + value := x.WithdrawLimit + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawCampaignAuthorization does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawCampaignAuthorization) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawCampaignAuthorization.withdraw_limit": + x.WithdrawLimit = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawCampaignAuthorization) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawCampaignAuthorization.withdraw_limit": + panic(fmt.Errorf("field withdraw_limit of message sge.legacy.reward.v1beta.WithdrawCampaignAuthorization is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_WithdrawCampaignAuthorization) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawCampaignAuthorization.withdraw_limit": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawCampaignAuthorization")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawCampaignAuthorization does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_WithdrawCampaignAuthorization) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.WithdrawCampaignAuthorization", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_WithdrawCampaignAuthorization) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawCampaignAuthorization) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_WithdrawCampaignAuthorization) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_WithdrawCampaignAuthorization) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*WithdrawCampaignAuthorization) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.WithdrawLimit) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*WithdrawCampaignAuthorization) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.WithdrawLimit) > 0 { + i -= len(x.WithdrawLimit) + copy(dAtA[i:], x.WithdrawLimit) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.WithdrawLimit))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*WithdrawCampaignAuthorization) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawCampaignAuthorization: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawCampaignAuthorization: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WithdrawLimit", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.WithdrawLimit = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/authz.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// CreateCampaignAuthorization allows the grantee to spend up to spend_limit +// from the granter's account for create campaign. +type CreateCampaignAuthorization struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + SpendLimit string `protobuf:"bytes,1,opt,name=spend_limit,json=spendLimit,proto3" json:"spend_limit,omitempty"` +} + +func (x *CreateCampaignAuthorization) Reset() { + *x = CreateCampaignAuthorization{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_authz_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CreateCampaignAuthorization) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CreateCampaignAuthorization) ProtoMessage() {} + +// Deprecated: Use CreateCampaignAuthorization.ProtoReflect.Descriptor instead. +func (*CreateCampaignAuthorization) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_authz_proto_rawDescGZIP(), []int{0} +} + +func (x *CreateCampaignAuthorization) GetSpendLimit() string { + if x != nil { + return x.SpendLimit + } + return "" +} + +// UpdateCampaignAuthorization allows the grantee to spend up to spend_limit +// from the granter's account for update campaign. +type UpdateCampaignAuthorization struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + SpendLimit string `protobuf:"bytes,1,opt,name=spend_limit,json=spendLimit,proto3" json:"spend_limit,omitempty"` +} + +func (x *UpdateCampaignAuthorization) Reset() { + *x = UpdateCampaignAuthorization{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_authz_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdateCampaignAuthorization) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdateCampaignAuthorization) ProtoMessage() {} + +// Deprecated: Use UpdateCampaignAuthorization.ProtoReflect.Descriptor instead. +func (*UpdateCampaignAuthorization) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_authz_proto_rawDescGZIP(), []int{1} +} + +func (x *UpdateCampaignAuthorization) GetSpendLimit() string { + if x != nil { + return x.SpendLimit + } + return "" +} + +// WithdrawCampaignAuthorization allows the grantee to withdraw remaining +// pool balance of the campaign from the granter's account. +type WithdrawCampaignAuthorization struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // withdraw_limit is the maximum limit of the withdrawal by authorization. + WithdrawLimit string `protobuf:"bytes,1,opt,name=withdraw_limit,json=withdrawLimit,proto3" json:"withdraw_limit,omitempty"` +} + +func (x *WithdrawCampaignAuthorization) Reset() { + *x = WithdrawCampaignAuthorization{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_authz_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WithdrawCampaignAuthorization) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WithdrawCampaignAuthorization) ProtoMessage() {} + +// Deprecated: Use WithdrawCampaignAuthorization.ProtoReflect.Descriptor instead. +func (*WithdrawCampaignAuthorization) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_authz_proto_rawDescGZIP(), []int{2} +} + +func (x *WithdrawCampaignAuthorization) GetWithdrawLimit() string { + if x != nil { + return x.WithdrawLimit + } + return "" +} + +var File_sge_legacy_reward_v1beta_authz_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_authz_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x61, 0x75, 0x74, 0x68, 0x7a, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x5d, 0x0a, 0x1b, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3e, 0x0a, 0x0b, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x5f, 0x6c, + 0x69, 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, + 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, + 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0a, 0x73, 0x70, 0x65, 0x6e, 0x64, + 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0x5d, 0x0a, 0x1b, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, + 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3e, 0x0a, 0x0b, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x5f, 0x6c, 0x69, + 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, + 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0a, 0x73, 0x70, 0x65, 0x6e, 0x64, 0x4c, + 0x69, 0x6d, 0x69, 0x74, 0x22, 0x65, 0x0a, 0x1d, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, + 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x44, 0x0a, 0x0e, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, + 0x77, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, + 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0d, 0x77, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x42, 0xf3, 0x01, 0x0a, 0x1c, + 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x41, 0x75, + 0x74, 0x68, 0x7a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x3b, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x52, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_authz_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_authz_proto_rawDescData = file_sge_legacy_reward_v1beta_authz_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_authz_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_authz_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_authz_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_authz_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_authz_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_authz_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_sge_legacy_reward_v1beta_authz_proto_goTypes = []interface{}{ + (*CreateCampaignAuthorization)(nil), // 0: sge.legacy.reward.v1beta.CreateCampaignAuthorization + (*UpdateCampaignAuthorization)(nil), // 1: sge.legacy.reward.v1beta.UpdateCampaignAuthorization + (*WithdrawCampaignAuthorization)(nil), // 2: sge.legacy.reward.v1beta.WithdrawCampaignAuthorization +} +var file_sge_legacy_reward_v1beta_authz_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_authz_proto_init() } +func file_sge_legacy_reward_v1beta_authz_proto_init() { + if File_sge_legacy_reward_v1beta_authz_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_authz_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CreateCampaignAuthorization); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_authz_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UpdateCampaignAuthorization); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_authz_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WithdrawCampaignAuthorization); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_authz_proto_rawDesc, + NumEnums: 0, + NumMessages: 3, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_v1beta_authz_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_authz_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_authz_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_authz_proto = out.File + file_sge_legacy_reward_v1beta_authz_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_authz_proto_goTypes = nil + file_sge_legacy_reward_v1beta_authz_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/campaign.pulsar.go b/api/sge/legacy/reward/v1beta/campaign.pulsar.go new file mode 100644 index 00000000..3db956b0 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/campaign.pulsar.go @@ -0,0 +1,2633 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Campaign protoreflect.MessageDescriptor + fd_Campaign_creator protoreflect.FieldDescriptor + fd_Campaign_uid protoreflect.FieldDescriptor + fd_Campaign_promoter protoreflect.FieldDescriptor + fd_Campaign_start_ts protoreflect.FieldDescriptor + fd_Campaign_end_ts protoreflect.FieldDescriptor + fd_Campaign_reward_category protoreflect.FieldDescriptor + fd_Campaign_reward_type protoreflect.FieldDescriptor + fd_Campaign_reward_amount_type protoreflect.FieldDescriptor + fd_Campaign_reward_amount protoreflect.FieldDescriptor + fd_Campaign_pool protoreflect.FieldDescriptor + fd_Campaign_is_active protoreflect.FieldDescriptor + fd_Campaign_meta protoreflect.FieldDescriptor + fd_Campaign_cap_count protoreflect.FieldDescriptor + fd_Campaign_constraints protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_campaign_proto_init() + md_Campaign = File_sge_legacy_reward_v1beta_campaign_proto.Messages().ByName("Campaign") + fd_Campaign_creator = md_Campaign.Fields().ByName("creator") + fd_Campaign_uid = md_Campaign.Fields().ByName("uid") + fd_Campaign_promoter = md_Campaign.Fields().ByName("promoter") + fd_Campaign_start_ts = md_Campaign.Fields().ByName("start_ts") + fd_Campaign_end_ts = md_Campaign.Fields().ByName("end_ts") + fd_Campaign_reward_category = md_Campaign.Fields().ByName("reward_category") + fd_Campaign_reward_type = md_Campaign.Fields().ByName("reward_type") + fd_Campaign_reward_amount_type = md_Campaign.Fields().ByName("reward_amount_type") + fd_Campaign_reward_amount = md_Campaign.Fields().ByName("reward_amount") + fd_Campaign_pool = md_Campaign.Fields().ByName("pool") + fd_Campaign_is_active = md_Campaign.Fields().ByName("is_active") + fd_Campaign_meta = md_Campaign.Fields().ByName("meta") + fd_Campaign_cap_count = md_Campaign.Fields().ByName("cap_count") + fd_Campaign_constraints = md_Campaign.Fields().ByName("constraints") +} + +var _ protoreflect.Message = (*fastReflection_Campaign)(nil) + +type fastReflection_Campaign Campaign + +func (x *Campaign) ProtoReflect() protoreflect.Message { + return (*fastReflection_Campaign)(x) +} + +func (x *Campaign) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Campaign_messageType fastReflection_Campaign_messageType +var _ protoreflect.MessageType = fastReflection_Campaign_messageType{} + +type fastReflection_Campaign_messageType struct{} + +func (x fastReflection_Campaign_messageType) Zero() protoreflect.Message { + return (*fastReflection_Campaign)(nil) +} +func (x fastReflection_Campaign_messageType) New() protoreflect.Message { + return new(fastReflection_Campaign) +} +func (x fastReflection_Campaign_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Campaign +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Campaign) Descriptor() protoreflect.MessageDescriptor { + return md_Campaign +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Campaign) Type() protoreflect.MessageType { + return _fastReflection_Campaign_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Campaign) New() protoreflect.Message { + return new(fastReflection_Campaign) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Campaign) Interface() protoreflect.ProtoMessage { + return (*Campaign)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Campaign) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_Campaign_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_Campaign_uid, value) { + return + } + } + if x.Promoter != "" { + value := protoreflect.ValueOfString(x.Promoter) + if !f(fd_Campaign_promoter, value) { + return + } + } + if x.StartTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.StartTs) + if !f(fd_Campaign_start_ts, value) { + return + } + } + if x.EndTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.EndTs) + if !f(fd_Campaign_end_ts, value) { + return + } + } + if x.RewardCategory != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.RewardCategory)) + if !f(fd_Campaign_reward_category, value) { + return + } + } + if x.RewardType != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.RewardType)) + if !f(fd_Campaign_reward_type, value) { + return + } + } + if x.RewardAmountType != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.RewardAmountType)) + if !f(fd_Campaign_reward_amount_type, value) { + return + } + } + if x.RewardAmount != nil { + value := protoreflect.ValueOfMessage(x.RewardAmount.ProtoReflect()) + if !f(fd_Campaign_reward_amount, value) { + return + } + } + if x.Pool != nil { + value := protoreflect.ValueOfMessage(x.Pool.ProtoReflect()) + if !f(fd_Campaign_pool, value) { + return + } + } + if x.IsActive != false { + value := protoreflect.ValueOfBool(x.IsActive) + if !f(fd_Campaign_is_active, value) { + return + } + } + if x.Meta != "" { + value := protoreflect.ValueOfString(x.Meta) + if !f(fd_Campaign_meta, value) { + return + } + } + if x.CapCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.CapCount) + if !f(fd_Campaign_cap_count, value) { + return + } + } + if x.Constraints != nil { + value := protoreflect.ValueOfMessage(x.Constraints.ProtoReflect()) + if !f(fd_Campaign_constraints, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Campaign) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Campaign.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.Campaign.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.Campaign.promoter": + return x.Promoter != "" + case "sge.legacy.reward.v1beta.Campaign.start_ts": + return x.StartTs != uint64(0) + case "sge.legacy.reward.v1beta.Campaign.end_ts": + return x.EndTs != uint64(0) + case "sge.legacy.reward.v1beta.Campaign.reward_category": + return x.RewardCategory != 0 + case "sge.legacy.reward.v1beta.Campaign.reward_type": + return x.RewardType != 0 + case "sge.legacy.reward.v1beta.Campaign.reward_amount_type": + return x.RewardAmountType != 0 + case "sge.legacy.reward.v1beta.Campaign.reward_amount": + return x.RewardAmount != nil + case "sge.legacy.reward.v1beta.Campaign.pool": + return x.Pool != nil + case "sge.legacy.reward.v1beta.Campaign.is_active": + return x.IsActive != false + case "sge.legacy.reward.v1beta.Campaign.meta": + return x.Meta != "" + case "sge.legacy.reward.v1beta.Campaign.cap_count": + return x.CapCount != uint64(0) + case "sge.legacy.reward.v1beta.Campaign.constraints": + return x.Constraints != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Campaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Campaign does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Campaign) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Campaign.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.Campaign.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.Campaign.promoter": + x.Promoter = "" + case "sge.legacy.reward.v1beta.Campaign.start_ts": + x.StartTs = uint64(0) + case "sge.legacy.reward.v1beta.Campaign.end_ts": + x.EndTs = uint64(0) + case "sge.legacy.reward.v1beta.Campaign.reward_category": + x.RewardCategory = 0 + case "sge.legacy.reward.v1beta.Campaign.reward_type": + x.RewardType = 0 + case "sge.legacy.reward.v1beta.Campaign.reward_amount_type": + x.RewardAmountType = 0 + case "sge.legacy.reward.v1beta.Campaign.reward_amount": + x.RewardAmount = nil + case "sge.legacy.reward.v1beta.Campaign.pool": + x.Pool = nil + case "sge.legacy.reward.v1beta.Campaign.is_active": + x.IsActive = false + case "sge.legacy.reward.v1beta.Campaign.meta": + x.Meta = "" + case "sge.legacy.reward.v1beta.Campaign.cap_count": + x.CapCount = uint64(0) + case "sge.legacy.reward.v1beta.Campaign.constraints": + x.Constraints = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Campaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Campaign does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Campaign) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.Campaign.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Campaign.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Campaign.promoter": + value := x.Promoter + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Campaign.start_ts": + value := x.StartTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.Campaign.end_ts": + value := x.EndTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.Campaign.reward_category": + value := x.RewardCategory + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.Campaign.reward_type": + value := x.RewardType + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.Campaign.reward_amount_type": + value := x.RewardAmountType + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.Campaign.reward_amount": + value := x.RewardAmount + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.Campaign.pool": + value := x.Pool + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.Campaign.is_active": + value := x.IsActive + return protoreflect.ValueOfBool(value) + case "sge.legacy.reward.v1beta.Campaign.meta": + value := x.Meta + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Campaign.cap_count": + value := x.CapCount + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.Campaign.constraints": + value := x.Constraints + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Campaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Campaign does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Campaign) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Campaign.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.Campaign.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.Campaign.promoter": + x.Promoter = value.Interface().(string) + case "sge.legacy.reward.v1beta.Campaign.start_ts": + x.StartTs = value.Uint() + case "sge.legacy.reward.v1beta.Campaign.end_ts": + x.EndTs = value.Uint() + case "sge.legacy.reward.v1beta.Campaign.reward_category": + x.RewardCategory = (RewardCategory)(value.Enum()) + case "sge.legacy.reward.v1beta.Campaign.reward_type": + x.RewardType = (RewardType)(value.Enum()) + case "sge.legacy.reward.v1beta.Campaign.reward_amount_type": + x.RewardAmountType = (RewardAmountType)(value.Enum()) + case "sge.legacy.reward.v1beta.Campaign.reward_amount": + x.RewardAmount = value.Message().Interface().(*RewardAmount) + case "sge.legacy.reward.v1beta.Campaign.pool": + x.Pool = value.Message().Interface().(*Pool) + case "sge.legacy.reward.v1beta.Campaign.is_active": + x.IsActive = value.Bool() + case "sge.legacy.reward.v1beta.Campaign.meta": + x.Meta = value.Interface().(string) + case "sge.legacy.reward.v1beta.Campaign.cap_count": + x.CapCount = value.Uint() + case "sge.legacy.reward.v1beta.Campaign.constraints": + x.Constraints = value.Message().Interface().(*CampaignConstraints) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Campaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Campaign does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Campaign) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Campaign.reward_amount": + if x.RewardAmount == nil { + x.RewardAmount = new(RewardAmount) + } + return protoreflect.ValueOfMessage(x.RewardAmount.ProtoReflect()) + case "sge.legacy.reward.v1beta.Campaign.pool": + if x.Pool == nil { + x.Pool = new(Pool) + } + return protoreflect.ValueOfMessage(x.Pool.ProtoReflect()) + case "sge.legacy.reward.v1beta.Campaign.constraints": + if x.Constraints == nil { + x.Constraints = new(CampaignConstraints) + } + return protoreflect.ValueOfMessage(x.Constraints.ProtoReflect()) + case "sge.legacy.reward.v1beta.Campaign.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.promoter": + panic(fmt.Errorf("field promoter of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.start_ts": + panic(fmt.Errorf("field start_ts of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.end_ts": + panic(fmt.Errorf("field end_ts of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.reward_category": + panic(fmt.Errorf("field reward_category of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.reward_type": + panic(fmt.Errorf("field reward_type of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.reward_amount_type": + panic(fmt.Errorf("field reward_amount_type of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.is_active": + panic(fmt.Errorf("field is_active of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.meta": + panic(fmt.Errorf("field meta of message sge.legacy.reward.v1beta.Campaign is not mutable")) + case "sge.legacy.reward.v1beta.Campaign.cap_count": + panic(fmt.Errorf("field cap_count of message sge.legacy.reward.v1beta.Campaign is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Campaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Campaign does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Campaign) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Campaign.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Campaign.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Campaign.promoter": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Campaign.start_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.Campaign.end_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.Campaign.reward_category": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.Campaign.reward_type": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.Campaign.reward_amount_type": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.Campaign.reward_amount": + m := new(RewardAmount) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.Campaign.pool": + m := new(Pool) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.Campaign.is_active": + return protoreflect.ValueOfBool(false) + case "sge.legacy.reward.v1beta.Campaign.meta": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Campaign.cap_count": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.Campaign.constraints": + m := new(CampaignConstraints) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Campaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Campaign does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Campaign) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.Campaign", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Campaign) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Campaign) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Campaign) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Campaign) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Campaign) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Promoter) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.StartTs != 0 { + n += 1 + runtime.Sov(uint64(x.StartTs)) + } + if x.EndTs != 0 { + n += 1 + runtime.Sov(uint64(x.EndTs)) + } + if x.RewardCategory != 0 { + n += 1 + runtime.Sov(uint64(x.RewardCategory)) + } + if x.RewardType != 0 { + n += 1 + runtime.Sov(uint64(x.RewardType)) + } + if x.RewardAmountType != 0 { + n += 1 + runtime.Sov(uint64(x.RewardAmountType)) + } + if x.RewardAmount != nil { + l = options.Size(x.RewardAmount) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Pool != nil { + l = options.Size(x.Pool) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.IsActive { + n += 2 + } + l = len(x.Meta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.CapCount != 0 { + n += 1 + runtime.Sov(uint64(x.CapCount)) + } + if x.Constraints != nil { + l = options.Size(x.Constraints) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Campaign) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Constraints != nil { + encoded, err := options.Marshal(x.Constraints) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x7a + } + if x.CapCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.CapCount)) + i-- + dAtA[i] = 0x70 + } + if len(x.Meta) > 0 { + i -= len(x.Meta) + copy(dAtA[i:], x.Meta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Meta))) + i-- + dAtA[i] = 0x6a + } + if x.IsActive { + i-- + if x.IsActive { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x58 + } + if x.Pool != nil { + encoded, err := options.Marshal(x.Pool) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x52 + } + if x.RewardAmount != nil { + encoded, err := options.Marshal(x.RewardAmount) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x4a + } + if x.RewardAmountType != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.RewardAmountType)) + i-- + dAtA[i] = 0x40 + } + if x.RewardType != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.RewardType)) + i-- + dAtA[i] = 0x38 + } + if x.RewardCategory != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.RewardCategory)) + i-- + dAtA[i] = 0x30 + } + if x.EndTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.EndTs)) + i-- + dAtA[i] = 0x28 + } + if x.StartTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.StartTs)) + i-- + dAtA[i] = 0x20 + } + if len(x.Promoter) > 0 { + i -= len(x.Promoter) + copy(dAtA[i:], x.Promoter) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Promoter))) + i-- + dAtA[i] = 0x1a + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Campaign) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Campaign: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Campaign: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Promoter", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Promoter = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field StartTs", wireType) + } + x.StartTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.StartTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EndTs", wireType) + } + x.EndTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.EndTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardCategory", wireType) + } + x.RewardCategory = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.RewardCategory |= RewardCategory(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardType", wireType) + } + x.RewardType = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.RewardType |= RewardType(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardAmountType", wireType) + } + x.RewardAmountType = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.RewardAmountType |= RewardAmountType(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 9: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardAmount", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.RewardAmount == nil { + x.RewardAmount = &RewardAmount{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.RewardAmount); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 10: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pool", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pool == nil { + x.Pool = &Pool{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pool); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 11: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field IsActive", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.IsActive = bool(v != 0) + case 13: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Meta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 14: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CapCount", wireType) + } + x.CapCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.CapCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 15: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Constraints", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Constraints == nil { + x.Constraints = &CampaignConstraints{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Constraints); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_Pool protoreflect.MessageDescriptor + fd_Pool_total protoreflect.FieldDescriptor + fd_Pool_spent protoreflect.FieldDescriptor + fd_Pool_withdrawn protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_campaign_proto_init() + md_Pool = File_sge_legacy_reward_v1beta_campaign_proto.Messages().ByName("Pool") + fd_Pool_total = md_Pool.Fields().ByName("total") + fd_Pool_spent = md_Pool.Fields().ByName("spent") + fd_Pool_withdrawn = md_Pool.Fields().ByName("withdrawn") +} + +var _ protoreflect.Message = (*fastReflection_Pool)(nil) + +type fastReflection_Pool Pool + +func (x *Pool) ProtoReflect() protoreflect.Message { + return (*fastReflection_Pool)(x) +} + +func (x *Pool) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Pool_messageType fastReflection_Pool_messageType +var _ protoreflect.MessageType = fastReflection_Pool_messageType{} + +type fastReflection_Pool_messageType struct{} + +func (x fastReflection_Pool_messageType) Zero() protoreflect.Message { + return (*fastReflection_Pool)(nil) +} +func (x fastReflection_Pool_messageType) New() protoreflect.Message { + return new(fastReflection_Pool) +} +func (x fastReflection_Pool_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Pool +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Pool) Descriptor() protoreflect.MessageDescriptor { + return md_Pool +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Pool) Type() protoreflect.MessageType { + return _fastReflection_Pool_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Pool) New() protoreflect.Message { + return new(fastReflection_Pool) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Pool) Interface() protoreflect.ProtoMessage { + return (*Pool)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Pool) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Total != "" { + value := protoreflect.ValueOfString(x.Total) + if !f(fd_Pool_total, value) { + return + } + } + if x.Spent != "" { + value := protoreflect.ValueOfString(x.Spent) + if !f(fd_Pool_spent, value) { + return + } + } + if x.Withdrawn != "" { + value := protoreflect.ValueOfString(x.Withdrawn) + if !f(fd_Pool_withdrawn, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Pool) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Pool.total": + return x.Total != "" + case "sge.legacy.reward.v1beta.Pool.spent": + return x.Spent != "" + case "sge.legacy.reward.v1beta.Pool.withdrawn": + return x.Withdrawn != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Pool")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Pool does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Pool) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Pool.total": + x.Total = "" + case "sge.legacy.reward.v1beta.Pool.spent": + x.Spent = "" + case "sge.legacy.reward.v1beta.Pool.withdrawn": + x.Withdrawn = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Pool")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Pool does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Pool) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.Pool.total": + value := x.Total + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Pool.spent": + value := x.Spent + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Pool.withdrawn": + value := x.Withdrawn + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Pool")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Pool does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Pool) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Pool.total": + x.Total = value.Interface().(string) + case "sge.legacy.reward.v1beta.Pool.spent": + x.Spent = value.Interface().(string) + case "sge.legacy.reward.v1beta.Pool.withdrawn": + x.Withdrawn = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Pool")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Pool does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Pool) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Pool.total": + panic(fmt.Errorf("field total of message sge.legacy.reward.v1beta.Pool is not mutable")) + case "sge.legacy.reward.v1beta.Pool.spent": + panic(fmt.Errorf("field spent of message sge.legacy.reward.v1beta.Pool is not mutable")) + case "sge.legacy.reward.v1beta.Pool.withdrawn": + panic(fmt.Errorf("field withdrawn of message sge.legacy.reward.v1beta.Pool is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Pool")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Pool does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Pool) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Pool.total": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Pool.spent": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Pool.withdrawn": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Pool")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Pool does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Pool) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.Pool", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Pool) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Pool) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Pool) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Pool) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Pool) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Total) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Spent) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Withdrawn) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Pool) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Withdrawn) > 0 { + i -= len(x.Withdrawn) + copy(dAtA[i:], x.Withdrawn) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Withdrawn))) + i-- + dAtA[i] = 0x1a + } + if len(x.Spent) > 0 { + i -= len(x.Spent) + copy(dAtA[i:], x.Spent) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Spent))) + i-- + dAtA[i] = 0x12 + } + if len(x.Total) > 0 { + i -= len(x.Total) + copy(dAtA[i:], x.Total) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Total))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Pool) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Pool: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Pool: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Total", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Total = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Spent", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Spent = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Withdrawn", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Withdrawn = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_CampaignConstraints protoreflect.MessageDescriptor + fd_CampaignConstraints_max_bet_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_campaign_proto_init() + md_CampaignConstraints = File_sge_legacy_reward_v1beta_campaign_proto.Messages().ByName("CampaignConstraints") + fd_CampaignConstraints_max_bet_amount = md_CampaignConstraints.Fields().ByName("max_bet_amount") +} + +var _ protoreflect.Message = (*fastReflection_CampaignConstraints)(nil) + +type fastReflection_CampaignConstraints CampaignConstraints + +func (x *CampaignConstraints) ProtoReflect() protoreflect.Message { + return (*fastReflection_CampaignConstraints)(x) +} + +func (x *CampaignConstraints) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_CampaignConstraints_messageType fastReflection_CampaignConstraints_messageType +var _ protoreflect.MessageType = fastReflection_CampaignConstraints_messageType{} + +type fastReflection_CampaignConstraints_messageType struct{} + +func (x fastReflection_CampaignConstraints_messageType) Zero() protoreflect.Message { + return (*fastReflection_CampaignConstraints)(nil) +} +func (x fastReflection_CampaignConstraints_messageType) New() protoreflect.Message { + return new(fastReflection_CampaignConstraints) +} +func (x fastReflection_CampaignConstraints_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_CampaignConstraints +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_CampaignConstraints) Descriptor() protoreflect.MessageDescriptor { + return md_CampaignConstraints +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_CampaignConstraints) Type() protoreflect.MessageType { + return _fastReflection_CampaignConstraints_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_CampaignConstraints) New() protoreflect.Message { + return new(fastReflection_CampaignConstraints) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_CampaignConstraints) Interface() protoreflect.ProtoMessage { + return (*CampaignConstraints)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_CampaignConstraints) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MaxBetAmount != "" { + value := protoreflect.ValueOfString(x.MaxBetAmount) + if !f(fd_CampaignConstraints_max_bet_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_CampaignConstraints) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CampaignConstraints.max_bet_amount": + return x.MaxBetAmount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CampaignConstraints")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CampaignConstraints does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CampaignConstraints) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CampaignConstraints.max_bet_amount": + x.MaxBetAmount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CampaignConstraints")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CampaignConstraints does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_CampaignConstraints) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.CampaignConstraints.max_bet_amount": + value := x.MaxBetAmount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CampaignConstraints")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CampaignConstraints does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CampaignConstraints) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CampaignConstraints.max_bet_amount": + x.MaxBetAmount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CampaignConstraints")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CampaignConstraints does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CampaignConstraints) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CampaignConstraints.max_bet_amount": + panic(fmt.Errorf("field max_bet_amount of message sge.legacy.reward.v1beta.CampaignConstraints is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CampaignConstraints")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CampaignConstraints does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_CampaignConstraints) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CampaignConstraints.max_bet_amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CampaignConstraints")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CampaignConstraints does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_CampaignConstraints) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.CampaignConstraints", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_CampaignConstraints) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CampaignConstraints) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_CampaignConstraints) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_CampaignConstraints) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*CampaignConstraints) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.MaxBetAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*CampaignConstraints) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.MaxBetAmount) > 0 { + i -= len(x.MaxBetAmount) + copy(dAtA[i:], x.MaxBetAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MaxBetAmount))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*CampaignConstraints) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CampaignConstraints: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CampaignConstraints: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxBetAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MaxBetAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/campaign.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Campaign is type for defining the campaign properties. +type Campaign struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of campaign creator. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // uid is the unique identifier of a campaign. + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` + // promoter is the address of campaign promoter. + // Funds for the campaign would be deducted from this account. + Promoter string `protobuf:"bytes,3,opt,name=promoter,proto3" json:"promoter,omitempty"` + // start_ts is the start timestamp of a campaign. + StartTs uint64 `protobuf:"varint,4,opt,name=start_ts,proto3" json:"start_ts,omitempty"` + // end_ts is the end timestamp of a campaign. + EndTs uint64 `protobuf:"varint,5,opt,name=end_ts,proto3" json:"end_ts,omitempty"` + // reward_category is the category of reward. + RewardCategory RewardCategory `protobuf:"varint,6,opt,name=reward_category,json=rewardCategory,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"reward_category,omitempty"` + // reward_type is the type of reward. + RewardType RewardType `protobuf:"varint,7,opt,name=reward_type,json=rewardType,proto3,enum=sge.legacy.reward.v1beta.RewardType" json:"reward_type,omitempty"` + // amount_type is the type of reward amount. + RewardAmountType RewardAmountType `protobuf:"varint,8,opt,name=reward_amount_type,json=rewardAmountType,proto3,enum=sge.legacy.reward.v1beta.RewardAmountType" json:"reward_amount_type,omitempty"` + // reward_amount is the amount defined for a reward. + RewardAmount *RewardAmount `protobuf:"bytes,9,opt,name=reward_amount,json=rewardAmount,proto3" json:"reward_amount,omitempty"` + // pool is the tracker of campaign funds. + Pool *Pool `protobuf:"bytes,10,opt,name=pool,proto3" json:"pool,omitempty"` + // is_active is the flag to check if the campaign is active or not. + IsActive bool `protobuf:"varint,11,opt,name=is_active,json=isActive,proto3" json:"is_active,omitempty"` + // meta is the metadata of the campaign. + // It is a stringified base64 encoded json. + Meta string `protobuf:"bytes,13,opt,name=meta,proto3" json:"meta,omitempty"` + // cap_count is the maximum allowed grant for a certain account. + CapCount uint64 `protobuf:"varint,14,opt,name=cap_count,json=capCount,proto3" json:"cap_count,omitempty"` + // constraints is the constrains of a campaign. + Constraints *CampaignConstraints `protobuf:"bytes,15,opt,name=constraints,proto3" json:"constraints,omitempty"` +} + +func (x *Campaign) Reset() { + *x = Campaign{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Campaign) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Campaign) ProtoMessage() {} + +// Deprecated: Use Campaign.ProtoReflect.Descriptor instead. +func (*Campaign) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_campaign_proto_rawDescGZIP(), []int{0} +} + +func (x *Campaign) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *Campaign) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *Campaign) GetPromoter() string { + if x != nil { + return x.Promoter + } + return "" +} + +func (x *Campaign) GetStartTs() uint64 { + if x != nil { + return x.StartTs + } + return 0 +} + +func (x *Campaign) GetEndTs() uint64 { + if x != nil { + return x.EndTs + } + return 0 +} + +func (x *Campaign) GetRewardCategory() RewardCategory { + if x != nil { + return x.RewardCategory + } + return RewardCategory_REWARD_CATEGORY_UNSPECIFIED +} + +func (x *Campaign) GetRewardType() RewardType { + if x != nil { + return x.RewardType + } + return RewardType_REWARD_TYPE_UNSPECIFIED +} + +func (x *Campaign) GetRewardAmountType() RewardAmountType { + if x != nil { + return x.RewardAmountType + } + return RewardAmountType_REWARD_AMOUNT_TYPE_UNSPECIFIED +} + +func (x *Campaign) GetRewardAmount() *RewardAmount { + if x != nil { + return x.RewardAmount + } + return nil +} + +func (x *Campaign) GetPool() *Pool { + if x != nil { + return x.Pool + } + return nil +} + +func (x *Campaign) GetIsActive() bool { + if x != nil { + return x.IsActive + } + return false +} + +func (x *Campaign) GetMeta() string { + if x != nil { + return x.Meta + } + return "" +} + +func (x *Campaign) GetCapCount() uint64 { + if x != nil { + return x.CapCount + } + return 0 +} + +func (x *Campaign) GetConstraints() *CampaignConstraints { + if x != nil { + return x.Constraints + } + return nil +} + +// Pool tracks funds assigned and spent to/for a campaign. +type Pool struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Total string `protobuf:"bytes,1,opt,name=total,proto3" json:"total,omitempty"` + Spent string `protobuf:"bytes,2,opt,name=spent,proto3" json:"spent,omitempty"` + Withdrawn string `protobuf:"bytes,3,opt,name=withdrawn,proto3" json:"withdrawn,omitempty"` +} + +func (x *Pool) Reset() { + *x = Pool{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Pool) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Pool) ProtoMessage() {} + +// Deprecated: Use Pool.ProtoReflect.Descriptor instead. +func (*Pool) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_campaign_proto_rawDescGZIP(), []int{1} +} + +func (x *Pool) GetTotal() string { + if x != nil { + return x.Total + } + return "" +} + +func (x *Pool) GetSpent() string { + if x != nil { + return x.Spent + } + return "" +} + +func (x *Pool) GetWithdrawn() string { + if x != nil { + return x.Withdrawn + } + return "" +} + +// CampaignConstraints contains campaign constraints and criteria. +type CampaignConstraints struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + MaxBetAmount string `protobuf:"bytes,1,opt,name=max_bet_amount,json=maxBetAmount,proto3" json:"max_bet_amount,omitempty"` +} + +func (x *CampaignConstraints) Reset() { + *x = CampaignConstraints{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CampaignConstraints) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CampaignConstraints) ProtoMessage() {} + +// Deprecated: Use CampaignConstraints.ProtoReflect.Descriptor instead. +func (*CampaignConstraints) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_campaign_proto_rawDescGZIP(), []int{2} +} + +func (x *CampaignConstraints) GetMaxBetAmount() string { + if x != nil { + return x.MaxBetAmount + } + return "" +} + +var File_sge_legacy_reward_v1beta_campaign_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_campaign_proto_rawDesc = []byte{ + 0x0a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x63, 0x61, 0x6d, 0x70, 0x61, + 0x69, 0x67, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, + 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x92, 0x06, 0x0a, 0x08, + 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x20, 0x0a, 0x03, + 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, + 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x34, + 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x6d, + 0x6f, 0x74, 0x65, 0x72, 0x12, 0x33, 0x0a, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x42, 0x17, 0xe2, 0xde, 0x1f, 0x07, 0x53, 0x74, 0x61, 0x72, + 0x74, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x52, + 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x12, 0x2b, 0x0a, 0x06, 0x65, 0x6e, 0x64, + 0x5f, 0x74, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x42, 0x13, 0xe2, 0xde, 0x1f, 0x05, 0x45, + 0x6e, 0x64, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x06, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x52, 0x06, + 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x12, 0x51, 0x0a, 0x0f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x5f, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, + 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x0e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x45, 0x0a, 0x0b, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x24, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x54, 0x79, 0x70, 0x65, 0x52, 0x0a, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x54, 0x79, 0x70, 0x65, + 0x12, 0x58, 0x0a, 0x12, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, + 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2a, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, + 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x10, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x4b, 0x0a, 0x0d, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x0c, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x38, 0x0a, 0x04, 0x70, 0x6f, 0x6f, 0x6c, 0x18, + 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x50, 0x6f, 0x6f, 0x6c, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x04, 0x70, 0x6f, 0x6f, + 0x6c, 0x12, 0x1b, 0x0a, 0x09, 0x69, 0x73, 0x5f, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x18, 0x0b, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, 0x65, + 0x74, 0x61, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x61, 0x70, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, + 0x0e, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x63, 0x61, 0x70, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, + 0x4f, 0x0a, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x18, 0x0f, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, + 0x6e, 0x74, 0x73, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, + 0x22, 0xdd, 0x01, 0x0a, 0x04, 0x50, 0x6f, 0x6f, 0x6c, 0x12, 0x43, 0x0a, 0x05, 0x74, 0x6f, 0x74, + 0x61, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, + 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, + 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x0c, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x22, 0x52, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x12, 0x43, + 0x0a, 0x05, 0x73, 0x70, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2d, 0xc8, + 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x0c, + 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x73, 0x70, 0x65, 0x6e, 0x74, 0x22, 0x52, 0x05, 0x73, 0x70, + 0x65, 0x6e, 0x74, 0x12, 0x4b, 0x0a, 0x09, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x6e, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, + 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x0c, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x73, + 0x70, 0x65, 0x6e, 0x74, 0x22, 0x52, 0x09, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x6e, + 0x22, 0x73, 0x0a, 0x13, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x73, + 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x12, 0x5c, 0x0a, 0x0e, 0x6d, 0x61, 0x78, 0x5f, 0x62, + 0x65, 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x36, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, + 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, + 0x1f, 0x15, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, 0x61, 0x78, 0x5f, 0x62, 0x65, 0x74, 0x5f, + 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x0c, 0x6d, 0x61, 0x78, 0x42, 0x65, 0x74, 0x41, + 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0xf6, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0d, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x3b, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, + 0x53, 0x4c, 0x52, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, + 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, + 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_campaign_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_campaign_proto_rawDescData = file_sge_legacy_reward_v1beta_campaign_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_campaign_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_campaign_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_campaign_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_campaign_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_campaign_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_campaign_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_sge_legacy_reward_v1beta_campaign_proto_goTypes = []interface{}{ + (*Campaign)(nil), // 0: sge.legacy.reward.v1beta.Campaign + (*Pool)(nil), // 1: sge.legacy.reward.v1beta.Pool + (*CampaignConstraints)(nil), // 2: sge.legacy.reward.v1beta.CampaignConstraints + (RewardCategory)(0), // 3: sge.legacy.reward.v1beta.RewardCategory + (RewardType)(0), // 4: sge.legacy.reward.v1beta.RewardType + (RewardAmountType)(0), // 5: sge.legacy.reward.v1beta.RewardAmountType + (*RewardAmount)(nil), // 6: sge.legacy.reward.v1beta.RewardAmount +} +var file_sge_legacy_reward_v1beta_campaign_proto_depIdxs = []int32{ + 3, // 0: sge.legacy.reward.v1beta.Campaign.reward_category:type_name -> sge.legacy.reward.v1beta.RewardCategory + 4, // 1: sge.legacy.reward.v1beta.Campaign.reward_type:type_name -> sge.legacy.reward.v1beta.RewardType + 5, // 2: sge.legacy.reward.v1beta.Campaign.reward_amount_type:type_name -> sge.legacy.reward.v1beta.RewardAmountType + 6, // 3: sge.legacy.reward.v1beta.Campaign.reward_amount:type_name -> sge.legacy.reward.v1beta.RewardAmount + 1, // 4: sge.legacy.reward.v1beta.Campaign.pool:type_name -> sge.legacy.reward.v1beta.Pool + 2, // 5: sge.legacy.reward.v1beta.Campaign.constraints:type_name -> sge.legacy.reward.v1beta.CampaignConstraints + 6, // [6:6] is the sub-list for method output_type + 6, // [6:6] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_campaign_proto_init() } +func file_sge_legacy_reward_v1beta_campaign_proto_init() { + if File_sge_legacy_reward_v1beta_campaign_proto != nil { + return + } + file_sge_legacy_reward_v1beta_reward_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Campaign); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Pool); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_campaign_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CampaignConstraints); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_campaign_proto_rawDesc, + NumEnums: 0, + NumMessages: 3, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_v1beta_campaign_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_campaign_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_campaign_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_campaign_proto = out.File + file_sge_legacy_reward_v1beta_campaign_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_campaign_proto_goTypes = nil + file_sge_legacy_reward_v1beta_campaign_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/genesis.pulsar.go b/api/sge/legacy/reward/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..52e1f9a1 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/genesis.pulsar.go @@ -0,0 +1,1531 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_2_list)(nil) + +type _GenesisState_2_list struct { + list *[]*Campaign +} + +func (x *_GenesisState_2_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_2_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_2_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Campaign) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_2_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Campaign) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_2_list) AppendMutable() protoreflect.Value { + v := new(Campaign) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_2_list) NewElement() protoreflect.Value { + v := new(Campaign) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_2_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_3_list)(nil) + +type _GenesisState_3_list struct { + list *[]*Reward +} + +func (x *_GenesisState_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Reward) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Reward) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_3_list) AppendMutable() protoreflect.Value { + v := new(Reward) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_3_list) NewElement() protoreflect.Value { + v := new(Reward) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_4_list)(nil) + +type _GenesisState_4_list struct { + list *[]*RewardByCategory +} + +func (x *_GenesisState_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCategory) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCategory) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_4_list) AppendMutable() protoreflect.Value { + v := new(RewardByCategory) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_4_list) NewElement() protoreflect.Value { + v := new(RewardByCategory) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_4_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_5_list)(nil) + +type _GenesisState_5_list struct { + list *[]*RewardByCampaign +} + +func (x *_GenesisState_5_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_5_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_5_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCampaign) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_5_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCampaign) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_5_list) AppendMutable() protoreflect.Value { + v := new(RewardByCampaign) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_5_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_5_list) NewElement() protoreflect.Value { + v := new(RewardByCampaign) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_5_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_6_list)(nil) + +type _GenesisState_6_list struct { + list *[]*Promoter +} + +func (x *_GenesisState_6_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_6_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_6_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Promoter) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_6_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Promoter) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_6_list) AppendMutable() protoreflect.Value { + v := new(Promoter) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_6_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_6_list) NewElement() protoreflect.Value { + v := new(Promoter) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_6_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_GenesisState_7_list)(nil) + +type _GenesisState_7_list struct { + list *[]*PromoterByAddress +} + +func (x *_GenesisState_7_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_7_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_7_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PromoterByAddress) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_7_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*PromoterByAddress) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_7_list) AppendMutable() protoreflect.Value { + v := new(PromoterByAddress) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_7_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_7_list) NewElement() protoreflect.Value { + v := new(PromoterByAddress) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_7_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor + fd_GenesisState_campaign_list protoreflect.FieldDescriptor + fd_GenesisState_reward_list protoreflect.FieldDescriptor + fd_GenesisState_reward_by_category_list protoreflect.FieldDescriptor + fd_GenesisState_reward_by_campaign_list protoreflect.FieldDescriptor + fd_GenesisState_promoter_list protoreflect.FieldDescriptor + fd_GenesisState_promoter_by_address_list protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_genesis_proto_init() + md_GenesisState = File_sge_legacy_reward_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") + fd_GenesisState_campaign_list = md_GenesisState.Fields().ByName("campaign_list") + fd_GenesisState_reward_list = md_GenesisState.Fields().ByName("reward_list") + fd_GenesisState_reward_by_category_list = md_GenesisState.Fields().ByName("reward_by_category_list") + fd_GenesisState_reward_by_campaign_list = md_GenesisState.Fields().ByName("reward_by_campaign_list") + fd_GenesisState_promoter_list = md_GenesisState.Fields().ByName("promoter_list") + fd_GenesisState_promoter_by_address_list = md_GenesisState.Fields().ByName("promoter_by_address_list") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } + if len(x.CampaignList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_2_list{list: &x.CampaignList}) + if !f(fd_GenesisState_campaign_list, value) { + return + } + } + if len(x.RewardList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_3_list{list: &x.RewardList}) + if !f(fd_GenesisState_reward_list, value) { + return + } + } + if len(x.RewardByCategoryList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_4_list{list: &x.RewardByCategoryList}) + if !f(fd_GenesisState_reward_by_category_list, value) { + return + } + } + if len(x.RewardByCampaignList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_5_list{list: &x.RewardByCampaignList}) + if !f(fd_GenesisState_reward_by_campaign_list, value) { + return + } + } + if len(x.PromoterList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_6_list{list: &x.PromoterList}) + if !f(fd_GenesisState_promoter_list, value) { + return + } + } + if len(x.PromoterByAddressList) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_7_list{list: &x.PromoterByAddressList}) + if !f(fd_GenesisState_promoter_by_address_list, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GenesisState.params": + return x.Params != nil + case "sge.legacy.reward.v1beta.GenesisState.campaign_list": + return len(x.CampaignList) != 0 + case "sge.legacy.reward.v1beta.GenesisState.reward_list": + return len(x.RewardList) != 0 + case "sge.legacy.reward.v1beta.GenesisState.reward_by_category_list": + return len(x.RewardByCategoryList) != 0 + case "sge.legacy.reward.v1beta.GenesisState.reward_by_campaign_list": + return len(x.RewardByCampaignList) != 0 + case "sge.legacy.reward.v1beta.GenesisState.promoter_list": + return len(x.PromoterList) != 0 + case "sge.legacy.reward.v1beta.GenesisState.promoter_by_address_list": + return len(x.PromoterByAddressList) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GenesisState.params": + x.Params = nil + case "sge.legacy.reward.v1beta.GenesisState.campaign_list": + x.CampaignList = nil + case "sge.legacy.reward.v1beta.GenesisState.reward_list": + x.RewardList = nil + case "sge.legacy.reward.v1beta.GenesisState.reward_by_category_list": + x.RewardByCategoryList = nil + case "sge.legacy.reward.v1beta.GenesisState.reward_by_campaign_list": + x.RewardByCampaignList = nil + case "sge.legacy.reward.v1beta.GenesisState.promoter_list": + x.PromoterList = nil + case "sge.legacy.reward.v1beta.GenesisState.promoter_by_address_list": + x.PromoterByAddressList = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.GenesisState.campaign_list": + if len(x.CampaignList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_2_list{}) + } + listValue := &_GenesisState_2_list{list: &x.CampaignList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.GenesisState.reward_list": + if len(x.RewardList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_3_list{}) + } + listValue := &_GenesisState_3_list{list: &x.RewardList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.GenesisState.reward_by_category_list": + if len(x.RewardByCategoryList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_4_list{}) + } + listValue := &_GenesisState_4_list{list: &x.RewardByCategoryList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.GenesisState.reward_by_campaign_list": + if len(x.RewardByCampaignList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_5_list{}) + } + listValue := &_GenesisState_5_list{list: &x.RewardByCampaignList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.GenesisState.promoter_list": + if len(x.PromoterList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_6_list{}) + } + listValue := &_GenesisState_6_list{list: &x.PromoterList} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.GenesisState.promoter_by_address_list": + if len(x.PromoterByAddressList) == 0 { + return protoreflect.ValueOfList(&_GenesisState_7_list{}) + } + listValue := &_GenesisState_7_list{list: &x.PromoterByAddressList} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + case "sge.legacy.reward.v1beta.GenesisState.campaign_list": + lv := value.List() + clv := lv.(*_GenesisState_2_list) + x.CampaignList = *clv.list + case "sge.legacy.reward.v1beta.GenesisState.reward_list": + lv := value.List() + clv := lv.(*_GenesisState_3_list) + x.RewardList = *clv.list + case "sge.legacy.reward.v1beta.GenesisState.reward_by_category_list": + lv := value.List() + clv := lv.(*_GenesisState_4_list) + x.RewardByCategoryList = *clv.list + case "sge.legacy.reward.v1beta.GenesisState.reward_by_campaign_list": + lv := value.List() + clv := lv.(*_GenesisState_5_list) + x.RewardByCampaignList = *clv.list + case "sge.legacy.reward.v1beta.GenesisState.promoter_list": + lv := value.List() + clv := lv.(*_GenesisState_6_list) + x.PromoterList = *clv.list + case "sge.legacy.reward.v1beta.GenesisState.promoter_by_address_list": + lv := value.List() + clv := lv.(*_GenesisState_7_list) + x.PromoterByAddressList = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.reward.v1beta.GenesisState.campaign_list": + if x.CampaignList == nil { + x.CampaignList = []*Campaign{} + } + value := &_GenesisState_2_list{list: &x.CampaignList} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.GenesisState.reward_list": + if x.RewardList == nil { + x.RewardList = []*Reward{} + } + value := &_GenesisState_3_list{list: &x.RewardList} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.GenesisState.reward_by_category_list": + if x.RewardByCategoryList == nil { + x.RewardByCategoryList = []*RewardByCategory{} + } + value := &_GenesisState_4_list{list: &x.RewardByCategoryList} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.GenesisState.reward_by_campaign_list": + if x.RewardByCampaignList == nil { + x.RewardByCampaignList = []*RewardByCampaign{} + } + value := &_GenesisState_5_list{list: &x.RewardByCampaignList} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.GenesisState.promoter_list": + if x.PromoterList == nil { + x.PromoterList = []*Promoter{} + } + value := &_GenesisState_6_list{list: &x.PromoterList} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.GenesisState.promoter_by_address_list": + if x.PromoterByAddressList == nil { + x.PromoterByAddressList = []*PromoterByAddress{} + } + value := &_GenesisState_7_list{list: &x.PromoterByAddressList} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.GenesisState.campaign_list": + list := []*Campaign{} + return protoreflect.ValueOfList(&_GenesisState_2_list{list: &list}) + case "sge.legacy.reward.v1beta.GenesisState.reward_list": + list := []*Reward{} + return protoreflect.ValueOfList(&_GenesisState_3_list{list: &list}) + case "sge.legacy.reward.v1beta.GenesisState.reward_by_category_list": + list := []*RewardByCategory{} + return protoreflect.ValueOfList(&_GenesisState_4_list{list: &list}) + case "sge.legacy.reward.v1beta.GenesisState.reward_by_campaign_list": + list := []*RewardByCampaign{} + return protoreflect.ValueOfList(&_GenesisState_5_list{list: &list}) + case "sge.legacy.reward.v1beta.GenesisState.promoter_list": + list := []*Promoter{} + return protoreflect.ValueOfList(&_GenesisState_6_list{list: &list}) + case "sge.legacy.reward.v1beta.GenesisState.promoter_by_address_list": + list := []*PromoterByAddress{} + return protoreflect.ValueOfList(&_GenesisState_7_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.CampaignList) > 0 { + for _, e := range x.CampaignList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.RewardList) > 0 { + for _, e := range x.RewardList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.RewardByCategoryList) > 0 { + for _, e := range x.RewardByCategoryList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.RewardByCampaignList) > 0 { + for _, e := range x.RewardByCampaignList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.PromoterList) > 0 { + for _, e := range x.PromoterList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.PromoterByAddressList) > 0 { + for _, e := range x.PromoterByAddressList { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.PromoterByAddressList) > 0 { + for iNdEx := len(x.PromoterByAddressList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.PromoterByAddressList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x3a + } + } + if len(x.PromoterList) > 0 { + for iNdEx := len(x.PromoterList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.PromoterList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x32 + } + } + if len(x.RewardByCampaignList) > 0 { + for iNdEx := len(x.RewardByCampaignList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.RewardByCampaignList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x2a + } + } + if len(x.RewardByCategoryList) > 0 { + for iNdEx := len(x.RewardByCategoryList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.RewardByCategoryList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if len(x.RewardList) > 0 { + for iNdEx := len(x.RewardList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.RewardList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if len(x.CampaignList) > 0 { + for iNdEx := len(x.CampaignList) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.CampaignList[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CampaignList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CampaignList = append(x.CampaignList, &Campaign{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.CampaignList[len(x.CampaignList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.RewardList = append(x.RewardList, &Reward{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.RewardList[len(x.RewardList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardByCategoryList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.RewardByCategoryList = append(x.RewardByCategoryList, &RewardByCategory{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.RewardByCategoryList[len(x.RewardByCategoryList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardByCampaignList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.RewardByCampaignList = append(x.RewardByCampaignList, &RewardByCampaign{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.RewardByCampaignList[len(x.RewardByCampaignList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PromoterList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PromoterList = append(x.PromoterList, &Promoter{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.PromoterList[len(x.PromoterList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PromoterByAddressList", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PromoterByAddressList = append(x.PromoterByAddressList, &PromoterByAddress{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.PromoterByAddressList[len(x.PromoterByAddressList)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the reward module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` + CampaignList []*Campaign `protobuf:"bytes,2,rep,name=campaign_list,json=campaignList,proto3" json:"campaign_list,omitempty"` + RewardList []*Reward `protobuf:"bytes,3,rep,name=reward_list,json=rewardList,proto3" json:"reward_list,omitempty"` + RewardByCategoryList []*RewardByCategory `protobuf:"bytes,4,rep,name=reward_by_category_list,json=rewardByCategoryList,proto3" json:"reward_by_category_list,omitempty"` + RewardByCampaignList []*RewardByCampaign `protobuf:"bytes,5,rep,name=reward_by_campaign_list,json=rewardByCampaignList,proto3" json:"reward_by_campaign_list,omitempty"` + PromoterList []*Promoter `protobuf:"bytes,6,rep,name=promoter_list,json=promoterList,proto3" json:"promoter_list,omitempty"` + PromoterByAddressList []*PromoterByAddress `protobuf:"bytes,7,rep,name=promoter_by_address_list,json=promoterByAddressList,proto3" json:"promoter_by_address_list,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +func (x *GenesisState) GetCampaignList() []*Campaign { + if x != nil { + return x.CampaignList + } + return nil +} + +func (x *GenesisState) GetRewardList() []*Reward { + if x != nil { + return x.RewardList + } + return nil +} + +func (x *GenesisState) GetRewardByCategoryList() []*RewardByCategory { + if x != nil { + return x.RewardByCategoryList + } + return nil +} + +func (x *GenesisState) GetRewardByCampaignList() []*RewardByCampaign { + if x != nil { + return x.RewardByCampaignList + } + return nil +} + +func (x *GenesisState) GetPromoterList() []*Promoter { + if x != nil { + return x.PromoterList + } + return nil +} + +func (x *GenesisState) GetPromoterByAddressList() []*PromoterByAddress { + if x != nil { + return x.PromoterByAddressList + } + return nil +} + +var File_sge_legacy_reward_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x26, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x73, + 0x69, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, + 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2f, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x72, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xf3, 0x04, 0x0a, 0x0c, 0x47, 0x65, 0x6e, + 0x65, 0x73, 0x69, 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x3e, 0x0a, 0x06, 0x70, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, + 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x4d, 0x0a, 0x0d, 0x63, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x22, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x43, 0x61, 0x6d, 0x70, + 0x61, 0x69, 0x67, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0c, 0x63, 0x61, 0x6d, 0x70, + 0x61, 0x69, 0x67, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x47, 0x0a, 0x0b, 0x72, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, + 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0a, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x4c, 0x69, 0x73, + 0x74, 0x12, 0x67, 0x0a, 0x17, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, 0x62, 0x79, 0x5f, 0x63, + 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x42, 0x04, + 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x14, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, 0x61, + 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x67, 0x0a, 0x17, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x5f, 0x62, 0x79, 0x5f, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, + 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x14, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x4c, + 0x69, 0x73, 0x74, 0x12, 0x4d, 0x0a, 0x0d, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x5f, + 0x6c, 0x69, 0x73, 0x74, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, 0x04, + 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0c, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x4c, 0x69, + 0x73, 0x74, 0x12, 0x6a, 0x0a, 0x18, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x5f, 0x62, + 0x79, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x07, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x15, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, + 0x72, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x42, 0xf5, + 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, + 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, + 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x52, 0xaa, 0x02, 0x18, 0x53, 0x67, + 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x3a, 0x3a, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_genesis_proto_rawDescData = file_sge_legacy_reward_v1beta_genesis_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_genesis_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_genesis_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_reward_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.legacy.reward.v1beta.GenesisState + (*Params)(nil), // 1: sge.legacy.reward.v1beta.Params + (*Campaign)(nil), // 2: sge.legacy.reward.v1beta.Campaign + (*Reward)(nil), // 3: sge.legacy.reward.v1beta.Reward + (*RewardByCategory)(nil), // 4: sge.legacy.reward.v1beta.RewardByCategory + (*RewardByCampaign)(nil), // 5: sge.legacy.reward.v1beta.RewardByCampaign + (*Promoter)(nil), // 6: sge.legacy.reward.v1beta.Promoter + (*PromoterByAddress)(nil), // 7: sge.legacy.reward.v1beta.PromoterByAddress +} +var file_sge_legacy_reward_v1beta_genesis_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.reward.v1beta.GenesisState.params:type_name -> sge.legacy.reward.v1beta.Params + 2, // 1: sge.legacy.reward.v1beta.GenesisState.campaign_list:type_name -> sge.legacy.reward.v1beta.Campaign + 3, // 2: sge.legacy.reward.v1beta.GenesisState.reward_list:type_name -> sge.legacy.reward.v1beta.Reward + 4, // 3: sge.legacy.reward.v1beta.GenesisState.reward_by_category_list:type_name -> sge.legacy.reward.v1beta.RewardByCategory + 5, // 4: sge.legacy.reward.v1beta.GenesisState.reward_by_campaign_list:type_name -> sge.legacy.reward.v1beta.RewardByCampaign + 6, // 5: sge.legacy.reward.v1beta.GenesisState.promoter_list:type_name -> sge.legacy.reward.v1beta.Promoter + 7, // 6: sge.legacy.reward.v1beta.GenesisState.promoter_by_address_list:type_name -> sge.legacy.reward.v1beta.PromoterByAddress + 7, // [7:7] is the sub-list for method output_type + 7, // [7:7] is the sub-list for method input_type + 7, // [7:7] is the sub-list for extension type_name + 7, // [7:7] is the sub-list for extension extendee + 0, // [0:7] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_genesis_proto_init() } +func file_sge_legacy_reward_v1beta_genesis_proto_init() { + if File_sge_legacy_reward_v1beta_genesis_proto != nil { + return + } + file_sge_legacy_reward_v1beta_campaign_proto_init() + file_sge_legacy_reward_v1beta_params_proto_init() + file_sge_legacy_reward_v1beta_promoter_proto_init() + file_sge_legacy_reward_v1beta_reward_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_genesis_proto = out.File + file_sge_legacy_reward_v1beta_genesis_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_genesis_proto_goTypes = nil + file_sge_legacy_reward_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/params.pulsar.go b/api/sge/legacy/reward/v1beta/params.pulsar.go new file mode 100644 index 00000000..f1f992f0 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/params.pulsar.go @@ -0,0 +1,501 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Params protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_params_proto_init() + md_Params = File_sge_legacy_reward_v1beta_params_proto.Messages().ByName("Params") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params defines the parameters for the module. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +var File_sge_legacy_reward_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, + 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x0e, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xf4, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x3b, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, + 0x53, 0x4c, 0x52, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, + 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, + 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_params_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_params_proto_rawDescData = file_sge_legacy_reward_v1beta_params_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_params_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_params_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_reward_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.legacy.reward.v1beta.Params +} +var file_sge_legacy_reward_v1beta_params_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_params_proto_init() } +func file_sge_legacy_reward_v1beta_params_proto_init() { + if File_sge_legacy_reward_v1beta_params_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_params_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_params_proto = out.File + file_sge_legacy_reward_v1beta_params_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_params_proto_goTypes = nil + file_sge_legacy_reward_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/promoter.pulsar.go b/api/sge/legacy/reward/v1beta/promoter.pulsar.go new file mode 100644 index 00000000..95ef110a --- /dev/null +++ b/api/sge/legacy/reward/v1beta/promoter.pulsar.go @@ -0,0 +1,2510 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_Promoter_3_list)(nil) + +type _Promoter_3_list struct { + list *[]string +} + +func (x *_Promoter_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_Promoter_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_Promoter_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_Promoter_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_Promoter_3_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message Promoter at list field Addresses as it is not of Message kind")) +} + +func (x *_Promoter_3_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_Promoter_3_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_Promoter_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_Promoter protoreflect.MessageDescriptor + fd_Promoter_creator protoreflect.FieldDescriptor + fd_Promoter_uid protoreflect.FieldDescriptor + fd_Promoter_addresses protoreflect.FieldDescriptor + fd_Promoter_conf protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_promoter_proto_init() + md_Promoter = File_sge_legacy_reward_v1beta_promoter_proto.Messages().ByName("Promoter") + fd_Promoter_creator = md_Promoter.Fields().ByName("creator") + fd_Promoter_uid = md_Promoter.Fields().ByName("uid") + fd_Promoter_addresses = md_Promoter.Fields().ByName("addresses") + fd_Promoter_conf = md_Promoter.Fields().ByName("conf") +} + +var _ protoreflect.Message = (*fastReflection_Promoter)(nil) + +type fastReflection_Promoter Promoter + +func (x *Promoter) ProtoReflect() protoreflect.Message { + return (*fastReflection_Promoter)(x) +} + +func (x *Promoter) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Promoter_messageType fastReflection_Promoter_messageType +var _ protoreflect.MessageType = fastReflection_Promoter_messageType{} + +type fastReflection_Promoter_messageType struct{} + +func (x fastReflection_Promoter_messageType) Zero() protoreflect.Message { + return (*fastReflection_Promoter)(nil) +} +func (x fastReflection_Promoter_messageType) New() protoreflect.Message { + return new(fastReflection_Promoter) +} +func (x fastReflection_Promoter_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Promoter +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Promoter) Descriptor() protoreflect.MessageDescriptor { + return md_Promoter +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Promoter) Type() protoreflect.MessageType { + return _fastReflection_Promoter_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Promoter) New() protoreflect.Message { + return new(fastReflection_Promoter) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Promoter) Interface() protoreflect.ProtoMessage { + return (*Promoter)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Promoter) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_Promoter_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_Promoter_uid, value) { + return + } + } + if len(x.Addresses) != 0 { + value := protoreflect.ValueOfList(&_Promoter_3_list{list: &x.Addresses}) + if !f(fd_Promoter_addresses, value) { + return + } + } + if x.Conf != nil { + value := protoreflect.ValueOfMessage(x.Conf.ProtoReflect()) + if !f(fd_Promoter_conf, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Promoter) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Promoter.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.Promoter.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.Promoter.addresses": + return len(x.Addresses) != 0 + case "sge.legacy.reward.v1beta.Promoter.conf": + return x.Conf != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Promoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Promoter does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Promoter) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Promoter.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.Promoter.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.Promoter.addresses": + x.Addresses = nil + case "sge.legacy.reward.v1beta.Promoter.conf": + x.Conf = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Promoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Promoter does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Promoter) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.Promoter.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Promoter.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Promoter.addresses": + if len(x.Addresses) == 0 { + return protoreflect.ValueOfList(&_Promoter_3_list{}) + } + listValue := &_Promoter_3_list{list: &x.Addresses} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.Promoter.conf": + value := x.Conf + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Promoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Promoter does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Promoter) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Promoter.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.Promoter.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.Promoter.addresses": + lv := value.List() + clv := lv.(*_Promoter_3_list) + x.Addresses = *clv.list + case "sge.legacy.reward.v1beta.Promoter.conf": + x.Conf = value.Message().Interface().(*PromoterConf) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Promoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Promoter does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Promoter) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Promoter.addresses": + if x.Addresses == nil { + x.Addresses = []string{} + } + value := &_Promoter_3_list{list: &x.Addresses} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.Promoter.conf": + if x.Conf == nil { + x.Conf = new(PromoterConf) + } + return protoreflect.ValueOfMessage(x.Conf.ProtoReflect()) + case "sge.legacy.reward.v1beta.Promoter.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.Promoter is not mutable")) + case "sge.legacy.reward.v1beta.Promoter.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.Promoter is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Promoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Promoter does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Promoter) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Promoter.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Promoter.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Promoter.addresses": + list := []string{} + return protoreflect.ValueOfList(&_Promoter_3_list{list: &list}) + case "sge.legacy.reward.v1beta.Promoter.conf": + m := new(PromoterConf) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Promoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Promoter does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Promoter) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.Promoter", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Promoter) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Promoter) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Promoter) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Promoter) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Promoter) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.Addresses) > 0 { + for _, s := range x.Addresses { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Conf != nil { + l = options.Size(x.Conf) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Promoter) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Conf != nil { + encoded, err := options.Marshal(x.Conf) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + if len(x.Addresses) > 0 { + for iNdEx := len(x.Addresses) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.Addresses[iNdEx]) + copy(dAtA[i:], x.Addresses[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Addresses[iNdEx]))) + i-- + dAtA[i] = 0x1a + } + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Promoter) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Promoter: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Promoter: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Addresses", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Addresses = append(x.Addresses, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Conf", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Conf == nil { + x.Conf = &PromoterConf{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Conf); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_PromoterConf_1_list)(nil) + +type _PromoterConf_1_list struct { + list *[]*CategoryCap +} + +func (x *_PromoterConf_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_PromoterConf_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_PromoterConf_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*CategoryCap) + (*x.list)[i] = concreteValue +} + +func (x *_PromoterConf_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*CategoryCap) + *x.list = append(*x.list, concreteValue) +} + +func (x *_PromoterConf_1_list) AppendMutable() protoreflect.Value { + v := new(CategoryCap) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_PromoterConf_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_PromoterConf_1_list) NewElement() protoreflect.Value { + v := new(CategoryCap) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_PromoterConf_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_PromoterConf protoreflect.MessageDescriptor + fd_PromoterConf_category_cap protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_promoter_proto_init() + md_PromoterConf = File_sge_legacy_reward_v1beta_promoter_proto.Messages().ByName("PromoterConf") + fd_PromoterConf_category_cap = md_PromoterConf.Fields().ByName("category_cap") +} + +var _ protoreflect.Message = (*fastReflection_PromoterConf)(nil) + +type fastReflection_PromoterConf PromoterConf + +func (x *PromoterConf) ProtoReflect() protoreflect.Message { + return (*fastReflection_PromoterConf)(x) +} + +func (x *PromoterConf) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_PromoterConf_messageType fastReflection_PromoterConf_messageType +var _ protoreflect.MessageType = fastReflection_PromoterConf_messageType{} + +type fastReflection_PromoterConf_messageType struct{} + +func (x fastReflection_PromoterConf_messageType) Zero() protoreflect.Message { + return (*fastReflection_PromoterConf)(nil) +} +func (x fastReflection_PromoterConf_messageType) New() protoreflect.Message { + return new(fastReflection_PromoterConf) +} +func (x fastReflection_PromoterConf_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_PromoterConf +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_PromoterConf) Descriptor() protoreflect.MessageDescriptor { + return md_PromoterConf +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_PromoterConf) Type() protoreflect.MessageType { + return _fastReflection_PromoterConf_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_PromoterConf) New() protoreflect.Message { + return new(fastReflection_PromoterConf) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_PromoterConf) Interface() protoreflect.ProtoMessage { + return (*PromoterConf)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_PromoterConf) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.CategoryCap) != 0 { + value := protoreflect.ValueOfList(&_PromoterConf_1_list{list: &x.CategoryCap}) + if !f(fd_PromoterConf_category_cap, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_PromoterConf) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterConf.category_cap": + return len(x.CategoryCap) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterConf does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterConf) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterConf.category_cap": + x.CategoryCap = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterConf does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_PromoterConf) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.PromoterConf.category_cap": + if len(x.CategoryCap) == 0 { + return protoreflect.ValueOfList(&_PromoterConf_1_list{}) + } + listValue := &_PromoterConf_1_list{list: &x.CategoryCap} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterConf does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterConf) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterConf.category_cap": + lv := value.List() + clv := lv.(*_PromoterConf_1_list) + x.CategoryCap = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterConf does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterConf) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterConf.category_cap": + if x.CategoryCap == nil { + x.CategoryCap = []*CategoryCap{} + } + value := &_PromoterConf_1_list{list: &x.CategoryCap} + return protoreflect.ValueOfList(value) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterConf does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_PromoterConf) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterConf.category_cap": + list := []*CategoryCap{} + return protoreflect.ValueOfList(&_PromoterConf_1_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterConf does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_PromoterConf) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.PromoterConf", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_PromoterConf) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterConf) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_PromoterConf) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_PromoterConf) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*PromoterConf) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.CategoryCap) > 0 { + for _, e := range x.CategoryCap { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*PromoterConf) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.CategoryCap) > 0 { + for iNdEx := len(x.CategoryCap) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.CategoryCap[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*PromoterConf) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PromoterConf: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PromoterConf: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CategoryCap", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CategoryCap = append(x.CategoryCap, &CategoryCap{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.CategoryCap[len(x.CategoryCap)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_CategoryCap protoreflect.MessageDescriptor + fd_CategoryCap_category protoreflect.FieldDescriptor + fd_CategoryCap_cap_per_acc protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_promoter_proto_init() + md_CategoryCap = File_sge_legacy_reward_v1beta_promoter_proto.Messages().ByName("CategoryCap") + fd_CategoryCap_category = md_CategoryCap.Fields().ByName("category") + fd_CategoryCap_cap_per_acc = md_CategoryCap.Fields().ByName("cap_per_acc") +} + +var _ protoreflect.Message = (*fastReflection_CategoryCap)(nil) + +type fastReflection_CategoryCap CategoryCap + +func (x *CategoryCap) ProtoReflect() protoreflect.Message { + return (*fastReflection_CategoryCap)(x) +} + +func (x *CategoryCap) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_CategoryCap_messageType fastReflection_CategoryCap_messageType +var _ protoreflect.MessageType = fastReflection_CategoryCap_messageType{} + +type fastReflection_CategoryCap_messageType struct{} + +func (x fastReflection_CategoryCap_messageType) Zero() protoreflect.Message { + return (*fastReflection_CategoryCap)(nil) +} +func (x fastReflection_CategoryCap_messageType) New() protoreflect.Message { + return new(fastReflection_CategoryCap) +} +func (x fastReflection_CategoryCap_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_CategoryCap +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_CategoryCap) Descriptor() protoreflect.MessageDescriptor { + return md_CategoryCap +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_CategoryCap) Type() protoreflect.MessageType { + return _fastReflection_CategoryCap_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_CategoryCap) New() protoreflect.Message { + return new(fastReflection_CategoryCap) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_CategoryCap) Interface() protoreflect.ProtoMessage { + return (*CategoryCap)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_CategoryCap) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Category != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Category)) + if !f(fd_CategoryCap_category, value) { + return + } + } + if x.CapPerAcc != int32(0) { + value := protoreflect.ValueOfInt32(x.CapPerAcc) + if !f(fd_CategoryCap_cap_per_acc, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_CategoryCap) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CategoryCap.category": + return x.Category != 0 + case "sge.legacy.reward.v1beta.CategoryCap.cap_per_acc": + return x.CapPerAcc != int32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CategoryCap")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CategoryCap does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CategoryCap) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CategoryCap.category": + x.Category = 0 + case "sge.legacy.reward.v1beta.CategoryCap.cap_per_acc": + x.CapPerAcc = int32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CategoryCap")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CategoryCap does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_CategoryCap) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.CategoryCap.category": + value := x.Category + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.CategoryCap.cap_per_acc": + value := x.CapPerAcc + return protoreflect.ValueOfInt32(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CategoryCap")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CategoryCap does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CategoryCap) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CategoryCap.category": + x.Category = (RewardCategory)(value.Enum()) + case "sge.legacy.reward.v1beta.CategoryCap.cap_per_acc": + x.CapPerAcc = int32(value.Int()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CategoryCap")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CategoryCap does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CategoryCap) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CategoryCap.category": + panic(fmt.Errorf("field category of message sge.legacy.reward.v1beta.CategoryCap is not mutable")) + case "sge.legacy.reward.v1beta.CategoryCap.cap_per_acc": + panic(fmt.Errorf("field cap_per_acc of message sge.legacy.reward.v1beta.CategoryCap is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CategoryCap")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CategoryCap does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_CategoryCap) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CategoryCap.category": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.CategoryCap.cap_per_acc": + return protoreflect.ValueOfInt32(int32(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CategoryCap")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CategoryCap does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_CategoryCap) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.CategoryCap", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_CategoryCap) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CategoryCap) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_CategoryCap) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_CategoryCap) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*CategoryCap) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Category != 0 { + n += 1 + runtime.Sov(uint64(x.Category)) + } + if x.CapPerAcc != 0 { + n += 1 + runtime.Sov(uint64(x.CapPerAcc)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*CategoryCap) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.CapPerAcc != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.CapPerAcc)) + i-- + dAtA[i] = 0x10 + } + if x.Category != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Category)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*CategoryCap) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CategoryCap: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CategoryCap: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Category", wireType) + } + x.Category = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Category |= RewardCategory(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CapPerAcc", wireType) + } + x.CapPerAcc = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.CapPerAcc |= int32(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_PromoterByAddress protoreflect.MessageDescriptor + fd_PromoterByAddress_promoter_uid protoreflect.FieldDescriptor + fd_PromoterByAddress_address protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_promoter_proto_init() + md_PromoterByAddress = File_sge_legacy_reward_v1beta_promoter_proto.Messages().ByName("PromoterByAddress") + fd_PromoterByAddress_promoter_uid = md_PromoterByAddress.Fields().ByName("promoter_uid") + fd_PromoterByAddress_address = md_PromoterByAddress.Fields().ByName("address") +} + +var _ protoreflect.Message = (*fastReflection_PromoterByAddress)(nil) + +type fastReflection_PromoterByAddress PromoterByAddress + +func (x *PromoterByAddress) ProtoReflect() protoreflect.Message { + return (*fastReflection_PromoterByAddress)(x) +} + +func (x *PromoterByAddress) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_PromoterByAddress_messageType fastReflection_PromoterByAddress_messageType +var _ protoreflect.MessageType = fastReflection_PromoterByAddress_messageType{} + +type fastReflection_PromoterByAddress_messageType struct{} + +func (x fastReflection_PromoterByAddress_messageType) Zero() protoreflect.Message { + return (*fastReflection_PromoterByAddress)(nil) +} +func (x fastReflection_PromoterByAddress_messageType) New() protoreflect.Message { + return new(fastReflection_PromoterByAddress) +} +func (x fastReflection_PromoterByAddress_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_PromoterByAddress +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_PromoterByAddress) Descriptor() protoreflect.MessageDescriptor { + return md_PromoterByAddress +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_PromoterByAddress) Type() protoreflect.MessageType { + return _fastReflection_PromoterByAddress_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_PromoterByAddress) New() protoreflect.Message { + return new(fastReflection_PromoterByAddress) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_PromoterByAddress) Interface() protoreflect.ProtoMessage { + return (*PromoterByAddress)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_PromoterByAddress) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.PromoterUid != "" { + value := protoreflect.ValueOfString(x.PromoterUid) + if !f(fd_PromoterByAddress_promoter_uid, value) { + return + } + } + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_PromoterByAddress_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_PromoterByAddress) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterByAddress.promoter_uid": + return x.PromoterUid != "" + case "sge.legacy.reward.v1beta.PromoterByAddress.address": + return x.Address != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterByAddress")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterByAddress does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterByAddress) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterByAddress.promoter_uid": + x.PromoterUid = "" + case "sge.legacy.reward.v1beta.PromoterByAddress.address": + x.Address = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterByAddress")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterByAddress does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_PromoterByAddress) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.PromoterByAddress.promoter_uid": + value := x.PromoterUid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.PromoterByAddress.address": + value := x.Address + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterByAddress")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterByAddress does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterByAddress) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterByAddress.promoter_uid": + x.PromoterUid = value.Interface().(string) + case "sge.legacy.reward.v1beta.PromoterByAddress.address": + x.Address = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterByAddress")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterByAddress does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterByAddress) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterByAddress.promoter_uid": + panic(fmt.Errorf("field promoter_uid of message sge.legacy.reward.v1beta.PromoterByAddress is not mutable")) + case "sge.legacy.reward.v1beta.PromoterByAddress.address": + panic(fmt.Errorf("field address of message sge.legacy.reward.v1beta.PromoterByAddress is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterByAddress")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterByAddress does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_PromoterByAddress) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.PromoterByAddress.promoter_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.PromoterByAddress.address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.PromoterByAddress")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.PromoterByAddress does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_PromoterByAddress) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.PromoterByAddress", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_PromoterByAddress) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_PromoterByAddress) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_PromoterByAddress) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_PromoterByAddress) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*PromoterByAddress) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.PromoterUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*PromoterByAddress) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0x12 + } + if len(x.PromoterUid) > 0 { + i -= len(x.PromoterUid) + copy(dAtA[i:], x.PromoterUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PromoterUid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*PromoterByAddress) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PromoterByAddress: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: PromoterByAddress: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PromoterUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PromoterUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/promoter.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Promoter is type for defining the reward promoter properties and +// configuration. +type Promoter struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of promoter. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // uid is the unique identifier of a promoter. + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` + // addresses is the list of account addresses of promoter. + Addresses []string `protobuf:"bytes,3,rep,name=addresses,proto3" json:"addresses,omitempty"` + // conf is the configurations of the current promoter for the reward grant. + Conf *PromoterConf `protobuf:"bytes,4,opt,name=conf,proto3" json:"conf,omitempty"` +} + +func (x *Promoter) Reset() { + *x = Promoter{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Promoter) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Promoter) ProtoMessage() {} + +// Deprecated: Use Promoter.ProtoReflect.Descriptor instead. +func (*Promoter) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_promoter_proto_rawDescGZIP(), []int{0} +} + +func (x *Promoter) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *Promoter) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *Promoter) GetAddresses() []string { + if x != nil { + return x.Addresses + } + return nil +} + +func (x *Promoter) GetConf() *PromoterConf { + if x != nil { + return x.Conf + } + return nil +} + +// PromoterConf is type for defining the promoter specific configurations. +type PromoterConf struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // category_cap is the maximium allowed cap for each category. + CategoryCap []*CategoryCap `protobuf:"bytes,1,rep,name=category_cap,json=categoryCap,proto3" json:"category_cap,omitempty"` +} + +func (x *PromoterConf) Reset() { + *x = PromoterConf{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PromoterConf) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PromoterConf) ProtoMessage() {} + +// Deprecated: Use PromoterConf.ProtoReflect.Descriptor instead. +func (*PromoterConf) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_promoter_proto_rawDescGZIP(), []int{1} +} + +func (x *PromoterConf) GetCategoryCap() []*CategoryCap { + if x != nil { + return x.CategoryCap + } + return nil +} + +// CategoryCap is type to define category and its maximum cap. +type CategoryCap struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Category RewardCategory `protobuf:"varint,1,opt,name=category,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"category,omitempty"` + CapPerAcc int32 `protobuf:"varint,2,opt,name=cap_per_acc,json=capPerAcc,proto3" json:"cap_per_acc,omitempty"` +} + +func (x *CategoryCap) Reset() { + *x = CategoryCap{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CategoryCap) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CategoryCap) ProtoMessage() {} + +// Deprecated: Use CategoryCap.ProtoReflect.Descriptor instead. +func (*CategoryCap) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_promoter_proto_rawDescGZIP(), []int{2} +} + +func (x *CategoryCap) GetCategory() RewardCategory { + if x != nil { + return x.Category + } + return RewardCategory_REWARD_CATEGORY_UNSPECIFIED +} + +func (x *CategoryCap) GetCapPerAcc() int32 { + if x != nil { + return x.CapPerAcc + } + return 0 +} + +// PromoterByAddress is type for defining the promoter by address. +type PromoterByAddress struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // promoter_uid is the unique identifier of a certain promoter. + PromoterUid string `protobuf:"bytes,1,opt,name=promoter_uid,proto3" json:"promoter_uid,omitempty"` + // address is the address of the promoter account. + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` +} + +func (x *PromoterByAddress) Reset() { + *x = PromoterByAddress{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PromoterByAddress) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PromoterByAddress) ProtoMessage() {} + +// Deprecated: Use PromoterByAddress.ProtoReflect.Descriptor instead. +func (*PromoterByAddress) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_promoter_proto_rawDescGZIP(), []int{3} +} + +func (x *PromoterByAddress) GetPromoterUid() string { + if x != nil { + return x.PromoterUid + } + return "" +} + +func (x *PromoterByAddress) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +var File_sge_legacy_reward_v1beta_promoter_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_promoter_proto_rawDesc = []byte{ + 0x0a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x6f, + 0x74, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, + 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xc0, 0x01, 0x0a, 0x08, + 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x20, 0x0a, 0x03, + 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, + 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x1c, + 0x0a, 0x09, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, + 0x09, 0x52, 0x09, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73, 0x12, 0x40, 0x0a, 0x04, + 0x63, 0x6f, 0x6e, 0x66, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x43, 0x6f, + 0x6e, 0x66, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x04, 0x63, 0x6f, 0x6e, 0x66, 0x22, 0x5e, + 0x0a, 0x0c, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x12, 0x4e, + 0x0a, 0x0c, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x5f, 0x63, 0x61, 0x70, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x43, 0x61, 0x70, 0x42, 0x04, 0xc8, 0xde, 0x1f, + 0x00, 0x52, 0x0b, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x43, 0x61, 0x70, 0x22, 0x73, + 0x0a, 0x0b, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x43, 0x61, 0x70, 0x12, 0x44, 0x0a, + 0x08, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, + 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x08, 0x63, 0x61, 0x74, 0x65, 0x67, + 0x6f, 0x72, 0x79, 0x12, 0x1e, 0x0a, 0x0b, 0x63, 0x61, 0x70, 0x5f, 0x70, 0x65, 0x72, 0x5f, 0x61, + 0x63, 0x63, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x63, 0x61, 0x70, 0x50, 0x65, 0x72, + 0x41, 0x63, 0x63, 0x22, 0x8c, 0x01, 0x0a, 0x11, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, + 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x43, 0x0a, 0x0c, 0x70, 0x72, 0x6f, + 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x1f, 0xe2, 0xde, 0x1f, 0x0b, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x55, 0x49, 0x44, + 0xea, 0xde, 0x1f, 0x0c, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x5f, 0x75, 0x69, 0x64, + 0x52, 0x0c, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x32, + 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x42, 0xf6, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x42, 0x0d, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x52, + 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, + 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, + 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_promoter_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_promoter_proto_rawDescData = file_sge_legacy_reward_v1beta_promoter_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_promoter_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_promoter_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_promoter_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_promoter_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_promoter_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_promoter_proto_msgTypes = make([]protoimpl.MessageInfo, 4) +var file_sge_legacy_reward_v1beta_promoter_proto_goTypes = []interface{}{ + (*Promoter)(nil), // 0: sge.legacy.reward.v1beta.Promoter + (*PromoterConf)(nil), // 1: sge.legacy.reward.v1beta.PromoterConf + (*CategoryCap)(nil), // 2: sge.legacy.reward.v1beta.CategoryCap + (*PromoterByAddress)(nil), // 3: sge.legacy.reward.v1beta.PromoterByAddress + (RewardCategory)(0), // 4: sge.legacy.reward.v1beta.RewardCategory +} +var file_sge_legacy_reward_v1beta_promoter_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.reward.v1beta.Promoter.conf:type_name -> sge.legacy.reward.v1beta.PromoterConf + 2, // 1: sge.legacy.reward.v1beta.PromoterConf.category_cap:type_name -> sge.legacy.reward.v1beta.CategoryCap + 4, // 2: sge.legacy.reward.v1beta.CategoryCap.category:type_name -> sge.legacy.reward.v1beta.RewardCategory + 3, // [3:3] is the sub-list for method output_type + 3, // [3:3] is the sub-list for method input_type + 3, // [3:3] is the sub-list for extension type_name + 3, // [3:3] is the sub-list for extension extendee + 0, // [0:3] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_promoter_proto_init() } +func file_sge_legacy_reward_v1beta_promoter_proto_init() { + if File_sge_legacy_reward_v1beta_promoter_proto != nil { + return + } + file_sge_legacy_reward_v1beta_reward_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Promoter); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PromoterConf); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CategoryCap); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_promoter_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PromoterByAddress); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_promoter_proto_rawDesc, + NumEnums: 0, + NumMessages: 4, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_v1beta_promoter_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_promoter_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_promoter_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_promoter_proto = out.File + file_sge_legacy_reward_v1beta_promoter_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_promoter_proto_goTypes = nil + file_sge_legacy_reward_v1beta_promoter_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/query.pulsar.go b/api/sge/legacy/reward/v1beta/query.pulsar.go new file mode 100644 index 00000000..7aeb1471 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/query.pulsar.go @@ -0,0 +1,11301 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + v1beta1 "cosmossdk.io/api/cosmos/base/query/v1beta1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPromoterByAddressRequest protoreflect.MessageDescriptor + fd_QueryPromoterByAddressRequest_addr protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryPromoterByAddressRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryPromoterByAddressRequest") + fd_QueryPromoterByAddressRequest_addr = md_QueryPromoterByAddressRequest.Fields().ByName("addr") +} + +var _ protoreflect.Message = (*fastReflection_QueryPromoterByAddressRequest)(nil) + +type fastReflection_QueryPromoterByAddressRequest QueryPromoterByAddressRequest + +func (x *QueryPromoterByAddressRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPromoterByAddressRequest)(x) +} + +func (x *QueryPromoterByAddressRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPromoterByAddressRequest_messageType fastReflection_QueryPromoterByAddressRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPromoterByAddressRequest_messageType{} + +type fastReflection_QueryPromoterByAddressRequest_messageType struct{} + +func (x fastReflection_QueryPromoterByAddressRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPromoterByAddressRequest)(nil) +} +func (x fastReflection_QueryPromoterByAddressRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPromoterByAddressRequest) +} +func (x fastReflection_QueryPromoterByAddressRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromoterByAddressRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPromoterByAddressRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromoterByAddressRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPromoterByAddressRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPromoterByAddressRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPromoterByAddressRequest) New() protoreflect.Message { + return new(fastReflection_QueryPromoterByAddressRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPromoterByAddressRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPromoterByAddressRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPromoterByAddressRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Addr != "" { + value := protoreflect.ValueOfString(x.Addr) + if !f(fd_QueryPromoterByAddressRequest_addr, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPromoterByAddressRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressRequest.addr": + return x.Addr != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressRequest.addr": + x.Addr = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPromoterByAddressRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressRequest.addr": + value := x.Addr + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressRequest.addr": + x.Addr = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressRequest.addr": + panic(fmt.Errorf("field addr of message sge.legacy.reward.v1beta.QueryPromoterByAddressRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPromoterByAddressRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressRequest.addr": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPromoterByAddressRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryPromoterByAddressRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPromoterByAddressRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPromoterByAddressRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPromoterByAddressRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPromoterByAddressRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Addr) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPromoterByAddressRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Addr) > 0 { + i -= len(x.Addr) + copy(dAtA[i:], x.Addr) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Addr))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPromoterByAddressRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromoterByAddressRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromoterByAddressRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Addr", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Addr = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPromoterByAddressResponse protoreflect.MessageDescriptor + fd_QueryPromoterByAddressResponse_promoter protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryPromoterByAddressResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryPromoterByAddressResponse") + fd_QueryPromoterByAddressResponse_promoter = md_QueryPromoterByAddressResponse.Fields().ByName("promoter") +} + +var _ protoreflect.Message = (*fastReflection_QueryPromoterByAddressResponse)(nil) + +type fastReflection_QueryPromoterByAddressResponse QueryPromoterByAddressResponse + +func (x *QueryPromoterByAddressResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPromoterByAddressResponse)(x) +} + +func (x *QueryPromoterByAddressResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPromoterByAddressResponse_messageType fastReflection_QueryPromoterByAddressResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPromoterByAddressResponse_messageType{} + +type fastReflection_QueryPromoterByAddressResponse_messageType struct{} + +func (x fastReflection_QueryPromoterByAddressResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPromoterByAddressResponse)(nil) +} +func (x fastReflection_QueryPromoterByAddressResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPromoterByAddressResponse) +} +func (x fastReflection_QueryPromoterByAddressResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromoterByAddressResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPromoterByAddressResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromoterByAddressResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPromoterByAddressResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPromoterByAddressResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPromoterByAddressResponse) New() protoreflect.Message { + return new(fastReflection_QueryPromoterByAddressResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPromoterByAddressResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPromoterByAddressResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPromoterByAddressResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Promoter != nil { + value := protoreflect.ValueOfMessage(x.Promoter.ProtoReflect()) + if !f(fd_QueryPromoterByAddressResponse_promoter, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPromoterByAddressResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressResponse.promoter": + return x.Promoter != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressResponse.promoter": + x.Promoter = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPromoterByAddressResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressResponse.promoter": + value := x.Promoter + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressResponse.promoter": + x.Promoter = value.Message().Interface().(*Promoter) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressResponse.promoter": + if x.Promoter == nil { + x.Promoter = new(Promoter) + } + return protoreflect.ValueOfMessage(x.Promoter.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPromoterByAddressResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromoterByAddressResponse.promoter": + m := new(Promoter) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromoterByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPromoterByAddressResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryPromoterByAddressResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPromoterByAddressResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromoterByAddressResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPromoterByAddressResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPromoterByAddressResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPromoterByAddressResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Promoter != nil { + l = options.Size(x.Promoter) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPromoterByAddressResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Promoter != nil { + encoded, err := options.Marshal(x.Promoter) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPromoterByAddressResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromoterByAddressResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromoterByAddressResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Promoter", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Promoter == nil { + x.Promoter = &Promoter{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Promoter); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPromotersRequest protoreflect.MessageDescriptor + fd_QueryPromotersRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryPromotersRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryPromotersRequest") + fd_QueryPromotersRequest_pagination = md_QueryPromotersRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryPromotersRequest)(nil) + +type fastReflection_QueryPromotersRequest QueryPromotersRequest + +func (x *QueryPromotersRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPromotersRequest)(x) +} + +func (x *QueryPromotersRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPromotersRequest_messageType fastReflection_QueryPromotersRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPromotersRequest_messageType{} + +type fastReflection_QueryPromotersRequest_messageType struct{} + +func (x fastReflection_QueryPromotersRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPromotersRequest)(nil) +} +func (x fastReflection_QueryPromotersRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPromotersRequest) +} +func (x fastReflection_QueryPromotersRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromotersRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPromotersRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromotersRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPromotersRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPromotersRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPromotersRequest) New() protoreflect.Message { + return new(fastReflection_QueryPromotersRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPromotersRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPromotersRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPromotersRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryPromotersRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPromotersRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPromotersRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPromotersRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPromotersRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryPromotersRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPromotersRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPromotersRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPromotersRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPromotersRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPromotersRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPromotersRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromotersRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromotersRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryPromotersResponse_1_list)(nil) + +type _QueryPromotersResponse_1_list struct { + list *[]*Promoter +} + +func (x *_QueryPromotersResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryPromotersResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryPromotersResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Promoter) + (*x.list)[i] = concreteValue +} + +func (x *_QueryPromotersResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Promoter) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryPromotersResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Promoter) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryPromotersResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryPromotersResponse_1_list) NewElement() protoreflect.Value { + v := new(Promoter) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryPromotersResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryPromotersResponse protoreflect.MessageDescriptor + fd_QueryPromotersResponse_promoter protoreflect.FieldDescriptor + fd_QueryPromotersResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryPromotersResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryPromotersResponse") + fd_QueryPromotersResponse_promoter = md_QueryPromotersResponse.Fields().ByName("promoter") + fd_QueryPromotersResponse_pagination = md_QueryPromotersResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryPromotersResponse)(nil) + +type fastReflection_QueryPromotersResponse QueryPromotersResponse + +func (x *QueryPromotersResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPromotersResponse)(x) +} + +func (x *QueryPromotersResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPromotersResponse_messageType fastReflection_QueryPromotersResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPromotersResponse_messageType{} + +type fastReflection_QueryPromotersResponse_messageType struct{} + +func (x fastReflection_QueryPromotersResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPromotersResponse)(nil) +} +func (x fastReflection_QueryPromotersResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPromotersResponse) +} +func (x fastReflection_QueryPromotersResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromotersResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPromotersResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPromotersResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPromotersResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPromotersResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPromotersResponse) New() protoreflect.Message { + return new(fastReflection_QueryPromotersResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPromotersResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPromotersResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPromotersResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Promoter) != 0 { + value := protoreflect.ValueOfList(&_QueryPromotersResponse_1_list{list: &x.Promoter}) + if !f(fd_QueryPromotersResponse_promoter, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryPromotersResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPromotersResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersResponse.promoter": + return len(x.Promoter) != 0 + case "sge.legacy.reward.v1beta.QueryPromotersResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersResponse.promoter": + x.Promoter = nil + case "sge.legacy.reward.v1beta.QueryPromotersResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPromotersResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersResponse.promoter": + if len(x.Promoter) == 0 { + return protoreflect.ValueOfList(&_QueryPromotersResponse_1_list{}) + } + listValue := &_QueryPromotersResponse_1_list{list: &x.Promoter} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.QueryPromotersResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersResponse.promoter": + lv := value.List() + clv := lv.(*_QueryPromotersResponse_1_list) + x.Promoter = *clv.list + case "sge.legacy.reward.v1beta.QueryPromotersResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersResponse.promoter": + if x.Promoter == nil { + x.Promoter = []*Promoter{} + } + value := &_QueryPromotersResponse_1_list{list: &x.Promoter} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.QueryPromotersResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPromotersResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryPromotersResponse.promoter": + list := []*Promoter{} + return protoreflect.ValueOfList(&_QueryPromotersResponse_1_list{list: &list}) + case "sge.legacy.reward.v1beta.QueryPromotersResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryPromotersResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryPromotersResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPromotersResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryPromotersResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPromotersResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPromotersResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPromotersResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPromotersResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPromotersResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Promoter) > 0 { + for _, e := range x.Promoter { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPromotersResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Promoter) > 0 { + for iNdEx := len(x.Promoter) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Promoter[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPromotersResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromotersResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPromotersResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Promoter", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Promoter = append(x.Promoter, &Promoter{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Promoter[len(x.Promoter)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryCampaignRequest protoreflect.MessageDescriptor + fd_QueryCampaignRequest_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryCampaignRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryCampaignRequest") + fd_QueryCampaignRequest_uid = md_QueryCampaignRequest.Fields().ByName("uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryCampaignRequest)(nil) + +type fastReflection_QueryCampaignRequest QueryCampaignRequest + +func (x *QueryCampaignRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCampaignRequest)(x) +} + +func (x *QueryCampaignRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryCampaignRequest_messageType fastReflection_QueryCampaignRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryCampaignRequest_messageType{} + +type fastReflection_QueryCampaignRequest_messageType struct{} + +func (x fastReflection_QueryCampaignRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCampaignRequest)(nil) +} +func (x fastReflection_QueryCampaignRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCampaignRequest) +} +func (x fastReflection_QueryCampaignRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryCampaignRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryCampaignRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryCampaignRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryCampaignRequest) New() protoreflect.Message { + return new(fastReflection_QueryCampaignRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryCampaignRequest) Interface() protoreflect.ProtoMessage { + return (*QueryCampaignRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryCampaignRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_QueryCampaignRequest_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryCampaignRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignRequest.uid": + return x.Uid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignRequest.uid": + x.Uid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryCampaignRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignRequest.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignRequest.uid": + x.Uid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignRequest.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.QueryCampaignRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryCampaignRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignRequest.uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryCampaignRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryCampaignRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryCampaignRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryCampaignRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryCampaignRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryCampaignRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryCampaignResponse protoreflect.MessageDescriptor + fd_QueryCampaignResponse_campaign protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryCampaignResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryCampaignResponse") + fd_QueryCampaignResponse_campaign = md_QueryCampaignResponse.Fields().ByName("campaign") +} + +var _ protoreflect.Message = (*fastReflection_QueryCampaignResponse)(nil) + +type fastReflection_QueryCampaignResponse QueryCampaignResponse + +func (x *QueryCampaignResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCampaignResponse)(x) +} + +func (x *QueryCampaignResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryCampaignResponse_messageType fastReflection_QueryCampaignResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryCampaignResponse_messageType{} + +type fastReflection_QueryCampaignResponse_messageType struct{} + +func (x fastReflection_QueryCampaignResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCampaignResponse)(nil) +} +func (x fastReflection_QueryCampaignResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCampaignResponse) +} +func (x fastReflection_QueryCampaignResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryCampaignResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryCampaignResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryCampaignResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryCampaignResponse) New() protoreflect.Message { + return new(fastReflection_QueryCampaignResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryCampaignResponse) Interface() protoreflect.ProtoMessage { + return (*QueryCampaignResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryCampaignResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Campaign != nil { + value := protoreflect.ValueOfMessage(x.Campaign.ProtoReflect()) + if !f(fd_QueryCampaignResponse_campaign, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryCampaignResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignResponse.campaign": + return x.Campaign != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignResponse.campaign": + x.Campaign = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryCampaignResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignResponse.campaign": + value := x.Campaign + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignResponse.campaign": + x.Campaign = value.Message().Interface().(*Campaign) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignResponse.campaign": + if x.Campaign == nil { + x.Campaign = new(Campaign) + } + return protoreflect.ValueOfMessage(x.Campaign.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryCampaignResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignResponse.campaign": + m := new(Campaign) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryCampaignResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryCampaignResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryCampaignResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryCampaignResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryCampaignResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryCampaignResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Campaign != nil { + l = options.Size(x.Campaign) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Campaign != nil { + encoded, err := options.Marshal(x.Campaign) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Campaign", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Campaign == nil { + x.Campaign = &Campaign{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Campaign); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryCampaignsRequest protoreflect.MessageDescriptor + fd_QueryCampaignsRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryCampaignsRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryCampaignsRequest") + fd_QueryCampaignsRequest_pagination = md_QueryCampaignsRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryCampaignsRequest)(nil) + +type fastReflection_QueryCampaignsRequest QueryCampaignsRequest + +func (x *QueryCampaignsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCampaignsRequest)(x) +} + +func (x *QueryCampaignsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryCampaignsRequest_messageType fastReflection_QueryCampaignsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryCampaignsRequest_messageType{} + +type fastReflection_QueryCampaignsRequest_messageType struct{} + +func (x fastReflection_QueryCampaignsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCampaignsRequest)(nil) +} +func (x fastReflection_QueryCampaignsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCampaignsRequest) +} +func (x fastReflection_QueryCampaignsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryCampaignsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryCampaignsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryCampaignsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryCampaignsRequest) New() protoreflect.Message { + return new(fastReflection_QueryCampaignsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryCampaignsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryCampaignsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryCampaignsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryCampaignsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryCampaignsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryCampaignsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryCampaignsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryCampaignsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryCampaignsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryCampaignsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryCampaignsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryCampaignsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryCampaignsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryCampaignsResponse_1_list)(nil) + +type _QueryCampaignsResponse_1_list struct { + list *[]*Campaign +} + +func (x *_QueryCampaignsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryCampaignsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryCampaignsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Campaign) + (*x.list)[i] = concreteValue +} + +func (x *_QueryCampaignsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Campaign) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryCampaignsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Campaign) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryCampaignsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryCampaignsResponse_1_list) NewElement() protoreflect.Value { + v := new(Campaign) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryCampaignsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryCampaignsResponse protoreflect.MessageDescriptor + fd_QueryCampaignsResponse_campaign protoreflect.FieldDescriptor + fd_QueryCampaignsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryCampaignsResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryCampaignsResponse") + fd_QueryCampaignsResponse_campaign = md_QueryCampaignsResponse.Fields().ByName("campaign") + fd_QueryCampaignsResponse_pagination = md_QueryCampaignsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryCampaignsResponse)(nil) + +type fastReflection_QueryCampaignsResponse QueryCampaignsResponse + +func (x *QueryCampaignsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryCampaignsResponse)(x) +} + +func (x *QueryCampaignsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryCampaignsResponse_messageType fastReflection_QueryCampaignsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryCampaignsResponse_messageType{} + +type fastReflection_QueryCampaignsResponse_messageType struct{} + +func (x fastReflection_QueryCampaignsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryCampaignsResponse)(nil) +} +func (x fastReflection_QueryCampaignsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryCampaignsResponse) +} +func (x fastReflection_QueryCampaignsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryCampaignsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryCampaignsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryCampaignsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryCampaignsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryCampaignsResponse) New() protoreflect.Message { + return new(fastReflection_QueryCampaignsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryCampaignsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryCampaignsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryCampaignsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Campaign) != 0 { + value := protoreflect.ValueOfList(&_QueryCampaignsResponse_1_list{list: &x.Campaign}) + if !f(fd_QueryCampaignsResponse_campaign, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryCampaignsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryCampaignsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.campaign": + return len(x.Campaign) != 0 + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.campaign": + x.Campaign = nil + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryCampaignsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.campaign": + if len(x.Campaign) == 0 { + return protoreflect.ValueOfList(&_QueryCampaignsResponse_1_list{}) + } + listValue := &_QueryCampaignsResponse_1_list{list: &x.Campaign} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.campaign": + lv := value.List() + clv := lv.(*_QueryCampaignsResponse_1_list) + x.Campaign = *clv.list + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.campaign": + if x.Campaign == nil { + x.Campaign = []*Campaign{} + } + value := &_QueryCampaignsResponse_1_list{list: &x.Campaign} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryCampaignsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.campaign": + list := []*Campaign{} + return protoreflect.ValueOfList(&_QueryCampaignsResponse_1_list{list: &list}) + case "sge.legacy.reward.v1beta.QueryCampaignsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryCampaignsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryCampaignsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryCampaignsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryCampaignsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryCampaignsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryCampaignsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryCampaignsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryCampaignsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryCampaignsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Campaign) > 0 { + for _, e := range x.Campaign { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Campaign) > 0 { + for iNdEx := len(x.Campaign) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Campaign[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryCampaignsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryCampaignsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Campaign", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Campaign = append(x.Campaign, &Campaign{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Campaign[len(x.Campaign)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryRewardRequest protoreflect.MessageDescriptor + fd_QueryRewardRequest_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardRequest") + fd_QueryRewardRequest_uid = md_QueryRewardRequest.Fields().ByName("uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardRequest)(nil) + +type fastReflection_QueryRewardRequest QueryRewardRequest + +func (x *QueryRewardRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardRequest)(x) +} + +func (x *QueryRewardRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardRequest_messageType fastReflection_QueryRewardRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardRequest_messageType{} + +type fastReflection_QueryRewardRequest_messageType struct{} + +func (x fastReflection_QueryRewardRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardRequest)(nil) +} +func (x fastReflection_QueryRewardRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardRequest) +} +func (x fastReflection_QueryRewardRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardRequest) New() protoreflect.Message { + return new(fastReflection_QueryRewardRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardRequest) Interface() protoreflect.ProtoMessage { + return (*QueryRewardRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_QueryRewardRequest_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardRequest.uid": + return x.Uid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardRequest.uid": + x.Uid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardRequest.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardRequest.uid": + x.Uid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardRequest.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.QueryRewardRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardRequest.uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryRewardResponse protoreflect.MessageDescriptor + fd_QueryRewardResponse_reward protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardResponse") + fd_QueryRewardResponse_reward = md_QueryRewardResponse.Fields().ByName("reward") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardResponse)(nil) + +type fastReflection_QueryRewardResponse QueryRewardResponse + +func (x *QueryRewardResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardResponse)(x) +} + +func (x *QueryRewardResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardResponse_messageType fastReflection_QueryRewardResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardResponse_messageType{} + +type fastReflection_QueryRewardResponse_messageType struct{} + +func (x fastReflection_QueryRewardResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardResponse)(nil) +} +func (x fastReflection_QueryRewardResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardResponse) +} +func (x fastReflection_QueryRewardResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardResponse) New() protoreflect.Message { + return new(fastReflection_QueryRewardResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardResponse) Interface() protoreflect.ProtoMessage { + return (*QueryRewardResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Reward != nil { + value := protoreflect.ValueOfMessage(x.Reward.ProtoReflect()) + if !f(fd_QueryRewardResponse_reward, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardResponse.reward": + return x.Reward != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardResponse.reward": + x.Reward = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardResponse.reward": + value := x.Reward + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardResponse.reward": + x.Reward = value.Message().Interface().(*Reward) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardResponse.reward": + if x.Reward == nil { + x.Reward = new(Reward) + } + return protoreflect.ValueOfMessage(x.Reward.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardResponse.reward": + m := new(Reward) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Reward != nil { + l = options.Size(x.Reward) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Reward != nil { + encoded, err := options.Marshal(x.Reward) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Reward", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Reward == nil { + x.Reward = &Reward{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Reward); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryRewardsRequest protoreflect.MessageDescriptor + fd_QueryRewardsRequest_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsRequest") + fd_QueryRewardsRequest_pagination = md_QueryRewardsRequest.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsRequest)(nil) + +type fastReflection_QueryRewardsRequest QueryRewardsRequest + +func (x *QueryRewardsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsRequest)(x) +} + +func (x *QueryRewardsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsRequest_messageType fastReflection_QueryRewardsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsRequest_messageType{} + +type fastReflection_QueryRewardsRequest_messageType struct{} + +func (x fastReflection_QueryRewardsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsRequest)(nil) +} +func (x fastReflection_QueryRewardsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsRequest) +} +func (x fastReflection_QueryRewardsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsRequest) New() protoreflect.Message { + return new(fastReflection_QueryRewardsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsRequest_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsRequest.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsRequest.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryRewardsResponse_1_list)(nil) + +type _QueryRewardsResponse_1_list struct { + list *[]*Reward +} + +func (x *_QueryRewardsResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryRewardsResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryRewardsResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Reward) + (*x.list)[i] = concreteValue +} + +func (x *_QueryRewardsResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Reward) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryRewardsResponse_1_list) AppendMutable() protoreflect.Value { + v := new(Reward) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryRewardsResponse_1_list) NewElement() protoreflect.Value { + v := new(Reward) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryRewardsResponse protoreflect.MessageDescriptor + fd_QueryRewardsResponse_rewards protoreflect.FieldDescriptor + fd_QueryRewardsResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsResponse") + fd_QueryRewardsResponse_rewards = md_QueryRewardsResponse.Fields().ByName("rewards") + fd_QueryRewardsResponse_pagination = md_QueryRewardsResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsResponse)(nil) + +type fastReflection_QueryRewardsResponse QueryRewardsResponse + +func (x *QueryRewardsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsResponse)(x) +} + +func (x *QueryRewardsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsResponse_messageType fastReflection_QueryRewardsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsResponse_messageType{} + +type fastReflection_QueryRewardsResponse_messageType struct{} + +func (x fastReflection_QueryRewardsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsResponse)(nil) +} +func (x fastReflection_QueryRewardsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsResponse) +} +func (x fastReflection_QueryRewardsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsResponse) New() protoreflect.Message { + return new(fastReflection_QueryRewardsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Rewards) != 0 { + value := protoreflect.ValueOfList(&_QueryRewardsResponse_1_list{list: &x.Rewards}) + if !f(fd_QueryRewardsResponse_rewards, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsResponse.rewards": + return len(x.Rewards) != 0 + case "sge.legacy.reward.v1beta.QueryRewardsResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsResponse.rewards": + x.Rewards = nil + case "sge.legacy.reward.v1beta.QueryRewardsResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsResponse.rewards": + if len(x.Rewards) == 0 { + return protoreflect.ValueOfList(&_QueryRewardsResponse_1_list{}) + } + listValue := &_QueryRewardsResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.QueryRewardsResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsResponse.rewards": + lv := value.List() + clv := lv.(*_QueryRewardsResponse_1_list) + x.Rewards = *clv.list + case "sge.legacy.reward.v1beta.QueryRewardsResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsResponse.rewards": + if x.Rewards == nil { + x.Rewards = []*Reward{} + } + value := &_QueryRewardsResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.QueryRewardsResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsResponse.rewards": + list := []*Reward{} + return protoreflect.ValueOfList(&_QueryRewardsResponse_1_list{list: &list}) + case "sge.legacy.reward.v1beta.QueryRewardsResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Rewards) > 0 { + for _, e := range x.Rewards { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Rewards) > 0 { + for iNdEx := len(x.Rewards) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Rewards[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Rewards", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Rewards = append(x.Rewards, &Reward{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Rewards[len(x.Rewards)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryRewardsByAddressRequest protoreflect.MessageDescriptor + fd_QueryRewardsByAddressRequest_pagination protoreflect.FieldDescriptor + fd_QueryRewardsByAddressRequest_address protoreflect.FieldDescriptor + fd_QueryRewardsByAddressRequest_promoter_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsByAddressRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsByAddressRequest") + fd_QueryRewardsByAddressRequest_pagination = md_QueryRewardsByAddressRequest.Fields().ByName("pagination") + fd_QueryRewardsByAddressRequest_address = md_QueryRewardsByAddressRequest.Fields().ByName("address") + fd_QueryRewardsByAddressRequest_promoter_uid = md_QueryRewardsByAddressRequest.Fields().ByName("promoter_uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsByAddressRequest)(nil) + +type fastReflection_QueryRewardsByAddressRequest QueryRewardsByAddressRequest + +func (x *QueryRewardsByAddressRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressRequest)(x) +} + +func (x *QueryRewardsByAddressRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[14] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsByAddressRequest_messageType fastReflection_QueryRewardsByAddressRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsByAddressRequest_messageType{} + +type fastReflection_QueryRewardsByAddressRequest_messageType struct{} + +func (x fastReflection_QueryRewardsByAddressRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressRequest)(nil) +} +func (x fastReflection_QueryRewardsByAddressRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressRequest) +} +func (x fastReflection_QueryRewardsByAddressRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsByAddressRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsByAddressRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsByAddressRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsByAddressRequest) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsByAddressRequest) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsByAddressRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsByAddressRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsByAddressRequest_pagination, value) { + return + } + } + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QueryRewardsByAddressRequest_address, value) { + return + } + } + if x.PromoterUid != "" { + value := protoreflect.ValueOfString(x.PromoterUid) + if !f(fd_QueryRewardsByAddressRequest_promoter_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsByAddressRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.pagination": + return x.Pagination != nil + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.address": + return x.Address != "" + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.promoter_uid": + return x.PromoterUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.pagination": + x.Pagination = nil + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.address": + x.Address = "" + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.promoter_uid": + x.PromoterUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsByAddressRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.promoter_uid": + value := x.PromoterUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.address": + x.Address = value.Interface().(string) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.promoter_uid": + x.PromoterUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.address": + panic(fmt.Errorf("field address of message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest is not mutable")) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.promoter_uid": + panic(fmt.Errorf("field promoter_uid of message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsByAddressRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.address": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.promoter_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsByAddressRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsByAddressRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsByAddressRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsByAddressRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsByAddressRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsByAddressRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.PromoterUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.PromoterUid) > 0 { + i -= len(x.PromoterUid) + copy(dAtA[i:], x.PromoterUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PromoterUid))) + i-- + dAtA[i] = 0x1a + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0x12 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PromoterUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PromoterUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryRewardsByAddressResponse_1_list)(nil) + +type _QueryRewardsByAddressResponse_1_list struct { + list *[]*RewardByCategory +} + +func (x *_QueryRewardsByAddressResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryRewardsByAddressResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryRewardsByAddressResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCategory) + (*x.list)[i] = concreteValue +} + +func (x *_QueryRewardsByAddressResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCategory) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryRewardsByAddressResponse_1_list) AppendMutable() protoreflect.Value { + v := new(RewardByCategory) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsByAddressResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryRewardsByAddressResponse_1_list) NewElement() protoreflect.Value { + v := new(RewardByCategory) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsByAddressResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryRewardsByAddressResponse protoreflect.MessageDescriptor + fd_QueryRewardsByAddressResponse_rewards protoreflect.FieldDescriptor + fd_QueryRewardsByAddressResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsByAddressResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsByAddressResponse") + fd_QueryRewardsByAddressResponse_rewards = md_QueryRewardsByAddressResponse.Fields().ByName("rewards") + fd_QueryRewardsByAddressResponse_pagination = md_QueryRewardsByAddressResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsByAddressResponse)(nil) + +type fastReflection_QueryRewardsByAddressResponse QueryRewardsByAddressResponse + +func (x *QueryRewardsByAddressResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressResponse)(x) +} + +func (x *QueryRewardsByAddressResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[15] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsByAddressResponse_messageType fastReflection_QueryRewardsByAddressResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsByAddressResponse_messageType{} + +type fastReflection_QueryRewardsByAddressResponse_messageType struct{} + +func (x fastReflection_QueryRewardsByAddressResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressResponse)(nil) +} +func (x fastReflection_QueryRewardsByAddressResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressResponse) +} +func (x fastReflection_QueryRewardsByAddressResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsByAddressResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsByAddressResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsByAddressResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsByAddressResponse) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsByAddressResponse) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsByAddressResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsByAddressResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Rewards) != 0 { + value := protoreflect.ValueOfList(&_QueryRewardsByAddressResponse_1_list{list: &x.Rewards}) + if !f(fd_QueryRewardsByAddressResponse_rewards, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsByAddressResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsByAddressResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.rewards": + return len(x.Rewards) != 0 + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.rewards": + x.Rewards = nil + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsByAddressResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.rewards": + if len(x.Rewards) == 0 { + return protoreflect.ValueOfList(&_QueryRewardsByAddressResponse_1_list{}) + } + listValue := &_QueryRewardsByAddressResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.rewards": + lv := value.List() + clv := lv.(*_QueryRewardsByAddressResponse_1_list) + x.Rewards = *clv.list + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.rewards": + if x.Rewards == nil { + x.Rewards = []*RewardByCategory{} + } + value := &_QueryRewardsByAddressResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsByAddressResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.rewards": + list := []*RewardByCategory{} + return protoreflect.ValueOfList(&_QueryRewardsByAddressResponse_1_list{list: &list}) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsByAddressResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsByAddressResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsByAddressResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsByAddressResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsByAddressResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsByAddressResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Rewards) > 0 { + for _, e := range x.Rewards { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Rewards) > 0 { + for iNdEx := len(x.Rewards) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Rewards[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Rewards", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Rewards = append(x.Rewards, &RewardByCategory{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Rewards[len(x.Rewards)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryRewardsByAddressAndCategoryRequest protoreflect.MessageDescriptor + fd_QueryRewardsByAddressAndCategoryRequest_pagination protoreflect.FieldDescriptor + fd_QueryRewardsByAddressAndCategoryRequest_address protoreflect.FieldDescriptor + fd_QueryRewardsByAddressAndCategoryRequest_category protoreflect.FieldDescriptor + fd_QueryRewardsByAddressAndCategoryRequest_promoter_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsByAddressAndCategoryRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsByAddressAndCategoryRequest") + fd_QueryRewardsByAddressAndCategoryRequest_pagination = md_QueryRewardsByAddressAndCategoryRequest.Fields().ByName("pagination") + fd_QueryRewardsByAddressAndCategoryRequest_address = md_QueryRewardsByAddressAndCategoryRequest.Fields().ByName("address") + fd_QueryRewardsByAddressAndCategoryRequest_category = md_QueryRewardsByAddressAndCategoryRequest.Fields().ByName("category") + fd_QueryRewardsByAddressAndCategoryRequest_promoter_uid = md_QueryRewardsByAddressAndCategoryRequest.Fields().ByName("promoter_uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsByAddressAndCategoryRequest)(nil) + +type fastReflection_QueryRewardsByAddressAndCategoryRequest QueryRewardsByAddressAndCategoryRequest + +func (x *QueryRewardsByAddressAndCategoryRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressAndCategoryRequest)(x) +} + +func (x *QueryRewardsByAddressAndCategoryRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[16] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType{} + +type fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType struct{} + +func (x fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressAndCategoryRequest)(nil) +} +func (x fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressAndCategoryRequest) +} +func (x fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressAndCategoryRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressAndCategoryRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsByAddressAndCategoryRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressAndCategoryRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsByAddressAndCategoryRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsByAddressAndCategoryRequest_pagination, value) { + return + } + } + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QueryRewardsByAddressAndCategoryRequest_address, value) { + return + } + } + if x.Category != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Category)) + if !f(fd_QueryRewardsByAddressAndCategoryRequest_category, value) { + return + } + } + if x.PromoterUid != "" { + value := protoreflect.ValueOfString(x.PromoterUid) + if !f(fd_QueryRewardsByAddressAndCategoryRequest_promoter_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.pagination": + return x.Pagination != nil + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.address": + return x.Address != "" + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.category": + return x.Category != 0 + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.promoter_uid": + return x.PromoterUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.pagination": + x.Pagination = nil + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.address": + x.Address = "" + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.category": + x.Category = 0 + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.promoter_uid": + x.PromoterUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.category": + value := x.Category + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.promoter_uid": + value := x.PromoterUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.address": + x.Address = value.Interface().(string) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.category": + x.Category = (RewardCategory)(value.Enum()) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.promoter_uid": + x.PromoterUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.address": + panic(fmt.Errorf("field address of message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest is not mutable")) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.category": + panic(fmt.Errorf("field category of message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest is not mutable")) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.promoter_uid": + panic(fmt.Errorf("field promoter_uid of message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.address": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.category": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.promoter_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsByAddressAndCategoryRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsByAddressAndCategoryRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Category != 0 { + n += 1 + runtime.Sov(uint64(x.Category)) + } + l = len(x.PromoterUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressAndCategoryRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.PromoterUid) > 0 { + i -= len(x.PromoterUid) + copy(dAtA[i:], x.PromoterUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PromoterUid))) + i-- + dAtA[i] = 0x22 + } + if x.Category != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Category)) + i-- + dAtA[i] = 0x18 + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0x12 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressAndCategoryRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressAndCategoryRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressAndCategoryRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Category", wireType) + } + x.Category = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Category |= RewardCategory(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PromoterUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PromoterUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryRewardsByAddressAndCategoryResponse_1_list)(nil) + +type _QueryRewardsByAddressAndCategoryResponse_1_list struct { + list *[]*RewardByCategory +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCategory) + (*x.list)[i] = concreteValue +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCategory) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) AppendMutable() protoreflect.Value { + v := new(RewardByCategory) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) NewElement() protoreflect.Value { + v := new(RewardByCategory) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsByAddressAndCategoryResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryRewardsByAddressAndCategoryResponse protoreflect.MessageDescriptor + fd_QueryRewardsByAddressAndCategoryResponse_rewards protoreflect.FieldDescriptor + fd_QueryRewardsByAddressAndCategoryResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsByAddressAndCategoryResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsByAddressAndCategoryResponse") + fd_QueryRewardsByAddressAndCategoryResponse_rewards = md_QueryRewardsByAddressAndCategoryResponse.Fields().ByName("rewards") + fd_QueryRewardsByAddressAndCategoryResponse_pagination = md_QueryRewardsByAddressAndCategoryResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsByAddressAndCategoryResponse)(nil) + +type fastReflection_QueryRewardsByAddressAndCategoryResponse QueryRewardsByAddressAndCategoryResponse + +func (x *QueryRewardsByAddressAndCategoryResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressAndCategoryResponse)(x) +} + +func (x *QueryRewardsByAddressAndCategoryResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[17] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType{} + +type fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType struct{} + +func (x fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsByAddressAndCategoryResponse)(nil) +} +func (x fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressAndCategoryResponse) +} +func (x fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressAndCategoryResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByAddressAndCategoryResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsByAddressAndCategoryResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByAddressAndCategoryResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsByAddressAndCategoryResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Rewards) != 0 { + value := protoreflect.ValueOfList(&_QueryRewardsByAddressAndCategoryResponse_1_list{list: &x.Rewards}) + if !f(fd_QueryRewardsByAddressAndCategoryResponse_rewards, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsByAddressAndCategoryResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.rewards": + return len(x.Rewards) != 0 + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.rewards": + x.Rewards = nil + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.rewards": + if len(x.Rewards) == 0 { + return protoreflect.ValueOfList(&_QueryRewardsByAddressAndCategoryResponse_1_list{}) + } + listValue := &_QueryRewardsByAddressAndCategoryResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.rewards": + lv := value.List() + clv := lv.(*_QueryRewardsByAddressAndCategoryResponse_1_list) + x.Rewards = *clv.list + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.rewards": + if x.Rewards == nil { + x.Rewards = []*RewardByCategory{} + } + value := &_QueryRewardsByAddressAndCategoryResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.rewards": + list := []*RewardByCategory{} + return protoreflect.ValueOfList(&_QueryRewardsByAddressAndCategoryResponse_1_list{list: &list}) + case "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsByAddressAndCategoryResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsByAddressAndCategoryResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Rewards) > 0 { + for _, e := range x.Rewards { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressAndCategoryResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Rewards) > 0 { + for iNdEx := len(x.Rewards) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Rewards[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByAddressAndCategoryResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressAndCategoryResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByAddressAndCategoryResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Rewards", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Rewards = append(x.Rewards, &RewardByCategory{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Rewards[len(x.Rewards)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryRewardsByCampaignRequest protoreflect.MessageDescriptor + fd_QueryRewardsByCampaignRequest_pagination protoreflect.FieldDescriptor + fd_QueryRewardsByCampaignRequest_campaign_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsByCampaignRequest = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsByCampaignRequest") + fd_QueryRewardsByCampaignRequest_pagination = md_QueryRewardsByCampaignRequest.Fields().ByName("pagination") + fd_QueryRewardsByCampaignRequest_campaign_uid = md_QueryRewardsByCampaignRequest.Fields().ByName("campaign_uid") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsByCampaignRequest)(nil) + +type fastReflection_QueryRewardsByCampaignRequest QueryRewardsByCampaignRequest + +func (x *QueryRewardsByCampaignRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsByCampaignRequest)(x) +} + +func (x *QueryRewardsByCampaignRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[18] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsByCampaignRequest_messageType fastReflection_QueryRewardsByCampaignRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsByCampaignRequest_messageType{} + +type fastReflection_QueryRewardsByCampaignRequest_messageType struct{} + +func (x fastReflection_QueryRewardsByCampaignRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsByCampaignRequest)(nil) +} +func (x fastReflection_QueryRewardsByCampaignRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByCampaignRequest) +} +func (x fastReflection_QueryRewardsByCampaignRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByCampaignRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsByCampaignRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByCampaignRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsByCampaignRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsByCampaignRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsByCampaignRequest) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByCampaignRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsByCampaignRequest) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsByCampaignRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsByCampaignRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsByCampaignRequest_pagination, value) { + return + } + } + if x.CampaignUid != "" { + value := protoreflect.ValueOfString(x.CampaignUid) + if !f(fd_QueryRewardsByCampaignRequest_campaign_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsByCampaignRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.pagination": + return x.Pagination != nil + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.campaign_uid": + return x.CampaignUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.pagination": + x.Pagination = nil + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.campaign_uid": + x.CampaignUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsByCampaignRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.campaign_uid": + value := x.CampaignUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageRequest) + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.campaign_uid": + x.CampaignUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageRequest) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.campaign_uid": + panic(fmt.Errorf("field campaign_uid of message sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsByCampaignRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.pagination": + m := new(v1beta1.PageRequest) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.campaign_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsByCampaignRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsByCampaignRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsByCampaignRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsByCampaignRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsByCampaignRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CampaignUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByCampaignRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.CampaignUid) > 0 { + i -= len(x.CampaignUid) + copy(dAtA[i:], x.CampaignUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CampaignUid))) + i-- + dAtA[i] = 0x12 + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByCampaignRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByCampaignRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByCampaignRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageRequest{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CampaignUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CampaignUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QueryRewardsByCampaignResponse_1_list)(nil) + +type _QueryRewardsByCampaignResponse_1_list struct { + list *[]*RewardByCampaign +} + +func (x *_QueryRewardsByCampaignResponse_1_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QueryRewardsByCampaignResponse_1_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QueryRewardsByCampaignResponse_1_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCampaign) + (*x.list)[i] = concreteValue +} + +func (x *_QueryRewardsByCampaignResponse_1_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*RewardByCampaign) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QueryRewardsByCampaignResponse_1_list) AppendMutable() protoreflect.Value { + v := new(RewardByCampaign) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsByCampaignResponse_1_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QueryRewardsByCampaignResponse_1_list) NewElement() protoreflect.Value { + v := new(RewardByCampaign) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QueryRewardsByCampaignResponse_1_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QueryRewardsByCampaignResponse protoreflect.MessageDescriptor + fd_QueryRewardsByCampaignResponse_rewards protoreflect.FieldDescriptor + fd_QueryRewardsByCampaignResponse_pagination protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_query_proto_init() + md_QueryRewardsByCampaignResponse = File_sge_legacy_reward_v1beta_query_proto.Messages().ByName("QueryRewardsByCampaignResponse") + fd_QueryRewardsByCampaignResponse_rewards = md_QueryRewardsByCampaignResponse.Fields().ByName("rewards") + fd_QueryRewardsByCampaignResponse_pagination = md_QueryRewardsByCampaignResponse.Fields().ByName("pagination") +} + +var _ protoreflect.Message = (*fastReflection_QueryRewardsByCampaignResponse)(nil) + +type fastReflection_QueryRewardsByCampaignResponse QueryRewardsByCampaignResponse + +func (x *QueryRewardsByCampaignResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryRewardsByCampaignResponse)(x) +} + +func (x *QueryRewardsByCampaignResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[19] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryRewardsByCampaignResponse_messageType fastReflection_QueryRewardsByCampaignResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryRewardsByCampaignResponse_messageType{} + +type fastReflection_QueryRewardsByCampaignResponse_messageType struct{} + +func (x fastReflection_QueryRewardsByCampaignResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryRewardsByCampaignResponse)(nil) +} +func (x fastReflection_QueryRewardsByCampaignResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByCampaignResponse) +} +func (x fastReflection_QueryRewardsByCampaignResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByCampaignResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryRewardsByCampaignResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryRewardsByCampaignResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryRewardsByCampaignResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryRewardsByCampaignResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryRewardsByCampaignResponse) New() protoreflect.Message { + return new(fastReflection_QueryRewardsByCampaignResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryRewardsByCampaignResponse) Interface() protoreflect.ProtoMessage { + return (*QueryRewardsByCampaignResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryRewardsByCampaignResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Rewards) != 0 { + value := protoreflect.ValueOfList(&_QueryRewardsByCampaignResponse_1_list{list: &x.Rewards}) + if !f(fd_QueryRewardsByCampaignResponse_rewards, value) { + return + } + } + if x.Pagination != nil { + value := protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + if !f(fd_QueryRewardsByCampaignResponse_pagination, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryRewardsByCampaignResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.rewards": + return len(x.Rewards) != 0 + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.pagination": + return x.Pagination != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.rewards": + x.Rewards = nil + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.pagination": + x.Pagination = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryRewardsByCampaignResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.rewards": + if len(x.Rewards) == 0 { + return protoreflect.ValueOfList(&_QueryRewardsByCampaignResponse_1_list{}) + } + listValue := &_QueryRewardsByCampaignResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.pagination": + value := x.Pagination + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.rewards": + lv := value.List() + clv := lv.(*_QueryRewardsByCampaignResponse_1_list) + x.Rewards = *clv.list + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.pagination": + x.Pagination = value.Message().Interface().(*v1beta1.PageResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.rewards": + if x.Rewards == nil { + x.Rewards = []*RewardByCampaign{} + } + value := &_QueryRewardsByCampaignResponse_1_list{list: &x.Rewards} + return protoreflect.ValueOfList(value) + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.pagination": + if x.Pagination == nil { + x.Pagination = new(v1beta1.PageResponse) + } + return protoreflect.ValueOfMessage(x.Pagination.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryRewardsByCampaignResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.rewards": + list := []*RewardByCampaign{} + return protoreflect.ValueOfList(&_QueryRewardsByCampaignResponse_1_list{list: &list}) + case "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.pagination": + m := new(v1beta1.PageResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryRewardsByCampaignResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryRewardsByCampaignResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryRewardsByCampaignResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryRewardsByCampaignResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryRewardsByCampaignResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryRewardsByCampaignResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if len(x.Rewards) > 0 { + for _, e := range x.Rewards { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.Pagination != nil { + l = options.Size(x.Pagination) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByCampaignResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Pagination != nil { + encoded, err := options.Marshal(x.Pagination) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Rewards) > 0 { + for iNdEx := len(x.Rewards) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Rewards[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryRewardsByCampaignResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByCampaignResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryRewardsByCampaignResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Rewards", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Rewards = append(x.Rewards, &RewardByCampaign{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Rewards[len(x.Rewards)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Pagination == nil { + x.Pagination = &v1beta1.PageResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Pagination); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is request type for the Query/Params RPC method. +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is response type for the Query/Params RPC method. +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params holds all the parameters of this module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QueryPromoterByAddressRequest is request type for the +// Query/GetPromoterByAddress RPC method. +type QueryPromoterByAddressRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Addr string `protobuf:"bytes,1,opt,name=addr,proto3" json:"addr,omitempty"` +} + +func (x *QueryPromoterByAddressRequest) Reset() { + *x = QueryPromoterByAddressRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPromoterByAddressRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPromoterByAddressRequest) ProtoMessage() {} + +// Deprecated: Use QueryPromoterByAddressRequest.ProtoReflect.Descriptor instead. +func (*QueryPromoterByAddressRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +func (x *QueryPromoterByAddressRequest) GetAddr() string { + if x != nil { + return x.Addr + } + return "" +} + +// QueryPromoterByAddressResponse is response type for the +// Query/GetPromoterByAddress RPC method. +type QueryPromoterByAddressResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // promoter holds the queries promoter. + Promoter *Promoter `protobuf:"bytes,1,opt,name=promoter,proto3" json:"promoter,omitempty"` +} + +func (x *QueryPromoterByAddressResponse) Reset() { + *x = QueryPromoterByAddressResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPromoterByAddressResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPromoterByAddressResponse) ProtoMessage() {} + +// Deprecated: Use QueryPromoterByAddressResponse.ProtoReflect.Descriptor instead. +func (*QueryPromoterByAddressResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QueryPromoterByAddressResponse) GetPromoter() *Promoter { + if x != nil { + return x.Promoter + } + return nil +} + +// QueryPromotersRequest is request body for the query all promoters endpoint. +type QueryPromotersRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryPromotersRequest) Reset() { + *x = QueryPromotersRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPromotersRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPromotersRequest) ProtoMessage() {} + +// Deprecated: Use QueryPromotersRequest.ProtoReflect.Descriptor instead. +func (*QueryPromotersRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{4} +} + +func (x *QueryPromotersRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryPromotersResponse is response body of the query all promoters +// endpoint. +type QueryPromotersResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Promoter []*Promoter `protobuf:"bytes,1,rep,name=promoter,proto3" json:"promoter,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryPromotersResponse) Reset() { + *x = QueryPromotersResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPromotersResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPromotersResponse) ProtoMessage() {} + +// Deprecated: Use QueryPromotersResponse.ProtoReflect.Descriptor instead. +func (*QueryPromotersResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{5} +} + +func (x *QueryPromotersResponse) GetPromoter() []*Promoter { + if x != nil { + return x.Promoter + } + return nil +} + +func (x *QueryPromotersResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryCampaignRequest is request body of the query campaign endpoint. +type QueryCampaignRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` +} + +func (x *QueryCampaignRequest) Reset() { + *x = QueryCampaignRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryCampaignRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryCampaignRequest) ProtoMessage() {} + +// Deprecated: Use QueryCampaignRequest.ProtoReflect.Descriptor instead. +func (*QueryCampaignRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{6} +} + +func (x *QueryCampaignRequest) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +// QueryCampaignRequest is response body of the query campaign endpoint. +type QueryCampaignResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Campaign *Campaign `protobuf:"bytes,1,opt,name=campaign,proto3" json:"campaign,omitempty"` +} + +func (x *QueryCampaignResponse) Reset() { + *x = QueryCampaignResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryCampaignResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryCampaignResponse) ProtoMessage() {} + +// Deprecated: Use QueryCampaignResponse.ProtoReflect.Descriptor instead. +func (*QueryCampaignResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{7} +} + +func (x *QueryCampaignResponse) GetCampaign() *Campaign { + if x != nil { + return x.Campaign + } + return nil +} + +// QueryCampaignsRequest is request body for the query all campaigns endpoint. +type QueryCampaignsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryCampaignsRequest) Reset() { + *x = QueryCampaignsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryCampaignsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryCampaignsRequest) ProtoMessage() {} + +// Deprecated: Use QueryCampaignsRequest.ProtoReflect.Descriptor instead. +func (*QueryCampaignsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{8} +} + +func (x *QueryCampaignsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryCampaignsResponse is response body of the query all campaigns +// endpoint. +type QueryCampaignsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Campaign []*Campaign `protobuf:"bytes,1,rep,name=campaign,proto3" json:"campaign,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryCampaignsResponse) Reset() { + *x = QueryCampaignsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryCampaignsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryCampaignsResponse) ProtoMessage() {} + +// Deprecated: Use QueryCampaignsResponse.ProtoReflect.Descriptor instead. +func (*QueryCampaignsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{9} +} + +func (x *QueryCampaignsResponse) GetCampaign() []*Campaign { + if x != nil { + return x.Campaign + } + return nil +} + +func (x *QueryCampaignsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryRewardRequest is request body of the query reward endpoint. +type QueryRewardRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` +} + +func (x *QueryRewardRequest) Reset() { + *x = QueryRewardRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardRequest) ProtoMessage() {} + +// Deprecated: Use QueryRewardRequest.ProtoReflect.Descriptor instead. +func (*QueryRewardRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{10} +} + +func (x *QueryRewardRequest) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +// QueryRewardResponse is response body of the query reward endpoint. +type QueryRewardResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Reward *Reward `protobuf:"bytes,1,opt,name=reward,proto3" json:"reward,omitempty"` +} + +func (x *QueryRewardResponse) Reset() { + *x = QueryRewardResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardResponse) ProtoMessage() {} + +// Deprecated: Use QueryRewardResponse.ProtoReflect.Descriptor instead. +func (*QueryRewardResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{11} +} + +func (x *QueryRewardResponse) GetReward() *Reward { + if x != nil { + return x.Reward + } + return nil +} + +// QueryRewardsRequest is request body for the query all rewards endpoint. +type QueryRewardsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryRewardsRequest) Reset() { + *x = QueryRewardsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsRequest) ProtoMessage() {} + +// Deprecated: Use QueryRewardsRequest.ProtoReflect.Descriptor instead. +func (*QueryRewardsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{12} +} + +func (x *QueryRewardsRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryRewardsResponse is response body of the query all rewards endpoint. +type QueryRewardsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Rewards []*Reward `protobuf:"bytes,1,rep,name=rewards,proto3" json:"rewards,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryRewardsResponse) Reset() { + *x = QueryRewardsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsResponse) ProtoMessage() {} + +// Deprecated: Use QueryRewardsResponse.ProtoReflect.Descriptor instead. +func (*QueryRewardsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{13} +} + +func (x *QueryRewardsResponse) GetRewards() []*Reward { + if x != nil { + return x.Rewards + } + return nil +} + +func (x *QueryRewardsResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryRewardsByAddressRequest is request body for the query all rewards by +// address endpoint. +type QueryRewardsByAddressRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + PromoterUid string `protobuf:"bytes,3,opt,name=promoter_uid,json=promoterUid,proto3" json:"promoter_uid,omitempty"` +} + +func (x *QueryRewardsByAddressRequest) Reset() { + *x = QueryRewardsByAddressRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsByAddressRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsByAddressRequest) ProtoMessage() {} + +// Deprecated: Use QueryRewardsByAddressRequest.ProtoReflect.Descriptor instead. +func (*QueryRewardsByAddressRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{14} +} + +func (x *QueryRewardsByAddressRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QueryRewardsByAddressRequest) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *QueryRewardsByAddressRequest) GetPromoterUid() string { + if x != nil { + return x.PromoterUid + } + return "" +} + +// QueryRewardsByAddressResponse is response body of the query all rewards by +// address endpoint. +type QueryRewardsByAddressResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Rewards []*RewardByCategory `protobuf:"bytes,1,rep,name=rewards,proto3" json:"rewards,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryRewardsByAddressResponse) Reset() { + *x = QueryRewardsByAddressResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsByAddressResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsByAddressResponse) ProtoMessage() {} + +// Deprecated: Use QueryRewardsByAddressResponse.ProtoReflect.Descriptor instead. +func (*QueryRewardsByAddressResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{15} +} + +func (x *QueryRewardsByAddressResponse) GetRewards() []*RewardByCategory { + if x != nil { + return x.Rewards + } + return nil +} + +func (x *QueryRewardsByAddressResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryRewardsByAddressAndCategoryRequest is request body for the query all +// rewards by address and category endpoint. +type QueryRewardsByAddressAndCategoryRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + Category RewardCategory `protobuf:"varint,3,opt,name=category,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"category,omitempty"` + PromoterUid string `protobuf:"bytes,4,opt,name=promoter_uid,json=promoterUid,proto3" json:"promoter_uid,omitempty"` +} + +func (x *QueryRewardsByAddressAndCategoryRequest) Reset() { + *x = QueryRewardsByAddressAndCategoryRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsByAddressAndCategoryRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsByAddressAndCategoryRequest) ProtoMessage() {} + +// Deprecated: Use QueryRewardsByAddressAndCategoryRequest.ProtoReflect.Descriptor instead. +func (*QueryRewardsByAddressAndCategoryRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{16} +} + +func (x *QueryRewardsByAddressAndCategoryRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QueryRewardsByAddressAndCategoryRequest) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *QueryRewardsByAddressAndCategoryRequest) GetCategory() RewardCategory { + if x != nil { + return x.Category + } + return RewardCategory_REWARD_CATEGORY_UNSPECIFIED +} + +func (x *QueryRewardsByAddressAndCategoryRequest) GetPromoterUid() string { + if x != nil { + return x.PromoterUid + } + return "" +} + +// QueryRewardsByAddressAndCategoryResponse is response body of the query all +// rewards by address and category endpoint. +type QueryRewardsByAddressAndCategoryResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Rewards []*RewardByCategory `protobuf:"bytes,1,rep,name=rewards,proto3" json:"rewards,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryRewardsByAddressAndCategoryResponse) Reset() { + *x = QueryRewardsByAddressAndCategoryResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsByAddressAndCategoryResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsByAddressAndCategoryResponse) ProtoMessage() {} + +// Deprecated: Use QueryRewardsByAddressAndCategoryResponse.ProtoReflect.Descriptor instead. +func (*QueryRewardsByAddressAndCategoryResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{17} +} + +func (x *QueryRewardsByAddressAndCategoryResponse) GetRewards() []*RewardByCategory { + if x != nil { + return x.Rewards + } + return nil +} + +func (x *QueryRewardsByAddressAndCategoryResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +// QueryRewardsByCampaignRequest is request body for the query all rewards by +// campaign endpoint. +type QueryRewardsByCampaignRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Pagination *v1beta1.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` + CampaignUid string `protobuf:"bytes,2,opt,name=campaign_uid,json=campaignUid,proto3" json:"campaign_uid,omitempty"` +} + +func (x *QueryRewardsByCampaignRequest) Reset() { + *x = QueryRewardsByCampaignRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsByCampaignRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsByCampaignRequest) ProtoMessage() {} + +// Deprecated: Use QueryRewardsByCampaignRequest.ProtoReflect.Descriptor instead. +func (*QueryRewardsByCampaignRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{18} +} + +func (x *QueryRewardsByCampaignRequest) GetPagination() *v1beta1.PageRequest { + if x != nil { + return x.Pagination + } + return nil +} + +func (x *QueryRewardsByCampaignRequest) GetCampaignUid() string { + if x != nil { + return x.CampaignUid + } + return "" +} + +// QueryRewardsByCampaignResponse is response body of the query all rewards by +// campaign endpoint. +type QueryRewardsByCampaignResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Rewards []*RewardByCampaign `protobuf:"bytes,1,rep,name=rewards,proto3" json:"rewards,omitempty"` + Pagination *v1beta1.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` +} + +func (x *QueryRewardsByCampaignResponse) Reset() { + *x = QueryRewardsByCampaignResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_query_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryRewardsByCampaignResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryRewardsByCampaignResponse) ProtoMessage() {} + +// Deprecated: Use QueryRewardsByCampaignResponse.ProtoReflect.Descriptor instead. +func (*QueryRewardsByCampaignResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP(), []int{19} +} + +func (x *QueryRewardsByCampaignResponse) GetRewards() []*RewardByCampaign { + if x != nil { + return x.Rewards + } + return nil +} + +func (x *QueryRewardsByCampaignResponse) GetPagination() *v1beta1.PageResponse { + if x != nil { + return x.Pagination + } + return nil +} + +var File_sge_legacy_reward_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x24, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x1a, 0x2a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x70, 0x61, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x14, 0x0a, 0x12, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x22, 0x55, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, + 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x4d, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2c, 0x0a, 0x04, 0x61, 0x64, 0x64, + 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, + 0x67, 0x52, 0x04, 0x61, 0x64, 0x64, 0x72, 0x22, 0x7e, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x5c, 0x0a, 0x08, 0x70, 0x72, 0x6f, + 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, + 0x1c, 0xc8, 0xde, 0x1f, 0x00, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x08, 0x70, + 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x22, 0x5f, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, + 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, + 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, + 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xbf, 0x01, 0x0a, 0x16, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x5c, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x18, + 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, 0x1c, 0xc8, 0xde, 0x1f, 0x00, 0xd2, + 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, + 0x72, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, + 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x28, 0x0a, 0x14, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x03, 0x75, 0x69, 0x64, 0x22, 0x5d, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x44, 0x0a, + 0x08, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x22, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x43, 0x61, 0x6d, 0x70, 0x61, + 0x69, 0x67, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x08, 0x63, 0x61, 0x6d, 0x70, 0x61, + 0x69, 0x67, 0x6e, 0x22, 0x5f, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x61, 0x6d, 0x70, + 0x61, 0x69, 0x67, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, + 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa7, 0x01, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x61, + 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x44, 0x0a, 0x08, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x43, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x08, 0x63, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x26, + 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x22, 0x55, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, + 0x06, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, + 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x22, 0x5d, 0x0a, + 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xa1, 0x01, 0x0a, + 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x07, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0xbd, 0x01, 0x0a, 0x1c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, + 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, + 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, + 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x21, 0x0a, + 0x0c, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x55, 0x69, 0x64, + 0x22, 0xb4, 0x01, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x4a, 0x0a, 0x07, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x18, 0x01, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x42, + 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x12, 0x47, + 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, + 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, + 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, + 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x8e, 0x02, 0x0a, 0x27, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x41, 0x6e, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, + 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, + 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, + 0x44, 0x0a, 0x08, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x0e, 0x32, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x08, 0x63, 0x61, 0x74, + 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, + 0x72, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, + 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x55, 0x69, 0x64, 0x22, 0xbf, 0x01, 0x0a, 0x28, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x41, 0x6e, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4a, 0x0a, 0x07, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, + 0x72, 0x79, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, + 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x8a, 0x01, 0x0a, 0x1d, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x43, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x0a, + 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, + 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x61, 0x6d, 0x70, + 0x61, 0x69, 0x67, 0x6e, 0x55, 0x69, 0x64, 0x22, 0xb5, 0x01, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, + 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4a, 0x0a, 0x07, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, + 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x12, 0x47, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x50, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x32, + 0xe2, 0x0d, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x8d, 0x01, 0x0a, 0x06, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x12, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x20, 0x12, 0x1e, 0x2f, 0x73, 0x67, 0x65, 0x2d, + 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x72, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0xc2, 0x01, 0x0a, 0x11, 0x50, 0x72, + 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, + 0x37, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x38, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, + 0x72, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x3a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x34, 0x12, 0x32, 0x2f, 0x73, 0x67, 0x65, + 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x2d, 0x62, 0x79, 0x2d, + 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x2f, 0x7b, 0x61, 0x64, 0x64, 0x72, 0x7d, 0x12, 0x99, + 0x01, 0x0a, 0x09, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x73, 0x12, 0x2f, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, + 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x30, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, + 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x12, 0x21, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, + 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x73, 0x12, 0x9b, 0x01, 0x0a, 0x08, 0x43, + 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x12, 0x2e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x28, + 0x12, 0x26, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, + 0x67, 0x6e, 0x2f, 0x7b, 0x75, 0x69, 0x64, 0x7d, 0x12, 0x99, 0x01, 0x0a, 0x09, 0x43, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x73, 0x12, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x30, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x23, 0x12, 0x21, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x63, 0x61, 0x6d, 0x70, 0x61, + 0x69, 0x67, 0x6e, 0x73, 0x12, 0x93, 0x01, 0x0a, 0x06, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x12, + 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2c, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2f, 0x7b, 0x75, 0x69, 0x64, 0x7d, 0x12, 0x91, 0x01, 0x0a, 0x07, 0x52, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x12, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x12, 0x1f, 0x2f, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x12, 0xc5, + 0x01, 0x0a, 0x10, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x12, 0x36, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x37, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x40, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3a, 0x12, 0x38, 0x2f, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x2f, 0x7b, 0x70, + 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x5f, 0x75, 0x69, 0x64, 0x7d, 0x2f, 0x7b, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x12, 0xf1, 0x01, 0x0a, 0x1b, 0x52, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x41, 0x6e, 0x64, 0x43, 0x61, + 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x41, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, + 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x41, 0x6e, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, + 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x42, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x73, 0x42, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x41, 0x6e, 0x64, 0x43, 0x61, 0x74, + 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x4b, 0x82, + 0xd3, 0xe4, 0x93, 0x02, 0x45, 0x12, 0x43, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x2f, 0x7b, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, + 0x5f, 0x75, 0x69, 0x64, 0x7d, 0x2f, 0x7b, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, 0x2f, + 0x7b, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x7d, 0x12, 0xc7, 0x01, 0x0a, 0x11, 0x52, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x12, 0x37, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x42, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, + 0x67, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x38, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x73, 0x42, 0x79, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x3f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x39, 0x12, 0x37, 0x2f, 0x73, 0x67, + 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x73, 0x2f, 0x63, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x2f, 0x7b, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, + 0x75, 0x69, 0x64, 0x7d, 0x42, 0xf3, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x52, 0xaa, + 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x52, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, + 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, + 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_query_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_query_proto_rawDescData = file_sge_legacy_reward_v1beta_query_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_query_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_query_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 20) +var file_sge_legacy_reward_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.legacy.reward.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.legacy.reward.v1beta.QueryParamsResponse + (*QueryPromoterByAddressRequest)(nil), // 2: sge.legacy.reward.v1beta.QueryPromoterByAddressRequest + (*QueryPromoterByAddressResponse)(nil), // 3: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse + (*QueryPromotersRequest)(nil), // 4: sge.legacy.reward.v1beta.QueryPromotersRequest + (*QueryPromotersResponse)(nil), // 5: sge.legacy.reward.v1beta.QueryPromotersResponse + (*QueryCampaignRequest)(nil), // 6: sge.legacy.reward.v1beta.QueryCampaignRequest + (*QueryCampaignResponse)(nil), // 7: sge.legacy.reward.v1beta.QueryCampaignResponse + (*QueryCampaignsRequest)(nil), // 8: sge.legacy.reward.v1beta.QueryCampaignsRequest + (*QueryCampaignsResponse)(nil), // 9: sge.legacy.reward.v1beta.QueryCampaignsResponse + (*QueryRewardRequest)(nil), // 10: sge.legacy.reward.v1beta.QueryRewardRequest + (*QueryRewardResponse)(nil), // 11: sge.legacy.reward.v1beta.QueryRewardResponse + (*QueryRewardsRequest)(nil), // 12: sge.legacy.reward.v1beta.QueryRewardsRequest + (*QueryRewardsResponse)(nil), // 13: sge.legacy.reward.v1beta.QueryRewardsResponse + (*QueryRewardsByAddressRequest)(nil), // 14: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest + (*QueryRewardsByAddressResponse)(nil), // 15: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse + (*QueryRewardsByAddressAndCategoryRequest)(nil), // 16: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest + (*QueryRewardsByAddressAndCategoryResponse)(nil), // 17: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse + (*QueryRewardsByCampaignRequest)(nil), // 18: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest + (*QueryRewardsByCampaignResponse)(nil), // 19: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse + (*Params)(nil), // 20: sge.legacy.reward.v1beta.Params + (*Promoter)(nil), // 21: sge.legacy.reward.v1beta.Promoter + (*v1beta1.PageRequest)(nil), // 22: cosmos.base.query.v1beta1.PageRequest + (*v1beta1.PageResponse)(nil), // 23: cosmos.base.query.v1beta1.PageResponse + (*Campaign)(nil), // 24: sge.legacy.reward.v1beta.Campaign + (*Reward)(nil), // 25: sge.legacy.reward.v1beta.Reward + (*RewardByCategory)(nil), // 26: sge.legacy.reward.v1beta.RewardByCategory + (RewardCategory)(0), // 27: sge.legacy.reward.v1beta.RewardCategory + (*RewardByCampaign)(nil), // 28: sge.legacy.reward.v1beta.RewardByCampaign +} +var file_sge_legacy_reward_v1beta_query_proto_depIdxs = []int32{ + 20, // 0: sge.legacy.reward.v1beta.QueryParamsResponse.params:type_name -> sge.legacy.reward.v1beta.Params + 21, // 1: sge.legacy.reward.v1beta.QueryPromoterByAddressResponse.promoter:type_name -> sge.legacy.reward.v1beta.Promoter + 22, // 2: sge.legacy.reward.v1beta.QueryPromotersRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 21, // 3: sge.legacy.reward.v1beta.QueryPromotersResponse.promoter:type_name -> sge.legacy.reward.v1beta.Promoter + 23, // 4: sge.legacy.reward.v1beta.QueryPromotersResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 24, // 5: sge.legacy.reward.v1beta.QueryCampaignResponse.campaign:type_name -> sge.legacy.reward.v1beta.Campaign + 22, // 6: sge.legacy.reward.v1beta.QueryCampaignsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 24, // 7: sge.legacy.reward.v1beta.QueryCampaignsResponse.campaign:type_name -> sge.legacy.reward.v1beta.Campaign + 23, // 8: sge.legacy.reward.v1beta.QueryCampaignsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 25, // 9: sge.legacy.reward.v1beta.QueryRewardResponse.reward:type_name -> sge.legacy.reward.v1beta.Reward + 22, // 10: sge.legacy.reward.v1beta.QueryRewardsRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 25, // 11: sge.legacy.reward.v1beta.QueryRewardsResponse.rewards:type_name -> sge.legacy.reward.v1beta.Reward + 23, // 12: sge.legacy.reward.v1beta.QueryRewardsResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 22, // 13: sge.legacy.reward.v1beta.QueryRewardsByAddressRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 26, // 14: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.rewards:type_name -> sge.legacy.reward.v1beta.RewardByCategory + 23, // 15: sge.legacy.reward.v1beta.QueryRewardsByAddressResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 22, // 16: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 27, // 17: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest.category:type_name -> sge.legacy.reward.v1beta.RewardCategory + 26, // 18: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.rewards:type_name -> sge.legacy.reward.v1beta.RewardByCategory + 23, // 19: sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 22, // 20: sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest.pagination:type_name -> cosmos.base.query.v1beta1.PageRequest + 28, // 21: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.rewards:type_name -> sge.legacy.reward.v1beta.RewardByCampaign + 23, // 22: sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse.pagination:type_name -> cosmos.base.query.v1beta1.PageResponse + 0, // 23: sge.legacy.reward.v1beta.Query.Params:input_type -> sge.legacy.reward.v1beta.QueryParamsRequest + 2, // 24: sge.legacy.reward.v1beta.Query.PromoterByAddress:input_type -> sge.legacy.reward.v1beta.QueryPromoterByAddressRequest + 4, // 25: sge.legacy.reward.v1beta.Query.Promoters:input_type -> sge.legacy.reward.v1beta.QueryPromotersRequest + 6, // 26: sge.legacy.reward.v1beta.Query.Campaign:input_type -> sge.legacy.reward.v1beta.QueryCampaignRequest + 8, // 27: sge.legacy.reward.v1beta.Query.Campaigns:input_type -> sge.legacy.reward.v1beta.QueryCampaignsRequest + 10, // 28: sge.legacy.reward.v1beta.Query.Reward:input_type -> sge.legacy.reward.v1beta.QueryRewardRequest + 12, // 29: sge.legacy.reward.v1beta.Query.Rewards:input_type -> sge.legacy.reward.v1beta.QueryRewardsRequest + 14, // 30: sge.legacy.reward.v1beta.Query.RewardsByAddress:input_type -> sge.legacy.reward.v1beta.QueryRewardsByAddressRequest + 16, // 31: sge.legacy.reward.v1beta.Query.RewardsByAddressAndCategory:input_type -> sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest + 18, // 32: sge.legacy.reward.v1beta.Query.RewardsByCampaign:input_type -> sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest + 1, // 33: sge.legacy.reward.v1beta.Query.Params:output_type -> sge.legacy.reward.v1beta.QueryParamsResponse + 3, // 34: sge.legacy.reward.v1beta.Query.PromoterByAddress:output_type -> sge.legacy.reward.v1beta.QueryPromoterByAddressResponse + 5, // 35: sge.legacy.reward.v1beta.Query.Promoters:output_type -> sge.legacy.reward.v1beta.QueryPromotersResponse + 7, // 36: sge.legacy.reward.v1beta.Query.Campaign:output_type -> sge.legacy.reward.v1beta.QueryCampaignResponse + 9, // 37: sge.legacy.reward.v1beta.Query.Campaigns:output_type -> sge.legacy.reward.v1beta.QueryCampaignsResponse + 11, // 38: sge.legacy.reward.v1beta.Query.Reward:output_type -> sge.legacy.reward.v1beta.QueryRewardResponse + 13, // 39: sge.legacy.reward.v1beta.Query.Rewards:output_type -> sge.legacy.reward.v1beta.QueryRewardsResponse + 15, // 40: sge.legacy.reward.v1beta.Query.RewardsByAddress:output_type -> sge.legacy.reward.v1beta.QueryRewardsByAddressResponse + 17, // 41: sge.legacy.reward.v1beta.Query.RewardsByAddressAndCategory:output_type -> sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse + 19, // 42: sge.legacy.reward.v1beta.Query.RewardsByCampaign:output_type -> sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse + 33, // [33:43] is the sub-list for method output_type + 23, // [23:33] is the sub-list for method input_type + 23, // [23:23] is the sub-list for extension type_name + 23, // [23:23] is the sub-list for extension extendee + 0, // [0:23] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_query_proto_init() } +func file_sge_legacy_reward_v1beta_query_proto_init() { + if File_sge_legacy_reward_v1beta_query_proto != nil { + return + } + file_sge_legacy_reward_v1beta_campaign_proto_init() + file_sge_legacy_reward_v1beta_params_proto_init() + file_sge_legacy_reward_v1beta_promoter_proto_init() + file_sge_legacy_reward_v1beta_reward_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPromoterByAddressRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPromoterByAddressResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPromotersRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPromotersResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryCampaignRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryCampaignResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryCampaignsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryCampaignsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsByAddressRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsByAddressResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsByAddressAndCategoryRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsByAddressAndCategoryResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsByCampaignRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_query_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryRewardsByCampaignResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 20, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_reward_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_query_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_query_proto = out.File + file_sge_legacy_reward_v1beta_query_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_query_proto_goTypes = nil + file_sge_legacy_reward_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/query_grpc.pb.go b/api/sge/legacy/reward/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..ba6e9145 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/query_grpc.pb.go @@ -0,0 +1,464 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/reward/v1beta/query.proto + +package rewardv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Params_FullMethodName = "/sge.legacy.reward.v1beta.Query/Params" + Query_PromoterByAddress_FullMethodName = "/sge.legacy.reward.v1beta.Query/PromoterByAddress" + Query_Promoters_FullMethodName = "/sge.legacy.reward.v1beta.Query/Promoters" + Query_Campaign_FullMethodName = "/sge.legacy.reward.v1beta.Query/Campaign" + Query_Campaigns_FullMethodName = "/sge.legacy.reward.v1beta.Query/Campaigns" + Query_Reward_FullMethodName = "/sge.legacy.reward.v1beta.Query/Reward" + Query_Rewards_FullMethodName = "/sge.legacy.reward.v1beta.Query/Rewards" + Query_RewardsByAddress_FullMethodName = "/sge.legacy.reward.v1beta.Query/RewardsByAddress" + Query_RewardsByAddressAndCategory_FullMethodName = "/sge.legacy.reward.v1beta.Query/RewardsByAddressAndCategory" + Query_RewardsByCampaign_FullMethodName = "/sge.legacy.reward.v1beta.Query/RewardsByCampaign" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Parameters queries the parameters of the module. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) + // PromoterByAddress queries a certain promoter. + PromoterByAddress(ctx context.Context, in *QueryPromoterByAddressRequest, opts ...grpc.CallOption) (*QueryPromoterByAddressResponse, error) + // Queries list of all Promoter items. + Promoters(ctx context.Context, in *QueryPromotersRequest, opts ...grpc.CallOption) (*QueryPromotersResponse, error) + // Queries a specific Campaign item. + Campaign(ctx context.Context, in *QueryCampaignRequest, opts ...grpc.CallOption) (*QueryCampaignResponse, error) + // Queries list of all Campaign items. + Campaigns(ctx context.Context, in *QueryCampaignsRequest, opts ...grpc.CallOption) (*QueryCampaignsResponse, error) + // Queries a specific Reward item + Reward(ctx context.Context, in *QueryRewardRequest, opts ...grpc.CallOption) (*QueryRewardResponse, error) + // Queries list of all Reward items. + Rewards(ctx context.Context, in *QueryRewardsRequest, opts ...grpc.CallOption) (*QueryRewardsResponse, error) + // Queries list of all Reward items by user address. + RewardsByAddress(ctx context.Context, in *QueryRewardsByAddressRequest, opts ...grpc.CallOption) (*QueryRewardsByAddressResponse, error) + // Queries list of all Reward items by user address and reward type + // endpoint. + RewardsByAddressAndCategory(ctx context.Context, in *QueryRewardsByAddressAndCategoryRequest, opts ...grpc.CallOption) (*QueryRewardsByAddressAndCategoryResponse, error) + // Queries list of all Reward items by campaign endpoint. + RewardsByCampaign(ctx context.Context, in *QueryRewardsByCampaignRequest, opts ...grpc.CallOption) (*QueryRewardsByCampaignResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) PromoterByAddress(ctx context.Context, in *QueryPromoterByAddressRequest, opts ...grpc.CallOption) (*QueryPromoterByAddressResponse, error) { + out := new(QueryPromoterByAddressResponse) + err := c.cc.Invoke(ctx, Query_PromoterByAddress_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Promoters(ctx context.Context, in *QueryPromotersRequest, opts ...grpc.CallOption) (*QueryPromotersResponse, error) { + out := new(QueryPromotersResponse) + err := c.cc.Invoke(ctx, Query_Promoters_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Campaign(ctx context.Context, in *QueryCampaignRequest, opts ...grpc.CallOption) (*QueryCampaignResponse, error) { + out := new(QueryCampaignResponse) + err := c.cc.Invoke(ctx, Query_Campaign_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Campaigns(ctx context.Context, in *QueryCampaignsRequest, opts ...grpc.CallOption) (*QueryCampaignsResponse, error) { + out := new(QueryCampaignsResponse) + err := c.cc.Invoke(ctx, Query_Campaigns_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Reward(ctx context.Context, in *QueryRewardRequest, opts ...grpc.CallOption) (*QueryRewardResponse, error) { + out := new(QueryRewardResponse) + err := c.cc.Invoke(ctx, Query_Reward_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Rewards(ctx context.Context, in *QueryRewardsRequest, opts ...grpc.CallOption) (*QueryRewardsResponse, error) { + out := new(QueryRewardsResponse) + err := c.cc.Invoke(ctx, Query_Rewards_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) RewardsByAddress(ctx context.Context, in *QueryRewardsByAddressRequest, opts ...grpc.CallOption) (*QueryRewardsByAddressResponse, error) { + out := new(QueryRewardsByAddressResponse) + err := c.cc.Invoke(ctx, Query_RewardsByAddress_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) RewardsByAddressAndCategory(ctx context.Context, in *QueryRewardsByAddressAndCategoryRequest, opts ...grpc.CallOption) (*QueryRewardsByAddressAndCategoryResponse, error) { + out := new(QueryRewardsByAddressAndCategoryResponse) + err := c.cc.Invoke(ctx, Query_RewardsByAddressAndCategory_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) RewardsByCampaign(ctx context.Context, in *QueryRewardsByCampaignRequest, opts ...grpc.CallOption) (*QueryRewardsByCampaignResponse, error) { + out := new(QueryRewardsByCampaignResponse) + err := c.cc.Invoke(ctx, Query_RewardsByCampaign_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Parameters queries the parameters of the module. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + // PromoterByAddress queries a certain promoter. + PromoterByAddress(context.Context, *QueryPromoterByAddressRequest) (*QueryPromoterByAddressResponse, error) + // Queries list of all Promoter items. + Promoters(context.Context, *QueryPromotersRequest) (*QueryPromotersResponse, error) + // Queries a specific Campaign item. + Campaign(context.Context, *QueryCampaignRequest) (*QueryCampaignResponse, error) + // Queries list of all Campaign items. + Campaigns(context.Context, *QueryCampaignsRequest) (*QueryCampaignsResponse, error) + // Queries a specific Reward item + Reward(context.Context, *QueryRewardRequest) (*QueryRewardResponse, error) + // Queries list of all Reward items. + Rewards(context.Context, *QueryRewardsRequest) (*QueryRewardsResponse, error) + // Queries list of all Reward items by user address. + RewardsByAddress(context.Context, *QueryRewardsByAddressRequest) (*QueryRewardsByAddressResponse, error) + // Queries list of all Reward items by user address and reward type + // endpoint. + RewardsByAddressAndCategory(context.Context, *QueryRewardsByAddressAndCategoryRequest) (*QueryRewardsByAddressAndCategoryResponse, error) + // Queries list of all Reward items by campaign endpoint. + RewardsByCampaign(context.Context, *QueryRewardsByCampaignRequest) (*QueryRewardsByCampaignResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) PromoterByAddress(context.Context, *QueryPromoterByAddressRequest) (*QueryPromoterByAddressResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PromoterByAddress not implemented") +} +func (UnimplementedQueryServer) Promoters(context.Context, *QueryPromotersRequest) (*QueryPromotersResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Promoters not implemented") +} +func (UnimplementedQueryServer) Campaign(context.Context, *QueryCampaignRequest) (*QueryCampaignResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Campaign not implemented") +} +func (UnimplementedQueryServer) Campaigns(context.Context, *QueryCampaignsRequest) (*QueryCampaignsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Campaigns not implemented") +} +func (UnimplementedQueryServer) Reward(context.Context, *QueryRewardRequest) (*QueryRewardResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Reward not implemented") +} +func (UnimplementedQueryServer) Rewards(context.Context, *QueryRewardsRequest) (*QueryRewardsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Rewards not implemented") +} +func (UnimplementedQueryServer) RewardsByAddress(context.Context, *QueryRewardsByAddressRequest) (*QueryRewardsByAddressResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RewardsByAddress not implemented") +} +func (UnimplementedQueryServer) RewardsByAddressAndCategory(context.Context, *QueryRewardsByAddressAndCategoryRequest) (*QueryRewardsByAddressAndCategoryResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RewardsByAddressAndCategory not implemented") +} +func (UnimplementedQueryServer) RewardsByCampaign(context.Context, *QueryRewardsByCampaignRequest) (*QueryRewardsByCampaignResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method RewardsByCampaign not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_PromoterByAddress_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPromoterByAddressRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).PromoterByAddress(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_PromoterByAddress_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).PromoterByAddress(ctx, req.(*QueryPromoterByAddressRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Promoters_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPromotersRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Promoters(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Promoters_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Promoters(ctx, req.(*QueryPromotersRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Campaign_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryCampaignRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Campaign(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Campaign_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Campaign(ctx, req.(*QueryCampaignRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Campaigns_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryCampaignsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Campaigns(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Campaigns_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Campaigns(ctx, req.(*QueryCampaignsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Reward_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryRewardRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Reward(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Reward_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Reward(ctx, req.(*QueryRewardRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Rewards_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryRewardsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Rewards(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Rewards_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Rewards(ctx, req.(*QueryRewardsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_RewardsByAddress_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryRewardsByAddressRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).RewardsByAddress(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_RewardsByAddress_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).RewardsByAddress(ctx, req.(*QueryRewardsByAddressRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_RewardsByAddressAndCategory_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryRewardsByAddressAndCategoryRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).RewardsByAddressAndCategory(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_RewardsByAddressAndCategory_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).RewardsByAddressAndCategory(ctx, req.(*QueryRewardsByAddressAndCategoryRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_RewardsByCampaign_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryRewardsByCampaignRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).RewardsByCampaign(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_RewardsByCampaign_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).RewardsByCampaign(ctx, req.(*QueryRewardsByCampaignRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.reward.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + { + MethodName: "PromoterByAddress", + Handler: _Query_PromoterByAddress_Handler, + }, + { + MethodName: "Promoters", + Handler: _Query_Promoters_Handler, + }, + { + MethodName: "Campaign", + Handler: _Query_Campaign_Handler, + }, + { + MethodName: "Campaigns", + Handler: _Query_Campaigns_Handler, + }, + { + MethodName: "Reward", + Handler: _Query_Reward_Handler, + }, + { + MethodName: "Rewards", + Handler: _Query_Rewards_Handler, + }, + { + MethodName: "RewardsByAddress", + Handler: _Query_RewardsByAddress_Handler, + }, + { + MethodName: "RewardsByAddressAndCategory", + Handler: _Query_RewardsByAddressAndCategory_Handler, + }, + { + MethodName: "RewardsByCampaign", + Handler: _Query_RewardsByCampaign_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/reward/v1beta/query.proto", +} diff --git a/api/sge/legacy/reward/v1beta/reward.pulsar.go b/api/sge/legacy/reward/v1beta/reward.pulsar.go new file mode 100644 index 00000000..3e622c79 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/reward.pulsar.go @@ -0,0 +1,3266 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Reward protoreflect.MessageDescriptor + fd_Reward_uid protoreflect.FieldDescriptor + fd_Reward_creator protoreflect.FieldDescriptor + fd_Reward_receiver protoreflect.FieldDescriptor + fd_Reward_campaign_uid protoreflect.FieldDescriptor + fd_Reward_reward_amount protoreflect.FieldDescriptor + fd_Reward_source_uid protoreflect.FieldDescriptor + fd_Reward_meta protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_reward_proto_init() + md_Reward = File_sge_legacy_reward_v1beta_reward_proto.Messages().ByName("Reward") + fd_Reward_uid = md_Reward.Fields().ByName("uid") + fd_Reward_creator = md_Reward.Fields().ByName("creator") + fd_Reward_receiver = md_Reward.Fields().ByName("receiver") + fd_Reward_campaign_uid = md_Reward.Fields().ByName("campaign_uid") + fd_Reward_reward_amount = md_Reward.Fields().ByName("reward_amount") + fd_Reward_source_uid = md_Reward.Fields().ByName("source_uid") + fd_Reward_meta = md_Reward.Fields().ByName("meta") +} + +var _ protoreflect.Message = (*fastReflection_Reward)(nil) + +type fastReflection_Reward Reward + +func (x *Reward) ProtoReflect() protoreflect.Message { + return (*fastReflection_Reward)(x) +} + +func (x *Reward) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Reward_messageType fastReflection_Reward_messageType +var _ protoreflect.MessageType = fastReflection_Reward_messageType{} + +type fastReflection_Reward_messageType struct{} + +func (x fastReflection_Reward_messageType) Zero() protoreflect.Message { + return (*fastReflection_Reward)(nil) +} +func (x fastReflection_Reward_messageType) New() protoreflect.Message { + return new(fastReflection_Reward) +} +func (x fastReflection_Reward_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Reward +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Reward) Descriptor() protoreflect.MessageDescriptor { + return md_Reward +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Reward) Type() protoreflect.MessageType { + return _fastReflection_Reward_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Reward) New() protoreflect.Message { + return new(fastReflection_Reward) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Reward) Interface() protoreflect.ProtoMessage { + return (*Reward)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Reward) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_Reward_uid, value) { + return + } + } + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_Reward_creator, value) { + return + } + } + if x.Receiver != "" { + value := protoreflect.ValueOfString(x.Receiver) + if !f(fd_Reward_receiver, value) { + return + } + } + if x.CampaignUid != "" { + value := protoreflect.ValueOfString(x.CampaignUid) + if !f(fd_Reward_campaign_uid, value) { + return + } + } + if x.RewardAmount != nil { + value := protoreflect.ValueOfMessage(x.RewardAmount.ProtoReflect()) + if !f(fd_Reward_reward_amount, value) { + return + } + } + if x.SourceUid != "" { + value := protoreflect.ValueOfString(x.SourceUid) + if !f(fd_Reward_source_uid, value) { + return + } + } + if x.Meta != "" { + value := protoreflect.ValueOfString(x.Meta) + if !f(fd_Reward_meta, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Reward) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Reward.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.Reward.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.Reward.receiver": + return x.Receiver != "" + case "sge.legacy.reward.v1beta.Reward.campaign_uid": + return x.CampaignUid != "" + case "sge.legacy.reward.v1beta.Reward.reward_amount": + return x.RewardAmount != nil + case "sge.legacy.reward.v1beta.Reward.source_uid": + return x.SourceUid != "" + case "sge.legacy.reward.v1beta.Reward.meta": + return x.Meta != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Reward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Reward does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Reward) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Reward.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.Reward.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.Reward.receiver": + x.Receiver = "" + case "sge.legacy.reward.v1beta.Reward.campaign_uid": + x.CampaignUid = "" + case "sge.legacy.reward.v1beta.Reward.reward_amount": + x.RewardAmount = nil + case "sge.legacy.reward.v1beta.Reward.source_uid": + x.SourceUid = "" + case "sge.legacy.reward.v1beta.Reward.meta": + x.Meta = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Reward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Reward does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Reward) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.Reward.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Reward.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Reward.receiver": + value := x.Receiver + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Reward.campaign_uid": + value := x.CampaignUid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Reward.reward_amount": + value := x.RewardAmount + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.Reward.source_uid": + value := x.SourceUid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.Reward.meta": + value := x.Meta + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Reward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Reward does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Reward) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Reward.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.Reward.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.Reward.receiver": + x.Receiver = value.Interface().(string) + case "sge.legacy.reward.v1beta.Reward.campaign_uid": + x.CampaignUid = value.Interface().(string) + case "sge.legacy.reward.v1beta.Reward.reward_amount": + x.RewardAmount = value.Message().Interface().(*RewardAmount) + case "sge.legacy.reward.v1beta.Reward.source_uid": + x.SourceUid = value.Interface().(string) + case "sge.legacy.reward.v1beta.Reward.meta": + x.Meta = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Reward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Reward does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Reward) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Reward.reward_amount": + if x.RewardAmount == nil { + x.RewardAmount = new(RewardAmount) + } + return protoreflect.ValueOfMessage(x.RewardAmount.ProtoReflect()) + case "sge.legacy.reward.v1beta.Reward.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.Reward is not mutable")) + case "sge.legacy.reward.v1beta.Reward.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.Reward is not mutable")) + case "sge.legacy.reward.v1beta.Reward.receiver": + panic(fmt.Errorf("field receiver of message sge.legacy.reward.v1beta.Reward is not mutable")) + case "sge.legacy.reward.v1beta.Reward.campaign_uid": + panic(fmt.Errorf("field campaign_uid of message sge.legacy.reward.v1beta.Reward is not mutable")) + case "sge.legacy.reward.v1beta.Reward.source_uid": + panic(fmt.Errorf("field source_uid of message sge.legacy.reward.v1beta.Reward is not mutable")) + case "sge.legacy.reward.v1beta.Reward.meta": + panic(fmt.Errorf("field meta of message sge.legacy.reward.v1beta.Reward is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Reward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Reward does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Reward) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.Reward.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Reward.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Reward.receiver": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Reward.campaign_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Reward.reward_amount": + m := new(RewardAmount) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.Reward.source_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.Reward.meta": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.Reward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.Reward does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Reward) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.Reward", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Reward) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Reward) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Reward) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Reward) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Reward) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Receiver) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CampaignUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.RewardAmount != nil { + l = options.Size(x.RewardAmount) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.SourceUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Meta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Reward) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Meta) > 0 { + i -= len(x.Meta) + copy(dAtA[i:], x.Meta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Meta))) + i-- + dAtA[i] = 0x62 + } + if len(x.SourceUid) > 0 { + i -= len(x.SourceUid) + copy(dAtA[i:], x.SourceUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SourceUid))) + i-- + dAtA[i] = 0x42 + } + if x.RewardAmount != nil { + encoded, err := options.Marshal(x.RewardAmount) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x3a + } + if len(x.CampaignUid) > 0 { + i -= len(x.CampaignUid) + copy(dAtA[i:], x.CampaignUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CampaignUid))) + i-- + dAtA[i] = 0x22 + } + if len(x.Receiver) > 0 { + i -= len(x.Receiver) + copy(dAtA[i:], x.Receiver) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Receiver))) + i-- + dAtA[i] = 0x1a + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Reward) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Reward: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Reward: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Receiver", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Receiver = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CampaignUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CampaignUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardAmount", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.RewardAmount == nil { + x.RewardAmount = &RewardAmount{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.RewardAmount); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SourceUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SourceUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 12: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Meta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_RewardAmount protoreflect.MessageDescriptor + fd_RewardAmount_main_account_amount protoreflect.FieldDescriptor + fd_RewardAmount_subaccount_amount protoreflect.FieldDescriptor + fd_RewardAmount_unlock_period protoreflect.FieldDescriptor + fd_RewardAmount_main_account_percentage protoreflect.FieldDescriptor + fd_RewardAmount_subaccount_percentage protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_reward_proto_init() + md_RewardAmount = File_sge_legacy_reward_v1beta_reward_proto.Messages().ByName("RewardAmount") + fd_RewardAmount_main_account_amount = md_RewardAmount.Fields().ByName("main_account_amount") + fd_RewardAmount_subaccount_amount = md_RewardAmount.Fields().ByName("subaccount_amount") + fd_RewardAmount_unlock_period = md_RewardAmount.Fields().ByName("unlock_period") + fd_RewardAmount_main_account_percentage = md_RewardAmount.Fields().ByName("main_account_percentage") + fd_RewardAmount_subaccount_percentage = md_RewardAmount.Fields().ByName("subaccount_percentage") +} + +var _ protoreflect.Message = (*fastReflection_RewardAmount)(nil) + +type fastReflection_RewardAmount RewardAmount + +func (x *RewardAmount) ProtoReflect() protoreflect.Message { + return (*fastReflection_RewardAmount)(x) +} + +func (x *RewardAmount) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_RewardAmount_messageType fastReflection_RewardAmount_messageType +var _ protoreflect.MessageType = fastReflection_RewardAmount_messageType{} + +type fastReflection_RewardAmount_messageType struct{} + +func (x fastReflection_RewardAmount_messageType) Zero() protoreflect.Message { + return (*fastReflection_RewardAmount)(nil) +} +func (x fastReflection_RewardAmount_messageType) New() protoreflect.Message { + return new(fastReflection_RewardAmount) +} +func (x fastReflection_RewardAmount_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_RewardAmount +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_RewardAmount) Descriptor() protoreflect.MessageDescriptor { + return md_RewardAmount +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_RewardAmount) Type() protoreflect.MessageType { + return _fastReflection_RewardAmount_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_RewardAmount) New() protoreflect.Message { + return new(fastReflection_RewardAmount) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_RewardAmount) Interface() protoreflect.ProtoMessage { + return (*RewardAmount)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_RewardAmount) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MainAccountAmount != "" { + value := protoreflect.ValueOfString(x.MainAccountAmount) + if !f(fd_RewardAmount_main_account_amount, value) { + return + } + } + if x.SubaccountAmount != "" { + value := protoreflect.ValueOfString(x.SubaccountAmount) + if !f(fd_RewardAmount_subaccount_amount, value) { + return + } + } + if x.UnlockPeriod != uint64(0) { + value := protoreflect.ValueOfUint64(x.UnlockPeriod) + if !f(fd_RewardAmount_unlock_period, value) { + return + } + } + if x.MainAccountPercentage != "" { + value := protoreflect.ValueOfString(x.MainAccountPercentage) + if !f(fd_RewardAmount_main_account_percentage, value) { + return + } + } + if x.SubaccountPercentage != "" { + value := protoreflect.ValueOfString(x.SubaccountPercentage) + if !f(fd_RewardAmount_subaccount_percentage, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_RewardAmount) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardAmount.main_account_amount": + return x.MainAccountAmount != "" + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_amount": + return x.SubaccountAmount != "" + case "sge.legacy.reward.v1beta.RewardAmount.unlock_period": + return x.UnlockPeriod != uint64(0) + case "sge.legacy.reward.v1beta.RewardAmount.main_account_percentage": + return x.MainAccountPercentage != "" + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_percentage": + return x.SubaccountPercentage != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardAmount")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardAmount does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardAmount) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardAmount.main_account_amount": + x.MainAccountAmount = "" + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_amount": + x.SubaccountAmount = "" + case "sge.legacy.reward.v1beta.RewardAmount.unlock_period": + x.UnlockPeriod = uint64(0) + case "sge.legacy.reward.v1beta.RewardAmount.main_account_percentage": + x.MainAccountPercentage = "" + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_percentage": + x.SubaccountPercentage = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardAmount")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardAmount does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_RewardAmount) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.RewardAmount.main_account_amount": + value := x.MainAccountAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_amount": + value := x.SubaccountAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardAmount.unlock_period": + value := x.UnlockPeriod + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.RewardAmount.main_account_percentage": + value := x.MainAccountPercentage + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_percentage": + value := x.SubaccountPercentage + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardAmount")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardAmount does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardAmount) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardAmount.main_account_amount": + x.MainAccountAmount = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_amount": + x.SubaccountAmount = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardAmount.unlock_period": + x.UnlockPeriod = value.Uint() + case "sge.legacy.reward.v1beta.RewardAmount.main_account_percentage": + x.MainAccountPercentage = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_percentage": + x.SubaccountPercentage = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardAmount")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardAmount does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardAmount) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardAmount.main_account_amount": + panic(fmt.Errorf("field main_account_amount of message sge.legacy.reward.v1beta.RewardAmount is not mutable")) + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_amount": + panic(fmt.Errorf("field subaccount_amount of message sge.legacy.reward.v1beta.RewardAmount is not mutable")) + case "sge.legacy.reward.v1beta.RewardAmount.unlock_period": + panic(fmt.Errorf("field unlock_period of message sge.legacy.reward.v1beta.RewardAmount is not mutable")) + case "sge.legacy.reward.v1beta.RewardAmount.main_account_percentage": + panic(fmt.Errorf("field main_account_percentage of message sge.legacy.reward.v1beta.RewardAmount is not mutable")) + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_percentage": + panic(fmt.Errorf("field subaccount_percentage of message sge.legacy.reward.v1beta.RewardAmount is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardAmount")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardAmount does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_RewardAmount) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardAmount.main_account_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardAmount.unlock_period": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.RewardAmount.main_account_percentage": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardAmount.subaccount_percentage": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardAmount")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardAmount does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_RewardAmount) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.RewardAmount", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_RewardAmount) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardAmount) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_RewardAmount) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_RewardAmount) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*RewardAmount) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.MainAccountAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.SubaccountAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.UnlockPeriod != 0 { + n += 1 + runtime.Sov(uint64(x.UnlockPeriod)) + } + l = len(x.MainAccountPercentage) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.SubaccountPercentage) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*RewardAmount) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.SubaccountPercentage) > 0 { + i -= len(x.SubaccountPercentage) + copy(dAtA[i:], x.SubaccountPercentage) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SubaccountPercentage))) + i-- + dAtA[i] = 0x2a + } + if len(x.MainAccountPercentage) > 0 { + i -= len(x.MainAccountPercentage) + copy(dAtA[i:], x.MainAccountPercentage) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MainAccountPercentage))) + i-- + dAtA[i] = 0x22 + } + if x.UnlockPeriod != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.UnlockPeriod)) + i-- + dAtA[i] = 0x18 + } + if len(x.SubaccountAmount) > 0 { + i -= len(x.SubaccountAmount) + copy(dAtA[i:], x.SubaccountAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SubaccountAmount))) + i-- + dAtA[i] = 0x12 + } + if len(x.MainAccountAmount) > 0 { + i -= len(x.MainAccountAmount) + copy(dAtA[i:], x.MainAccountAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MainAccountAmount))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*RewardAmount) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardAmount: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardAmount: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MainAccountAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MainAccountAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SubaccountAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SubaccountAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field UnlockPeriod", wireType) + } + x.UnlockPeriod = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.UnlockPeriod |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MainAccountPercentage", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MainAccountPercentage = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SubaccountPercentage", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SubaccountPercentage = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_RewardByCategory protoreflect.MessageDescriptor + fd_RewardByCategory_uid protoreflect.FieldDescriptor + fd_RewardByCategory_addr protoreflect.FieldDescriptor + fd_RewardByCategory_reward_category protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_reward_proto_init() + md_RewardByCategory = File_sge_legacy_reward_v1beta_reward_proto.Messages().ByName("RewardByCategory") + fd_RewardByCategory_uid = md_RewardByCategory.Fields().ByName("uid") + fd_RewardByCategory_addr = md_RewardByCategory.Fields().ByName("addr") + fd_RewardByCategory_reward_category = md_RewardByCategory.Fields().ByName("reward_category") +} + +var _ protoreflect.Message = (*fastReflection_RewardByCategory)(nil) + +type fastReflection_RewardByCategory RewardByCategory + +func (x *RewardByCategory) ProtoReflect() protoreflect.Message { + return (*fastReflection_RewardByCategory)(x) +} + +func (x *RewardByCategory) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_RewardByCategory_messageType fastReflection_RewardByCategory_messageType +var _ protoreflect.MessageType = fastReflection_RewardByCategory_messageType{} + +type fastReflection_RewardByCategory_messageType struct{} + +func (x fastReflection_RewardByCategory_messageType) Zero() protoreflect.Message { + return (*fastReflection_RewardByCategory)(nil) +} +func (x fastReflection_RewardByCategory_messageType) New() protoreflect.Message { + return new(fastReflection_RewardByCategory) +} +func (x fastReflection_RewardByCategory_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_RewardByCategory +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_RewardByCategory) Descriptor() protoreflect.MessageDescriptor { + return md_RewardByCategory +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_RewardByCategory) Type() protoreflect.MessageType { + return _fastReflection_RewardByCategory_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_RewardByCategory) New() protoreflect.Message { + return new(fastReflection_RewardByCategory) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_RewardByCategory) Interface() protoreflect.ProtoMessage { + return (*RewardByCategory)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_RewardByCategory) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_RewardByCategory_uid, value) { + return + } + } + if x.Addr != "" { + value := protoreflect.ValueOfString(x.Addr) + if !f(fd_RewardByCategory_addr, value) { + return + } + } + if x.RewardCategory != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.RewardCategory)) + if !f(fd_RewardByCategory_reward_category, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_RewardByCategory) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCategory.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.RewardByCategory.addr": + return x.Addr != "" + case "sge.legacy.reward.v1beta.RewardByCategory.reward_category": + return x.RewardCategory != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCategory")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCategory does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCategory) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCategory.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.RewardByCategory.addr": + x.Addr = "" + case "sge.legacy.reward.v1beta.RewardByCategory.reward_category": + x.RewardCategory = 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCategory")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCategory does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_RewardByCategory) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.RewardByCategory.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardByCategory.addr": + value := x.Addr + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardByCategory.reward_category": + value := x.RewardCategory + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCategory")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCategory does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCategory) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCategory.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardByCategory.addr": + x.Addr = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardByCategory.reward_category": + x.RewardCategory = (RewardCategory)(value.Enum()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCategory")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCategory does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCategory) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCategory.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.RewardByCategory is not mutable")) + case "sge.legacy.reward.v1beta.RewardByCategory.addr": + panic(fmt.Errorf("field addr of message sge.legacy.reward.v1beta.RewardByCategory is not mutable")) + case "sge.legacy.reward.v1beta.RewardByCategory.reward_category": + panic(fmt.Errorf("field reward_category of message sge.legacy.reward.v1beta.RewardByCategory is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCategory")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCategory does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_RewardByCategory) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCategory.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardByCategory.addr": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardByCategory.reward_category": + return protoreflect.ValueOfEnum(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCategory")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCategory does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_RewardByCategory) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.RewardByCategory", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_RewardByCategory) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCategory) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_RewardByCategory) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_RewardByCategory) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*RewardByCategory) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Addr) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.RewardCategory != 0 { + n += 1 + runtime.Sov(uint64(x.RewardCategory)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*RewardByCategory) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.RewardCategory != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.RewardCategory)) + i-- + dAtA[i] = 0x18 + } + if len(x.Addr) > 0 { + i -= len(x.Addr) + copy(dAtA[i:], x.Addr) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Addr))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*RewardByCategory) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardByCategory: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardByCategory: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Addr", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Addr = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardCategory", wireType) + } + x.RewardCategory = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.RewardCategory |= RewardCategory(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_RewardByCampaign protoreflect.MessageDescriptor + fd_RewardByCampaign_uid protoreflect.FieldDescriptor + fd_RewardByCampaign_campaign_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_reward_proto_init() + md_RewardByCampaign = File_sge_legacy_reward_v1beta_reward_proto.Messages().ByName("RewardByCampaign") + fd_RewardByCampaign_uid = md_RewardByCampaign.Fields().ByName("uid") + fd_RewardByCampaign_campaign_uid = md_RewardByCampaign.Fields().ByName("campaign_uid") +} + +var _ protoreflect.Message = (*fastReflection_RewardByCampaign)(nil) + +type fastReflection_RewardByCampaign RewardByCampaign + +func (x *RewardByCampaign) ProtoReflect() protoreflect.Message { + return (*fastReflection_RewardByCampaign)(x) +} + +func (x *RewardByCampaign) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_RewardByCampaign_messageType fastReflection_RewardByCampaign_messageType +var _ protoreflect.MessageType = fastReflection_RewardByCampaign_messageType{} + +type fastReflection_RewardByCampaign_messageType struct{} + +func (x fastReflection_RewardByCampaign_messageType) Zero() protoreflect.Message { + return (*fastReflection_RewardByCampaign)(nil) +} +func (x fastReflection_RewardByCampaign_messageType) New() protoreflect.Message { + return new(fastReflection_RewardByCampaign) +} +func (x fastReflection_RewardByCampaign_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_RewardByCampaign +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_RewardByCampaign) Descriptor() protoreflect.MessageDescriptor { + return md_RewardByCampaign +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_RewardByCampaign) Type() protoreflect.MessageType { + return _fastReflection_RewardByCampaign_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_RewardByCampaign) New() protoreflect.Message { + return new(fastReflection_RewardByCampaign) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_RewardByCampaign) Interface() protoreflect.ProtoMessage { + return (*RewardByCampaign)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_RewardByCampaign) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_RewardByCampaign_uid, value) { + return + } + } + if x.CampaignUid != "" { + value := protoreflect.ValueOfString(x.CampaignUid) + if !f(fd_RewardByCampaign_campaign_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_RewardByCampaign) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCampaign.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.RewardByCampaign.campaign_uid": + return x.CampaignUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCampaign does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCampaign) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCampaign.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.RewardByCampaign.campaign_uid": + x.CampaignUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCampaign does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_RewardByCampaign) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.RewardByCampaign.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardByCampaign.campaign_uid": + value := x.CampaignUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCampaign does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCampaign) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCampaign.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardByCampaign.campaign_uid": + x.CampaignUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCampaign does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCampaign) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCampaign.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.RewardByCampaign is not mutable")) + case "sge.legacy.reward.v1beta.RewardByCampaign.campaign_uid": + panic(fmt.Errorf("field campaign_uid of message sge.legacy.reward.v1beta.RewardByCampaign is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCampaign does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_RewardByCampaign) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardByCampaign.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardByCampaign.campaign_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardByCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardByCampaign does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_RewardByCampaign) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.RewardByCampaign", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_RewardByCampaign) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardByCampaign) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_RewardByCampaign) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_RewardByCampaign) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*RewardByCampaign) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CampaignUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*RewardByCampaign) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.CampaignUid) > 0 { + i -= len(x.CampaignUid) + copy(dAtA[i:], x.CampaignUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CampaignUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*RewardByCampaign) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardByCampaign: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardByCampaign: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CampaignUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CampaignUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/reward.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// RewardType defines supported types of rewards in reward module. +type RewardCategory int32 + +const ( + // the invalid or unknown + RewardCategory_REWARD_CATEGORY_UNSPECIFIED RewardCategory = 0 + // signup reward + RewardCategory_REWARD_CATEGORY_SIGNUP RewardCategory = 1 + // referral reward + RewardCategory_REWARD_CATEGORY_REFERRAL RewardCategory = 2 + // affiliate reward + RewardCategory_REWARD_CATEGORY_AFFILIATE RewardCategory = 3 + // bet refunds + RewardCategory_REWARD_CATEGORY_BET_REFUND RewardCategory = 4 + // milestone reward + RewardCategory_REWARD_CATEGORY_MILESTONE RewardCategory = 5 + // bet discounts + RewardCategory_REWARD_CATEGORY_BET_DISCOUNT RewardCategory = 6 + // other rewards + RewardCategory_REWARD_CATEGORY_OTHER RewardCategory = 7 +) + +// Enum value maps for RewardCategory. +var ( + RewardCategory_name = map[int32]string{ + 0: "REWARD_CATEGORY_UNSPECIFIED", + 1: "REWARD_CATEGORY_SIGNUP", + 2: "REWARD_CATEGORY_REFERRAL", + 3: "REWARD_CATEGORY_AFFILIATE", + 4: "REWARD_CATEGORY_BET_REFUND", + 5: "REWARD_CATEGORY_MILESTONE", + 6: "REWARD_CATEGORY_BET_DISCOUNT", + 7: "REWARD_CATEGORY_OTHER", + } + RewardCategory_value = map[string]int32{ + "REWARD_CATEGORY_UNSPECIFIED": 0, + "REWARD_CATEGORY_SIGNUP": 1, + "REWARD_CATEGORY_REFERRAL": 2, + "REWARD_CATEGORY_AFFILIATE": 3, + "REWARD_CATEGORY_BET_REFUND": 4, + "REWARD_CATEGORY_MILESTONE": 5, + "REWARD_CATEGORY_BET_DISCOUNT": 6, + "REWARD_CATEGORY_OTHER": 7, + } +) + +func (x RewardCategory) Enum() *RewardCategory { + p := new(RewardCategory) + *p = x + return p +} + +func (x RewardCategory) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (RewardCategory) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_reward_v1beta_reward_proto_enumTypes[0].Descriptor() +} + +func (RewardCategory) Type() protoreflect.EnumType { + return &file_sge_legacy_reward_v1beta_reward_proto_enumTypes[0] +} + +func (x RewardCategory) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use RewardCategory.Descriptor instead. +func (RewardCategory) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP(), []int{0} +} + +// RewardType defines supported types of rewards of reward module. +type RewardType int32 + +const ( + // the invalid or unknown + RewardType_REWARD_TYPE_UNSPECIFIED RewardType = 0 + // signup reward + RewardType_REWARD_TYPE_SIGNUP RewardType = 1 + // referral signup reward + RewardType_REWARD_TYPE_REFERRAL_SIGNUP RewardType = 2 + // affiliate signup reward + RewardType_REWARD_TYPE_AFFILIATE_SIGNUP RewardType = 3 + // referral reward + RewardType_REWARD_TYPE_REFERRAL RewardType = 4 + // affiliate reward + RewardType_REWARD_TYPE_AFFILIATE RewardType = 5 + // bet refunds + RewardType_REWARD_TYPE_BET_REFUND RewardType = 6 + // milestone reward + RewardType_REWARD_TYPE_MILESTONE RewardType = 7 + // bet discounts + RewardType_REWARD_TYPE_BET_DISCOUNT RewardType = 8 + // other rewards + RewardType_REWARD_TYPE_OTHER RewardType = 9 +) + +// Enum value maps for RewardType. +var ( + RewardType_name = map[int32]string{ + 0: "REWARD_TYPE_UNSPECIFIED", + 1: "REWARD_TYPE_SIGNUP", + 2: "REWARD_TYPE_REFERRAL_SIGNUP", + 3: "REWARD_TYPE_AFFILIATE_SIGNUP", + 4: "REWARD_TYPE_REFERRAL", + 5: "REWARD_TYPE_AFFILIATE", + 6: "REWARD_TYPE_BET_REFUND", + 7: "REWARD_TYPE_MILESTONE", + 8: "REWARD_TYPE_BET_DISCOUNT", + 9: "REWARD_TYPE_OTHER", + } + RewardType_value = map[string]int32{ + "REWARD_TYPE_UNSPECIFIED": 0, + "REWARD_TYPE_SIGNUP": 1, + "REWARD_TYPE_REFERRAL_SIGNUP": 2, + "REWARD_TYPE_AFFILIATE_SIGNUP": 3, + "REWARD_TYPE_REFERRAL": 4, + "REWARD_TYPE_AFFILIATE": 5, + "REWARD_TYPE_BET_REFUND": 6, + "REWARD_TYPE_MILESTONE": 7, + "REWARD_TYPE_BET_DISCOUNT": 8, + "REWARD_TYPE_OTHER": 9, + } +) + +func (x RewardType) Enum() *RewardType { + p := new(RewardType) + *p = x + return p +} + +func (x RewardType) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (RewardType) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_reward_v1beta_reward_proto_enumTypes[1].Descriptor() +} + +func (RewardType) Type() protoreflect.EnumType { + return &file_sge_legacy_reward_v1beta_reward_proto_enumTypes[1] +} + +func (x RewardType) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use RewardType.Descriptor instead. +func (RewardType) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP(), []int{1} +} + +// RewardType defines supported types of rewards of reward module. +type RewardAmountType int32 + +const ( + // the invalid or unknown + RewardAmountType_REWARD_AMOUNT_TYPE_UNSPECIFIED RewardAmountType = 0 + // Fixed amount + RewardAmountType_REWARD_AMOUNT_TYPE_FIXED RewardAmountType = 1 + // Business logic defined amount + RewardAmountType_REWARD_AMOUNT_TYPE_LOGIC RewardAmountType = 2 + // Percentage of bet amount + RewardAmountType_REWARD_AMOUNT_TYPE_PERCENTAGE RewardAmountType = 3 +) + +// Enum value maps for RewardAmountType. +var ( + RewardAmountType_name = map[int32]string{ + 0: "REWARD_AMOUNT_TYPE_UNSPECIFIED", + 1: "REWARD_AMOUNT_TYPE_FIXED", + 2: "REWARD_AMOUNT_TYPE_LOGIC", + 3: "REWARD_AMOUNT_TYPE_PERCENTAGE", + } + RewardAmountType_value = map[string]int32{ + "REWARD_AMOUNT_TYPE_UNSPECIFIED": 0, + "REWARD_AMOUNT_TYPE_FIXED": 1, + "REWARD_AMOUNT_TYPE_LOGIC": 2, + "REWARD_AMOUNT_TYPE_PERCENTAGE": 3, + } +) + +func (x RewardAmountType) Enum() *RewardAmountType { + p := new(RewardAmountType) + *p = x + return p +} + +func (x RewardAmountType) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (RewardAmountType) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_reward_v1beta_reward_proto_enumTypes[2].Descriptor() +} + +func (RewardAmountType) Type() protoreflect.EnumType { + return &file_sge_legacy_reward_v1beta_reward_proto_enumTypes[2] +} + +func (x RewardAmountType) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use RewardAmountType.Descriptor instead. +func (RewardAmountType) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP(), []int{2} +} + +// Reward is the type for transaction made to reward a user +// based on users eligibility. +type Reward struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the unique identifier for a reward. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // creator is the address of the account that invokes the reward transaction. + Creator string `protobuf:"bytes,2,opt,name=creator,proto3" json:"creator,omitempty"` + // receiver is the address of the account that receives the reward. + Receiver string `protobuf:"bytes,3,opt,name=receiver,proto3" json:"receiver,omitempty"` + // campaign_uid is the unique identifier of the campaign. + CampaignUid string `protobuf:"bytes,4,opt,name=campaign_uid,proto3" json:"campaign_uid,omitempty"` + // reward_amount is the amount of the reward. + RewardAmount *RewardAmount `protobuf:"bytes,7,opt,name=reward_amount,proto3" json:"reward_amount,omitempty"` + // source_uid is the address of the source. + // It is used to identify the source of the reward. + // For example, the source uid of a referral signup + // reward is the address of the referer. + SourceUid string `protobuf:"bytes,8,opt,name=source_uid,proto3" json:"source_uid,omitempty"` + // meta is the metadata of the campaign. + // It is a stringified base64 encoded json. + Meta string `protobuf:"bytes,12,opt,name=meta,proto3" json:"meta,omitempty"` +} + +func (x *Reward) Reset() { + *x = Reward{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Reward) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Reward) ProtoMessage() {} + +// Deprecated: Use Reward.ProtoReflect.Descriptor instead. +func (*Reward) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP(), []int{0} +} + +func (x *Reward) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *Reward) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *Reward) GetReceiver() string { + if x != nil { + return x.Receiver + } + return "" +} + +func (x *Reward) GetCampaignUid() string { + if x != nil { + return x.CampaignUid + } + return "" +} + +func (x *Reward) GetRewardAmount() *RewardAmount { + if x != nil { + return x.RewardAmount + } + return nil +} + +func (x *Reward) GetSourceUid() string { + if x != nil { + return x.SourceUid + } + return "" +} + +func (x *Reward) GetMeta() string { + if x != nil { + return x.Meta + } + return "" +} + +// RewardAmount +type RewardAmount struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // main_account_amount transferred to main account address + MainAccountAmount string `protobuf:"bytes,1,opt,name=main_account_amount,json=mainAccountAmount,proto3" json:"main_account_amount,omitempty"` + // subaccount_amount transferred to subaccount address + SubaccountAmount string `protobuf:"bytes,2,opt,name=subaccount_amount,json=subaccountAmount,proto3" json:"subaccount_amount,omitempty"` + // unlock_period is the period after which the reward is unlocked. + UnlockPeriod uint64 `protobuf:"varint,3,opt,name=unlock_period,proto3" json:"unlock_period,omitempty"` + // main_account_percentage transferred to main account address + MainAccountPercentage string `protobuf:"bytes,4,opt,name=main_account_percentage,json=mainAccountPercentage,proto3" json:"main_account_percentage,omitempty"` + // subaccount_percentage amount transferred to subaccount address + SubaccountPercentage string `protobuf:"bytes,5,opt,name=subaccount_percentage,json=subaccountPercentage,proto3" json:"subaccount_percentage,omitempty"` +} + +func (x *RewardAmount) Reset() { + *x = RewardAmount{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RewardAmount) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RewardAmount) ProtoMessage() {} + +// Deprecated: Use RewardAmount.ProtoReflect.Descriptor instead. +func (*RewardAmount) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP(), []int{1} +} + +func (x *RewardAmount) GetMainAccountAmount() string { + if x != nil { + return x.MainAccountAmount + } + return "" +} + +func (x *RewardAmount) GetSubaccountAmount() string { + if x != nil { + return x.SubaccountAmount + } + return "" +} + +func (x *RewardAmount) GetUnlockPeriod() uint64 { + if x != nil { + return x.UnlockPeriod + } + return 0 +} + +func (x *RewardAmount) GetMainAccountPercentage() string { + if x != nil { + return x.MainAccountPercentage + } + return "" +} + +func (x *RewardAmount) GetSubaccountPercentage() string { + if x != nil { + return x.SubaccountPercentage + } + return "" +} + +// RewardByCategory +type RewardByCategory struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the unique identifier for a reward. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // addr is the address of the reward receiver. + Addr string `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"` + // reward_category is the category of the reward. + RewardCategory RewardCategory `protobuf:"varint,3,opt,name=reward_category,json=rewardCategory,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"reward_category,omitempty"` +} + +func (x *RewardByCategory) Reset() { + *x = RewardByCategory{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RewardByCategory) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RewardByCategory) ProtoMessage() {} + +// Deprecated: Use RewardByCategory.ProtoReflect.Descriptor instead. +func (*RewardByCategory) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP(), []int{2} +} + +func (x *RewardByCategory) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *RewardByCategory) GetAddr() string { + if x != nil { + return x.Addr + } + return "" +} + +func (x *RewardByCategory) GetRewardCategory() RewardCategory { + if x != nil { + return x.RewardCategory + } + return RewardCategory_REWARD_CATEGORY_UNSPECIFIED +} + +// RewardByCampaign +type RewardByCampaign struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the unique identifier for a reward. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // campaign_uid is the unique identifier of the campaign. + CampaignUid string `protobuf:"bytes,2,opt,name=campaign_uid,proto3" json:"campaign_uid,omitempty"` +} + +func (x *RewardByCampaign) Reset() { + *x = RewardByCampaign{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_reward_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RewardByCampaign) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RewardByCampaign) ProtoMessage() {} + +// Deprecated: Use RewardByCampaign.ProtoReflect.Descriptor instead. +func (*RewardByCampaign) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP(), []int{3} +} + +func (x *RewardByCampaign) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *RewardByCampaign) GetCampaignUid() string { + if x != nil { + return x.CampaignUid + } + return "" +} + +var File_sge_legacy_reward_v1beta_reward_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_reward_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x22, 0x9b, 0x03, 0x0a, 0x06, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x12, 0x20, 0x0a, + 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, + 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, + 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x6f, 0x72, 0x12, 0x34, 0x0a, 0x08, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x72, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, + 0x08, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x72, 0x12, 0x43, 0x0a, 0x0c, 0x63, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x1f, 0xe2, 0xde, 0x1f, 0x0b, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x55, 0x49, 0x44, + 0xea, 0xde, 0x1f, 0x0c, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, 0x75, 0x69, 0x64, + 0x52, 0x0c, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x6f, + 0x0a, 0x0d, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0x21, 0xe2, + 0xde, 0x1f, 0x0c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0xea, + 0xde, 0x1f, 0x0d, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, + 0x52, 0x0d, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, + 0x3b, 0x0a, 0x0a, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x08, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x55, + 0x49, 0x44, 0xea, 0xde, 0x1f, 0x0a, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x75, 0x69, 0x64, + 0x52, 0x0a, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, + 0x6d, 0x65, 0x74, 0x61, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, 0x65, 0x74, 0x61, + 0x22, 0xa5, 0x04, 0x0a, 0x0c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, + 0x74, 0x12, 0x6b, 0x0a, 0x13, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x3b, + 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, + 0x1a, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x11, 0x6d, 0x61, 0x69, + 0x6e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x66, + 0x0a, 0x11, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x39, 0xc8, 0xde, 0x1f, 0x00, 0xda, + 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x18, 0x79, 0x61, 0x6d, 0x6c, + 0x3a, 0x22, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x22, 0x52, 0x10, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x47, 0x0a, 0x0d, 0x75, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, + 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x42, 0x21, 0xe2, + 0xde, 0x1f, 0x0c, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0xea, + 0xde, 0x1f, 0x0d, 0x75, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, + 0x52, 0x0d, 0x75, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x12, + 0x7d, 0x0a, 0x17, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, + 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x45, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x44, 0x65, 0x63, 0xf2, 0xde, 0x1f, 0x1e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6d, + 0x61, 0x69, 0x6e, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x70, 0x65, 0x72, 0x63, + 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x22, 0x52, 0x15, 0x6d, 0x61, 0x69, 0x6e, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x50, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x12, 0x78, + 0x0a, 0x15, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x70, 0x65, 0x72, + 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x43, 0xc8, + 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, + 0x65, 0x63, 0xf2, 0xde, 0x1f, 0x1c, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x73, 0x75, 0x62, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, + 0x65, 0x22, 0x52, 0x14, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x50, 0x65, + 0x72, 0x63, 0x65, 0x6e, 0x74, 0x61, 0x67, 0x65, 0x22, 0xb5, 0x01, 0x0a, 0x10, 0x52, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x20, 0x0a, + 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, + 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, + 0x2c, 0x0a, 0x04, 0x61, 0x64, 0x64, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, + 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x04, 0x61, 0x64, 0x64, 0x72, 0x12, 0x51, 0x0a, + 0x0f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, + 0x52, 0x0e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, + 0x22, 0x79, 0x0a, 0x10, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x42, 0x79, 0x43, 0x61, 0x6d, 0x70, + 0x61, 0x69, 0x67, 0x6e, 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, + 0x64, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x43, 0x0a, 0x0c, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, + 0x67, 0x6e, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1f, 0xe2, 0xde, + 0x1f, 0x0b, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, + 0x0c, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0c, 0x63, + 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, 0x75, 0x69, 0x64, 0x2a, 0x86, 0x02, 0x0a, 0x0e, + 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x1f, + 0x0a, 0x1b, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, 0x52, + 0x59, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, + 0x1a, 0x0a, 0x16, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, + 0x52, 0x59, 0x5f, 0x53, 0x49, 0x47, 0x4e, 0x55, 0x50, 0x10, 0x01, 0x12, 0x1c, 0x0a, 0x18, 0x52, + 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, 0x52, 0x59, 0x5f, 0x52, + 0x45, 0x46, 0x45, 0x52, 0x52, 0x41, 0x4c, 0x10, 0x02, 0x12, 0x1d, 0x0a, 0x19, 0x52, 0x45, 0x57, + 0x41, 0x52, 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, 0x52, 0x59, 0x5f, 0x41, 0x46, 0x46, + 0x49, 0x4c, 0x49, 0x41, 0x54, 0x45, 0x10, 0x03, 0x12, 0x1e, 0x0a, 0x1a, 0x52, 0x45, 0x57, 0x41, + 0x52, 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, 0x52, 0x59, 0x5f, 0x42, 0x45, 0x54, 0x5f, + 0x52, 0x45, 0x46, 0x55, 0x4e, 0x44, 0x10, 0x04, 0x12, 0x1d, 0x0a, 0x19, 0x52, 0x45, 0x57, 0x41, + 0x52, 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, 0x52, 0x59, 0x5f, 0x4d, 0x49, 0x4c, 0x45, + 0x53, 0x54, 0x4f, 0x4e, 0x45, 0x10, 0x05, 0x12, 0x20, 0x0a, 0x1c, 0x52, 0x45, 0x57, 0x41, 0x52, + 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, 0x52, 0x59, 0x5f, 0x42, 0x45, 0x54, 0x5f, 0x44, + 0x49, 0x53, 0x43, 0x4f, 0x55, 0x4e, 0x54, 0x10, 0x06, 0x12, 0x19, 0x0a, 0x15, 0x52, 0x45, 0x57, + 0x41, 0x52, 0x44, 0x5f, 0x43, 0x41, 0x54, 0x45, 0x47, 0x4f, 0x52, 0x59, 0x5f, 0x4f, 0x54, 0x48, + 0x45, 0x52, 0x10, 0x07, 0x2a, 0xa5, 0x02, 0x0a, 0x0a, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x54, + 0x79, 0x70, 0x65, 0x12, 0x1b, 0x0a, 0x17, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x54, 0x59, + 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, + 0x12, 0x16, 0x0a, 0x12, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, + 0x53, 0x49, 0x47, 0x4e, 0x55, 0x50, 0x10, 0x01, 0x12, 0x1f, 0x0a, 0x1b, 0x52, 0x45, 0x57, 0x41, + 0x52, 0x44, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x46, 0x45, 0x52, 0x52, 0x41, 0x4c, + 0x5f, 0x53, 0x49, 0x47, 0x4e, 0x55, 0x50, 0x10, 0x02, 0x12, 0x20, 0x0a, 0x1c, 0x52, 0x45, 0x57, + 0x41, 0x52, 0x44, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x46, 0x46, 0x49, 0x4c, 0x49, 0x41, + 0x54, 0x45, 0x5f, 0x53, 0x49, 0x47, 0x4e, 0x55, 0x50, 0x10, 0x03, 0x12, 0x18, 0x0a, 0x14, 0x52, + 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x46, 0x45, 0x52, + 0x52, 0x41, 0x4c, 0x10, 0x04, 0x12, 0x19, 0x0a, 0x15, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, + 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x46, 0x46, 0x49, 0x4c, 0x49, 0x41, 0x54, 0x45, 0x10, 0x05, + 0x12, 0x1a, 0x0a, 0x16, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, + 0x42, 0x45, 0x54, 0x5f, 0x52, 0x45, 0x46, 0x55, 0x4e, 0x44, 0x10, 0x06, 0x12, 0x19, 0x0a, 0x15, + 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4d, 0x49, 0x4c, 0x45, + 0x53, 0x54, 0x4f, 0x4e, 0x45, 0x10, 0x07, 0x12, 0x1c, 0x0a, 0x18, 0x52, 0x45, 0x57, 0x41, 0x52, + 0x44, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x42, 0x45, 0x54, 0x5f, 0x44, 0x49, 0x53, 0x43, 0x4f, + 0x55, 0x4e, 0x54, 0x10, 0x08, 0x12, 0x15, 0x0a, 0x11, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, + 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4f, 0x54, 0x48, 0x45, 0x52, 0x10, 0x09, 0x2a, 0x95, 0x01, 0x0a, + 0x10, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x54, 0x79, 0x70, + 0x65, 0x12, 0x22, 0x0a, 0x1e, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x41, 0x4d, 0x4f, 0x55, + 0x4e, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, + 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1c, 0x0a, 0x18, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, + 0x41, 0x4d, 0x4f, 0x55, 0x4e, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x46, 0x49, 0x58, 0x45, + 0x44, 0x10, 0x01, 0x12, 0x1c, 0x0a, 0x18, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x41, 0x4d, + 0x4f, 0x55, 0x4e, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4c, 0x4f, 0x47, 0x49, 0x43, 0x10, + 0x02, 0x12, 0x21, 0x0a, 0x1d, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x41, 0x4d, 0x4f, 0x55, + 0x4e, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x50, 0x45, 0x52, 0x43, 0x45, 0x4e, 0x54, 0x41, + 0x47, 0x45, 0x10, 0x03, 0x42, 0xf4, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x52, + 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, + 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, + 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_reward_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_reward_proto_rawDescData = file_sge_legacy_reward_v1beta_reward_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_reward_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_reward_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_reward_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_reward_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_reward_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_reward_proto_enumTypes = make([]protoimpl.EnumInfo, 3) +var file_sge_legacy_reward_v1beta_reward_proto_msgTypes = make([]protoimpl.MessageInfo, 4) +var file_sge_legacy_reward_v1beta_reward_proto_goTypes = []interface{}{ + (RewardCategory)(0), // 0: sge.legacy.reward.v1beta.RewardCategory + (RewardType)(0), // 1: sge.legacy.reward.v1beta.RewardType + (RewardAmountType)(0), // 2: sge.legacy.reward.v1beta.RewardAmountType + (*Reward)(nil), // 3: sge.legacy.reward.v1beta.Reward + (*RewardAmount)(nil), // 4: sge.legacy.reward.v1beta.RewardAmount + (*RewardByCategory)(nil), // 5: sge.legacy.reward.v1beta.RewardByCategory + (*RewardByCampaign)(nil), // 6: sge.legacy.reward.v1beta.RewardByCampaign +} +var file_sge_legacy_reward_v1beta_reward_proto_depIdxs = []int32{ + 4, // 0: sge.legacy.reward.v1beta.Reward.reward_amount:type_name -> sge.legacy.reward.v1beta.RewardAmount + 0, // 1: sge.legacy.reward.v1beta.RewardByCategory.reward_category:type_name -> sge.legacy.reward.v1beta.RewardCategory + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_reward_proto_init() } +func file_sge_legacy_reward_v1beta_reward_proto_init() { + if File_sge_legacy_reward_v1beta_reward_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_reward_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Reward); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_reward_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RewardAmount); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_reward_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RewardByCategory); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_reward_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RewardByCampaign); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_reward_proto_rawDesc, + NumEnums: 3, + NumMessages: 4, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_v1beta_reward_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_reward_proto_depIdxs, + EnumInfos: file_sge_legacy_reward_v1beta_reward_proto_enumTypes, + MessageInfos: file_sge_legacy_reward_v1beta_reward_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_reward_proto = out.File + file_sge_legacy_reward_v1beta_reward_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_reward_proto_goTypes = nil + file_sge_legacy_reward_v1beta_reward_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/ticket.pulsar.go b/api/sge/legacy/reward/v1beta/ticket.pulsar.go new file mode 100644 index 00000000..75c48b4c --- /dev/null +++ b/api/sge/legacy/reward/v1beta/ticket.pulsar.go @@ -0,0 +1,6279 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + v1beta "github.com/sge-network/sge/api/sge/legacy/type/v1beta" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_CreateCampaignPayload protoreflect.MessageDescriptor + fd_CreateCampaignPayload_promoter protoreflect.FieldDescriptor + fd_CreateCampaignPayload_start_ts protoreflect.FieldDescriptor + fd_CreateCampaignPayload_end_ts protoreflect.FieldDescriptor + fd_CreateCampaignPayload_category protoreflect.FieldDescriptor + fd_CreateCampaignPayload_reward_type protoreflect.FieldDescriptor + fd_CreateCampaignPayload_reward_amount_type protoreflect.FieldDescriptor + fd_CreateCampaignPayload_reward_amount protoreflect.FieldDescriptor + fd_CreateCampaignPayload_is_active protoreflect.FieldDescriptor + fd_CreateCampaignPayload_meta protoreflect.FieldDescriptor + fd_CreateCampaignPayload_cap_count protoreflect.FieldDescriptor + fd_CreateCampaignPayload_constraints protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_CreateCampaignPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("CreateCampaignPayload") + fd_CreateCampaignPayload_promoter = md_CreateCampaignPayload.Fields().ByName("promoter") + fd_CreateCampaignPayload_start_ts = md_CreateCampaignPayload.Fields().ByName("start_ts") + fd_CreateCampaignPayload_end_ts = md_CreateCampaignPayload.Fields().ByName("end_ts") + fd_CreateCampaignPayload_category = md_CreateCampaignPayload.Fields().ByName("category") + fd_CreateCampaignPayload_reward_type = md_CreateCampaignPayload.Fields().ByName("reward_type") + fd_CreateCampaignPayload_reward_amount_type = md_CreateCampaignPayload.Fields().ByName("reward_amount_type") + fd_CreateCampaignPayload_reward_amount = md_CreateCampaignPayload.Fields().ByName("reward_amount") + fd_CreateCampaignPayload_is_active = md_CreateCampaignPayload.Fields().ByName("is_active") + fd_CreateCampaignPayload_meta = md_CreateCampaignPayload.Fields().ByName("meta") + fd_CreateCampaignPayload_cap_count = md_CreateCampaignPayload.Fields().ByName("cap_count") + fd_CreateCampaignPayload_constraints = md_CreateCampaignPayload.Fields().ByName("constraints") +} + +var _ protoreflect.Message = (*fastReflection_CreateCampaignPayload)(nil) + +type fastReflection_CreateCampaignPayload CreateCampaignPayload + +func (x *CreateCampaignPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_CreateCampaignPayload)(x) +} + +func (x *CreateCampaignPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_CreateCampaignPayload_messageType fastReflection_CreateCampaignPayload_messageType +var _ protoreflect.MessageType = fastReflection_CreateCampaignPayload_messageType{} + +type fastReflection_CreateCampaignPayload_messageType struct{} + +func (x fastReflection_CreateCampaignPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_CreateCampaignPayload)(nil) +} +func (x fastReflection_CreateCampaignPayload_messageType) New() protoreflect.Message { + return new(fastReflection_CreateCampaignPayload) +} +func (x fastReflection_CreateCampaignPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_CreateCampaignPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_CreateCampaignPayload) Descriptor() protoreflect.MessageDescriptor { + return md_CreateCampaignPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_CreateCampaignPayload) Type() protoreflect.MessageType { + return _fastReflection_CreateCampaignPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_CreateCampaignPayload) New() protoreflect.Message { + return new(fastReflection_CreateCampaignPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_CreateCampaignPayload) Interface() protoreflect.ProtoMessage { + return (*CreateCampaignPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_CreateCampaignPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Promoter != "" { + value := protoreflect.ValueOfString(x.Promoter) + if !f(fd_CreateCampaignPayload_promoter, value) { + return + } + } + if x.StartTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.StartTs) + if !f(fd_CreateCampaignPayload_start_ts, value) { + return + } + } + if x.EndTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.EndTs) + if !f(fd_CreateCampaignPayload_end_ts, value) { + return + } + } + if x.Category != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Category)) + if !f(fd_CreateCampaignPayload_category, value) { + return + } + } + if x.RewardType != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.RewardType)) + if !f(fd_CreateCampaignPayload_reward_type, value) { + return + } + } + if x.RewardAmountType != 0 { + value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.RewardAmountType)) + if !f(fd_CreateCampaignPayload_reward_amount_type, value) { + return + } + } + if x.RewardAmount != nil { + value := protoreflect.ValueOfMessage(x.RewardAmount.ProtoReflect()) + if !f(fd_CreateCampaignPayload_reward_amount, value) { + return + } + } + if x.IsActive != false { + value := protoreflect.ValueOfBool(x.IsActive) + if !f(fd_CreateCampaignPayload_is_active, value) { + return + } + } + if x.Meta != "" { + value := protoreflect.ValueOfString(x.Meta) + if !f(fd_CreateCampaignPayload_meta, value) { + return + } + } + if x.CapCount != uint64(0) { + value := protoreflect.ValueOfUint64(x.CapCount) + if !f(fd_CreateCampaignPayload_cap_count, value) { + return + } + } + if x.Constraints != nil { + value := protoreflect.ValueOfMessage(x.Constraints.ProtoReflect()) + if !f(fd_CreateCampaignPayload_constraints, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_CreateCampaignPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignPayload.promoter": + return x.Promoter != "" + case "sge.legacy.reward.v1beta.CreateCampaignPayload.start_ts": + return x.StartTs != uint64(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.end_ts": + return x.EndTs != uint64(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.category": + return x.Category != 0 + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_type": + return x.RewardType != 0 + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount_type": + return x.RewardAmountType != 0 + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount": + return x.RewardAmount != nil + case "sge.legacy.reward.v1beta.CreateCampaignPayload.is_active": + return x.IsActive != false + case "sge.legacy.reward.v1beta.CreateCampaignPayload.meta": + return x.Meta != "" + case "sge.legacy.reward.v1beta.CreateCampaignPayload.cap_count": + return x.CapCount != uint64(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.constraints": + return x.Constraints != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignPayload.promoter": + x.Promoter = "" + case "sge.legacy.reward.v1beta.CreateCampaignPayload.start_ts": + x.StartTs = uint64(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.end_ts": + x.EndTs = uint64(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.category": + x.Category = 0 + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_type": + x.RewardType = 0 + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount_type": + x.RewardAmountType = 0 + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount": + x.RewardAmount = nil + case "sge.legacy.reward.v1beta.CreateCampaignPayload.is_active": + x.IsActive = false + case "sge.legacy.reward.v1beta.CreateCampaignPayload.meta": + x.Meta = "" + case "sge.legacy.reward.v1beta.CreateCampaignPayload.cap_count": + x.CapCount = uint64(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.constraints": + x.Constraints = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_CreateCampaignPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignPayload.promoter": + value := x.Promoter + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.start_ts": + value := x.StartTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.end_ts": + value := x.EndTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.category": + value := x.Category + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_type": + value := x.RewardType + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount_type": + value := x.RewardAmountType + return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount": + value := x.RewardAmount + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.is_active": + value := x.IsActive + return protoreflect.ValueOfBool(value) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.meta": + value := x.Meta + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.cap_count": + value := x.CapCount + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.constraints": + value := x.Constraints + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignPayload.promoter": + x.Promoter = value.Interface().(string) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.start_ts": + x.StartTs = value.Uint() + case "sge.legacy.reward.v1beta.CreateCampaignPayload.end_ts": + x.EndTs = value.Uint() + case "sge.legacy.reward.v1beta.CreateCampaignPayload.category": + x.Category = (RewardCategory)(value.Enum()) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_type": + x.RewardType = (RewardType)(value.Enum()) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount_type": + x.RewardAmountType = (RewardAmountType)(value.Enum()) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount": + x.RewardAmount = value.Message().Interface().(*RewardAmount) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.is_active": + x.IsActive = value.Bool() + case "sge.legacy.reward.v1beta.CreateCampaignPayload.meta": + x.Meta = value.Interface().(string) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.cap_count": + x.CapCount = value.Uint() + case "sge.legacy.reward.v1beta.CreateCampaignPayload.constraints": + x.Constraints = value.Message().Interface().(*CampaignConstraints) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount": + if x.RewardAmount == nil { + x.RewardAmount = new(RewardAmount) + } + return protoreflect.ValueOfMessage(x.RewardAmount.ProtoReflect()) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.constraints": + if x.Constraints == nil { + x.Constraints = new(CampaignConstraints) + } + return protoreflect.ValueOfMessage(x.Constraints.ProtoReflect()) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.promoter": + panic(fmt.Errorf("field promoter of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.start_ts": + panic(fmt.Errorf("field start_ts of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.end_ts": + panic(fmt.Errorf("field end_ts of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.category": + panic(fmt.Errorf("field category of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_type": + panic(fmt.Errorf("field reward_type of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount_type": + panic(fmt.Errorf("field reward_amount_type of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.is_active": + panic(fmt.Errorf("field is_active of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.meta": + panic(fmt.Errorf("field meta of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.cap_count": + panic(fmt.Errorf("field cap_count of message sge.legacy.reward.v1beta.CreateCampaignPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_CreateCampaignPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreateCampaignPayload.promoter": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.CreateCampaignPayload.start_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.end_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.category": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_type": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount_type": + return protoreflect.ValueOfEnum(0) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount": + m := new(RewardAmount) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.is_active": + return protoreflect.ValueOfBool(false) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.meta": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.CreateCampaignPayload.cap_count": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.CreateCampaignPayload.constraints": + m := new(CampaignConstraints) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_CreateCampaignPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.CreateCampaignPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_CreateCampaignPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreateCampaignPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_CreateCampaignPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_CreateCampaignPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*CreateCampaignPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Promoter) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.StartTs != 0 { + n += 1 + runtime.Sov(uint64(x.StartTs)) + } + if x.EndTs != 0 { + n += 1 + runtime.Sov(uint64(x.EndTs)) + } + if x.Category != 0 { + n += 1 + runtime.Sov(uint64(x.Category)) + } + if x.RewardType != 0 { + n += 1 + runtime.Sov(uint64(x.RewardType)) + } + if x.RewardAmountType != 0 { + n += 1 + runtime.Sov(uint64(x.RewardAmountType)) + } + if x.RewardAmount != nil { + l = options.Size(x.RewardAmount) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.IsActive { + n += 2 + } + l = len(x.Meta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.CapCount != 0 { + n += 1 + runtime.Sov(uint64(x.CapCount)) + } + if x.Constraints != nil { + l = options.Size(x.Constraints) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*CreateCampaignPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Constraints != nil { + encoded, err := options.Marshal(x.Constraints) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x62 + } + if x.CapCount != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.CapCount)) + i-- + dAtA[i] = 0x58 + } + if len(x.Meta) > 0 { + i -= len(x.Meta) + copy(dAtA[i:], x.Meta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Meta))) + i-- + dAtA[i] = 0x52 + } + if x.IsActive { + i-- + if x.IsActive { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x40 + } + if x.RewardAmount != nil { + encoded, err := options.Marshal(x.RewardAmount) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x3a + } + if x.RewardAmountType != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.RewardAmountType)) + i-- + dAtA[i] = 0x30 + } + if x.RewardType != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.RewardType)) + i-- + dAtA[i] = 0x28 + } + if x.Category != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.Category)) + i-- + dAtA[i] = 0x20 + } + if x.EndTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.EndTs)) + i-- + dAtA[i] = 0x18 + } + if x.StartTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.StartTs)) + i-- + dAtA[i] = 0x10 + } + if len(x.Promoter) > 0 { + i -= len(x.Promoter) + copy(dAtA[i:], x.Promoter) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Promoter))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*CreateCampaignPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CreateCampaignPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CreateCampaignPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Promoter", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Promoter = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field StartTs", wireType) + } + x.StartTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.StartTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EndTs", wireType) + } + x.EndTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.EndTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Category", wireType) + } + x.Category = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.Category |= RewardCategory(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardType", wireType) + } + x.RewardType = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.RewardType |= RewardType(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardAmountType", wireType) + } + x.RewardAmountType = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.RewardAmountType |= RewardAmountType(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field RewardAmount", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.RewardAmount == nil { + x.RewardAmount = &RewardAmount{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.RewardAmount); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 8: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field IsActive", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.IsActive = bool(v != 0) + case 10: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Meta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 11: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CapCount", wireType) + } + x.CapCount = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.CapCount |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 12: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Constraints", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Constraints == nil { + x.Constraints = &CampaignConstraints{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Constraints); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_UpdateCampaignPayload protoreflect.MessageDescriptor + fd_UpdateCampaignPayload_end_ts protoreflect.FieldDescriptor + fd_UpdateCampaignPayload_is_active protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_UpdateCampaignPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("UpdateCampaignPayload") + fd_UpdateCampaignPayload_end_ts = md_UpdateCampaignPayload.Fields().ByName("end_ts") + fd_UpdateCampaignPayload_is_active = md_UpdateCampaignPayload.Fields().ByName("is_active") +} + +var _ protoreflect.Message = (*fastReflection_UpdateCampaignPayload)(nil) + +type fastReflection_UpdateCampaignPayload UpdateCampaignPayload + +func (x *UpdateCampaignPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_UpdateCampaignPayload)(x) +} + +func (x *UpdateCampaignPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_UpdateCampaignPayload_messageType fastReflection_UpdateCampaignPayload_messageType +var _ protoreflect.MessageType = fastReflection_UpdateCampaignPayload_messageType{} + +type fastReflection_UpdateCampaignPayload_messageType struct{} + +func (x fastReflection_UpdateCampaignPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_UpdateCampaignPayload)(nil) +} +func (x fastReflection_UpdateCampaignPayload_messageType) New() protoreflect.Message { + return new(fastReflection_UpdateCampaignPayload) +} +func (x fastReflection_UpdateCampaignPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_UpdateCampaignPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_UpdateCampaignPayload) Descriptor() protoreflect.MessageDescriptor { + return md_UpdateCampaignPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_UpdateCampaignPayload) Type() protoreflect.MessageType { + return _fastReflection_UpdateCampaignPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_UpdateCampaignPayload) New() protoreflect.Message { + return new(fastReflection_UpdateCampaignPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_UpdateCampaignPayload) Interface() protoreflect.ProtoMessage { + return (*UpdateCampaignPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_UpdateCampaignPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.EndTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.EndTs) + if !f(fd_UpdateCampaignPayload_end_ts, value) { + return + } + } + if x.IsActive != false { + value := protoreflect.ValueOfBool(x.IsActive) + if !f(fd_UpdateCampaignPayload_is_active, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_UpdateCampaignPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.end_ts": + return x.EndTs != uint64(0) + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.is_active": + return x.IsActive != false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.end_ts": + x.EndTs = uint64(0) + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.is_active": + x.IsActive = false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_UpdateCampaignPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.end_ts": + value := x.EndTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.is_active": + value := x.IsActive + return protoreflect.ValueOfBool(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.end_ts": + x.EndTs = value.Uint() + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.is_active": + x.IsActive = value.Bool() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.end_ts": + panic(fmt.Errorf("field end_ts of message sge.legacy.reward.v1beta.UpdateCampaignPayload is not mutable")) + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.is_active": + panic(fmt.Errorf("field is_active of message sge.legacy.reward.v1beta.UpdateCampaignPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_UpdateCampaignPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.end_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.reward.v1beta.UpdateCampaignPayload.is_active": + return protoreflect.ValueOfBool(false) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.UpdateCampaignPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.UpdateCampaignPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_UpdateCampaignPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.UpdateCampaignPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_UpdateCampaignPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_UpdateCampaignPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_UpdateCampaignPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_UpdateCampaignPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*UpdateCampaignPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.EndTs != 0 { + n += 1 + runtime.Sov(uint64(x.EndTs)) + } + if x.IsActive { + n += 2 + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*UpdateCampaignPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.IsActive { + i-- + if x.IsActive { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x10 + } + if x.EndTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.EndTs)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*UpdateCampaignPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: UpdateCampaignPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: UpdateCampaignPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EndTs", wireType) + } + x.EndTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.EndTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field IsActive", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.IsActive = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_WithdrawFundsPayload protoreflect.MessageDescriptor + fd_WithdrawFundsPayload_promoter protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_WithdrawFundsPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("WithdrawFundsPayload") + fd_WithdrawFundsPayload_promoter = md_WithdrawFundsPayload.Fields().ByName("promoter") +} + +var _ protoreflect.Message = (*fastReflection_WithdrawFundsPayload)(nil) + +type fastReflection_WithdrawFundsPayload WithdrawFundsPayload + +func (x *WithdrawFundsPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_WithdrawFundsPayload)(x) +} + +func (x *WithdrawFundsPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_WithdrawFundsPayload_messageType fastReflection_WithdrawFundsPayload_messageType +var _ protoreflect.MessageType = fastReflection_WithdrawFundsPayload_messageType{} + +type fastReflection_WithdrawFundsPayload_messageType struct{} + +func (x fastReflection_WithdrawFundsPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_WithdrawFundsPayload)(nil) +} +func (x fastReflection_WithdrawFundsPayload_messageType) New() protoreflect.Message { + return new(fastReflection_WithdrawFundsPayload) +} +func (x fastReflection_WithdrawFundsPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawFundsPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_WithdrawFundsPayload) Descriptor() protoreflect.MessageDescriptor { + return md_WithdrawFundsPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_WithdrawFundsPayload) Type() protoreflect.MessageType { + return _fastReflection_WithdrawFundsPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_WithdrawFundsPayload) New() protoreflect.Message { + return new(fastReflection_WithdrawFundsPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_WithdrawFundsPayload) Interface() protoreflect.ProtoMessage { + return (*WithdrawFundsPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_WithdrawFundsPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Promoter != "" { + value := protoreflect.ValueOfString(x.Promoter) + if !f(fd_WithdrawFundsPayload_promoter, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_WithdrawFundsPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawFundsPayload.promoter": + return x.Promoter != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawFundsPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawFundsPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawFundsPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawFundsPayload.promoter": + x.Promoter = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawFundsPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawFundsPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_WithdrawFundsPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.WithdrawFundsPayload.promoter": + value := x.Promoter + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawFundsPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawFundsPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawFundsPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawFundsPayload.promoter": + x.Promoter = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawFundsPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawFundsPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawFundsPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawFundsPayload.promoter": + panic(fmt.Errorf("field promoter of message sge.legacy.reward.v1beta.WithdrawFundsPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawFundsPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawFundsPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_WithdrawFundsPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.WithdrawFundsPayload.promoter": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.WithdrawFundsPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.WithdrawFundsPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_WithdrawFundsPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.WithdrawFundsPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_WithdrawFundsPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_WithdrawFundsPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_WithdrawFundsPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_WithdrawFundsPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*WithdrawFundsPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Promoter) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*WithdrawFundsPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Promoter) > 0 { + i -= len(x.Promoter) + copy(dAtA[i:], x.Promoter) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Promoter))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*WithdrawFundsPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawFundsPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WithdrawFundsPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Promoter", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Promoter = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_RewardPayloadCommon protoreflect.MessageDescriptor + fd_RewardPayloadCommon_receiver protoreflect.FieldDescriptor + fd_RewardPayloadCommon_source_uid protoreflect.FieldDescriptor + fd_RewardPayloadCommon_meta protoreflect.FieldDescriptor + fd_RewardPayloadCommon_kyc_data protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_RewardPayloadCommon = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("RewardPayloadCommon") + fd_RewardPayloadCommon_receiver = md_RewardPayloadCommon.Fields().ByName("receiver") + fd_RewardPayloadCommon_source_uid = md_RewardPayloadCommon.Fields().ByName("source_uid") + fd_RewardPayloadCommon_meta = md_RewardPayloadCommon.Fields().ByName("meta") + fd_RewardPayloadCommon_kyc_data = md_RewardPayloadCommon.Fields().ByName("kyc_data") +} + +var _ protoreflect.Message = (*fastReflection_RewardPayloadCommon)(nil) + +type fastReflection_RewardPayloadCommon RewardPayloadCommon + +func (x *RewardPayloadCommon) ProtoReflect() protoreflect.Message { + return (*fastReflection_RewardPayloadCommon)(x) +} + +func (x *RewardPayloadCommon) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_RewardPayloadCommon_messageType fastReflection_RewardPayloadCommon_messageType +var _ protoreflect.MessageType = fastReflection_RewardPayloadCommon_messageType{} + +type fastReflection_RewardPayloadCommon_messageType struct{} + +func (x fastReflection_RewardPayloadCommon_messageType) Zero() protoreflect.Message { + return (*fastReflection_RewardPayloadCommon)(nil) +} +func (x fastReflection_RewardPayloadCommon_messageType) New() protoreflect.Message { + return new(fastReflection_RewardPayloadCommon) +} +func (x fastReflection_RewardPayloadCommon_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_RewardPayloadCommon +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_RewardPayloadCommon) Descriptor() protoreflect.MessageDescriptor { + return md_RewardPayloadCommon +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_RewardPayloadCommon) Type() protoreflect.MessageType { + return _fastReflection_RewardPayloadCommon_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_RewardPayloadCommon) New() protoreflect.Message { + return new(fastReflection_RewardPayloadCommon) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_RewardPayloadCommon) Interface() protoreflect.ProtoMessage { + return (*RewardPayloadCommon)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_RewardPayloadCommon) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Receiver != "" { + value := protoreflect.ValueOfString(x.Receiver) + if !f(fd_RewardPayloadCommon_receiver, value) { + return + } + } + if x.SourceUid != "" { + value := protoreflect.ValueOfString(x.SourceUid) + if !f(fd_RewardPayloadCommon_source_uid, value) { + return + } + } + if x.Meta != "" { + value := protoreflect.ValueOfString(x.Meta) + if !f(fd_RewardPayloadCommon_meta, value) { + return + } + } + if x.KycData != nil { + value := protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + if !f(fd_RewardPayloadCommon_kyc_data, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_RewardPayloadCommon) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardPayloadCommon.receiver": + return x.Receiver != "" + case "sge.legacy.reward.v1beta.RewardPayloadCommon.source_uid": + return x.SourceUid != "" + case "sge.legacy.reward.v1beta.RewardPayloadCommon.meta": + return x.Meta != "" + case "sge.legacy.reward.v1beta.RewardPayloadCommon.kyc_data": + return x.KycData != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardPayloadCommon")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardPayloadCommon does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardPayloadCommon) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardPayloadCommon.receiver": + x.Receiver = "" + case "sge.legacy.reward.v1beta.RewardPayloadCommon.source_uid": + x.SourceUid = "" + case "sge.legacy.reward.v1beta.RewardPayloadCommon.meta": + x.Meta = "" + case "sge.legacy.reward.v1beta.RewardPayloadCommon.kyc_data": + x.KycData = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardPayloadCommon")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardPayloadCommon does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_RewardPayloadCommon) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.RewardPayloadCommon.receiver": + value := x.Receiver + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.source_uid": + value := x.SourceUid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.meta": + value := x.Meta + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.kyc_data": + value := x.KycData + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardPayloadCommon")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardPayloadCommon does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardPayloadCommon) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardPayloadCommon.receiver": + x.Receiver = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.source_uid": + x.SourceUid = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.meta": + x.Meta = value.Interface().(string) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.kyc_data": + x.KycData = value.Message().Interface().(*v1beta.KycDataPayload) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardPayloadCommon")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardPayloadCommon does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardPayloadCommon) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardPayloadCommon.kyc_data": + if x.KycData == nil { + x.KycData = new(v1beta.KycDataPayload) + } + return protoreflect.ValueOfMessage(x.KycData.ProtoReflect()) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.receiver": + panic(fmt.Errorf("field receiver of message sge.legacy.reward.v1beta.RewardPayloadCommon is not mutable")) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.source_uid": + panic(fmt.Errorf("field source_uid of message sge.legacy.reward.v1beta.RewardPayloadCommon is not mutable")) + case "sge.legacy.reward.v1beta.RewardPayloadCommon.meta": + panic(fmt.Errorf("field meta of message sge.legacy.reward.v1beta.RewardPayloadCommon is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardPayloadCommon")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardPayloadCommon does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_RewardPayloadCommon) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.RewardPayloadCommon.receiver": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardPayloadCommon.source_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardPayloadCommon.meta": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.RewardPayloadCommon.kyc_data": + m := new(v1beta.KycDataPayload) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.RewardPayloadCommon")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.RewardPayloadCommon does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_RewardPayloadCommon) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.RewardPayloadCommon", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_RewardPayloadCommon) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_RewardPayloadCommon) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_RewardPayloadCommon) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_RewardPayloadCommon) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*RewardPayloadCommon) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Receiver) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.SourceUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Meta) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.KycData != nil { + l = options.Size(x.KycData) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*RewardPayloadCommon) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.KycData != nil { + encoded, err := options.Marshal(x.KycData) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + if len(x.Meta) > 0 { + i -= len(x.Meta) + copy(dAtA[i:], x.Meta) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Meta))) + i-- + dAtA[i] = 0x1a + } + if len(x.SourceUid) > 0 { + i -= len(x.SourceUid) + copy(dAtA[i:], x.SourceUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SourceUid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Receiver) > 0 { + i -= len(x.Receiver) + copy(dAtA[i:], x.Receiver) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Receiver))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*RewardPayloadCommon) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardPayloadCommon: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: RewardPayloadCommon: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Receiver", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Receiver = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SourceUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SourceUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Meta", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Meta = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field KycData", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.KycData == nil { + x.KycData = &v1beta.KycDataPayload{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.KycData); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_GrantSignupRewardPayload protoreflect.MessageDescriptor + fd_GrantSignupRewardPayload_common protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_GrantSignupRewardPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("GrantSignupRewardPayload") + fd_GrantSignupRewardPayload_common = md_GrantSignupRewardPayload.Fields().ByName("common") +} + +var _ protoreflect.Message = (*fastReflection_GrantSignupRewardPayload)(nil) + +type fastReflection_GrantSignupRewardPayload GrantSignupRewardPayload + +func (x *GrantSignupRewardPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_GrantSignupRewardPayload)(x) +} + +func (x *GrantSignupRewardPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GrantSignupRewardPayload_messageType fastReflection_GrantSignupRewardPayload_messageType +var _ protoreflect.MessageType = fastReflection_GrantSignupRewardPayload_messageType{} + +type fastReflection_GrantSignupRewardPayload_messageType struct{} + +func (x fastReflection_GrantSignupRewardPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_GrantSignupRewardPayload)(nil) +} +func (x fastReflection_GrantSignupRewardPayload_messageType) New() protoreflect.Message { + return new(fastReflection_GrantSignupRewardPayload) +} +func (x fastReflection_GrantSignupRewardPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GrantSignupRewardPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GrantSignupRewardPayload) Descriptor() protoreflect.MessageDescriptor { + return md_GrantSignupRewardPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GrantSignupRewardPayload) Type() protoreflect.MessageType { + return _fastReflection_GrantSignupRewardPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GrantSignupRewardPayload) New() protoreflect.Message { + return new(fastReflection_GrantSignupRewardPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GrantSignupRewardPayload) Interface() protoreflect.ProtoMessage { + return (*GrantSignupRewardPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GrantSignupRewardPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Common != nil { + value := protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + if !f(fd_GrantSignupRewardPayload_common, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GrantSignupRewardPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupRewardPayload.common": + return x.Common != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupRewardPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupRewardPayload.common": + x.Common = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GrantSignupRewardPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupRewardPayload.common": + value := x.Common + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupRewardPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupRewardPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupRewardPayload.common": + x.Common = value.Message().Interface().(*RewardPayloadCommon) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupRewardPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupRewardPayload.common": + if x.Common == nil { + x.Common = new(RewardPayloadCommon) + } + return protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupRewardPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GrantSignupRewardPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupRewardPayload.common": + m := new(RewardPayloadCommon) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupRewardPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GrantSignupRewardPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.GrantSignupRewardPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GrantSignupRewardPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupRewardPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GrantSignupRewardPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GrantSignupRewardPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GrantSignupRewardPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Common != nil { + l = options.Size(x.Common) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GrantSignupRewardPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Common != nil { + encoded, err := options.Marshal(x.Common) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GrantSignupRewardPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantSignupRewardPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantSignupRewardPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Common", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Common == nil { + x.Common = &RewardPayloadCommon{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Common); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_GrantSignupReferrerRewardPayload protoreflect.MessageDescriptor + fd_GrantSignupReferrerRewardPayload_common protoreflect.FieldDescriptor + fd_GrantSignupReferrerRewardPayload_referee protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_GrantSignupReferrerRewardPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("GrantSignupReferrerRewardPayload") + fd_GrantSignupReferrerRewardPayload_common = md_GrantSignupReferrerRewardPayload.Fields().ByName("common") + fd_GrantSignupReferrerRewardPayload_referee = md_GrantSignupReferrerRewardPayload.Fields().ByName("referee") +} + +var _ protoreflect.Message = (*fastReflection_GrantSignupReferrerRewardPayload)(nil) + +type fastReflection_GrantSignupReferrerRewardPayload GrantSignupReferrerRewardPayload + +func (x *GrantSignupReferrerRewardPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_GrantSignupReferrerRewardPayload)(x) +} + +func (x *GrantSignupReferrerRewardPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GrantSignupReferrerRewardPayload_messageType fastReflection_GrantSignupReferrerRewardPayload_messageType +var _ protoreflect.MessageType = fastReflection_GrantSignupReferrerRewardPayload_messageType{} + +type fastReflection_GrantSignupReferrerRewardPayload_messageType struct{} + +func (x fastReflection_GrantSignupReferrerRewardPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_GrantSignupReferrerRewardPayload)(nil) +} +func (x fastReflection_GrantSignupReferrerRewardPayload_messageType) New() protoreflect.Message { + return new(fastReflection_GrantSignupReferrerRewardPayload) +} +func (x fastReflection_GrantSignupReferrerRewardPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GrantSignupReferrerRewardPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Descriptor() protoreflect.MessageDescriptor { + return md_GrantSignupReferrerRewardPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Type() protoreflect.MessageType { + return _fastReflection_GrantSignupReferrerRewardPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GrantSignupReferrerRewardPayload) New() protoreflect.Message { + return new(fastReflection_GrantSignupReferrerRewardPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Interface() protoreflect.ProtoMessage { + return (*GrantSignupReferrerRewardPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Common != nil { + value := protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + if !f(fd_GrantSignupReferrerRewardPayload_common, value) { + return + } + } + if x.Referee != "" { + value := protoreflect.ValueOfString(x.Referee) + if !f(fd_GrantSignupReferrerRewardPayload_referee, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.common": + return x.Common != nil + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.referee": + return x.Referee != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.common": + x.Common = nil + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.referee": + x.Referee = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.common": + value := x.Common + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.referee": + value := x.Referee + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.common": + x.Common = value.Message().Interface().(*RewardPayloadCommon) + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.referee": + x.Referee = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupReferrerRewardPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.common": + if x.Common == nil { + x.Common = new(RewardPayloadCommon) + } + return protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.referee": + panic(fmt.Errorf("field referee of message sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GrantSignupReferrerRewardPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.common": + m := new(RewardPayloadCommon) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.referee": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GrantSignupReferrerRewardPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GrantSignupReferrerRewardPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupReferrerRewardPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GrantSignupReferrerRewardPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GrantSignupReferrerRewardPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GrantSignupReferrerRewardPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Common != nil { + l = options.Size(x.Common) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Referee) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GrantSignupReferrerRewardPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Referee) > 0 { + i -= len(x.Referee) + copy(dAtA[i:], x.Referee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Referee))) + i-- + dAtA[i] = 0x12 + } + if x.Common != nil { + encoded, err := options.Marshal(x.Common) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GrantSignupReferrerRewardPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantSignupReferrerRewardPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantSignupReferrerRewardPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Common", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Common == nil { + x.Common = &RewardPayloadCommon{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Common); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Referee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Referee = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_GrantSignupAffiliatorRewardPayload protoreflect.MessageDescriptor + fd_GrantSignupAffiliatorRewardPayload_common protoreflect.FieldDescriptor + fd_GrantSignupAffiliatorRewardPayload_affiliatee protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_GrantSignupAffiliatorRewardPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("GrantSignupAffiliatorRewardPayload") + fd_GrantSignupAffiliatorRewardPayload_common = md_GrantSignupAffiliatorRewardPayload.Fields().ByName("common") + fd_GrantSignupAffiliatorRewardPayload_affiliatee = md_GrantSignupAffiliatorRewardPayload.Fields().ByName("affiliatee") +} + +var _ protoreflect.Message = (*fastReflection_GrantSignupAffiliatorRewardPayload)(nil) + +type fastReflection_GrantSignupAffiliatorRewardPayload GrantSignupAffiliatorRewardPayload + +func (x *GrantSignupAffiliatorRewardPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_GrantSignupAffiliatorRewardPayload)(x) +} + +func (x *GrantSignupAffiliatorRewardPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GrantSignupAffiliatorRewardPayload_messageType fastReflection_GrantSignupAffiliatorRewardPayload_messageType +var _ protoreflect.MessageType = fastReflection_GrantSignupAffiliatorRewardPayload_messageType{} + +type fastReflection_GrantSignupAffiliatorRewardPayload_messageType struct{} + +func (x fastReflection_GrantSignupAffiliatorRewardPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_GrantSignupAffiliatorRewardPayload)(nil) +} +func (x fastReflection_GrantSignupAffiliatorRewardPayload_messageType) New() protoreflect.Message { + return new(fastReflection_GrantSignupAffiliatorRewardPayload) +} +func (x fastReflection_GrantSignupAffiliatorRewardPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GrantSignupAffiliatorRewardPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Descriptor() protoreflect.MessageDescriptor { + return md_GrantSignupAffiliatorRewardPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Type() protoreflect.MessageType { + return _fastReflection_GrantSignupAffiliatorRewardPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) New() protoreflect.Message { + return new(fastReflection_GrantSignupAffiliatorRewardPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Interface() protoreflect.ProtoMessage { + return (*GrantSignupAffiliatorRewardPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Common != nil { + value := protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + if !f(fd_GrantSignupAffiliatorRewardPayload_common, value) { + return + } + } + if x.Affiliatee != "" { + value := protoreflect.ValueOfString(x.Affiliatee) + if !f(fd_GrantSignupAffiliatorRewardPayload_affiliatee, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.common": + return x.Common != nil + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.affiliatee": + return x.Affiliatee != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.common": + x.Common = nil + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.affiliatee": + x.Affiliatee = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.common": + value := x.Common + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.affiliatee": + value := x.Affiliatee + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.common": + x.Common = value.Message().Interface().(*RewardPayloadCommon) + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.affiliatee": + x.Affiliatee = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.common": + if x.Common == nil { + x.Common = new(RewardPayloadCommon) + } + return protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.affiliatee": + panic(fmt.Errorf("field affiliatee of message sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.common": + m := new(RewardPayloadCommon) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.affiliatee": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GrantSignupAffiliatorRewardPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GrantSignupAffiliatorRewardPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Common != nil { + l = options.Size(x.Common) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Affiliatee) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GrantSignupAffiliatorRewardPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Affiliatee) > 0 { + i -= len(x.Affiliatee) + copy(dAtA[i:], x.Affiliatee) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Affiliatee))) + i-- + dAtA[i] = 0x12 + } + if x.Common != nil { + encoded, err := options.Marshal(x.Common) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GrantSignupAffiliatorRewardPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantSignupAffiliatorRewardPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantSignupAffiliatorRewardPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Common", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Common == nil { + x.Common = &RewardPayloadCommon{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Common); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Affiliatee", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Affiliatee = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_GrantBetBonusRewardPayload protoreflect.MessageDescriptor + fd_GrantBetBonusRewardPayload_common protoreflect.FieldDescriptor + fd_GrantBetBonusRewardPayload_bet_uid protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_GrantBetBonusRewardPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("GrantBetBonusRewardPayload") + fd_GrantBetBonusRewardPayload_common = md_GrantBetBonusRewardPayload.Fields().ByName("common") + fd_GrantBetBonusRewardPayload_bet_uid = md_GrantBetBonusRewardPayload.Fields().ByName("bet_uid") +} + +var _ protoreflect.Message = (*fastReflection_GrantBetBonusRewardPayload)(nil) + +type fastReflection_GrantBetBonusRewardPayload GrantBetBonusRewardPayload + +func (x *GrantBetBonusRewardPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_GrantBetBonusRewardPayload)(x) +} + +func (x *GrantBetBonusRewardPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GrantBetBonusRewardPayload_messageType fastReflection_GrantBetBonusRewardPayload_messageType +var _ protoreflect.MessageType = fastReflection_GrantBetBonusRewardPayload_messageType{} + +type fastReflection_GrantBetBonusRewardPayload_messageType struct{} + +func (x fastReflection_GrantBetBonusRewardPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_GrantBetBonusRewardPayload)(nil) +} +func (x fastReflection_GrantBetBonusRewardPayload_messageType) New() protoreflect.Message { + return new(fastReflection_GrantBetBonusRewardPayload) +} +func (x fastReflection_GrantBetBonusRewardPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GrantBetBonusRewardPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GrantBetBonusRewardPayload) Descriptor() protoreflect.MessageDescriptor { + return md_GrantBetBonusRewardPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GrantBetBonusRewardPayload) Type() protoreflect.MessageType { + return _fastReflection_GrantBetBonusRewardPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GrantBetBonusRewardPayload) New() protoreflect.Message { + return new(fastReflection_GrantBetBonusRewardPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GrantBetBonusRewardPayload) Interface() protoreflect.ProtoMessage { + return (*GrantBetBonusRewardPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GrantBetBonusRewardPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Common != nil { + value := protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + if !f(fd_GrantBetBonusRewardPayload_common, value) { + return + } + } + if x.BetUid != "" { + value := protoreflect.ValueOfString(x.BetUid) + if !f(fd_GrantBetBonusRewardPayload_bet_uid, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GrantBetBonusRewardPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.common": + return x.Common != nil + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.bet_uid": + return x.BetUid != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantBetBonusRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantBetBonusRewardPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.common": + x.Common = nil + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.bet_uid": + x.BetUid = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantBetBonusRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GrantBetBonusRewardPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.common": + value := x.Common + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.bet_uid": + value := x.BetUid + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantBetBonusRewardPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantBetBonusRewardPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.common": + x.Common = value.Message().Interface().(*RewardPayloadCommon) + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.bet_uid": + x.BetUid = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantBetBonusRewardPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantBetBonusRewardPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.common": + if x.Common == nil { + x.Common = new(RewardPayloadCommon) + } + return protoreflect.ValueOfMessage(x.Common.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.bet_uid": + panic(fmt.Errorf("field bet_uid of message sge.legacy.reward.v1beta.GrantBetBonusRewardPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantBetBonusRewardPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GrantBetBonusRewardPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.common": + m := new(RewardPayloadCommon) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.bet_uid": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.GrantBetBonusRewardPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GrantBetBonusRewardPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.GrantBetBonusRewardPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GrantBetBonusRewardPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GrantBetBonusRewardPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GrantBetBonusRewardPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GrantBetBonusRewardPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GrantBetBonusRewardPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Common != nil { + l = options.Size(x.Common) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.BetUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GrantBetBonusRewardPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.BetUid) > 0 { + i -= len(x.BetUid) + copy(dAtA[i:], x.BetUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.BetUid))) + i-- + dAtA[i] = 0x12 + } + if x.Common != nil { + encoded, err := options.Marshal(x.Common) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GrantBetBonusRewardPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantBetBonusRewardPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GrantBetBonusRewardPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Common", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Common == nil { + x.Common = &RewardPayloadCommon{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Common); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BetUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.BetUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_CreatePromoterPayload protoreflect.MessageDescriptor + fd_CreatePromoterPayload_uid protoreflect.FieldDescriptor + fd_CreatePromoterPayload_conf protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_CreatePromoterPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("CreatePromoterPayload") + fd_CreatePromoterPayload_uid = md_CreatePromoterPayload.Fields().ByName("uid") + fd_CreatePromoterPayload_conf = md_CreatePromoterPayload.Fields().ByName("conf") +} + +var _ protoreflect.Message = (*fastReflection_CreatePromoterPayload)(nil) + +type fastReflection_CreatePromoterPayload CreatePromoterPayload + +func (x *CreatePromoterPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_CreatePromoterPayload)(x) +} + +func (x *CreatePromoterPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_CreatePromoterPayload_messageType fastReflection_CreatePromoterPayload_messageType +var _ protoreflect.MessageType = fastReflection_CreatePromoterPayload_messageType{} + +type fastReflection_CreatePromoterPayload_messageType struct{} + +func (x fastReflection_CreatePromoterPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_CreatePromoterPayload)(nil) +} +func (x fastReflection_CreatePromoterPayload_messageType) New() protoreflect.Message { + return new(fastReflection_CreatePromoterPayload) +} +func (x fastReflection_CreatePromoterPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_CreatePromoterPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_CreatePromoterPayload) Descriptor() protoreflect.MessageDescriptor { + return md_CreatePromoterPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_CreatePromoterPayload) Type() protoreflect.MessageType { + return _fastReflection_CreatePromoterPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_CreatePromoterPayload) New() protoreflect.Message { + return new(fastReflection_CreatePromoterPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_CreatePromoterPayload) Interface() protoreflect.ProtoMessage { + return (*CreatePromoterPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_CreatePromoterPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_CreatePromoterPayload_uid, value) { + return + } + } + if x.Conf != nil { + value := protoreflect.ValueOfMessage(x.Conf.ProtoReflect()) + if !f(fd_CreatePromoterPayload_conf, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_CreatePromoterPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreatePromoterPayload.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.CreatePromoterPayload.conf": + return x.Conf != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreatePromoterPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreatePromoterPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreatePromoterPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreatePromoterPayload.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.CreatePromoterPayload.conf": + x.Conf = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreatePromoterPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreatePromoterPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_CreatePromoterPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.CreatePromoterPayload.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.CreatePromoterPayload.conf": + value := x.Conf + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreatePromoterPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreatePromoterPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreatePromoterPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreatePromoterPayload.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.CreatePromoterPayload.conf": + x.Conf = value.Message().Interface().(*PromoterConf) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreatePromoterPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreatePromoterPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreatePromoterPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreatePromoterPayload.conf": + if x.Conf == nil { + x.Conf = new(PromoterConf) + } + return protoreflect.ValueOfMessage(x.Conf.ProtoReflect()) + case "sge.legacy.reward.v1beta.CreatePromoterPayload.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.CreatePromoterPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreatePromoterPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreatePromoterPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_CreatePromoterPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.CreatePromoterPayload.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.CreatePromoterPayload.conf": + m := new(PromoterConf) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.CreatePromoterPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.CreatePromoterPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_CreatePromoterPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.CreatePromoterPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_CreatePromoterPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_CreatePromoterPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_CreatePromoterPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_CreatePromoterPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*CreatePromoterPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Conf != nil { + l = options.Size(x.Conf) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*CreatePromoterPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Conf != nil { + encoded, err := options.Marshal(x.Conf) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*CreatePromoterPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CreatePromoterPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: CreatePromoterPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Conf", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Conf == nil { + x.Conf = &PromoterConf{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Conf); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_SetPromoterConfPayload protoreflect.MessageDescriptor + fd_SetPromoterConfPayload_conf protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_ticket_proto_init() + md_SetPromoterConfPayload = File_sge_legacy_reward_v1beta_ticket_proto.Messages().ByName("SetPromoterConfPayload") + fd_SetPromoterConfPayload_conf = md_SetPromoterConfPayload.Fields().ByName("conf") +} + +var _ protoreflect.Message = (*fastReflection_SetPromoterConfPayload)(nil) + +type fastReflection_SetPromoterConfPayload SetPromoterConfPayload + +func (x *SetPromoterConfPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_SetPromoterConfPayload)(x) +} + +func (x *SetPromoterConfPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_SetPromoterConfPayload_messageType fastReflection_SetPromoterConfPayload_messageType +var _ protoreflect.MessageType = fastReflection_SetPromoterConfPayload_messageType{} + +type fastReflection_SetPromoterConfPayload_messageType struct{} + +func (x fastReflection_SetPromoterConfPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_SetPromoterConfPayload)(nil) +} +func (x fastReflection_SetPromoterConfPayload_messageType) New() protoreflect.Message { + return new(fastReflection_SetPromoterConfPayload) +} +func (x fastReflection_SetPromoterConfPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_SetPromoterConfPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_SetPromoterConfPayload) Descriptor() protoreflect.MessageDescriptor { + return md_SetPromoterConfPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_SetPromoterConfPayload) Type() protoreflect.MessageType { + return _fastReflection_SetPromoterConfPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_SetPromoterConfPayload) New() protoreflect.Message { + return new(fastReflection_SetPromoterConfPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_SetPromoterConfPayload) Interface() protoreflect.ProtoMessage { + return (*SetPromoterConfPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_SetPromoterConfPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Conf != nil { + value := protoreflect.ValueOfMessage(x.Conf.ProtoReflect()) + if !f(fd_SetPromoterConfPayload_conf, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_SetPromoterConfPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.SetPromoterConfPayload.conf": + return x.Conf != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.SetPromoterConfPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.SetPromoterConfPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SetPromoterConfPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.SetPromoterConfPayload.conf": + x.Conf = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.SetPromoterConfPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.SetPromoterConfPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_SetPromoterConfPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.SetPromoterConfPayload.conf": + value := x.Conf + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.SetPromoterConfPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.SetPromoterConfPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SetPromoterConfPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.SetPromoterConfPayload.conf": + x.Conf = value.Message().Interface().(*PromoterConf) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.SetPromoterConfPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.SetPromoterConfPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SetPromoterConfPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.SetPromoterConfPayload.conf": + if x.Conf == nil { + x.Conf = new(PromoterConf) + } + return protoreflect.ValueOfMessage(x.Conf.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.SetPromoterConfPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.SetPromoterConfPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_SetPromoterConfPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.SetPromoterConfPayload.conf": + m := new(PromoterConf) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.SetPromoterConfPayload")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.SetPromoterConfPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_SetPromoterConfPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.SetPromoterConfPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_SetPromoterConfPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SetPromoterConfPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_SetPromoterConfPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_SetPromoterConfPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*SetPromoterConfPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Conf != nil { + l = options.Size(x.Conf) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*SetPromoterConfPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Conf != nil { + encoded, err := options.Marshal(x.Conf) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*SetPromoterConfPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SetPromoterConfPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SetPromoterConfPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Conf", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Conf == nil { + x.Conf = &PromoterConf{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Conf); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/ticket.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// CreateCampaignPayload is the type for campaign creation payload. +type CreateCampaignPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // promoter is the address of campaign promoter. + // Funds for the campaign would be deducted from this account. + Promoter string `protobuf:"bytes,1,opt,name=promoter,proto3" json:"promoter,omitempty"` + // start_ts is the start timestamp of the campaign. + StartTs uint64 `protobuf:"varint,2,opt,name=start_ts,json=startTs,proto3" json:"start_ts,omitempty"` + // end_ts is the end timestamp of the campaign. + EndTs uint64 `protobuf:"varint,3,opt,name=end_ts,json=endTs,proto3" json:"end_ts,omitempty"` + // category is the category of the campaign. + Category RewardCategory `protobuf:"varint,4,opt,name=category,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"category,omitempty"` + // reward_type is the type of reward. + RewardType RewardType `protobuf:"varint,5,opt,name=reward_type,json=rewardType,proto3,enum=sge.legacy.reward.v1beta.RewardType" json:"reward_type,omitempty"` + // Reward amount + RewardAmountType RewardAmountType `protobuf:"varint,6,opt,name=reward_amount_type,json=rewardAmountType,proto3,enum=sge.legacy.reward.v1beta.RewardAmountType" json:"reward_amount_type,omitempty"` + // reward_amount is the amount of reward. + RewardAmount *RewardAmount `protobuf:"bytes,7,opt,name=reward_amount,json=rewardAmount,proto3" json:"reward_amount,omitempty"` + // is_active is the flag to check if the campaign is active or not. + IsActive bool `protobuf:"varint,8,opt,name=is_active,json=isActive,proto3" json:"is_active,omitempty"` + // meta is the metadata of the campaign. + // It is a stringified base64 encoded json. + Meta string `protobuf:"bytes,10,opt,name=meta,proto3" json:"meta,omitempty"` + // cap_count is the maximum allowed grant for a certain account. + CapCount uint64 `protobuf:"varint,11,opt,name=cap_count,json=capCount,proto3" json:"cap_count,omitempty"` + // constraints is the constrains of a campaign. + Constraints *CampaignConstraints `protobuf:"bytes,12,opt,name=constraints,proto3" json:"constraints,omitempty"` +} + +func (x *CreateCampaignPayload) Reset() { + *x = CreateCampaignPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CreateCampaignPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CreateCampaignPayload) ProtoMessage() {} + +// Deprecated: Use CreateCampaignPayload.ProtoReflect.Descriptor instead. +func (*CreateCampaignPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{0} +} + +func (x *CreateCampaignPayload) GetPromoter() string { + if x != nil { + return x.Promoter + } + return "" +} + +func (x *CreateCampaignPayload) GetStartTs() uint64 { + if x != nil { + return x.StartTs + } + return 0 +} + +func (x *CreateCampaignPayload) GetEndTs() uint64 { + if x != nil { + return x.EndTs + } + return 0 +} + +func (x *CreateCampaignPayload) GetCategory() RewardCategory { + if x != nil { + return x.Category + } + return RewardCategory_REWARD_CATEGORY_UNSPECIFIED +} + +func (x *CreateCampaignPayload) GetRewardType() RewardType { + if x != nil { + return x.RewardType + } + return RewardType_REWARD_TYPE_UNSPECIFIED +} + +func (x *CreateCampaignPayload) GetRewardAmountType() RewardAmountType { + if x != nil { + return x.RewardAmountType + } + return RewardAmountType_REWARD_AMOUNT_TYPE_UNSPECIFIED +} + +func (x *CreateCampaignPayload) GetRewardAmount() *RewardAmount { + if x != nil { + return x.RewardAmount + } + return nil +} + +func (x *CreateCampaignPayload) GetIsActive() bool { + if x != nil { + return x.IsActive + } + return false +} + +func (x *CreateCampaignPayload) GetMeta() string { + if x != nil { + return x.Meta + } + return "" +} + +func (x *CreateCampaignPayload) GetCapCount() uint64 { + if x != nil { + return x.CapCount + } + return 0 +} + +func (x *CreateCampaignPayload) GetConstraints() *CampaignConstraints { + if x != nil { + return x.Constraints + } + return nil +} + +// UpdateCampaignPayload is the type for campaign update payload. +type UpdateCampaignPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // end_ts is the end timestamp of the campaign. + EndTs uint64 `protobuf:"varint,1,opt,name=end_ts,json=endTs,proto3" json:"end_ts,omitempty"` + // is_active is the flag to check if the campaign is active or not. + IsActive bool `protobuf:"varint,2,opt,name=is_active,json=isActive,proto3" json:"is_active,omitempty"` +} + +func (x *UpdateCampaignPayload) Reset() { + *x = UpdateCampaignPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdateCampaignPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdateCampaignPayload) ProtoMessage() {} + +// Deprecated: Use UpdateCampaignPayload.ProtoReflect.Descriptor instead. +func (*UpdateCampaignPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{1} +} + +func (x *UpdateCampaignPayload) GetEndTs() uint64 { + if x != nil { + return x.EndTs + } + return 0 +} + +func (x *UpdateCampaignPayload) GetIsActive() bool { + if x != nil { + return x.IsActive + } + return false +} + +// WithdrawFundsPayload is the type for campaign withdraw funds payload. +type WithdrawFundsPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // promoter is the address of campaign promoter. + // Funds would be transferred to this account. + Promoter string `protobuf:"bytes,1,opt,name=promoter,proto3" json:"promoter,omitempty"` +} + +func (x *WithdrawFundsPayload) Reset() { + *x = WithdrawFundsPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *WithdrawFundsPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*WithdrawFundsPayload) ProtoMessage() {} + +// Deprecated: Use WithdrawFundsPayload.ProtoReflect.Descriptor instead. +func (*WithdrawFundsPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{2} +} + +func (x *WithdrawFundsPayload) GetPromoter() string { + if x != nil { + return x.Promoter + } + return "" +} + +// RewardPayloadCommon +type RewardPayloadCommon struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // receiver is the address of the account that receives the reward. + Receiver string `protobuf:"bytes,1,opt,name=receiver,proto3" json:"receiver,omitempty"` + // source_uid is the address of the source. + // It is used to identify the source of the reward. + // For example, the source uid of a referral signup reward is the address of + // the referer. + SourceUid string `protobuf:"bytes,2,opt,name=source_uid,proto3" json:"source_uid,omitempty"` + // meta is the metadata of the campaign. + // It is a stringified base64 encoded json. + Meta string `protobuf:"bytes,3,opt,name=meta,proto3" json:"meta,omitempty"` + // kyc_data contains the details of user kyc. + KycData *v1beta.KycDataPayload `protobuf:"bytes,4,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data,omitempty"` +} + +func (x *RewardPayloadCommon) Reset() { + *x = RewardPayloadCommon{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RewardPayloadCommon) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RewardPayloadCommon) ProtoMessage() {} + +// Deprecated: Use RewardPayloadCommon.ProtoReflect.Descriptor instead. +func (*RewardPayloadCommon) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{3} +} + +func (x *RewardPayloadCommon) GetReceiver() string { + if x != nil { + return x.Receiver + } + return "" +} + +func (x *RewardPayloadCommon) GetSourceUid() string { + if x != nil { + return x.SourceUid + } + return "" +} + +func (x *RewardPayloadCommon) GetMeta() string { + if x != nil { + return x.Meta + } + return "" +} + +func (x *RewardPayloadCommon) GetKycData() *v1beta.KycDataPayload { + if x != nil { + return x.KycData + } + return nil +} + +// GrantSignupRewardPayload is the type for signup reward grant payload. +type GrantSignupRewardPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // common is the common properties of a reward + Common *RewardPayloadCommon `protobuf:"bytes,2,opt,name=common,proto3" json:"common,omitempty"` +} + +func (x *GrantSignupRewardPayload) Reset() { + *x = GrantSignupRewardPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GrantSignupRewardPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GrantSignupRewardPayload) ProtoMessage() {} + +// Deprecated: Use GrantSignupRewardPayload.ProtoReflect.Descriptor instead. +func (*GrantSignupRewardPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{4} +} + +func (x *GrantSignupRewardPayload) GetCommon() *RewardPayloadCommon { + if x != nil { + return x.Common + } + return nil +} + +// GrantSignupReferrerRewardPayload is the type for signup referrer reward grant +// payload. +type GrantSignupReferrerRewardPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // common is the common properties of a reward + Common *RewardPayloadCommon `protobuf:"bytes,1,opt,name=common,proto3" json:"common,omitempty"` + // referee is the address of the account that used this referrer address as + // source_uid + Referee string `protobuf:"bytes,2,opt,name=referee,proto3" json:"referee,omitempty"` +} + +func (x *GrantSignupReferrerRewardPayload) Reset() { + *x = GrantSignupReferrerRewardPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GrantSignupReferrerRewardPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GrantSignupReferrerRewardPayload) ProtoMessage() {} + +// Deprecated: Use GrantSignupReferrerRewardPayload.ProtoReflect.Descriptor instead. +func (*GrantSignupReferrerRewardPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{5} +} + +func (x *GrantSignupReferrerRewardPayload) GetCommon() *RewardPayloadCommon { + if x != nil { + return x.Common + } + return nil +} + +func (x *GrantSignupReferrerRewardPayload) GetReferee() string { + if x != nil { + return x.Referee + } + return "" +} + +// GrantSignupAffiliatorRewardPayload is the type for signup affiliator reward +// grant payload. +type GrantSignupAffiliatorRewardPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // common is the common properties of a reward + Common *RewardPayloadCommon `protobuf:"bytes,1,opt,name=common,proto3" json:"common,omitempty"` + // affiliatee is the address of the account that used this affiliator's + // address as source_uid + Affiliatee string `protobuf:"bytes,2,opt,name=affiliatee,proto3" json:"affiliatee,omitempty"` +} + +func (x *GrantSignupAffiliatorRewardPayload) Reset() { + *x = GrantSignupAffiliatorRewardPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GrantSignupAffiliatorRewardPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GrantSignupAffiliatorRewardPayload) ProtoMessage() {} + +// Deprecated: Use GrantSignupAffiliatorRewardPayload.ProtoReflect.Descriptor instead. +func (*GrantSignupAffiliatorRewardPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{6} +} + +func (x *GrantSignupAffiliatorRewardPayload) GetCommon() *RewardPayloadCommon { + if x != nil { + return x.Common + } + return nil +} + +func (x *GrantSignupAffiliatorRewardPayload) GetAffiliatee() string { + if x != nil { + return x.Affiliatee + } + return "" +} + +// GrantBetBonusRewardPayload is the type for bet bonus reward +// grant payload. +type GrantBetBonusRewardPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // common is the common properties of a reward + Common *RewardPayloadCommon `protobuf:"bytes,1,opt,name=common,proto3" json:"common,omitempty"` + // bet_uid is the list of uids + BetUid string `protobuf:"bytes,2,opt,name=bet_uid,proto3" json:"bet_uid,omitempty"` +} + +func (x *GrantBetBonusRewardPayload) Reset() { + *x = GrantBetBonusRewardPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GrantBetBonusRewardPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GrantBetBonusRewardPayload) ProtoMessage() {} + +// Deprecated: Use GrantBetBonusRewardPayload.ProtoReflect.Descriptor instead. +func (*GrantBetBonusRewardPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{7} +} + +func (x *GrantBetBonusRewardPayload) GetCommon() *RewardPayloadCommon { + if x != nil { + return x.Common + } + return nil +} + +func (x *GrantBetBonusRewardPayload) GetBetUid() string { + if x != nil { + return x.BetUid + } + return "" +} + +// CreatePromoterPayload is the payload for the promoter create. +type CreatePromoterPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // uid is the uid of the promoter to be created + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + Conf *PromoterConf `protobuf:"bytes,2,opt,name=conf,proto3" json:"conf,omitempty"` +} + +func (x *CreatePromoterPayload) Reset() { + *x = CreatePromoterPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CreatePromoterPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CreatePromoterPayload) ProtoMessage() {} + +// Deprecated: Use CreatePromoterPayload.ProtoReflect.Descriptor instead. +func (*CreatePromoterPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{8} +} + +func (x *CreatePromoterPayload) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *CreatePromoterPayload) GetConf() *PromoterConf { + if x != nil { + return x.Conf + } + return nil +} + +// SetPromoterConfPayload is the payload for the promoter configuration change. +type SetPromoterConfPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Conf *PromoterConf `protobuf:"bytes,1,opt,name=conf,proto3" json:"conf,omitempty"` +} + +func (x *SetPromoterConfPayload) Reset() { + *x = SetPromoterConfPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SetPromoterConfPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SetPromoterConfPayload) ProtoMessage() {} + +// Deprecated: Use SetPromoterConfPayload.ProtoReflect.Descriptor instead. +func (*SetPromoterConfPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP(), []int{9} +} + +func (x *SetPromoterConfPayload) GetConf() *PromoterConf { + if x != nil { + return x.Conf + } + return nil +} + +var File_sge_legacy_reward_v1beta_ticket_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_ticket_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x63, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x27, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x20, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2f, 0x6b, 0x79, 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xd2, 0x04, + 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x34, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x6d, 0x6f, + 0x74, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x12, 0x19, 0x0a, + 0x08, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, + 0x07, 0x73, 0x74, 0x61, 0x72, 0x74, 0x54, 0x73, 0x12, 0x15, 0x0a, 0x06, 0x65, 0x6e, 0x64, 0x5f, + 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x65, 0x6e, 0x64, 0x54, 0x73, 0x12, + 0x44, 0x0a, 0x08, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, + 0x0e, 0x32, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x08, 0x63, 0x61, 0x74, + 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x45, 0x0a, 0x0b, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, + 0x74, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x24, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x54, 0x79, 0x70, 0x65, + 0x52, 0x0a, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x54, 0x79, 0x70, 0x65, 0x12, 0x58, 0x0a, 0x12, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x74, 0x79, + 0x70, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, + 0x54, 0x79, 0x70, 0x65, 0x52, 0x10, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, 0x75, + 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x4b, 0x0a, 0x0d, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, + 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x0c, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x41, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x69, 0x73, 0x5f, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, + 0x12, 0x12, 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x6d, 0x65, 0x74, 0x61, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x61, 0x70, 0x5f, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x63, 0x61, 0x70, 0x43, 0x6f, 0x75, 0x6e, + 0x74, 0x12, 0x4f, 0x0a, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, + 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, + 0x61, 0x69, 0x6e, 0x74, 0x73, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, + 0x74, 0x73, 0x22, 0x4b, 0x0a, 0x15, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, + 0x61, 0x69, 0x67, 0x6e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x15, 0x0a, 0x06, 0x65, + 0x6e, 0x64, 0x5f, 0x74, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x65, 0x6e, 0x64, + 0x54, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x69, 0x73, 0x5f, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x69, 0x73, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, 0x22, + 0x4c, 0x0a, 0x14, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x46, 0x75, 0x6e, 0x64, 0x73, + 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x34, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x6d, 0x6f, + 0x74, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x22, 0xdf, 0x01, + 0x0a, 0x13, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x43, + 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x12, 0x34, 0x0a, 0x08, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, + 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, + 0x67, 0x52, 0x08, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x72, 0x12, 0x3b, 0x0a, 0x0a, 0x73, + 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x1b, 0xe2, 0xde, 0x1f, 0x09, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x55, 0x49, 0x44, 0xea, 0xde, + 0x1f, 0x0a, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x75, 0x69, 0x64, 0x52, 0x0a, 0x73, 0x6f, + 0x75, 0x72, 0x63, 0x65, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x12, 0x41, 0x0a, 0x08, + 0x6b, 0x79, 0x63, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x74, 0x79, 0x70, 0x65, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4b, 0x79, 0x63, 0x44, 0x61, 0x74, 0x61, 0x50, + 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x07, 0x6b, 0x79, 0x63, 0x44, 0x61, 0x74, 0x61, 0x22, + 0x67, 0x0a, 0x18, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x75, 0x70, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x4b, 0x0a, 0x06, 0x63, + 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, 0x79, + 0x6c, 0x6f, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, + 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x22, 0xa3, 0x01, 0x0a, 0x20, 0x47, 0x72, 0x61, + 0x6e, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x75, 0x70, 0x52, 0x65, 0x66, 0x65, 0x72, 0x72, 0x65, 0x72, + 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x4b, 0x0a, + 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, + 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x42, 0x04, 0xc8, 0xde, + 0x1f, 0x00, 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x72, 0x65, + 0x66, 0x65, 0x72, 0x65, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, + 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, + 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x65, 0x22, 0xab, + 0x01, 0x0a, 0x22, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x75, 0x70, 0x41, 0x66, + 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, + 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x4b, 0x0a, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x43, 0x6f, + 0x6d, 0x6d, 0x6f, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, + 0x6f, 0x6e, 0x12, 0x38, 0x0a, 0x0a, 0x61, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x65, 0x65, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, + 0x52, 0x0a, 0x61, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x65, 0x65, 0x22, 0x9a, 0x01, 0x0a, + 0x1a, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x42, 0x65, 0x74, 0x42, 0x6f, 0x6e, 0x75, 0x73, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x4b, 0x0a, 0x06, 0x63, + 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x50, 0x61, 0x79, + 0x6c, 0x6f, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, + 0x52, 0x06, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x12, 0x2f, 0x0a, 0x07, 0x62, 0x65, 0x74, 0x5f, + 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x15, 0xe2, 0xde, 0x1f, 0x06, 0x42, + 0x65, 0x74, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x07, 0x62, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, + 0x52, 0x07, 0x62, 0x65, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x22, 0x7b, 0x0a, 0x15, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x50, 0x61, 0x79, 0x6c, 0x6f, + 0x61, 0x64, 0x12, 0x20, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x0e, 0xe2, 0xde, 0x1f, 0x03, 0x55, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x03, 0x75, 0x69, 0x64, 0x52, + 0x03, 0x75, 0x69, 0x64, 0x12, 0x40, 0x0a, 0x04, 0x63, 0x6f, 0x6e, 0x66, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, + 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, + 0x52, 0x04, 0x63, 0x6f, 0x6e, 0x66, 0x22, 0x5a, 0x0a, 0x16, 0x53, 0x65, 0x74, 0x50, 0x72, 0x6f, + 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, + 0x12, 0x40, 0x0a, 0x04, 0x63, 0x6f, 0x6e, 0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, + 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x04, 0x63, 0x6f, + 0x6e, 0x66, 0x42, 0xf4, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x42, 0x0b, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, + 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x72, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x52, 0xaa, 0x02, + 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x52, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, + 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, 0x61, 0x72, + 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_ticket_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_ticket_proto_rawDescData = file_sge_legacy_reward_v1beta_ticket_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_ticket_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_ticket_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_ticket_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_ticket_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_ticket_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_ticket_proto_msgTypes = make([]protoimpl.MessageInfo, 10) +var file_sge_legacy_reward_v1beta_ticket_proto_goTypes = []interface{}{ + (*CreateCampaignPayload)(nil), // 0: sge.legacy.reward.v1beta.CreateCampaignPayload + (*UpdateCampaignPayload)(nil), // 1: sge.legacy.reward.v1beta.UpdateCampaignPayload + (*WithdrawFundsPayload)(nil), // 2: sge.legacy.reward.v1beta.WithdrawFundsPayload + (*RewardPayloadCommon)(nil), // 3: sge.legacy.reward.v1beta.RewardPayloadCommon + (*GrantSignupRewardPayload)(nil), // 4: sge.legacy.reward.v1beta.GrantSignupRewardPayload + (*GrantSignupReferrerRewardPayload)(nil), // 5: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload + (*GrantSignupAffiliatorRewardPayload)(nil), // 6: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload + (*GrantBetBonusRewardPayload)(nil), // 7: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload + (*CreatePromoterPayload)(nil), // 8: sge.legacy.reward.v1beta.CreatePromoterPayload + (*SetPromoterConfPayload)(nil), // 9: sge.legacy.reward.v1beta.SetPromoterConfPayload + (RewardCategory)(0), // 10: sge.legacy.reward.v1beta.RewardCategory + (RewardType)(0), // 11: sge.legacy.reward.v1beta.RewardType + (RewardAmountType)(0), // 12: sge.legacy.reward.v1beta.RewardAmountType + (*RewardAmount)(nil), // 13: sge.legacy.reward.v1beta.RewardAmount + (*CampaignConstraints)(nil), // 14: sge.legacy.reward.v1beta.CampaignConstraints + (*v1beta.KycDataPayload)(nil), // 15: sge.legacy.type.v1beta.KycDataPayload + (*PromoterConf)(nil), // 16: sge.legacy.reward.v1beta.PromoterConf +} +var file_sge_legacy_reward_v1beta_ticket_proto_depIdxs = []int32{ + 10, // 0: sge.legacy.reward.v1beta.CreateCampaignPayload.category:type_name -> sge.legacy.reward.v1beta.RewardCategory + 11, // 1: sge.legacy.reward.v1beta.CreateCampaignPayload.reward_type:type_name -> sge.legacy.reward.v1beta.RewardType + 12, // 2: sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount_type:type_name -> sge.legacy.reward.v1beta.RewardAmountType + 13, // 3: sge.legacy.reward.v1beta.CreateCampaignPayload.reward_amount:type_name -> sge.legacy.reward.v1beta.RewardAmount + 14, // 4: sge.legacy.reward.v1beta.CreateCampaignPayload.constraints:type_name -> sge.legacy.reward.v1beta.CampaignConstraints + 15, // 5: sge.legacy.reward.v1beta.RewardPayloadCommon.kyc_data:type_name -> sge.legacy.type.v1beta.KycDataPayload + 3, // 6: sge.legacy.reward.v1beta.GrantSignupRewardPayload.common:type_name -> sge.legacy.reward.v1beta.RewardPayloadCommon + 3, // 7: sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload.common:type_name -> sge.legacy.reward.v1beta.RewardPayloadCommon + 3, // 8: sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload.common:type_name -> sge.legacy.reward.v1beta.RewardPayloadCommon + 3, // 9: sge.legacy.reward.v1beta.GrantBetBonusRewardPayload.common:type_name -> sge.legacy.reward.v1beta.RewardPayloadCommon + 16, // 10: sge.legacy.reward.v1beta.CreatePromoterPayload.conf:type_name -> sge.legacy.reward.v1beta.PromoterConf + 16, // 11: sge.legacy.reward.v1beta.SetPromoterConfPayload.conf:type_name -> sge.legacy.reward.v1beta.PromoterConf + 12, // [12:12] is the sub-list for method output_type + 12, // [12:12] is the sub-list for method input_type + 12, // [12:12] is the sub-list for extension type_name + 12, // [12:12] is the sub-list for extension extendee + 0, // [0:12] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_ticket_proto_init() } +func file_sge_legacy_reward_v1beta_ticket_proto_init() { + if File_sge_legacy_reward_v1beta_ticket_proto != nil { + return + } + file_sge_legacy_reward_v1beta_campaign_proto_init() + file_sge_legacy_reward_v1beta_promoter_proto_init() + file_sge_legacy_reward_v1beta_reward_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CreateCampaignPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UpdateCampaignPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*WithdrawFundsPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RewardPayloadCommon); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GrantSignupRewardPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GrantSignupReferrerRewardPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GrantSignupAffiliatorRewardPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GrantBetBonusRewardPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CreatePromoterPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_ticket_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SetPromoterConfPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_ticket_proto_rawDesc, + NumEnums: 0, + NumMessages: 10, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_reward_v1beta_ticket_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_ticket_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_ticket_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_ticket_proto = out.File + file_sge_legacy_reward_v1beta_ticket_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_ticket_proto_goTypes = nil + file_sge_legacy_reward_v1beta_ticket_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/tx.pulsar.go b/api/sge/legacy/reward/v1beta/tx.pulsar.go new file mode 100644 index 00000000..82b01f40 --- /dev/null +++ b/api/sge/legacy/reward/v1beta/tx.pulsar.go @@ -0,0 +1,7521 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package rewardv1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_MsgCreatePromoter protoreflect.MessageDescriptor + fd_MsgCreatePromoter_creator protoreflect.FieldDescriptor + fd_MsgCreatePromoter_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgCreatePromoter = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgCreatePromoter") + fd_MsgCreatePromoter_creator = md_MsgCreatePromoter.Fields().ByName("creator") + fd_MsgCreatePromoter_ticket = md_MsgCreatePromoter.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgCreatePromoter)(nil) + +type fastReflection_MsgCreatePromoter MsgCreatePromoter + +func (x *MsgCreatePromoter) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgCreatePromoter)(x) +} + +func (x *MsgCreatePromoter) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgCreatePromoter_messageType fastReflection_MsgCreatePromoter_messageType +var _ protoreflect.MessageType = fastReflection_MsgCreatePromoter_messageType{} + +type fastReflection_MsgCreatePromoter_messageType struct{} + +func (x fastReflection_MsgCreatePromoter_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgCreatePromoter)(nil) +} +func (x fastReflection_MsgCreatePromoter_messageType) New() protoreflect.Message { + return new(fastReflection_MsgCreatePromoter) +} +func (x fastReflection_MsgCreatePromoter_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreatePromoter +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgCreatePromoter) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreatePromoter +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgCreatePromoter) Type() protoreflect.MessageType { + return _fastReflection_MsgCreatePromoter_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgCreatePromoter) New() protoreflect.Message { + return new(fastReflection_MsgCreatePromoter) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgCreatePromoter) Interface() protoreflect.ProtoMessage { + return (*MsgCreatePromoter)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgCreatePromoter) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgCreatePromoter_creator, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgCreatePromoter_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgCreatePromoter) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreatePromoter.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.MsgCreatePromoter.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoter does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoter) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreatePromoter.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.MsgCreatePromoter.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoter does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgCreatePromoter) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.MsgCreatePromoter.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgCreatePromoter.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoter does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoter) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreatePromoter.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgCreatePromoter.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoter does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoter) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreatePromoter.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.MsgCreatePromoter is not mutable")) + case "sge.legacy.reward.v1beta.MsgCreatePromoter.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.reward.v1beta.MsgCreatePromoter is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoter does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgCreatePromoter) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreatePromoter.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgCreatePromoter.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoter")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoter does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgCreatePromoter) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgCreatePromoter", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgCreatePromoter) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoter) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgCreatePromoter) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgCreatePromoter) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgCreatePromoter) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgCreatePromoter) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgCreatePromoter) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreatePromoter: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreatePromoter: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgCreatePromoterResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgCreatePromoterResponse = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgCreatePromoterResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgCreatePromoterResponse)(nil) + +type fastReflection_MsgCreatePromoterResponse MsgCreatePromoterResponse + +func (x *MsgCreatePromoterResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgCreatePromoterResponse)(x) +} + +func (x *MsgCreatePromoterResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgCreatePromoterResponse_messageType fastReflection_MsgCreatePromoterResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgCreatePromoterResponse_messageType{} + +type fastReflection_MsgCreatePromoterResponse_messageType struct{} + +func (x fastReflection_MsgCreatePromoterResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgCreatePromoterResponse)(nil) +} +func (x fastReflection_MsgCreatePromoterResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgCreatePromoterResponse) +} +func (x fastReflection_MsgCreatePromoterResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreatePromoterResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgCreatePromoterResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreatePromoterResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgCreatePromoterResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgCreatePromoterResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgCreatePromoterResponse) New() protoreflect.Message { + return new(fastReflection_MsgCreatePromoterResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgCreatePromoterResponse) Interface() protoreflect.ProtoMessage { + return (*MsgCreatePromoterResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgCreatePromoterResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgCreatePromoterResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoterResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoterResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoterResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoterResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoterResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgCreatePromoterResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoterResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoterResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoterResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoterResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoterResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoterResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoterResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoterResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgCreatePromoterResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreatePromoterResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreatePromoterResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgCreatePromoterResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgCreatePromoterResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgCreatePromoterResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreatePromoterResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgCreatePromoterResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgCreatePromoterResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgCreatePromoterResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgCreatePromoterResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgCreatePromoterResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreatePromoterResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreatePromoterResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgSetPromoterConf protoreflect.MessageDescriptor + fd_MsgSetPromoterConf_creator protoreflect.FieldDescriptor + fd_MsgSetPromoterConf_uid protoreflect.FieldDescriptor + fd_MsgSetPromoterConf_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgSetPromoterConf = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgSetPromoterConf") + fd_MsgSetPromoterConf_creator = md_MsgSetPromoterConf.Fields().ByName("creator") + fd_MsgSetPromoterConf_uid = md_MsgSetPromoterConf.Fields().ByName("uid") + fd_MsgSetPromoterConf_ticket = md_MsgSetPromoterConf.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgSetPromoterConf)(nil) + +type fastReflection_MsgSetPromoterConf MsgSetPromoterConf + +func (x *MsgSetPromoterConf) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgSetPromoterConf)(x) +} + +func (x *MsgSetPromoterConf) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgSetPromoterConf_messageType fastReflection_MsgSetPromoterConf_messageType +var _ protoreflect.MessageType = fastReflection_MsgSetPromoterConf_messageType{} + +type fastReflection_MsgSetPromoterConf_messageType struct{} + +func (x fastReflection_MsgSetPromoterConf_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgSetPromoterConf)(nil) +} +func (x fastReflection_MsgSetPromoterConf_messageType) New() protoreflect.Message { + return new(fastReflection_MsgSetPromoterConf) +} +func (x fastReflection_MsgSetPromoterConf_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSetPromoterConf +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgSetPromoterConf) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSetPromoterConf +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgSetPromoterConf) Type() protoreflect.MessageType { + return _fastReflection_MsgSetPromoterConf_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgSetPromoterConf) New() protoreflect.Message { + return new(fastReflection_MsgSetPromoterConf) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgSetPromoterConf) Interface() protoreflect.ProtoMessage { + return (*MsgSetPromoterConf)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgSetPromoterConf) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgSetPromoterConf_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MsgSetPromoterConf_uid, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgSetPromoterConf_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgSetPromoterConf) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConf does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConf) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConf does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgSetPromoterConf) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConf does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConf) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConf does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConf) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.MsgSetPromoterConf is not mutable")) + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.MsgSetPromoterConf is not mutable")) + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.reward.v1beta.MsgSetPromoterConf is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConf does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgSetPromoterConf) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgSetPromoterConf.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConf")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConf does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgSetPromoterConf) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgSetPromoterConf", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgSetPromoterConf) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConf) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgSetPromoterConf) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgSetPromoterConf) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgSetPromoterConf) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgSetPromoterConf) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x1a + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgSetPromoterConf) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSetPromoterConf: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSetPromoterConf: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgSetPromoterConfResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgSetPromoterConfResponse = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgSetPromoterConfResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgSetPromoterConfResponse)(nil) + +type fastReflection_MsgSetPromoterConfResponse MsgSetPromoterConfResponse + +func (x *MsgSetPromoterConfResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgSetPromoterConfResponse)(x) +} + +func (x *MsgSetPromoterConfResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgSetPromoterConfResponse_messageType fastReflection_MsgSetPromoterConfResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgSetPromoterConfResponse_messageType{} + +type fastReflection_MsgSetPromoterConfResponse_messageType struct{} + +func (x fastReflection_MsgSetPromoterConfResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgSetPromoterConfResponse)(nil) +} +func (x fastReflection_MsgSetPromoterConfResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgSetPromoterConfResponse) +} +func (x fastReflection_MsgSetPromoterConfResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSetPromoterConfResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgSetPromoterConfResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgSetPromoterConfResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgSetPromoterConfResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgSetPromoterConfResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgSetPromoterConfResponse) New() protoreflect.Message { + return new(fastReflection_MsgSetPromoterConfResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgSetPromoterConfResponse) Interface() protoreflect.ProtoMessage { + return (*MsgSetPromoterConfResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgSetPromoterConfResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgSetPromoterConfResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConfResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConfResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConfResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConfResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConfResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgSetPromoterConfResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConfResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConfResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConfResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConfResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConfResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConfResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConfResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConfResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgSetPromoterConfResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgSetPromoterConfResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgSetPromoterConfResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgSetPromoterConfResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgSetPromoterConfResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgSetPromoterConfResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgSetPromoterConfResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgSetPromoterConfResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgSetPromoterConfResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgSetPromoterConfResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgSetPromoterConfResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgSetPromoterConfResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSetPromoterConfResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgSetPromoterConfResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgCreateCampaign protoreflect.MessageDescriptor + fd_MsgCreateCampaign_creator protoreflect.FieldDescriptor + fd_MsgCreateCampaign_uid protoreflect.FieldDescriptor + fd_MsgCreateCampaign_total_funds protoreflect.FieldDescriptor + fd_MsgCreateCampaign_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgCreateCampaign = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgCreateCampaign") + fd_MsgCreateCampaign_creator = md_MsgCreateCampaign.Fields().ByName("creator") + fd_MsgCreateCampaign_uid = md_MsgCreateCampaign.Fields().ByName("uid") + fd_MsgCreateCampaign_total_funds = md_MsgCreateCampaign.Fields().ByName("total_funds") + fd_MsgCreateCampaign_ticket = md_MsgCreateCampaign.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgCreateCampaign)(nil) + +type fastReflection_MsgCreateCampaign MsgCreateCampaign + +func (x *MsgCreateCampaign) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgCreateCampaign)(x) +} + +func (x *MsgCreateCampaign) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgCreateCampaign_messageType fastReflection_MsgCreateCampaign_messageType +var _ protoreflect.MessageType = fastReflection_MsgCreateCampaign_messageType{} + +type fastReflection_MsgCreateCampaign_messageType struct{} + +func (x fastReflection_MsgCreateCampaign_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgCreateCampaign)(nil) +} +func (x fastReflection_MsgCreateCampaign_messageType) New() protoreflect.Message { + return new(fastReflection_MsgCreateCampaign) +} +func (x fastReflection_MsgCreateCampaign_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreateCampaign +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgCreateCampaign) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreateCampaign +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgCreateCampaign) Type() protoreflect.MessageType { + return _fastReflection_MsgCreateCampaign_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgCreateCampaign) New() protoreflect.Message { + return new(fastReflection_MsgCreateCampaign) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgCreateCampaign) Interface() protoreflect.ProtoMessage { + return (*MsgCreateCampaign)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgCreateCampaign) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgCreateCampaign_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MsgCreateCampaign_uid, value) { + return + } + } + if x.TotalFunds != "" { + value := protoreflect.ValueOfString(x.TotalFunds) + if !f(fd_MsgCreateCampaign_total_funds, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgCreateCampaign_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgCreateCampaign) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreateCampaign.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.MsgCreateCampaign.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.MsgCreateCampaign.total_funds": + return x.TotalFunds != "" + case "sge.legacy.reward.v1beta.MsgCreateCampaign.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaign does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaign) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreateCampaign.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.MsgCreateCampaign.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.MsgCreateCampaign.total_funds": + x.TotalFunds = "" + case "sge.legacy.reward.v1beta.MsgCreateCampaign.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaign does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgCreateCampaign) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.MsgCreateCampaign.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.total_funds": + value := x.TotalFunds + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaign does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaign) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreateCampaign.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.total_funds": + x.TotalFunds = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaign does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaign) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreateCampaign.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.MsgCreateCampaign is not mutable")) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.MsgCreateCampaign is not mutable")) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.total_funds": + panic(fmt.Errorf("field total_funds of message sge.legacy.reward.v1beta.MsgCreateCampaign is not mutable")) + case "sge.legacy.reward.v1beta.MsgCreateCampaign.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.reward.v1beta.MsgCreateCampaign is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaign does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgCreateCampaign) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgCreateCampaign.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgCreateCampaign.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgCreateCampaign.total_funds": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgCreateCampaign.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaign does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgCreateCampaign) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgCreateCampaign", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgCreateCampaign) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaign) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgCreateCampaign) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgCreateCampaign) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgCreateCampaign) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.TotalFunds) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgCreateCampaign) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x22 + } + if len(x.TotalFunds) > 0 { + i -= len(x.TotalFunds) + copy(dAtA[i:], x.TotalFunds) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.TotalFunds))) + i-- + dAtA[i] = 0x1a + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgCreateCampaign) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreateCampaign: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreateCampaign: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TotalFunds", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.TotalFunds = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgCreateCampaignResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgCreateCampaignResponse = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgCreateCampaignResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgCreateCampaignResponse)(nil) + +type fastReflection_MsgCreateCampaignResponse MsgCreateCampaignResponse + +func (x *MsgCreateCampaignResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgCreateCampaignResponse)(x) +} + +func (x *MsgCreateCampaignResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgCreateCampaignResponse_messageType fastReflection_MsgCreateCampaignResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgCreateCampaignResponse_messageType{} + +type fastReflection_MsgCreateCampaignResponse_messageType struct{} + +func (x fastReflection_MsgCreateCampaignResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgCreateCampaignResponse)(nil) +} +func (x fastReflection_MsgCreateCampaignResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgCreateCampaignResponse) +} +func (x fastReflection_MsgCreateCampaignResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreateCampaignResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgCreateCampaignResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreateCampaignResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgCreateCampaignResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgCreateCampaignResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgCreateCampaignResponse) New() protoreflect.Message { + return new(fastReflection_MsgCreateCampaignResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgCreateCampaignResponse) Interface() protoreflect.ProtoMessage { + return (*MsgCreateCampaignResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgCreateCampaignResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgCreateCampaignResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaignResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgCreateCampaignResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaignResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaignResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaignResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgCreateCampaignResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgCreateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgCreateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgCreateCampaignResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgCreateCampaignResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgCreateCampaignResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateCampaignResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgCreateCampaignResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgCreateCampaignResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgCreateCampaignResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgCreateCampaignResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgCreateCampaignResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreateCampaignResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreateCampaignResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateCampaign protoreflect.MessageDescriptor + fd_MsgUpdateCampaign_creator protoreflect.FieldDescriptor + fd_MsgUpdateCampaign_uid protoreflect.FieldDescriptor + fd_MsgUpdateCampaign_topup_funds protoreflect.FieldDescriptor + fd_MsgUpdateCampaign_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgUpdateCampaign = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgUpdateCampaign") + fd_MsgUpdateCampaign_creator = md_MsgUpdateCampaign.Fields().ByName("creator") + fd_MsgUpdateCampaign_uid = md_MsgUpdateCampaign.Fields().ByName("uid") + fd_MsgUpdateCampaign_topup_funds = md_MsgUpdateCampaign.Fields().ByName("topup_funds") + fd_MsgUpdateCampaign_ticket = md_MsgUpdateCampaign.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateCampaign)(nil) + +type fastReflection_MsgUpdateCampaign MsgUpdateCampaign + +func (x *MsgUpdateCampaign) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateCampaign)(x) +} + +func (x *MsgUpdateCampaign) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateCampaign_messageType fastReflection_MsgUpdateCampaign_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateCampaign_messageType{} + +type fastReflection_MsgUpdateCampaign_messageType struct{} + +func (x fastReflection_MsgUpdateCampaign_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateCampaign)(nil) +} +func (x fastReflection_MsgUpdateCampaign_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateCampaign) +} +func (x fastReflection_MsgUpdateCampaign_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateCampaign +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateCampaign) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateCampaign +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateCampaign) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateCampaign_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateCampaign) New() protoreflect.Message { + return new(fastReflection_MsgUpdateCampaign) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateCampaign) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateCampaign)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateCampaign) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgUpdateCampaign_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MsgUpdateCampaign_uid, value) { + return + } + } + if x.TopupFunds != "" { + value := protoreflect.ValueOfString(x.TopupFunds) + if !f(fd_MsgUpdateCampaign_topup_funds, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgUpdateCampaign_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateCampaign) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.topup_funds": + return x.TopupFunds != "" + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaign does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaign) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.topup_funds": + x.TopupFunds = "" + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaign does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateCampaign) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.topup_funds": + value := x.TopupFunds + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaign does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaign) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.topup_funds": + x.TopupFunds = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaign does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaign) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.MsgUpdateCampaign is not mutable")) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.MsgUpdateCampaign is not mutable")) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.topup_funds": + panic(fmt.Errorf("field topup_funds of message sge.legacy.reward.v1beta.MsgUpdateCampaign is not mutable")) + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.reward.v1beta.MsgUpdateCampaign is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaign does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateCampaign) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.topup_funds": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgUpdateCampaign.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaign")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaign does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateCampaign) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgUpdateCampaign", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateCampaign) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaign) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateCampaign) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateCampaign) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateCampaign) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.TopupFunds) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateCampaign) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x22 + } + if len(x.TopupFunds) > 0 { + i -= len(x.TopupFunds) + copy(dAtA[i:], x.TopupFunds) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.TopupFunds))) + i-- + dAtA[i] = 0x1a + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateCampaign) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateCampaign: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateCampaign: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TopupFunds", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.TopupFunds = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateCampaignResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgUpdateCampaignResponse = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgUpdateCampaignResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateCampaignResponse)(nil) + +type fastReflection_MsgUpdateCampaignResponse MsgUpdateCampaignResponse + +func (x *MsgUpdateCampaignResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateCampaignResponse)(x) +} + +func (x *MsgUpdateCampaignResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateCampaignResponse_messageType fastReflection_MsgUpdateCampaignResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateCampaignResponse_messageType{} + +type fastReflection_MsgUpdateCampaignResponse_messageType struct{} + +func (x fastReflection_MsgUpdateCampaignResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateCampaignResponse)(nil) +} +func (x fastReflection_MsgUpdateCampaignResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateCampaignResponse) +} +func (x fastReflection_MsgUpdateCampaignResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateCampaignResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateCampaignResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateCampaignResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateCampaignResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateCampaignResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateCampaignResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateCampaignResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateCampaignResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateCampaignResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateCampaignResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateCampaignResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaignResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateCampaignResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaignResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaignResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaignResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateCampaignResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateCampaignResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateCampaignResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateCampaignResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgUpdateCampaignResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateCampaignResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateCampaignResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateCampaignResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateCampaignResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateCampaignResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateCampaignResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateCampaignResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateCampaignResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateCampaignResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgGrantReward protoreflect.MessageDescriptor + fd_MsgGrantReward_creator protoreflect.FieldDescriptor + fd_MsgGrantReward_uid protoreflect.FieldDescriptor + fd_MsgGrantReward_campaign_uid protoreflect.FieldDescriptor + fd_MsgGrantReward_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgGrantReward = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgGrantReward") + fd_MsgGrantReward_creator = md_MsgGrantReward.Fields().ByName("creator") + fd_MsgGrantReward_uid = md_MsgGrantReward.Fields().ByName("uid") + fd_MsgGrantReward_campaign_uid = md_MsgGrantReward.Fields().ByName("campaign_uid") + fd_MsgGrantReward_ticket = md_MsgGrantReward.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgGrantReward)(nil) + +type fastReflection_MsgGrantReward MsgGrantReward + +func (x *MsgGrantReward) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgGrantReward)(x) +} + +func (x *MsgGrantReward) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgGrantReward_messageType fastReflection_MsgGrantReward_messageType +var _ protoreflect.MessageType = fastReflection_MsgGrantReward_messageType{} + +type fastReflection_MsgGrantReward_messageType struct{} + +func (x fastReflection_MsgGrantReward_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgGrantReward)(nil) +} +func (x fastReflection_MsgGrantReward_messageType) New() protoreflect.Message { + return new(fastReflection_MsgGrantReward) +} +func (x fastReflection_MsgGrantReward_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgGrantReward +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgGrantReward) Descriptor() protoreflect.MessageDescriptor { + return md_MsgGrantReward +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgGrantReward) Type() protoreflect.MessageType { + return _fastReflection_MsgGrantReward_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgGrantReward) New() protoreflect.Message { + return new(fastReflection_MsgGrantReward) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgGrantReward) Interface() protoreflect.ProtoMessage { + return (*MsgGrantReward)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgGrantReward) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgGrantReward_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MsgGrantReward_uid, value) { + return + } + } + if x.CampaignUid != "" { + value := protoreflect.ValueOfString(x.CampaignUid) + if !f(fd_MsgGrantReward_campaign_uid, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgGrantReward_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgGrantReward) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgGrantReward.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.MsgGrantReward.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.MsgGrantReward.campaign_uid": + return x.CampaignUid != "" + case "sge.legacy.reward.v1beta.MsgGrantReward.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantReward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantReward does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantReward) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgGrantReward.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.MsgGrantReward.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.MsgGrantReward.campaign_uid": + x.CampaignUid = "" + case "sge.legacy.reward.v1beta.MsgGrantReward.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantReward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantReward does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgGrantReward) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.MsgGrantReward.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgGrantReward.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgGrantReward.campaign_uid": + value := x.CampaignUid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgGrantReward.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantReward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantReward does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantReward) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgGrantReward.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgGrantReward.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgGrantReward.campaign_uid": + x.CampaignUid = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgGrantReward.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantReward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantReward does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantReward) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgGrantReward.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.MsgGrantReward is not mutable")) + case "sge.legacy.reward.v1beta.MsgGrantReward.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.MsgGrantReward is not mutable")) + case "sge.legacy.reward.v1beta.MsgGrantReward.campaign_uid": + panic(fmt.Errorf("field campaign_uid of message sge.legacy.reward.v1beta.MsgGrantReward is not mutable")) + case "sge.legacy.reward.v1beta.MsgGrantReward.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.reward.v1beta.MsgGrantReward is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantReward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantReward does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgGrantReward) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgGrantReward.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgGrantReward.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgGrantReward.campaign_uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgGrantReward.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantReward")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantReward does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgGrantReward) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgGrantReward", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgGrantReward) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantReward) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgGrantReward) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgGrantReward) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgGrantReward) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.CampaignUid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgGrantReward) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x22 + } + if len(x.CampaignUid) > 0 { + i -= len(x.CampaignUid) + copy(dAtA[i:], x.CampaignUid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.CampaignUid))) + i-- + dAtA[i] = 0x1a + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgGrantReward) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgGrantReward: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgGrantReward: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field CampaignUid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.CampaignUid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgGrantRewardResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgGrantRewardResponse = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgGrantRewardResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgGrantRewardResponse)(nil) + +type fastReflection_MsgGrantRewardResponse MsgGrantRewardResponse + +func (x *MsgGrantRewardResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgGrantRewardResponse)(x) +} + +func (x *MsgGrantRewardResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgGrantRewardResponse_messageType fastReflection_MsgGrantRewardResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgGrantRewardResponse_messageType{} + +type fastReflection_MsgGrantRewardResponse_messageType struct{} + +func (x fastReflection_MsgGrantRewardResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgGrantRewardResponse)(nil) +} +func (x fastReflection_MsgGrantRewardResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgGrantRewardResponse) +} +func (x fastReflection_MsgGrantRewardResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgGrantRewardResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgGrantRewardResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgGrantRewardResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgGrantRewardResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgGrantRewardResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgGrantRewardResponse) New() protoreflect.Message { + return new(fastReflection_MsgGrantRewardResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgGrantRewardResponse) Interface() protoreflect.ProtoMessage { + return (*MsgGrantRewardResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgGrantRewardResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgGrantRewardResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantRewardResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantRewardResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantRewardResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgGrantRewardResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantRewardResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantRewardResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantRewardResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantRewardResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantRewardResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgGrantRewardResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgGrantRewardResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgGrantRewardResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgGrantRewardResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgGrantRewardResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgGrantRewardResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgGrantRewardResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgGrantRewardResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgGrantRewardResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgGrantRewardResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgGrantRewardResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgGrantRewardResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgGrantRewardResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgGrantRewardResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdrawFunds protoreflect.MessageDescriptor + fd_MsgWithdrawFunds_creator protoreflect.FieldDescriptor + fd_MsgWithdrawFunds_uid protoreflect.FieldDescriptor + fd_MsgWithdrawFunds_ticket protoreflect.FieldDescriptor + fd_MsgWithdrawFunds_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgWithdrawFunds = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgWithdrawFunds") + fd_MsgWithdrawFunds_creator = md_MsgWithdrawFunds.Fields().ByName("creator") + fd_MsgWithdrawFunds_uid = md_MsgWithdrawFunds.Fields().ByName("uid") + fd_MsgWithdrawFunds_ticket = md_MsgWithdrawFunds.Fields().ByName("ticket") + fd_MsgWithdrawFunds_amount = md_MsgWithdrawFunds.Fields().ByName("amount") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdrawFunds)(nil) + +type fastReflection_MsgWithdrawFunds MsgWithdrawFunds + +func (x *MsgWithdrawFunds) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdrawFunds)(x) +} + +func (x *MsgWithdrawFunds) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdrawFunds_messageType fastReflection_MsgWithdrawFunds_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdrawFunds_messageType{} + +type fastReflection_MsgWithdrawFunds_messageType struct{} + +func (x fastReflection_MsgWithdrawFunds_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdrawFunds)(nil) +} +func (x fastReflection_MsgWithdrawFunds_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawFunds) +} +func (x fastReflection_MsgWithdrawFunds_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawFunds +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdrawFunds) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawFunds +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdrawFunds) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdrawFunds_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdrawFunds) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawFunds) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdrawFunds) Interface() protoreflect.ProtoMessage { + return (*MsgWithdrawFunds)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdrawFunds) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgWithdrawFunds_creator, value) { + return + } + } + if x.Uid != "" { + value := protoreflect.ValueOfString(x.Uid) + if !f(fd_MsgWithdrawFunds_uid, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgWithdrawFunds_ticket, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_MsgWithdrawFunds_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdrawFunds) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.creator": + return x.Creator != "" + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.uid": + return x.Uid != "" + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.ticket": + return x.Ticket != "" + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.amount": + return x.Amount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFunds")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFunds does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFunds) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.creator": + x.Creator = "" + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.uid": + x.Uid = "" + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.ticket": + x.Ticket = "" + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.amount": + x.Amount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFunds")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFunds does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdrawFunds) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.uid": + value := x.Uid + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFunds")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFunds does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFunds) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.uid": + x.Uid = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.ticket": + x.Ticket = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.amount": + x.Amount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFunds")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFunds does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFunds) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.creator": + panic(fmt.Errorf("field creator of message sge.legacy.reward.v1beta.MsgWithdrawFunds is not mutable")) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.uid": + panic(fmt.Errorf("field uid of message sge.legacy.reward.v1beta.MsgWithdrawFunds is not mutable")) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.reward.v1beta.MsgWithdrawFunds is not mutable")) + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.amount": + panic(fmt.Errorf("field amount of message sge.legacy.reward.v1beta.MsgWithdrawFunds is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFunds")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFunds does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdrawFunds) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.uid": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.ticket": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgWithdrawFunds.amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFunds")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFunds does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdrawFunds) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgWithdrawFunds", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdrawFunds) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFunds) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdrawFunds) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdrawFunds) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdrawFunds) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Uid) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawFunds) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x22 + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x1a + } + if len(x.Uid) > 0 { + i -= len(x.Uid) + copy(dAtA[i:], x.Uid) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Uid))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawFunds) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawFunds: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawFunds: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Uid", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Uid = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdrawFundsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgWithdrawFundsResponse = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgWithdrawFundsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdrawFundsResponse)(nil) + +type fastReflection_MsgWithdrawFundsResponse MsgWithdrawFundsResponse + +func (x *MsgWithdrawFundsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdrawFundsResponse)(x) +} + +func (x *MsgWithdrawFundsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdrawFundsResponse_messageType fastReflection_MsgWithdrawFundsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdrawFundsResponse_messageType{} + +type fastReflection_MsgWithdrawFundsResponse_messageType struct{} + +func (x fastReflection_MsgWithdrawFundsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdrawFundsResponse)(nil) +} +func (x fastReflection_MsgWithdrawFundsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawFundsResponse) +} +func (x fastReflection_MsgWithdrawFundsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawFundsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdrawFundsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawFundsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdrawFundsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdrawFundsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdrawFundsResponse) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawFundsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdrawFundsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgWithdrawFundsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdrawFundsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdrawFundsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFundsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFundsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFundsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFundsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFundsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdrawFundsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFundsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFundsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFundsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFundsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFundsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFundsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFundsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFundsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdrawFundsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgWithdrawFundsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgWithdrawFundsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdrawFundsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgWithdrawFundsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdrawFundsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawFundsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdrawFundsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdrawFundsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdrawFundsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawFundsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawFundsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawFundsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawFundsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.legacy.reward.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.legacy.reward.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.legacy.reward.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.legacy.reward.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.reward.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.legacy.reward.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.reward.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.legacy.reward.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_reward_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_legacy_reward_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.reward.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.reward.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.reward.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/reward/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgCreatePromoter is msg to create a promoter. +type MsgCreatePromoter struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of message signer account. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // ticket is the payload data. + Ticket string `protobuf:"bytes,2,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgCreatePromoter) Reset() { + *x = MsgCreatePromoter{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgCreatePromoter) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgCreatePromoter) ProtoMessage() {} + +// Deprecated: Use MsgCreatePromoter.ProtoReflect.Descriptor instead. +func (*MsgCreatePromoter) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgCreatePromoter) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgCreatePromoter) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgCreatePromoterResponse promoter create message response type. +type MsgCreatePromoterResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgCreatePromoterResponse) Reset() { + *x = MsgCreatePromoterResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgCreatePromoterResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgCreatePromoterResponse) ProtoMessage() {} + +// Deprecated: Use MsgCreatePromoterResponse.ProtoReflect.Descriptor instead. +func (*MsgCreatePromoterResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +// MsgSetPromoterConf is msg to set promoter configuration. +type MsgSetPromoterConf struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of message signer account. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // uid is the unique identifier of the promoter. + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` + // ticket is the payload data. + Ticket string `protobuf:"bytes,3,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgSetPromoterConf) Reset() { + *x = MsgSetPromoterConf{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgSetPromoterConf) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgSetPromoterConf) ProtoMessage() {} + +// Deprecated: Use MsgSetPromoterConf.ProtoReflect.Descriptor instead. +func (*MsgSetPromoterConf) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{2} +} + +func (x *MsgSetPromoterConf) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgSetPromoterConf) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MsgSetPromoterConf) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgCreateCampaignResponse campaign create message response type. +type MsgSetPromoterConfResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgSetPromoterConfResponse) Reset() { + *x = MsgSetPromoterConfResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgSetPromoterConfResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgSetPromoterConfResponse) ProtoMessage() {} + +// Deprecated: Use MsgSetPromoterConfResponse.ProtoReflect.Descriptor instead. +func (*MsgSetPromoterConfResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{3} +} + +// MsgCreateCampaign is msg to create a reward campaign +type MsgCreateCampaign struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of campaign creator account. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // uid is the unique identifier of the campaign. + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` + // total_funds is the total funds allocated to the campaign. + TotalFunds string `protobuf:"bytes,3,opt,name=total_funds,json=totalFunds,proto3" json:"total_funds,omitempty"` + // ticket is the payload data. + Ticket string `protobuf:"bytes,4,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgCreateCampaign) Reset() { + *x = MsgCreateCampaign{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgCreateCampaign) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgCreateCampaign) ProtoMessage() {} + +// Deprecated: Use MsgCreateCampaign.ProtoReflect.Descriptor instead. +func (*MsgCreateCampaign) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{4} +} + +func (x *MsgCreateCampaign) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgCreateCampaign) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MsgCreateCampaign) GetTotalFunds() string { + if x != nil { + return x.TotalFunds + } + return "" +} + +func (x *MsgCreateCampaign) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgCreateCampaignResponse campaign create message response type. +type MsgCreateCampaignResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgCreateCampaignResponse) Reset() { + *x = MsgCreateCampaignResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgCreateCampaignResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgCreateCampaignResponse) ProtoMessage() {} + +// Deprecated: Use MsgCreateCampaignResponse.ProtoReflect.Descriptor instead. +func (*MsgCreateCampaignResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{5} +} + +// MsgUpdateCampaign is campaign update message type. +type MsgUpdateCampaign struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of creator account. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // uid is the unique identifier of the campaign. + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` + // topup_funds is the topup funds to increase the pool balance of the + // campaign. + TopupFunds string `protobuf:"bytes,3,opt,name=topup_funds,json=topupFunds,proto3" json:"topup_funds,omitempty"` + // ticket is the payload data. + Ticket string `protobuf:"bytes,4,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgUpdateCampaign) Reset() { + *x = MsgUpdateCampaign{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateCampaign) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateCampaign) ProtoMessage() {} + +// Deprecated: Use MsgUpdateCampaign.ProtoReflect.Descriptor instead. +func (*MsgUpdateCampaign) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{6} +} + +func (x *MsgUpdateCampaign) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgUpdateCampaign) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MsgUpdateCampaign) GetTopupFunds() string { + if x != nil { + return x.TopupFunds + } + return "" +} + +func (x *MsgUpdateCampaign) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgUpdateCampaignResponse campaign update message response type. +type MsgUpdateCampaignResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateCampaignResponse) Reset() { + *x = MsgUpdateCampaignResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateCampaignResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateCampaignResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateCampaignResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateCampaignResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{7} +} + +// MsgGrantReward is execute reward message type. +type MsgGrantReward struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of creator account. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // uid is the unique identifier of the reward. + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` + // campaign_uid is the unique identifier of the reward campaign. + CampaignUid string `protobuf:"bytes,3,opt,name=campaign_uid,json=campaignUid,proto3" json:"campaign_uid,omitempty"` + // ticket is the payload data. + Ticket string `protobuf:"bytes,4,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgGrantReward) Reset() { + *x = MsgGrantReward{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgGrantReward) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgGrantReward) ProtoMessage() {} + +// Deprecated: Use MsgGrantReward.ProtoReflect.Descriptor instead. +func (*MsgGrantReward) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{8} +} + +func (x *MsgGrantReward) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgGrantReward) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MsgGrantReward) GetCampaignUid() string { + if x != nil { + return x.CampaignUid + } + return "" +} + +func (x *MsgGrantReward) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgGrantSignupRewardResponse execute signup reward message response type. +type MsgGrantRewardResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgGrantRewardResponse) Reset() { + *x = MsgGrantRewardResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgGrantRewardResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgGrantRewardResponse) ProtoMessage() {} + +// Deprecated: Use MsgGrantRewardResponse.ProtoReflect.Descriptor instead. +func (*MsgGrantRewardResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{9} +} + +// MsgWithdrawFunds is withdraw funds message type. +type MsgWithdrawFunds struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the address of creator account. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // uid is the unique identifier of the reward campaign. + Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` + // ticket is the payload data. + Ticket string `protobuf:"bytes,3,opt,name=ticket,proto3" json:"ticket,omitempty"` + // amount is the requested withdrawal amount + Amount string `protobuf:"bytes,4,opt,name=amount,proto3" json:"amount,omitempty"` +} + +func (x *MsgWithdrawFunds) Reset() { + *x = MsgWithdrawFunds{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdrawFunds) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdrawFunds) ProtoMessage() {} + +// Deprecated: Use MsgWithdrawFunds.ProtoReflect.Descriptor instead. +func (*MsgWithdrawFunds) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{10} +} + +func (x *MsgWithdrawFunds) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgWithdrawFunds) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *MsgWithdrawFunds) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +func (x *MsgWithdrawFunds) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +// MsgWithdrawFundsResponse withdraw funds message response type. +type MsgWithdrawFundsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgWithdrawFundsResponse) Reset() { + *x = MsgWithdrawFundsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdrawFundsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdrawFundsResponse) ProtoMessage() {} + +// Deprecated: Use MsgWithdrawFundsResponse.ProtoReflect.Descriptor instead. +func (*MsgWithdrawFundsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{11} +} + +// MsgUpdateParams is the Msg/UpdateParams request type. +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/bet parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{12} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_reward_v1beta_tx_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP(), []int{13} +} + +var File_sge_legacy_reward_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_legacy_reward_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x21, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, + 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, + 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, + 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25, 0x73, 0x67, 0x65, 0x2f, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x22, 0x6d, 0x0a, 0x11, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, + 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, + 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, + 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, + 0x63, 0x6b, 0x65, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, + 0x65, 0x74, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, + 0x22, 0x1b, 0x0a, 0x19, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, + 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x80, 0x01, + 0x0a, 0x12, 0x4d, 0x73, 0x67, 0x53, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, + 0x43, 0x6f, 0x6e, 0x66, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, + 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, + 0x63, 0x6b, 0x65, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, + 0x65, 0x74, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, + 0x22, 0x1c, 0x0a, 0x1a, 0x4d, 0x73, 0x67, 0x53, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, + 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xd5, + 0x01, 0x0a, 0x11, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, + 0x61, 0x69, 0x67, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, + 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x54, 0x0a, 0x0b, 0x74, 0x6f, + 0x74, 0x61, 0x6c, 0x5f, 0x66, 0x75, 0x6e, 0x64, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x33, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, + 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, + 0x1f, 0x12, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x66, 0x75, + 0x6e, 0x64, 0x73, 0x22, 0x52, 0x0a, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x46, 0x75, 0x6e, 0x64, 0x73, + 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x1b, 0x0a, 0x19, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0xd5, 0x01, 0x0a, 0x11, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, + 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x10, 0x0a, + 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, + 0x54, 0x0a, 0x0b, 0x74, 0x6f, 0x70, 0x75, 0x70, 0x5f, 0x66, 0x75, 0x6e, 0x64, 0x73, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x42, 0x33, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, + 0x49, 0x6e, 0x74, 0xf2, 0xde, 0x1f, 0x12, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x74, 0x6f, 0x70, + 0x75, 0x70, 0x5f, 0x66, 0x75, 0x6e, 0x64, 0x73, 0x22, 0x52, 0x0a, 0x74, 0x6f, 0x70, 0x75, 0x70, + 0x46, 0x75, 0x6e, 0x64, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, 0x0c, 0x82, + 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x1b, 0x0a, 0x19, 0x4d, + 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x9f, 0x01, 0x0a, 0x0e, 0x4d, 0x73, 0x67, + 0x47, 0x72, 0x61, 0x6e, 0x74, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x12, 0x32, 0x0a, 0x07, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, + 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, + 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, + 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x5f, 0x75, 0x69, + 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, + 0x6e, 0x55, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, 0x0c, 0x82, 0xe7, + 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x18, 0x0a, 0x16, 0x4d, 0x73, + 0x67, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xb5, 0x01, 0x0a, 0x10, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x46, 0x75, 0x6e, 0x64, 0x73, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, + 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x10, 0x0a, + 0x03, 0x75, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, + 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x35, 0x0a, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, + 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, + 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, + 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x0c, + 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x1a, 0x0a, 0x18, + 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x46, 0x75, 0x6e, 0x64, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xb3, 0x01, 0x0a, 0x0f, 0x4d, 0x73, 0x67, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, 0x0a, 0x09, + 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, + 0x72, 0x69, 0x74, 0x79, 0x12, 0x43, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, + 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x3a, 0x23, 0xd2, 0xb4, 0x2d, 0x11, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, + 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, 0x30, + 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x3a, 0x15, 0xd2, 0xb4, 0x2d, 0x11, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, + 0x32, 0xdb, 0x06, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x7a, 0x0a, 0x0f, 0x53, 0x65, 0x74, 0x50, + 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x12, 0x2c, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x65, 0x74, 0x50, 0x72, 0x6f, + 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x1a, 0x34, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6d, 0x6f, + 0x74, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x03, 0x88, 0x02, 0x01, 0x12, 0x77, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, + 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, 0x12, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6d, 0x6f, + 0x74, 0x65, 0x72, 0x1a, 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, + 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6d, 0x6f, 0x74, 0x65, 0x72, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x77, 0x0a, + 0x0e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x12, + 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, + 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x1a, 0x33, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x77, 0x0a, 0x0e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, 0x67, 0x6e, 0x12, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, + 0x70, 0x61, 0x69, 0x67, 0x6e, 0x1a, 0x33, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x6d, 0x70, 0x61, 0x69, + 0x67, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, + 0x74, 0x0a, 0x0d, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x46, 0x75, 0x6e, 0x64, 0x73, + 0x12, 0x2a, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, + 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x46, 0x75, 0x6e, 0x64, 0x73, 0x1a, 0x32, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, + 0x72, 0x61, 0x77, 0x46, 0x75, 0x6e, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x6e, 0x0a, 0x0b, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x52, 0x65, + 0x77, 0x61, 0x72, 0x64, 0x12, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x4d, 0x73, 0x67, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x1a, 0x30, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, + 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x47, 0x72, 0x61, + 0x6e, 0x74, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x86, 0x01, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x29, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x1a, 0x31, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x72, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x18, 0xca, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, + 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x88, 0x02, 0x01, 0x42, 0xf0, + 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, + 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x3b, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x52, 0xaa, 0x02, 0x18, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xca, 0x02, 0x18, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, + 0x65, 0x77, 0x61, 0x72, 0x64, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x24, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x3a, 0x3a, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_reward_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_legacy_reward_v1beta_tx_proto_rawDescData = file_sge_legacy_reward_v1beta_tx_proto_rawDesc +) + +func file_sge_legacy_reward_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_legacy_reward_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_legacy_reward_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_reward_v1beta_tx_proto_rawDescData) + }) + return file_sge_legacy_reward_v1beta_tx_proto_rawDescData +} + +var file_sge_legacy_reward_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 14) +var file_sge_legacy_reward_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgCreatePromoter)(nil), // 0: sge.legacy.reward.v1beta.MsgCreatePromoter + (*MsgCreatePromoterResponse)(nil), // 1: sge.legacy.reward.v1beta.MsgCreatePromoterResponse + (*MsgSetPromoterConf)(nil), // 2: sge.legacy.reward.v1beta.MsgSetPromoterConf + (*MsgSetPromoterConfResponse)(nil), // 3: sge.legacy.reward.v1beta.MsgSetPromoterConfResponse + (*MsgCreateCampaign)(nil), // 4: sge.legacy.reward.v1beta.MsgCreateCampaign + (*MsgCreateCampaignResponse)(nil), // 5: sge.legacy.reward.v1beta.MsgCreateCampaignResponse + (*MsgUpdateCampaign)(nil), // 6: sge.legacy.reward.v1beta.MsgUpdateCampaign + (*MsgUpdateCampaignResponse)(nil), // 7: sge.legacy.reward.v1beta.MsgUpdateCampaignResponse + (*MsgGrantReward)(nil), // 8: sge.legacy.reward.v1beta.MsgGrantReward + (*MsgGrantRewardResponse)(nil), // 9: sge.legacy.reward.v1beta.MsgGrantRewardResponse + (*MsgWithdrawFunds)(nil), // 10: sge.legacy.reward.v1beta.MsgWithdrawFunds + (*MsgWithdrawFundsResponse)(nil), // 11: sge.legacy.reward.v1beta.MsgWithdrawFundsResponse + (*MsgUpdateParams)(nil), // 12: sge.legacy.reward.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 13: sge.legacy.reward.v1beta.MsgUpdateParamsResponse + (*Params)(nil), // 14: sge.legacy.reward.v1beta.Params +} +var file_sge_legacy_reward_v1beta_tx_proto_depIdxs = []int32{ + 14, // 0: sge.legacy.reward.v1beta.MsgUpdateParams.params:type_name -> sge.legacy.reward.v1beta.Params + 2, // 1: sge.legacy.reward.v1beta.Msg.SetPromoterConf:input_type -> sge.legacy.reward.v1beta.MsgSetPromoterConf + 0, // 2: sge.legacy.reward.v1beta.Msg.CreatePromoter:input_type -> sge.legacy.reward.v1beta.MsgCreatePromoter + 4, // 3: sge.legacy.reward.v1beta.Msg.CreateCampaign:input_type -> sge.legacy.reward.v1beta.MsgCreateCampaign + 6, // 4: sge.legacy.reward.v1beta.Msg.UpdateCampaign:input_type -> sge.legacy.reward.v1beta.MsgUpdateCampaign + 10, // 5: sge.legacy.reward.v1beta.Msg.WithdrawFunds:input_type -> sge.legacy.reward.v1beta.MsgWithdrawFunds + 8, // 6: sge.legacy.reward.v1beta.Msg.GrantReward:input_type -> sge.legacy.reward.v1beta.MsgGrantReward + 12, // 7: sge.legacy.reward.v1beta.Msg.UpdateParams:input_type -> sge.legacy.reward.v1beta.MsgUpdateParams + 3, // 8: sge.legacy.reward.v1beta.Msg.SetPromoterConf:output_type -> sge.legacy.reward.v1beta.MsgSetPromoterConfResponse + 1, // 9: sge.legacy.reward.v1beta.Msg.CreatePromoter:output_type -> sge.legacy.reward.v1beta.MsgCreatePromoterResponse + 5, // 10: sge.legacy.reward.v1beta.Msg.CreateCampaign:output_type -> sge.legacy.reward.v1beta.MsgCreateCampaignResponse + 7, // 11: sge.legacy.reward.v1beta.Msg.UpdateCampaign:output_type -> sge.legacy.reward.v1beta.MsgUpdateCampaignResponse + 11, // 12: sge.legacy.reward.v1beta.Msg.WithdrawFunds:output_type -> sge.legacy.reward.v1beta.MsgWithdrawFundsResponse + 9, // 13: sge.legacy.reward.v1beta.Msg.GrantReward:output_type -> sge.legacy.reward.v1beta.MsgGrantRewardResponse + 13, // 14: sge.legacy.reward.v1beta.Msg.UpdateParams:output_type -> sge.legacy.reward.v1beta.MsgUpdateParamsResponse + 8, // [8:15] is the sub-list for method output_type + 1, // [1:8] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_reward_v1beta_tx_proto_init() } +func file_sge_legacy_reward_v1beta_tx_proto_init() { + if File_sge_legacy_reward_v1beta_tx_proto != nil { + return + } + file_sge_legacy_reward_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgCreatePromoter); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgCreatePromoterResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgSetPromoterConf); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgSetPromoterConfResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgCreateCampaign); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgCreateCampaignResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateCampaign); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateCampaignResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgGrantReward); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgGrantRewardResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdrawFunds); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdrawFundsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_reward_v1beta_tx_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_reward_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 14, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_reward_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_legacy_reward_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_legacy_reward_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_legacy_reward_v1beta_tx_proto = out.File + file_sge_legacy_reward_v1beta_tx_proto_rawDesc = nil + file_sge_legacy_reward_v1beta_tx_proto_goTypes = nil + file_sge_legacy_reward_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/legacy/reward/v1beta/tx_grpc.pb.go b/api/sge/legacy/reward/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..6f7f598c --- /dev/null +++ b/api/sge/legacy/reward/v1beta/tx_grpc.pb.go @@ -0,0 +1,368 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/reward/v1beta/tx.proto + +package rewardv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_SetPromoterConf_FullMethodName = "/sge.legacy.reward.v1beta.Msg/SetPromoterConf" + Msg_CreatePromoter_FullMethodName = "/sge.legacy.reward.v1beta.Msg/CreatePromoter" + Msg_CreateCampaign_FullMethodName = "/sge.legacy.reward.v1beta.Msg/CreateCampaign" + Msg_UpdateCampaign_FullMethodName = "/sge.legacy.reward.v1beta.Msg/UpdateCampaign" + Msg_WithdrawFunds_FullMethodName = "/sge.legacy.reward.v1beta.Msg/WithdrawFunds" + Msg_GrantReward_FullMethodName = "/sge.legacy.reward.v1beta.Msg/GrantReward" + Msg_UpdateParams_FullMethodName = "/sge.legacy.reward.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // Deprecated: Do not use. + // SetPromoterConf is a method to set the configurations of a promoter. + SetPromoterConf(ctx context.Context, in *MsgSetPromoterConf, opts ...grpc.CallOption) (*MsgSetPromoterConfResponse, error) + // Deprecated: Do not use. + // CreatePromoter is a method to create a promoter + CreatePromoter(ctx context.Context, in *MsgCreatePromoter, opts ...grpc.CallOption) (*MsgCreatePromoterResponse, error) + // Deprecated: Do not use. + // CreateCampaign is a method to create a campaign + CreateCampaign(ctx context.Context, in *MsgCreateCampaign, opts ...grpc.CallOption) (*MsgCreateCampaignResponse, error) + // Deprecated: Do not use. + // UpdateCampaign is a method to update campaign + UpdateCampaign(ctx context.Context, in *MsgUpdateCampaign, opts ...grpc.CallOption) (*MsgUpdateCampaignResponse, error) + // Deprecated: Do not use. + // WithdrawCampaignFunds is method to withdraw funds from the campaign + WithdrawFunds(ctx context.Context, in *MsgWithdrawFunds, opts ...grpc.CallOption) (*MsgWithdrawFundsResponse, error) + // Deprecated: Do not use. + // GrantReward is method to allocate rewards + GrantReward(ctx context.Context, in *MsgGrantReward, opts ...grpc.CallOption) (*MsgGrantRewardResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/ovm module + // parameters. The authority is defined in the keeper. + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +// Deprecated: Do not use. +func (c *msgClient) SetPromoterConf(ctx context.Context, in *MsgSetPromoterConf, opts ...grpc.CallOption) (*MsgSetPromoterConfResponse, error) { + out := new(MsgSetPromoterConfResponse) + err := c.cc.Invoke(ctx, Msg_SetPromoterConf_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) CreatePromoter(ctx context.Context, in *MsgCreatePromoter, opts ...grpc.CallOption) (*MsgCreatePromoterResponse, error) { + out := new(MsgCreatePromoterResponse) + err := c.cc.Invoke(ctx, Msg_CreatePromoter_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) CreateCampaign(ctx context.Context, in *MsgCreateCampaign, opts ...grpc.CallOption) (*MsgCreateCampaignResponse, error) { + out := new(MsgCreateCampaignResponse) + err := c.cc.Invoke(ctx, Msg_CreateCampaign_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateCampaign(ctx context.Context, in *MsgUpdateCampaign, opts ...grpc.CallOption) (*MsgUpdateCampaignResponse, error) { + out := new(MsgUpdateCampaignResponse) + err := c.cc.Invoke(ctx, Msg_UpdateCampaign_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) WithdrawFunds(ctx context.Context, in *MsgWithdrawFunds, opts ...grpc.CallOption) (*MsgWithdrawFundsResponse, error) { + out := new(MsgWithdrawFundsResponse) + err := c.cc.Invoke(ctx, Msg_WithdrawFunds_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) GrantReward(ctx context.Context, in *MsgGrantReward, opts ...grpc.CallOption) (*MsgGrantRewardResponse, error) { + out := new(MsgGrantRewardResponse) + err := c.cc.Invoke(ctx, Msg_GrantReward_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // Deprecated: Do not use. + // SetPromoterConf is a method to set the configurations of a promoter. + SetPromoterConf(context.Context, *MsgSetPromoterConf) (*MsgSetPromoterConfResponse, error) + // Deprecated: Do not use. + // CreatePromoter is a method to create a promoter + CreatePromoter(context.Context, *MsgCreatePromoter) (*MsgCreatePromoterResponse, error) + // Deprecated: Do not use. + // CreateCampaign is a method to create a campaign + CreateCampaign(context.Context, *MsgCreateCampaign) (*MsgCreateCampaignResponse, error) + // Deprecated: Do not use. + // UpdateCampaign is a method to update campaign + UpdateCampaign(context.Context, *MsgUpdateCampaign) (*MsgUpdateCampaignResponse, error) + // Deprecated: Do not use. + // WithdrawCampaignFunds is method to withdraw funds from the campaign + WithdrawFunds(context.Context, *MsgWithdrawFunds) (*MsgWithdrawFundsResponse, error) + // Deprecated: Do not use. + // GrantReward is method to allocate rewards + GrantReward(context.Context, *MsgGrantReward) (*MsgGrantRewardResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/ovm module + // parameters. The authority is defined in the keeper. + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) SetPromoterConf(context.Context, *MsgSetPromoterConf) (*MsgSetPromoterConfResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SetPromoterConf not implemented") +} +func (UnimplementedMsgServer) CreatePromoter(context.Context, *MsgCreatePromoter) (*MsgCreatePromoterResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreatePromoter not implemented") +} +func (UnimplementedMsgServer) CreateCampaign(context.Context, *MsgCreateCampaign) (*MsgCreateCampaignResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method CreateCampaign not implemented") +} +func (UnimplementedMsgServer) UpdateCampaign(context.Context, *MsgUpdateCampaign) (*MsgUpdateCampaignResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateCampaign not implemented") +} +func (UnimplementedMsgServer) WithdrawFunds(context.Context, *MsgWithdrawFunds) (*MsgWithdrawFundsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WithdrawFunds not implemented") +} +func (UnimplementedMsgServer) GrantReward(context.Context, *MsgGrantReward) (*MsgGrantRewardResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GrantReward not implemented") +} +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_SetPromoterConf_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgSetPromoterConf) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).SetPromoterConf(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_SetPromoterConf_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).SetPromoterConf(ctx, req.(*MsgSetPromoterConf)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_CreatePromoter_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgCreatePromoter) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).CreatePromoter(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_CreatePromoter_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).CreatePromoter(ctx, req.(*MsgCreatePromoter)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_CreateCampaign_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgCreateCampaign) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).CreateCampaign(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_CreateCampaign_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).CreateCampaign(ctx, req.(*MsgCreateCampaign)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateCampaign_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateCampaign) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateCampaign(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateCampaign_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateCampaign(ctx, req.(*MsgUpdateCampaign)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_WithdrawFunds_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgWithdrawFunds) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).WithdrawFunds(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_WithdrawFunds_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).WithdrawFunds(ctx, req.(*MsgWithdrawFunds)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_GrantReward_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgGrantReward) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).GrantReward(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_GrantReward_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).GrantReward(ctx, req.(*MsgGrantReward)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.reward.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "SetPromoterConf", + Handler: _Msg_SetPromoterConf_Handler, + }, + { + MethodName: "CreatePromoter", + Handler: _Msg_CreatePromoter_Handler, + }, + { + MethodName: "CreateCampaign", + Handler: _Msg_CreateCampaign_Handler, + }, + { + MethodName: "UpdateCampaign", + Handler: _Msg_UpdateCampaign_Handler, + }, + { + MethodName: "WithdrawFunds", + Handler: _Msg_WithdrawFunds_Handler, + }, + { + MethodName: "GrantReward", + Handler: _Msg_GrantReward_Handler, + }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/reward/v1beta/tx.proto", +} diff --git a/api/sge/legacy/subaccount/module/v1/module.pulsar.go b/api/sge/legacy/subaccount/module/v1/module.pulsar.go new file mode 100644 index 00000000..1e3f515e --- /dev/null +++ b/api/sge/legacy/subaccount/module/v1/module.pulsar.go @@ -0,0 +1,658 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_module_v1_module_proto_init() + md_Module = File_sge_legacy_subaccount_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.legacy.subaccount.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.legacy.subaccount.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.legacy.subaccount.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.legacy.subaccount.module.v1.Module is not mutable")) + case "sge.legacy.subaccount.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.legacy.subaccount.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.module.v1.Module")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/subaccount/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the subaccount module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_legacy_subaccount_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_legacy_subaccount_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x2c, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, + 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1f, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x1a, + 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, + 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x22, 0x6e, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x12, 0x2c, 0x0a, 0x12, 0x66, + 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x5f, 0x6e, 0x61, 0x6d, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x66, 0x65, 0x65, 0x43, 0x6f, 0x6c, 0x6c, + 0x65, 0x63, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x75, 0x74, + 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, + 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, 0x18, 0xba, 0xc0, 0x96, 0xda, 0x01, 0x12, 0x0a, + 0x10, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x42, 0x9c, 0x02, 0x0a, 0x23, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, + 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x47, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, + 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, + 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x6d, + 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, + 0x31, 0xa2, 0x02, 0x04, 0x53, 0x4c, 0x53, 0x4d, 0xaa, 0x02, 0x1f, 0x53, 0x67, 0x65, 0x2e, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x1f, 0x53, 0x67, 0x65, + 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x2b, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, + 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x23, 0x53, 0x67, 0x65, + 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_subaccount_module_v1_module_proto_rawDescOnce sync.Once + file_sge_legacy_subaccount_module_v1_module_proto_rawDescData = file_sge_legacy_subaccount_module_v1_module_proto_rawDesc +) + +func file_sge_legacy_subaccount_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_legacy_subaccount_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_legacy_subaccount_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_subaccount_module_v1_module_proto_rawDescData) + }) + return file_sge_legacy_subaccount_module_v1_module_proto_rawDescData +} + +var file_sge_legacy_subaccount_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_subaccount_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.legacy.subaccount.module.v1.Module +} +var file_sge_legacy_subaccount_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_subaccount_module_v1_module_proto_init() } +func file_sge_legacy_subaccount_module_v1_module_proto_init() { + if File_sge_legacy_subaccount_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_subaccount_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_subaccount_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_subaccount_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_legacy_subaccount_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_legacy_subaccount_module_v1_module_proto_msgTypes, + }.Build() + File_sge_legacy_subaccount_module_v1_module_proto = out.File + file_sge_legacy_subaccount_module_v1_module_proto_rawDesc = nil + file_sge_legacy_subaccount_module_v1_module_proto_goTypes = nil + file_sge_legacy_subaccount_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/legacy/subaccount/v1beta/balance.pulsar.go b/api/sge/legacy/subaccount/v1beta/balance.pulsar.go new file mode 100644 index 00000000..4975dbd4 --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/balance.pulsar.go @@ -0,0 +1,1415 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package subaccountv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_AccountSummary protoreflect.MessageDescriptor + fd_AccountSummary_deposited_amount protoreflect.FieldDescriptor + fd_AccountSummary_spent_amount protoreflect.FieldDescriptor + fd_AccountSummary_withdrawn_amount protoreflect.FieldDescriptor + fd_AccountSummary_lost_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_balance_proto_init() + md_AccountSummary = File_sge_legacy_subaccount_v1beta_balance_proto.Messages().ByName("AccountSummary") + fd_AccountSummary_deposited_amount = md_AccountSummary.Fields().ByName("deposited_amount") + fd_AccountSummary_spent_amount = md_AccountSummary.Fields().ByName("spent_amount") + fd_AccountSummary_withdrawn_amount = md_AccountSummary.Fields().ByName("withdrawn_amount") + fd_AccountSummary_lost_amount = md_AccountSummary.Fields().ByName("lost_amount") +} + +var _ protoreflect.Message = (*fastReflection_AccountSummary)(nil) + +type fastReflection_AccountSummary AccountSummary + +func (x *AccountSummary) ProtoReflect() protoreflect.Message { + return (*fastReflection_AccountSummary)(x) +} + +func (x *AccountSummary) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_AccountSummary_messageType fastReflection_AccountSummary_messageType +var _ protoreflect.MessageType = fastReflection_AccountSummary_messageType{} + +type fastReflection_AccountSummary_messageType struct{} + +func (x fastReflection_AccountSummary_messageType) Zero() protoreflect.Message { + return (*fastReflection_AccountSummary)(nil) +} +func (x fastReflection_AccountSummary_messageType) New() protoreflect.Message { + return new(fastReflection_AccountSummary) +} +func (x fastReflection_AccountSummary_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_AccountSummary +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_AccountSummary) Descriptor() protoreflect.MessageDescriptor { + return md_AccountSummary +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_AccountSummary) Type() protoreflect.MessageType { + return _fastReflection_AccountSummary_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_AccountSummary) New() protoreflect.Message { + return new(fastReflection_AccountSummary) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_AccountSummary) Interface() protoreflect.ProtoMessage { + return (*AccountSummary)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_AccountSummary) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.DepositedAmount != "" { + value := protoreflect.ValueOfString(x.DepositedAmount) + if !f(fd_AccountSummary_deposited_amount, value) { + return + } + } + if x.SpentAmount != "" { + value := protoreflect.ValueOfString(x.SpentAmount) + if !f(fd_AccountSummary_spent_amount, value) { + return + } + } + if x.WithdrawnAmount != "" { + value := protoreflect.ValueOfString(x.WithdrawnAmount) + if !f(fd_AccountSummary_withdrawn_amount, value) { + return + } + } + if x.LostAmount != "" { + value := protoreflect.ValueOfString(x.LostAmount) + if !f(fd_AccountSummary_lost_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_AccountSummary) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.AccountSummary.deposited_amount": + return x.DepositedAmount != "" + case "sge.legacy.subaccount.v1beta.AccountSummary.spent_amount": + return x.SpentAmount != "" + case "sge.legacy.subaccount.v1beta.AccountSummary.withdrawn_amount": + return x.WithdrawnAmount != "" + case "sge.legacy.subaccount.v1beta.AccountSummary.lost_amount": + return x.LostAmount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.AccountSummary")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.AccountSummary does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountSummary) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.AccountSummary.deposited_amount": + x.DepositedAmount = "" + case "sge.legacy.subaccount.v1beta.AccountSummary.spent_amount": + x.SpentAmount = "" + case "sge.legacy.subaccount.v1beta.AccountSummary.withdrawn_amount": + x.WithdrawnAmount = "" + case "sge.legacy.subaccount.v1beta.AccountSummary.lost_amount": + x.LostAmount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.AccountSummary")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.AccountSummary does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_AccountSummary) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.AccountSummary.deposited_amount": + value := x.DepositedAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.AccountSummary.spent_amount": + value := x.SpentAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.AccountSummary.withdrawn_amount": + value := x.WithdrawnAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.AccountSummary.lost_amount": + value := x.LostAmount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.AccountSummary")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.AccountSummary does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountSummary) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.AccountSummary.deposited_amount": + x.DepositedAmount = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.AccountSummary.spent_amount": + x.SpentAmount = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.AccountSummary.withdrawn_amount": + x.WithdrawnAmount = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.AccountSummary.lost_amount": + x.LostAmount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.AccountSummary")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.AccountSummary does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountSummary) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.AccountSummary.deposited_amount": + panic(fmt.Errorf("field deposited_amount of message sge.legacy.subaccount.v1beta.AccountSummary is not mutable")) + case "sge.legacy.subaccount.v1beta.AccountSummary.spent_amount": + panic(fmt.Errorf("field spent_amount of message sge.legacy.subaccount.v1beta.AccountSummary is not mutable")) + case "sge.legacy.subaccount.v1beta.AccountSummary.withdrawn_amount": + panic(fmt.Errorf("field withdrawn_amount of message sge.legacy.subaccount.v1beta.AccountSummary is not mutable")) + case "sge.legacy.subaccount.v1beta.AccountSummary.lost_amount": + panic(fmt.Errorf("field lost_amount of message sge.legacy.subaccount.v1beta.AccountSummary is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.AccountSummary")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.AccountSummary does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_AccountSummary) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.AccountSummary.deposited_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.AccountSummary.spent_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.AccountSummary.withdrawn_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.AccountSummary.lost_amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.AccountSummary")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.AccountSummary does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_AccountSummary) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.AccountSummary", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_AccountSummary) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_AccountSummary) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_AccountSummary) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_AccountSummary) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*AccountSummary) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.DepositedAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.SpentAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.WithdrawnAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.LostAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*AccountSummary) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.LostAmount) > 0 { + i -= len(x.LostAmount) + copy(dAtA[i:], x.LostAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.LostAmount))) + i-- + dAtA[i] = 0x22 + } + if len(x.WithdrawnAmount) > 0 { + i -= len(x.WithdrawnAmount) + copy(dAtA[i:], x.WithdrawnAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.WithdrawnAmount))) + i-- + dAtA[i] = 0x1a + } + if len(x.SpentAmount) > 0 { + i -= len(x.SpentAmount) + copy(dAtA[i:], x.SpentAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SpentAmount))) + i-- + dAtA[i] = 0x12 + } + if len(x.DepositedAmount) > 0 { + i -= len(x.DepositedAmount) + copy(dAtA[i:], x.DepositedAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.DepositedAmount))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*AccountSummary) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountSummary: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: AccountSummary: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositedAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.DepositedAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SpentAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SpentAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WithdrawnAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.WithdrawnAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field LostAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.LostAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_LockedBalance protoreflect.MessageDescriptor + fd_LockedBalance_unlock_ts protoreflect.FieldDescriptor + fd_LockedBalance_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_balance_proto_init() + md_LockedBalance = File_sge_legacy_subaccount_v1beta_balance_proto.Messages().ByName("LockedBalance") + fd_LockedBalance_unlock_ts = md_LockedBalance.Fields().ByName("unlock_ts") + fd_LockedBalance_amount = md_LockedBalance.Fields().ByName("amount") +} + +var _ protoreflect.Message = (*fastReflection_LockedBalance)(nil) + +type fastReflection_LockedBalance LockedBalance + +func (x *LockedBalance) ProtoReflect() protoreflect.Message { + return (*fastReflection_LockedBalance)(x) +} + +func (x *LockedBalance) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_LockedBalance_messageType fastReflection_LockedBalance_messageType +var _ protoreflect.MessageType = fastReflection_LockedBalance_messageType{} + +type fastReflection_LockedBalance_messageType struct{} + +func (x fastReflection_LockedBalance_messageType) Zero() protoreflect.Message { + return (*fastReflection_LockedBalance)(nil) +} +func (x fastReflection_LockedBalance_messageType) New() protoreflect.Message { + return new(fastReflection_LockedBalance) +} +func (x fastReflection_LockedBalance_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_LockedBalance +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_LockedBalance) Descriptor() protoreflect.MessageDescriptor { + return md_LockedBalance +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_LockedBalance) Type() protoreflect.MessageType { + return _fastReflection_LockedBalance_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_LockedBalance) New() protoreflect.Message { + return new(fastReflection_LockedBalance) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_LockedBalance) Interface() protoreflect.ProtoMessage { + return (*LockedBalance)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_LockedBalance) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.UnlockTs != uint64(0) { + value := protoreflect.ValueOfUint64(x.UnlockTs) + if !f(fd_LockedBalance_unlock_ts, value) { + return + } + } + if x.Amount != "" { + value := protoreflect.ValueOfString(x.Amount) + if !f(fd_LockedBalance_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_LockedBalance) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.LockedBalance.unlock_ts": + return x.UnlockTs != uint64(0) + case "sge.legacy.subaccount.v1beta.LockedBalance.amount": + return x.Amount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.LockedBalance")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.LockedBalance does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_LockedBalance) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.LockedBalance.unlock_ts": + x.UnlockTs = uint64(0) + case "sge.legacy.subaccount.v1beta.LockedBalance.amount": + x.Amount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.LockedBalance")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.LockedBalance does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_LockedBalance) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.LockedBalance.unlock_ts": + value := x.UnlockTs + return protoreflect.ValueOfUint64(value) + case "sge.legacy.subaccount.v1beta.LockedBalance.amount": + value := x.Amount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.LockedBalance")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.LockedBalance does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_LockedBalance) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.LockedBalance.unlock_ts": + x.UnlockTs = value.Uint() + case "sge.legacy.subaccount.v1beta.LockedBalance.amount": + x.Amount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.LockedBalance")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.LockedBalance does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_LockedBalance) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.LockedBalance.unlock_ts": + panic(fmt.Errorf("field unlock_ts of message sge.legacy.subaccount.v1beta.LockedBalance is not mutable")) + case "sge.legacy.subaccount.v1beta.LockedBalance.amount": + panic(fmt.Errorf("field amount of message sge.legacy.subaccount.v1beta.LockedBalance is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.LockedBalance")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.LockedBalance does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_LockedBalance) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.LockedBalance.unlock_ts": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.subaccount.v1beta.LockedBalance.amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.LockedBalance")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.LockedBalance does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_LockedBalance) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.LockedBalance", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_LockedBalance) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_LockedBalance) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_LockedBalance) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_LockedBalance) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*LockedBalance) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.UnlockTs != 0 { + n += 1 + runtime.Sov(uint64(x.UnlockTs)) + } + l = len(x.Amount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*LockedBalance) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Amount) > 0 { + i -= len(x.Amount) + copy(dAtA[i:], x.Amount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Amount))) + i-- + dAtA[i] = 0x12 + } + if x.UnlockTs != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.UnlockTs)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*LockedBalance) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: LockedBalance: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: LockedBalance: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field UnlockTs", wireType) + } + x.UnlockTs = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.UnlockTs |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Amount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/subaccount/v1beta/balance.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// LockedBalanceStatus type. +type LockedBalanceStatus int32 + +const ( + // the invalid or unknown + LockedBalanceStatus_LOCKED_BALANCE_STATUS_UNSPECIFIED LockedBalanceStatus = 0 + // locked + LockedBalanceStatus_LOCKED_BALANCE_STATUS_LOCKED LockedBalanceStatus = 1 + // unlocked + LockedBalanceStatus_LOCKED_BALANCE_STATUS_UNLOCKED LockedBalanceStatus = 2 +) + +// Enum value maps for LockedBalanceStatus. +var ( + LockedBalanceStatus_name = map[int32]string{ + 0: "LOCKED_BALANCE_STATUS_UNSPECIFIED", + 1: "LOCKED_BALANCE_STATUS_LOCKED", + 2: "LOCKED_BALANCE_STATUS_UNLOCKED", + } + LockedBalanceStatus_value = map[string]int32{ + "LOCKED_BALANCE_STATUS_UNSPECIFIED": 0, + "LOCKED_BALANCE_STATUS_LOCKED": 1, + "LOCKED_BALANCE_STATUS_UNLOCKED": 2, + } +) + +func (x LockedBalanceStatus) Enum() *LockedBalanceStatus { + p := new(LockedBalanceStatus) + *p = x + return p +} + +func (x LockedBalanceStatus) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (LockedBalanceStatus) Descriptor() protoreflect.EnumDescriptor { + return file_sge_legacy_subaccount_v1beta_balance_proto_enumTypes[0].Descriptor() +} + +func (LockedBalanceStatus) Type() protoreflect.EnumType { + return &file_sge_legacy_subaccount_v1beta_balance_proto_enumTypes[0] +} + +func (x LockedBalanceStatus) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use LockedBalanceStatus.Descriptor instead. +func (LockedBalanceStatus) EnumDescriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_balance_proto_rawDescGZIP(), []int{0} +} + +// AccountSummary defines the balance of a subaccount. +type AccountSummary struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // deposited_amount keeps track of how much was deposited so far in the + // subaccount. + DepositedAmount string `protobuf:"bytes,1,opt,name=deposited_amount,json=depositedAmount,proto3" json:"deposited_amount,omitempty"` + // spent_amount keeps track of how much was spent in the account in betting, + // house, staking, etc. + SpentAmount string `protobuf:"bytes,2,opt,name=spent_amount,json=spentAmount,proto3" json:"spent_amount,omitempty"` + // withdrawn_amount keeps track of how much was withdrawn in the account after + // locked coins become unlocked. + WithdrawnAmount string `protobuf:"bytes,3,opt,name=withdrawn_amount,json=withdrawnAmount,proto3" json:"withdrawn_amount,omitempty"` + // lost_amount keeps track of the amounts that were lost due to betting + // losses, slashing etc. + LostAmount string `protobuf:"bytes,4,opt,name=lost_amount,json=lostAmount,proto3" json:"lost_amount,omitempty"` +} + +func (x *AccountSummary) Reset() { + *x = AccountSummary{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AccountSummary) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AccountSummary) ProtoMessage() {} + +// Deprecated: Use AccountSummary.ProtoReflect.Descriptor instead. +func (*AccountSummary) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_balance_proto_rawDescGZIP(), []int{0} +} + +func (x *AccountSummary) GetDepositedAmount() string { + if x != nil { + return x.DepositedAmount + } + return "" +} + +func (x *AccountSummary) GetSpentAmount() string { + if x != nil { + return x.SpentAmount + } + return "" +} + +func (x *AccountSummary) GetWithdrawnAmount() string { + if x != nil { + return x.WithdrawnAmount + } + return "" +} + +func (x *AccountSummary) GetLostAmount() string { + if x != nil { + return x.LostAmount + } + return "" +} + +// LockedBalance defines a balance which is locked. +type LockedBalance struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + UnlockTs uint64 `protobuf:"varint,1,opt,name=unlock_ts,proto3" json:"unlock_ts,omitempty"` + Amount string `protobuf:"bytes,2,opt,name=amount,proto3" json:"amount,omitempty"` +} + +func (x *LockedBalance) Reset() { + *x = LockedBalance{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *LockedBalance) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*LockedBalance) ProtoMessage() {} + +// Deprecated: Use LockedBalance.ProtoReflect.Descriptor instead. +func (*LockedBalance) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_balance_proto_rawDescGZIP(), []int{1} +} + +func (x *LockedBalance) GetUnlockTs() uint64 { + if x != nil { + return x.UnlockTs + } + return 0 +} + +func (x *LockedBalance) GetAmount() string { + if x != nil { + return x.Amount + } + return "" +} + +var File_sge_legacy_subaccount_v1beta_balance_proto protoreflect.FileDescriptor + +var file_sge_legacy_subaccount_v1beta_balance_proto_rawDesc = []byte{ + 0x0a, 0x2a, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, + 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1c, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x22, 0xa6, 0x02, 0x0a, 0x0e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, + 0x61, 0x72, 0x79, 0x12, 0x48, 0x0a, 0x10, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x65, 0x64, + 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, + 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0f, 0x64, 0x65, + 0x70, 0x6f, 0x73, 0x69, 0x74, 0x65, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x40, 0x0a, + 0x0c, 0x73, 0x70, 0x65, 0x6e, 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, + 0x6e, 0x74, 0x52, 0x0b, 0x73, 0x70, 0x65, 0x6e, 0x74, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, + 0x48, 0x0a, 0x10, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x6e, 0x5f, 0x61, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, + 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, + 0x61, 0x77, 0x6e, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x3e, 0x0a, 0x0b, 0x6c, 0x6f, 0x73, + 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, + 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0a, 0x6c, + 0x6f, 0x73, 0x74, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x7f, 0x0a, 0x0d, 0x4c, 0x6f, 0x63, + 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x37, 0x0a, 0x09, 0x75, 0x6e, + 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x74, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x42, 0x19, 0xe2, + 0xde, 0x1f, 0x08, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x54, 0x53, 0xea, 0xde, 0x1f, 0x09, 0x75, + 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x74, 0x73, 0x52, 0x09, 0x75, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, + 0x5f, 0x74, 0x73, 0x12, 0x35, 0x0a, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, + 0x6e, 0x74, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x2a, 0x82, 0x01, 0x0a, 0x13, 0x4c, + 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x75, 0x73, 0x12, 0x25, 0x0a, 0x21, 0x4c, 0x4f, 0x43, 0x4b, 0x45, 0x44, 0x5f, 0x42, 0x41, 0x4c, + 0x41, 0x4e, 0x43, 0x45, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, + 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x20, 0x0a, 0x1c, 0x4c, 0x4f, 0x43, + 0x4b, 0x45, 0x44, 0x5f, 0x42, 0x41, 0x4c, 0x41, 0x4e, 0x43, 0x45, 0x5f, 0x53, 0x54, 0x41, 0x54, + 0x55, 0x53, 0x5f, 0x4c, 0x4f, 0x43, 0x4b, 0x45, 0x44, 0x10, 0x01, 0x12, 0x22, 0x0a, 0x1e, 0x4c, + 0x4f, 0x43, 0x4b, 0x45, 0x44, 0x5f, 0x42, 0x41, 0x4c, 0x41, 0x4e, 0x43, 0x45, 0x5f, 0x53, 0x54, + 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x4c, 0x4f, 0x43, 0x4b, 0x45, 0x44, 0x10, 0x02, 0x42, + 0x91, 0x02, 0x0a, 0x20, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x3b, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x53, 0xaa, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x2e, 0x4c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x28, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0xea, 0x02, 0x1f, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, + 0x3a, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_subaccount_v1beta_balance_proto_rawDescOnce sync.Once + file_sge_legacy_subaccount_v1beta_balance_proto_rawDescData = file_sge_legacy_subaccount_v1beta_balance_proto_rawDesc +) + +func file_sge_legacy_subaccount_v1beta_balance_proto_rawDescGZIP() []byte { + file_sge_legacy_subaccount_v1beta_balance_proto_rawDescOnce.Do(func() { + file_sge_legacy_subaccount_v1beta_balance_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_subaccount_v1beta_balance_proto_rawDescData) + }) + return file_sge_legacy_subaccount_v1beta_balance_proto_rawDescData +} + +var file_sge_legacy_subaccount_v1beta_balance_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_subaccount_v1beta_balance_proto_goTypes = []interface{}{ + (LockedBalanceStatus)(0), // 0: sge.legacy.subaccount.v1beta.LockedBalanceStatus + (*AccountSummary)(nil), // 1: sge.legacy.subaccount.v1beta.AccountSummary + (*LockedBalance)(nil), // 2: sge.legacy.subaccount.v1beta.LockedBalance +} +var file_sge_legacy_subaccount_v1beta_balance_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_subaccount_v1beta_balance_proto_init() } +func file_sge_legacy_subaccount_v1beta_balance_proto_init() { + if File_sge_legacy_subaccount_v1beta_balance_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AccountSummary); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*LockedBalance); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_subaccount_v1beta_balance_proto_rawDesc, + NumEnums: 1, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_subaccount_v1beta_balance_proto_goTypes, + DependencyIndexes: file_sge_legacy_subaccount_v1beta_balance_proto_depIdxs, + EnumInfos: file_sge_legacy_subaccount_v1beta_balance_proto_enumTypes, + MessageInfos: file_sge_legacy_subaccount_v1beta_balance_proto_msgTypes, + }.Build() + File_sge_legacy_subaccount_v1beta_balance_proto = out.File + file_sge_legacy_subaccount_v1beta_balance_proto_rawDesc = nil + file_sge_legacy_subaccount_v1beta_balance_proto_goTypes = nil + file_sge_legacy_subaccount_v1beta_balance_proto_depIdxs = nil +} diff --git a/api/sge/legacy/subaccount/v1beta/genesis.pulsar.go b/api/sge/legacy/subaccount/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..f8b13d23 --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/genesis.pulsar.go @@ -0,0 +1,1622 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package subaccountv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_GenesisState_3_list)(nil) + +type _GenesisState_3_list struct { + list *[]*GenesisSubaccount +} + +func (x *_GenesisState_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisState_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisState_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*GenesisSubaccount) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisState_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*GenesisSubaccount) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisState_3_list) AppendMutable() protoreflect.Value { + v := new(GenesisSubaccount) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisState_3_list) NewElement() protoreflect.Value { + v := new(GenesisSubaccount) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisState_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor + fd_GenesisState_subaccount_id protoreflect.FieldDescriptor + fd_GenesisState_subaccounts protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_genesis_proto_init() + md_GenesisState = File_sge_legacy_subaccount_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") + fd_GenesisState_subaccount_id = md_GenesisState.Fields().ByName("subaccount_id") + fd_GenesisState_subaccounts = md_GenesisState.Fields().ByName("subaccounts") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } + if x.SubaccountId != uint64(0) { + value := protoreflect.ValueOfUint64(x.SubaccountId) + if !f(fd_GenesisState_subaccount_id, value) { + return + } + } + if len(x.Subaccounts) != 0 { + value := protoreflect.ValueOfList(&_GenesisState_3_list{list: &x.Subaccounts}) + if !f(fd_GenesisState_subaccounts, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisState.params": + return x.Params != nil + case "sge.legacy.subaccount.v1beta.GenesisState.subaccount_id": + return x.SubaccountId != uint64(0) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccounts": + return len(x.Subaccounts) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisState.params": + x.Params = nil + case "sge.legacy.subaccount.v1beta.GenesisState.subaccount_id": + x.SubaccountId = uint64(0) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccounts": + x.Subaccounts = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccount_id": + value := x.SubaccountId + return protoreflect.ValueOfUint64(value) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccounts": + if len(x.Subaccounts) == 0 { + return protoreflect.ValueOfList(&_GenesisState_3_list{}) + } + listValue := &_GenesisState_3_list{list: &x.Subaccounts} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccount_id": + x.SubaccountId = value.Uint() + case "sge.legacy.subaccount.v1beta.GenesisState.subaccounts": + lv := value.List() + clv := lv.(*_GenesisState_3_list) + x.Subaccounts = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccounts": + if x.Subaccounts == nil { + x.Subaccounts = []*GenesisSubaccount{} + } + value := &_GenesisState_3_list{list: &x.Subaccounts} + return protoreflect.ValueOfList(value) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccount_id": + panic(fmt.Errorf("field subaccount_id of message sge.legacy.subaccount.v1beta.GenesisState is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccount_id": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.legacy.subaccount.v1beta.GenesisState.subaccounts": + list := []*GenesisSubaccount{} + return protoreflect.ValueOfList(&_GenesisState_3_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.SubaccountId != 0 { + n += 1 + runtime.Sov(uint64(x.SubaccountId)) + } + if len(x.Subaccounts) > 0 { + for _, e := range x.Subaccounts { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Subaccounts) > 0 { + for iNdEx := len(x.Subaccounts) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Subaccounts[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if x.SubaccountId != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.SubaccountId)) + i-- + dAtA[i] = 0x10 + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SubaccountId", wireType) + } + x.SubaccountId = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.SubaccountId |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Subaccounts", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Subaccounts = append(x.Subaccounts, &GenesisSubaccount{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Subaccounts[len(x.Subaccounts)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_GenesisSubaccount_4_list)(nil) + +type _GenesisSubaccount_4_list struct { + list *[]*LockedBalance +} + +func (x *_GenesisSubaccount_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_GenesisSubaccount_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_GenesisSubaccount_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + (*x.list)[i] = concreteValue +} + +func (x *_GenesisSubaccount_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + *x.list = append(*x.list, concreteValue) +} + +func (x *_GenesisSubaccount_4_list) AppendMutable() protoreflect.Value { + v := new(LockedBalance) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisSubaccount_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_GenesisSubaccount_4_list) NewElement() protoreflect.Value { + v := new(LockedBalance) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_GenesisSubaccount_4_list) IsValid() bool { + return x.list != nil +} + +var ( + md_GenesisSubaccount protoreflect.MessageDescriptor + fd_GenesisSubaccount_address protoreflect.FieldDescriptor + fd_GenesisSubaccount_owner protoreflect.FieldDescriptor + fd_GenesisSubaccount_balance protoreflect.FieldDescriptor + fd_GenesisSubaccount_locked_balances protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_genesis_proto_init() + md_GenesisSubaccount = File_sge_legacy_subaccount_v1beta_genesis_proto.Messages().ByName("GenesisSubaccount") + fd_GenesisSubaccount_address = md_GenesisSubaccount.Fields().ByName("address") + fd_GenesisSubaccount_owner = md_GenesisSubaccount.Fields().ByName("owner") + fd_GenesisSubaccount_balance = md_GenesisSubaccount.Fields().ByName("balance") + fd_GenesisSubaccount_locked_balances = md_GenesisSubaccount.Fields().ByName("locked_balances") +} + +var _ protoreflect.Message = (*fastReflection_GenesisSubaccount)(nil) + +type fastReflection_GenesisSubaccount GenesisSubaccount + +func (x *GenesisSubaccount) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisSubaccount)(x) +} + +func (x *GenesisSubaccount) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisSubaccount_messageType fastReflection_GenesisSubaccount_messageType +var _ protoreflect.MessageType = fastReflection_GenesisSubaccount_messageType{} + +type fastReflection_GenesisSubaccount_messageType struct{} + +func (x fastReflection_GenesisSubaccount_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisSubaccount)(nil) +} +func (x fastReflection_GenesisSubaccount_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisSubaccount) +} +func (x fastReflection_GenesisSubaccount_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisSubaccount +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisSubaccount) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisSubaccount +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisSubaccount) Type() protoreflect.MessageType { + return _fastReflection_GenesisSubaccount_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisSubaccount) New() protoreflect.Message { + return new(fastReflection_GenesisSubaccount) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisSubaccount) Interface() protoreflect.ProtoMessage { + return (*GenesisSubaccount)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisSubaccount) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_GenesisSubaccount_address, value) { + return + } + } + if x.Owner != "" { + value := protoreflect.ValueOfString(x.Owner) + if !f(fd_GenesisSubaccount_owner, value) { + return + } + } + if x.Balance != nil { + value := protoreflect.ValueOfMessage(x.Balance.ProtoReflect()) + if !f(fd_GenesisSubaccount_balance, value) { + return + } + } + if len(x.LockedBalances) != 0 { + value := protoreflect.ValueOfList(&_GenesisSubaccount_4_list{list: &x.LockedBalances}) + if !f(fd_GenesisSubaccount_locked_balances, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisSubaccount) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.address": + return x.Address != "" + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.owner": + return x.Owner != "" + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.balance": + return x.Balance != nil + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.locked_balances": + return len(x.LockedBalances) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisSubaccount")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisSubaccount does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisSubaccount) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.address": + x.Address = "" + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.owner": + x.Owner = "" + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.balance": + x.Balance = nil + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.locked_balances": + x.LockedBalances = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisSubaccount")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisSubaccount does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisSubaccount) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.owner": + value := x.Owner + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.balance": + value := x.Balance + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.locked_balances": + if len(x.LockedBalances) == 0 { + return protoreflect.ValueOfList(&_GenesisSubaccount_4_list{}) + } + listValue := &_GenesisSubaccount_4_list{list: &x.LockedBalances} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisSubaccount")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisSubaccount does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisSubaccount) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.address": + x.Address = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.owner": + x.Owner = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.balance": + x.Balance = value.Message().Interface().(*AccountSummary) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.locked_balances": + lv := value.List() + clv := lv.(*_GenesisSubaccount_4_list) + x.LockedBalances = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisSubaccount")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisSubaccount does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisSubaccount) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.balance": + if x.Balance == nil { + x.Balance = new(AccountSummary) + } + return protoreflect.ValueOfMessage(x.Balance.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.locked_balances": + if x.LockedBalances == nil { + x.LockedBalances = []*LockedBalance{} + } + value := &_GenesisSubaccount_4_list{list: &x.LockedBalances} + return protoreflect.ValueOfList(value) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.address": + panic(fmt.Errorf("field address of message sge.legacy.subaccount.v1beta.GenesisSubaccount is not mutable")) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.owner": + panic(fmt.Errorf("field owner of message sge.legacy.subaccount.v1beta.GenesisSubaccount is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisSubaccount")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisSubaccount does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisSubaccount) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.address": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.owner": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.balance": + m := new(AccountSummary) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.GenesisSubaccount.locked_balances": + list := []*LockedBalance{} + return protoreflect.ValueOfList(&_GenesisSubaccount_4_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.GenesisSubaccount")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.GenesisSubaccount does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisSubaccount) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.GenesisSubaccount", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisSubaccount) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisSubaccount) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisSubaccount) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisSubaccount) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisSubaccount) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Owner) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Balance != nil { + l = options.Size(x.Balance) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.LockedBalances) > 0 { + for _, e := range x.LockedBalances { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisSubaccount) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.LockedBalances) > 0 { + for iNdEx := len(x.LockedBalances) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.LockedBalances[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if x.Balance != nil { + encoded, err := options.Marshal(x.Balance) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + if len(x.Owner) > 0 { + i -= len(x.Owner) + copy(dAtA[i:], x.Owner) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Owner))) + i-- + dAtA[i] = 0x12 + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisSubaccount) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisSubaccount: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisSubaccount: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Owner", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Owner = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Balance", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Balance == nil { + x.Balance = &AccountSummary{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Balance); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field LockedBalances", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.LockedBalances = append(x.LockedBalances, &LockedBalance{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.LockedBalances[len(x.LockedBalances)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/subaccount/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the subaccount module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params contains the subaccount parameters. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` + SubaccountId uint64 `protobuf:"varint,2,opt,name=subaccount_id,json=subaccountId,proto3" json:"subaccount_id,omitempty"` + // subaccounts contains all the subaccounts. + Subaccounts []*GenesisSubaccount `protobuf:"bytes,3,rep,name=subaccounts,proto3" json:"subaccounts,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +func (x *GenesisState) GetSubaccountId() uint64 { + if x != nil { + return x.SubaccountId + } + return 0 +} + +func (x *GenesisState) GetSubaccounts() []*GenesisSubaccount { + if x != nil { + return x.Subaccounts + } + return nil +} + +// GenesisSubaccount defines the genesis subaccount containing owner, address +// and balance information. +type GenesisSubaccount struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // address is the address of the subaccount. + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // owner is the owner of the subaccount. + Owner string `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"` + // balance defines the balance status of a subaccount + Balance *AccountSummary `protobuf:"bytes,3,opt,name=balance,proto3" json:"balance,omitempty"` + // locked_balances defines the lockup of balances history of a subaccount + LockedBalances []*LockedBalance `protobuf:"bytes,4,rep,name=locked_balances,json=lockedBalances,proto3" json:"locked_balances,omitempty"` +} + +func (x *GenesisSubaccount) Reset() { + *x = GenesisSubaccount{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisSubaccount) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisSubaccount) ProtoMessage() {} + +// Deprecated: Use GenesisSubaccount.ProtoReflect.Descriptor instead. +func (*GenesisSubaccount) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescGZIP(), []int{1} +} + +func (x *GenesisSubaccount) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *GenesisSubaccount) GetOwner() string { + if x != nil { + return x.Owner + } + return "" +} + +func (x *GenesisSubaccount) GetBalance() *AccountSummary { + if x != nil { + return x.Balance + } + return nil +} + +func (x *GenesisSubaccount) GetLockedBalances() []*LockedBalance { + if x != nil { + return x.LockedBalances + } + return nil +} + +var File_sge_legacy_subaccount_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_legacy_subaccount_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x2a, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x67, + 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1c, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x2a, 0x73, 0x67, 0x65, + 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x29, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x22, 0xd0, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x12, 0x42, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x23, 0x0a, 0x0d, 0x73, 0x75, 0x62, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, + 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x57, 0x0a, 0x0b, + 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x2f, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, + 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0b, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x22, 0xa1, 0x02, 0x0a, 0x11, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, + 0x73, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x32, 0x0a, 0x07, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, + 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, + 0x2e, 0x0a, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, + 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x12, + 0x4c, 0x0a, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, + 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x42, 0x04, + 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x5a, 0x0a, + 0x0f, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, + 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, + 0x6e, 0x63, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0e, 0x6c, 0x6f, 0x63, 0x6b, 0x65, + 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x42, 0x91, 0x02, 0x0a, 0x20, 0x63, 0x6f, + 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, + 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4c, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, + 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x73, 0x75, 0x62, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, + 0x4c, 0x53, 0xaa, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xca, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, + 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xe2, 0x02, 0x28, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, + 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1f, 0x53, 0x67, + 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x53, 0x75, 0x62, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescData = file_sge_legacy_subaccount_v1beta_genesis_proto_rawDesc +) + +func file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescData) + }) + return file_sge_legacy_subaccount_v1beta_genesis_proto_rawDescData +} + +var file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_legacy_subaccount_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.legacy.subaccount.v1beta.GenesisState + (*GenesisSubaccount)(nil), // 1: sge.legacy.subaccount.v1beta.GenesisSubaccount + (*Params)(nil), // 2: sge.legacy.subaccount.v1beta.Params + (*AccountSummary)(nil), // 3: sge.legacy.subaccount.v1beta.AccountSummary + (*LockedBalance)(nil), // 4: sge.legacy.subaccount.v1beta.LockedBalance +} +var file_sge_legacy_subaccount_v1beta_genesis_proto_depIdxs = []int32{ + 2, // 0: sge.legacy.subaccount.v1beta.GenesisState.params:type_name -> sge.legacy.subaccount.v1beta.Params + 1, // 1: sge.legacy.subaccount.v1beta.GenesisState.subaccounts:type_name -> sge.legacy.subaccount.v1beta.GenesisSubaccount + 3, // 2: sge.legacy.subaccount.v1beta.GenesisSubaccount.balance:type_name -> sge.legacy.subaccount.v1beta.AccountSummary + 4, // 3: sge.legacy.subaccount.v1beta.GenesisSubaccount.locked_balances:type_name -> sge.legacy.subaccount.v1beta.LockedBalance + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_sge_legacy_subaccount_v1beta_genesis_proto_init() } +func file_sge_legacy_subaccount_v1beta_genesis_proto_init() { + if File_sge_legacy_subaccount_v1beta_genesis_proto != nil { + return + } + file_sge_legacy_subaccount_v1beta_balance_proto_init() + file_sge_legacy_subaccount_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisSubaccount); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_subaccount_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_subaccount_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_legacy_subaccount_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_legacy_subaccount_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_legacy_subaccount_v1beta_genesis_proto = out.File + file_sge_legacy_subaccount_v1beta_genesis_proto_rawDesc = nil + file_sge_legacy_subaccount_v1beta_genesis_proto_goTypes = nil + file_sge_legacy_subaccount_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/legacy/subaccount/v1beta/params.pulsar.go b/api/sge/legacy/subaccount/v1beta/params.pulsar.go new file mode 100644 index 00000000..522963b6 --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/params.pulsar.go @@ -0,0 +1,635 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package subaccountv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Params protoreflect.MessageDescriptor + fd_Params_wager_enabled protoreflect.FieldDescriptor + fd_Params_deposit_enabled protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_params_proto_init() + md_Params = File_sge_legacy_subaccount_v1beta_params_proto.Messages().ByName("Params") + fd_Params_wager_enabled = md_Params.Fields().ByName("wager_enabled") + fd_Params_deposit_enabled = md_Params.Fields().ByName("deposit_enabled") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.WagerEnabled != false { + value := protoreflect.ValueOfBool(x.WagerEnabled) + if !f(fd_Params_wager_enabled, value) { + return + } + } + if x.DepositEnabled != false { + value := protoreflect.ValueOfBool(x.DepositEnabled) + if !f(fd_Params_deposit_enabled, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.Params.wager_enabled": + return x.WagerEnabled != false + case "sge.legacy.subaccount.v1beta.Params.deposit_enabled": + return x.DepositEnabled != false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.Params.wager_enabled": + x.WagerEnabled = false + case "sge.legacy.subaccount.v1beta.Params.deposit_enabled": + x.DepositEnabled = false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.Params.wager_enabled": + value := x.WagerEnabled + return protoreflect.ValueOfBool(value) + case "sge.legacy.subaccount.v1beta.Params.deposit_enabled": + value := x.DepositEnabled + return protoreflect.ValueOfBool(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.Params.wager_enabled": + x.WagerEnabled = value.Bool() + case "sge.legacy.subaccount.v1beta.Params.deposit_enabled": + x.DepositEnabled = value.Bool() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.Params.wager_enabled": + panic(fmt.Errorf("field wager_enabled of message sge.legacy.subaccount.v1beta.Params is not mutable")) + case "sge.legacy.subaccount.v1beta.Params.deposit_enabled": + panic(fmt.Errorf("field deposit_enabled of message sge.legacy.subaccount.v1beta.Params is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.Params.wager_enabled": + return protoreflect.ValueOfBool(false) + case "sge.legacy.subaccount.v1beta.Params.deposit_enabled": + return protoreflect.ValueOfBool(false) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.Params")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.WagerEnabled { + n += 2 + } + if x.DepositEnabled { + n += 2 + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.DepositEnabled { + i-- + if x.DepositEnabled { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x10 + } + if x.WagerEnabled { + i-- + if x.WagerEnabled { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WagerEnabled", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.WagerEnabled = bool(v != 0) + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositEnabled", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.DepositEnabled = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/subaccount/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params defines the parameters for the module. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // wager_enabled is enable/disable status of wager feature. + WagerEnabled bool `protobuf:"varint,1,opt,name=wager_enabled,json=wagerEnabled,proto3" json:"wager_enabled,omitempty"` + // deposit_enabled is enable/disable status of deposit feature. + DepositEnabled bool `protobuf:"varint,2,opt,name=deposit_enabled,json=depositEnabled,proto3" json:"deposit_enabled,omitempty"` +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +func (x *Params) GetWagerEnabled() bool { + if x != nil { + return x.WagerEnabled + } + return false +} + +func (x *Params) GetDepositEnabled() bool { + if x != nil { + return x.DepositEnabled + } + return false +} + +var File_sge_legacy_subaccount_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_legacy_subaccount_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x29, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1c, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, + 0x5c, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x23, 0x0a, 0x0d, 0x77, 0x61, 0x67, + 0x65, 0x72, 0x5f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x0c, 0x77, 0x61, 0x67, 0x65, 0x72, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x27, + 0x0a, 0x0f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, + 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0x90, 0x02, + 0x0a, 0x20, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x42, 0x0b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, + 0x01, 0x5a, 0x4c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, + 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, + 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x73, + 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, + 0x02, 0x03, 0x53, 0x4c, 0x53, 0xaa, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xe2, 0x02, 0x28, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x1f, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x53, 0x75, + 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_subaccount_v1beta_params_proto_rawDescOnce sync.Once + file_sge_legacy_subaccount_v1beta_params_proto_rawDescData = file_sge_legacy_subaccount_v1beta_params_proto_rawDesc +) + +func file_sge_legacy_subaccount_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_legacy_subaccount_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_legacy_subaccount_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_subaccount_v1beta_params_proto_rawDescData) + }) + return file_sge_legacy_subaccount_v1beta_params_proto_rawDescData +} + +var file_sge_legacy_subaccount_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_subaccount_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.legacy.subaccount.v1beta.Params +} +var file_sge_legacy_subaccount_v1beta_params_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_subaccount_v1beta_params_proto_init() } +func file_sge_legacy_subaccount_v1beta_params_proto_init() { + if File_sge_legacy_subaccount_v1beta_params_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_subaccount_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_subaccount_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_subaccount_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_legacy_subaccount_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_legacy_subaccount_v1beta_params_proto_msgTypes, + }.Build() + File_sge_legacy_subaccount_v1beta_params_proto = out.File + file_sge_legacy_subaccount_v1beta_params_proto_rawDesc = nil + file_sge_legacy_subaccount_v1beta_params_proto_goTypes = nil + file_sge_legacy_subaccount_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/legacy/subaccount/v1beta/query.pulsar.go b/api/sge/legacy/subaccount/v1beta/query.pulsar.go new file mode 100644 index 00000000..02c10cda --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/query.pulsar.go @@ -0,0 +1,2457 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package subaccountv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_legacy_subaccount_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_legacy_subaccount_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QuerySubaccountRequest protoreflect.MessageDescriptor + fd_QuerySubaccountRequest_address protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_query_proto_init() + md_QuerySubaccountRequest = File_sge_legacy_subaccount_v1beta_query_proto.Messages().ByName("QuerySubaccountRequest") + fd_QuerySubaccountRequest_address = md_QuerySubaccountRequest.Fields().ByName("address") +} + +var _ protoreflect.Message = (*fastReflection_QuerySubaccountRequest)(nil) + +type fastReflection_QuerySubaccountRequest QuerySubaccountRequest + +func (x *QuerySubaccountRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QuerySubaccountRequest)(x) +} + +func (x *QuerySubaccountRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QuerySubaccountRequest_messageType fastReflection_QuerySubaccountRequest_messageType +var _ protoreflect.MessageType = fastReflection_QuerySubaccountRequest_messageType{} + +type fastReflection_QuerySubaccountRequest_messageType struct{} + +func (x fastReflection_QuerySubaccountRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QuerySubaccountRequest)(nil) +} +func (x fastReflection_QuerySubaccountRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QuerySubaccountRequest) +} +func (x fastReflection_QuerySubaccountRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySubaccountRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QuerySubaccountRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySubaccountRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QuerySubaccountRequest) Type() protoreflect.MessageType { + return _fastReflection_QuerySubaccountRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QuerySubaccountRequest) New() protoreflect.Message { + return new(fastReflection_QuerySubaccountRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QuerySubaccountRequest) Interface() protoreflect.ProtoMessage { + return (*QuerySubaccountRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QuerySubaccountRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QuerySubaccountRequest_address, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QuerySubaccountRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountRequest.address": + return x.Address != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountRequest.address": + x.Address = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QuerySubaccountRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountRequest.address": + value := x.Address + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountRequest.address": + x.Address = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountRequest.address": + panic(fmt.Errorf("field address of message sge.legacy.subaccount.v1beta.QuerySubaccountRequest is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QuerySubaccountRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountRequest.address": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountRequest")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QuerySubaccountRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.QuerySubaccountRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QuerySubaccountRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QuerySubaccountRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QuerySubaccountRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QuerySubaccountRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QuerySubaccountRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QuerySubaccountRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySubaccountRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySubaccountRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_QuerySubaccountResponse_3_list)(nil) + +type _QuerySubaccountResponse_3_list struct { + list *[]*LockedBalance +} + +func (x *_QuerySubaccountResponse_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QuerySubaccountResponse_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QuerySubaccountResponse_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + (*x.list)[i] = concreteValue +} + +func (x *_QuerySubaccountResponse_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QuerySubaccountResponse_3_list) AppendMutable() protoreflect.Value { + v := new(LockedBalance) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySubaccountResponse_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QuerySubaccountResponse_3_list) NewElement() protoreflect.Value { + v := new(LockedBalance) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySubaccountResponse_3_list) IsValid() bool { + return x.list != nil +} + +var _ protoreflect.List = (*_QuerySubaccountResponse_4_list)(nil) + +type _QuerySubaccountResponse_4_list struct { + list *[]*LockedBalance +} + +func (x *_QuerySubaccountResponse_4_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_QuerySubaccountResponse_4_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_QuerySubaccountResponse_4_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + (*x.list)[i] = concreteValue +} + +func (x *_QuerySubaccountResponse_4_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + *x.list = append(*x.list, concreteValue) +} + +func (x *_QuerySubaccountResponse_4_list) AppendMutable() protoreflect.Value { + v := new(LockedBalance) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySubaccountResponse_4_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_QuerySubaccountResponse_4_list) NewElement() protoreflect.Value { + v := new(LockedBalance) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_QuerySubaccountResponse_4_list) IsValid() bool { + return x.list != nil +} + +var ( + md_QuerySubaccountResponse protoreflect.MessageDescriptor + fd_QuerySubaccountResponse_address protoreflect.FieldDescriptor + fd_QuerySubaccountResponse_balance protoreflect.FieldDescriptor + fd_QuerySubaccountResponse_locked_balance protoreflect.FieldDescriptor + fd_QuerySubaccountResponse_unlocked_balance protoreflect.FieldDescriptor + fd_QuerySubaccountResponse_withdrawable_unlocked_balance protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_query_proto_init() + md_QuerySubaccountResponse = File_sge_legacy_subaccount_v1beta_query_proto.Messages().ByName("QuerySubaccountResponse") + fd_QuerySubaccountResponse_address = md_QuerySubaccountResponse.Fields().ByName("address") + fd_QuerySubaccountResponse_balance = md_QuerySubaccountResponse.Fields().ByName("balance") + fd_QuerySubaccountResponse_locked_balance = md_QuerySubaccountResponse.Fields().ByName("locked_balance") + fd_QuerySubaccountResponse_unlocked_balance = md_QuerySubaccountResponse.Fields().ByName("unlocked_balance") + fd_QuerySubaccountResponse_withdrawable_unlocked_balance = md_QuerySubaccountResponse.Fields().ByName("withdrawable_unlocked_balance") +} + +var _ protoreflect.Message = (*fastReflection_QuerySubaccountResponse)(nil) + +type fastReflection_QuerySubaccountResponse QuerySubaccountResponse + +func (x *QuerySubaccountResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QuerySubaccountResponse)(x) +} + +func (x *QuerySubaccountResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QuerySubaccountResponse_messageType fastReflection_QuerySubaccountResponse_messageType +var _ protoreflect.MessageType = fastReflection_QuerySubaccountResponse_messageType{} + +type fastReflection_QuerySubaccountResponse_messageType struct{} + +func (x fastReflection_QuerySubaccountResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QuerySubaccountResponse)(nil) +} +func (x fastReflection_QuerySubaccountResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QuerySubaccountResponse) +} +func (x fastReflection_QuerySubaccountResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySubaccountResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QuerySubaccountResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QuerySubaccountResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QuerySubaccountResponse) Type() protoreflect.MessageType { + return _fastReflection_QuerySubaccountResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QuerySubaccountResponse) New() protoreflect.Message { + return new(fastReflection_QuerySubaccountResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QuerySubaccountResponse) Interface() protoreflect.ProtoMessage { + return (*QuerySubaccountResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QuerySubaccountResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_QuerySubaccountResponse_address, value) { + return + } + } + if x.Balance != nil { + value := protoreflect.ValueOfMessage(x.Balance.ProtoReflect()) + if !f(fd_QuerySubaccountResponse_balance, value) { + return + } + } + if len(x.LockedBalance) != 0 { + value := protoreflect.ValueOfList(&_QuerySubaccountResponse_3_list{list: &x.LockedBalance}) + if !f(fd_QuerySubaccountResponse_locked_balance, value) { + return + } + } + if len(x.UnlockedBalance) != 0 { + value := protoreflect.ValueOfList(&_QuerySubaccountResponse_4_list{list: &x.UnlockedBalance}) + if !f(fd_QuerySubaccountResponse_unlocked_balance, value) { + return + } + } + if x.WithdrawableUnlockedBalance != "" { + value := protoreflect.ValueOfString(x.WithdrawableUnlockedBalance) + if !f(fd_QuerySubaccountResponse_withdrawable_unlocked_balance, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QuerySubaccountResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.address": + return x.Address != "" + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.balance": + return x.Balance != nil + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.locked_balance": + return len(x.LockedBalance) != 0 + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.unlocked_balance": + return len(x.UnlockedBalance) != 0 + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.withdrawable_unlocked_balance": + return x.WithdrawableUnlockedBalance != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.address": + x.Address = "" + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.balance": + x.Balance = nil + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.locked_balance": + x.LockedBalance = nil + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.unlocked_balance": + x.UnlockedBalance = nil + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.withdrawable_unlocked_balance": + x.WithdrawableUnlockedBalance = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QuerySubaccountResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.balance": + value := x.Balance + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.locked_balance": + if len(x.LockedBalance) == 0 { + return protoreflect.ValueOfList(&_QuerySubaccountResponse_3_list{}) + } + listValue := &_QuerySubaccountResponse_3_list{list: &x.LockedBalance} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.unlocked_balance": + if len(x.UnlockedBalance) == 0 { + return protoreflect.ValueOfList(&_QuerySubaccountResponse_4_list{}) + } + listValue := &_QuerySubaccountResponse_4_list{list: &x.UnlockedBalance} + return protoreflect.ValueOfList(listValue) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.withdrawable_unlocked_balance": + value := x.WithdrawableUnlockedBalance + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.address": + x.Address = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.balance": + x.Balance = value.Message().Interface().(*AccountSummary) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.locked_balance": + lv := value.List() + clv := lv.(*_QuerySubaccountResponse_3_list) + x.LockedBalance = *clv.list + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.unlocked_balance": + lv := value.List() + clv := lv.(*_QuerySubaccountResponse_4_list) + x.UnlockedBalance = *clv.list + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.withdrawable_unlocked_balance": + x.WithdrawableUnlockedBalance = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.balance": + if x.Balance == nil { + x.Balance = new(AccountSummary) + } + return protoreflect.ValueOfMessage(x.Balance.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.locked_balance": + if x.LockedBalance == nil { + x.LockedBalance = []*LockedBalance{} + } + value := &_QuerySubaccountResponse_3_list{list: &x.LockedBalance} + return protoreflect.ValueOfList(value) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.unlocked_balance": + if x.UnlockedBalance == nil { + x.UnlockedBalance = []*LockedBalance{} + } + value := &_QuerySubaccountResponse_4_list{list: &x.UnlockedBalance} + return protoreflect.ValueOfList(value) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.address": + panic(fmt.Errorf("field address of message sge.legacy.subaccount.v1beta.QuerySubaccountResponse is not mutable")) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.withdrawable_unlocked_balance": + panic(fmt.Errorf("field withdrawable_unlocked_balance of message sge.legacy.subaccount.v1beta.QuerySubaccountResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QuerySubaccountResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.address": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.balance": + m := new(AccountSummary) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.locked_balance": + list := []*LockedBalance{} + return protoreflect.ValueOfList(&_QuerySubaccountResponse_3_list{list: &list}) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.unlocked_balance": + list := []*LockedBalance{} + return protoreflect.ValueOfList(&_QuerySubaccountResponse_4_list{list: &list}) + case "sge.legacy.subaccount.v1beta.QuerySubaccountResponse.withdrawable_unlocked_balance": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.QuerySubaccountResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.QuerySubaccountResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QuerySubaccountResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.QuerySubaccountResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QuerySubaccountResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QuerySubaccountResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QuerySubaccountResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QuerySubaccountResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QuerySubaccountResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Balance != nil { + l = options.Size(x.Balance) + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.LockedBalance) > 0 { + for _, e := range x.LockedBalance { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if len(x.UnlockedBalance) > 0 { + for _, e := range x.UnlockedBalance { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + l = len(x.WithdrawableUnlockedBalance) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QuerySubaccountResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.WithdrawableUnlockedBalance) > 0 { + i -= len(x.WithdrawableUnlockedBalance) + copy(dAtA[i:], x.WithdrawableUnlockedBalance) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.WithdrawableUnlockedBalance))) + i-- + dAtA[i] = 0x2a + } + if len(x.UnlockedBalance) > 0 { + for iNdEx := len(x.UnlockedBalance) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.UnlockedBalance[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x22 + } + } + if len(x.LockedBalance) > 0 { + for iNdEx := len(x.LockedBalance) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.LockedBalance[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if x.Balance != nil { + encoded, err := options.Marshal(x.Balance) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QuerySubaccountResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySubaccountResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QuerySubaccountResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Balance", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Balance == nil { + x.Balance = &AccountSummary{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Balance); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field LockedBalance", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.LockedBalance = append(x.LockedBalance, &LockedBalance{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.LockedBalance[len(x.LockedBalance)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field UnlockedBalance", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.UnlockedBalance = append(x.UnlockedBalance, &LockedBalance{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.UnlockedBalance[len(x.UnlockedBalance)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field WithdrawableUnlockedBalance", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.WithdrawableUnlockedBalance = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/subaccount/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is the request type for the Query/Params RPC method +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is the response type for the Query/Params RPC method +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QuerySubaccountRequest is the request type for the Query/Subaccount RPC +type QuerySubaccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` +} + +func (x *QuerySubaccountRequest) Reset() { + *x = QuerySubaccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QuerySubaccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QuerySubaccountRequest) ProtoMessage() {} + +// Deprecated: Use QuerySubaccountRequest.ProtoReflect.Descriptor instead. +func (*QuerySubaccountRequest) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +func (x *QuerySubaccountRequest) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +// QuerySubaccountResponse is the response type for the Query/Subaccount RPC +type QuerySubaccountResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + Balance *AccountSummary `protobuf:"bytes,2,opt,name=balance,proto3" json:"balance,omitempty"` + LockedBalance []*LockedBalance `protobuf:"bytes,3,rep,name=locked_balance,json=lockedBalance,proto3" json:"locked_balance,omitempty"` + UnlockedBalance []*LockedBalance `protobuf:"bytes,4,rep,name=unlocked_balance,json=unlockedBalance,proto3" json:"unlocked_balance,omitempty"` + WithdrawableUnlockedBalance string `protobuf:"bytes,5,opt,name=withdrawable_unlocked_balance,json=withdrawableUnlockedBalance,proto3" json:"withdrawable_unlocked_balance,omitempty"` +} + +func (x *QuerySubaccountResponse) Reset() { + *x = QuerySubaccountResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QuerySubaccountResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QuerySubaccountResponse) ProtoMessage() {} + +// Deprecated: Use QuerySubaccountResponse.ProtoReflect.Descriptor instead. +func (*QuerySubaccountResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QuerySubaccountResponse) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *QuerySubaccountResponse) GetBalance() *AccountSummary { + if x != nil { + return x.Balance + } + return nil +} + +func (x *QuerySubaccountResponse) GetLockedBalance() []*LockedBalance { + if x != nil { + return x.LockedBalance + } + return nil +} + +func (x *QuerySubaccountResponse) GetUnlockedBalance() []*LockedBalance { + if x != nil { + return x.UnlockedBalance + } + return nil +} + +func (x *QuerySubaccountResponse) GetWithdrawableUnlockedBalance() string { + if x != nil { + return x.WithdrawableUnlockedBalance + } + return "" +} + +var File_sge_legacy_subaccount_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_legacy_subaccount_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x28, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1c, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, + 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, + 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x2a, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x29, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, + 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x14, + 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x22, 0x59, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, + 0x32, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x22, 0xb6, 0x03, 0x0a, 0x17, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x12, 0x4c, 0x0a, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, + 0x72, 0x79, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, + 0x65, 0x12, 0x58, 0x0a, 0x0e, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x62, 0x61, 0x6c, 0x61, + 0x6e, 0x63, 0x65, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, + 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0d, 0x6c, 0x6f, + 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x5c, 0x0a, 0x10, 0x75, + 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x18, + 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, + 0x63, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0f, 0x75, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, + 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x61, 0x0a, 0x1d, 0x77, 0x69, 0x74, + 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x75, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, + 0x65, 0x64, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, + 0x1b, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x62, 0x6c, 0x65, 0x55, 0x6e, 0x6c, + 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x32, 0xc1, 0x02, 0x0a, + 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0xa7, 0x01, 0x0a, 0x0a, 0x53, 0x75, 0x62, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x34, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x35, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x2c, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x73, 0x67, 0x65, + 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x73, 0x75, 0x62, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x7b, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x7d, + 0x12, 0x8d, 0x01, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x30, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x31, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x1e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18, 0x12, 0x16, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x73, + 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x42, 0x8f, 0x02, 0x0a, 0x20, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x4c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, + 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x3b, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x53, 0xaa, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2e, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1c, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x28, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x1f, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, + 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_subaccount_v1beta_query_proto_rawDescOnce sync.Once + file_sge_legacy_subaccount_v1beta_query_proto_rawDescData = file_sge_legacy_subaccount_v1beta_query_proto_rawDesc +) + +func file_sge_legacy_subaccount_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_legacy_subaccount_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_legacy_subaccount_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_subaccount_v1beta_query_proto_rawDescData) + }) + return file_sge_legacy_subaccount_v1beta_query_proto_rawDescData +} + +var file_sge_legacy_subaccount_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 4) +var file_sge_legacy_subaccount_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.legacy.subaccount.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.legacy.subaccount.v1beta.QueryParamsResponse + (*QuerySubaccountRequest)(nil), // 2: sge.legacy.subaccount.v1beta.QuerySubaccountRequest + (*QuerySubaccountResponse)(nil), // 3: sge.legacy.subaccount.v1beta.QuerySubaccountResponse + (*Params)(nil), // 4: sge.legacy.subaccount.v1beta.Params + (*AccountSummary)(nil), // 5: sge.legacy.subaccount.v1beta.AccountSummary + (*LockedBalance)(nil), // 6: sge.legacy.subaccount.v1beta.LockedBalance +} +var file_sge_legacy_subaccount_v1beta_query_proto_depIdxs = []int32{ + 4, // 0: sge.legacy.subaccount.v1beta.QueryParamsResponse.params:type_name -> sge.legacy.subaccount.v1beta.Params + 5, // 1: sge.legacy.subaccount.v1beta.QuerySubaccountResponse.balance:type_name -> sge.legacy.subaccount.v1beta.AccountSummary + 6, // 2: sge.legacy.subaccount.v1beta.QuerySubaccountResponse.locked_balance:type_name -> sge.legacy.subaccount.v1beta.LockedBalance + 6, // 3: sge.legacy.subaccount.v1beta.QuerySubaccountResponse.unlocked_balance:type_name -> sge.legacy.subaccount.v1beta.LockedBalance + 2, // 4: sge.legacy.subaccount.v1beta.Query.Subaccount:input_type -> sge.legacy.subaccount.v1beta.QuerySubaccountRequest + 0, // 5: sge.legacy.subaccount.v1beta.Query.Params:input_type -> sge.legacy.subaccount.v1beta.QueryParamsRequest + 3, // 6: sge.legacy.subaccount.v1beta.Query.Subaccount:output_type -> sge.legacy.subaccount.v1beta.QuerySubaccountResponse + 1, // 7: sge.legacy.subaccount.v1beta.Query.Params:output_type -> sge.legacy.subaccount.v1beta.QueryParamsResponse + 6, // [6:8] is the sub-list for method output_type + 4, // [4:6] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_sge_legacy_subaccount_v1beta_query_proto_init() } +func file_sge_legacy_subaccount_v1beta_query_proto_init() { + if File_sge_legacy_subaccount_v1beta_query_proto != nil { + return + } + file_sge_legacy_subaccount_v1beta_balance_proto_init() + file_sge_legacy_subaccount_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QuerySubaccountRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QuerySubaccountResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_subaccount_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 4, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_subaccount_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_legacy_subaccount_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_legacy_subaccount_v1beta_query_proto_msgTypes, + }.Build() + File_sge_legacy_subaccount_v1beta_query_proto = out.File + file_sge_legacy_subaccount_v1beta_query_proto_rawDesc = nil + file_sge_legacy_subaccount_v1beta_query_proto_goTypes = nil + file_sge_legacy_subaccount_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/legacy/subaccount/v1beta/query_grpc.pb.go b/api/sge/legacy/subaccount/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..d056f139 --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/query_grpc.pb.go @@ -0,0 +1,150 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/subaccount/v1beta/query.proto + +package subaccountv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Subaccount_FullMethodName = "/sge.legacy.subaccount.v1beta.Query/Subaccount" + Query_Params_FullMethodName = "/sge.legacy.subaccount.v1beta.Query/Params" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Subaccount fetches a subaccount given the owner. + Subaccount(ctx context.Context, in *QuerySubaccountRequest, opts ...grpc.CallOption) (*QuerySubaccountResponse, error) + // Params returns the subaccount module parameters. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Subaccount(ctx context.Context, in *QuerySubaccountRequest, opts ...grpc.CallOption) (*QuerySubaccountResponse, error) { + out := new(QuerySubaccountResponse) + err := c.cc.Invoke(ctx, Query_Subaccount_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Subaccount fetches a subaccount given the owner. + Subaccount(context.Context, *QuerySubaccountRequest) (*QuerySubaccountResponse, error) + // Params returns the subaccount module parameters. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Subaccount(context.Context, *QuerySubaccountRequest) (*QuerySubaccountResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Subaccount not implemented") +} +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Subaccount_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QuerySubaccountRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Subaccount(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Subaccount_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Subaccount(ctx, req.(*QuerySubaccountRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.subaccount.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Subaccount", + Handler: _Query_Subaccount_Handler, + }, + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/subaccount/v1beta/query.proto", +} diff --git a/api/sge/legacy/subaccount/v1beta/ticket.pulsar.go b/api/sge/legacy/subaccount/v1beta/ticket.pulsar.go new file mode 100644 index 00000000..2bbf55f1 --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/ticket.pulsar.go @@ -0,0 +1,757 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package subaccountv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + v1beta "github.com/sge-network/sge/api/sge/legacy/bet/v1beta" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_SubAccWagerTicketPayload protoreflect.MessageDescriptor + fd_SubAccWagerTicketPayload_msg protoreflect.FieldDescriptor + fd_SubAccWagerTicketPayload_mainacc_deduct_amount protoreflect.FieldDescriptor + fd_SubAccWagerTicketPayload_subacc_deduct_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_ticket_proto_init() + md_SubAccWagerTicketPayload = File_sge_legacy_subaccount_v1beta_ticket_proto.Messages().ByName("SubAccWagerTicketPayload") + fd_SubAccWagerTicketPayload_msg = md_SubAccWagerTicketPayload.Fields().ByName("msg") + fd_SubAccWagerTicketPayload_mainacc_deduct_amount = md_SubAccWagerTicketPayload.Fields().ByName("mainacc_deduct_amount") + fd_SubAccWagerTicketPayload_subacc_deduct_amount = md_SubAccWagerTicketPayload.Fields().ByName("subacc_deduct_amount") +} + +var _ protoreflect.Message = (*fastReflection_SubAccWagerTicketPayload)(nil) + +type fastReflection_SubAccWagerTicketPayload SubAccWagerTicketPayload + +func (x *SubAccWagerTicketPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_SubAccWagerTicketPayload)(x) +} + +func (x *SubAccWagerTicketPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_ticket_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_SubAccWagerTicketPayload_messageType fastReflection_SubAccWagerTicketPayload_messageType +var _ protoreflect.MessageType = fastReflection_SubAccWagerTicketPayload_messageType{} + +type fastReflection_SubAccWagerTicketPayload_messageType struct{} + +func (x fastReflection_SubAccWagerTicketPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_SubAccWagerTicketPayload)(nil) +} +func (x fastReflection_SubAccWagerTicketPayload_messageType) New() protoreflect.Message { + return new(fastReflection_SubAccWagerTicketPayload) +} +func (x fastReflection_SubAccWagerTicketPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_SubAccWagerTicketPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_SubAccWagerTicketPayload) Descriptor() protoreflect.MessageDescriptor { + return md_SubAccWagerTicketPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_SubAccWagerTicketPayload) Type() protoreflect.MessageType { + return _fastReflection_SubAccWagerTicketPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_SubAccWagerTicketPayload) New() protoreflect.Message { + return new(fastReflection_SubAccWagerTicketPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_SubAccWagerTicketPayload) Interface() protoreflect.ProtoMessage { + return (*SubAccWagerTicketPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_SubAccWagerTicketPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Msg != nil { + value := protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + if !f(fd_SubAccWagerTicketPayload_msg, value) { + return + } + } + if x.MainaccDeductAmount != "" { + value := protoreflect.ValueOfString(x.MainaccDeductAmount) + if !f(fd_SubAccWagerTicketPayload_mainacc_deduct_amount, value) { + return + } + } + if x.SubaccDeductAmount != "" { + value := protoreflect.ValueOfString(x.SubaccDeductAmount) + if !f(fd_SubAccWagerTicketPayload_subacc_deduct_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_SubAccWagerTicketPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.msg": + return x.Msg != nil + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.mainacc_deduct_amount": + return x.MainaccDeductAmount != "" + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.subacc_deduct_amount": + return x.SubaccDeductAmount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SubAccWagerTicketPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.msg": + x.Msg = nil + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.mainacc_deduct_amount": + x.MainaccDeductAmount = "" + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.subacc_deduct_amount": + x.SubaccDeductAmount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_SubAccWagerTicketPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.msg": + value := x.Msg + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.mainacc_deduct_amount": + value := x.MainaccDeductAmount + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.subacc_deduct_amount": + value := x.SubaccDeductAmount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SubAccWagerTicketPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.msg": + x.Msg = value.Message().Interface().(*v1beta.MsgWager) + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.mainacc_deduct_amount": + x.MainaccDeductAmount = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.subacc_deduct_amount": + x.SubaccDeductAmount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SubAccWagerTicketPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.msg": + if x.Msg == nil { + x.Msg = new(v1beta.MsgWager) + } + return protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.mainacc_deduct_amount": + panic(fmt.Errorf("field mainacc_deduct_amount of message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload is not mutable")) + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.subacc_deduct_amount": + panic(fmt.Errorf("field subacc_deduct_amount of message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_SubAccWagerTicketPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.msg": + m := new(v1beta.MsgWager) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.mainacc_deduct_amount": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.subacc_deduct_amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_SubAccWagerTicketPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_SubAccWagerTicketPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_SubAccWagerTicketPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_SubAccWagerTicketPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_SubAccWagerTicketPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*SubAccWagerTicketPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Msg != nil { + l = options.Size(x.Msg) + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.MainaccDeductAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.SubaccDeductAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*SubAccWagerTicketPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.SubaccDeductAmount) > 0 { + i -= len(x.SubaccDeductAmount) + copy(dAtA[i:], x.SubaccDeductAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SubaccDeductAmount))) + i-- + dAtA[i] = 0x1a + } + if len(x.MainaccDeductAmount) > 0 { + i -= len(x.MainaccDeductAmount) + copy(dAtA[i:], x.MainaccDeductAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MainaccDeductAmount))) + i-- + dAtA[i] = 0x12 + } + if x.Msg != nil { + encoded, err := options.Marshal(x.Msg) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*SubAccWagerTicketPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SubAccWagerTicketPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: SubAccWagerTicketPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Msg == nil { + x.Msg = &v1beta.MsgWager{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Msg); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MainaccDeductAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MainaccDeductAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SubaccDeductAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.SubaccDeductAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/subaccount/v1beta/ticket.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// SubAccWagerTicketPayload indicates data of subaccount wager ticket. +type SubAccWagerTicketPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // msg holds normal wager message + Msg *v1beta.MsgWager `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"` + // mainacc_deduct_amount is amount to be deducted from main account + MainaccDeductAmount string `protobuf:"bytes,2,opt,name=mainacc_deduct_amount,json=mainaccDeductAmount,proto3" json:"mainacc_deduct_amount,omitempty"` + // subacc_deduct_amount is amount to be deducted from sub account + SubaccDeductAmount string `protobuf:"bytes,3,opt,name=subacc_deduct_amount,json=subaccDeductAmount,proto3" json:"subacc_deduct_amount,omitempty"` +} + +func (x *SubAccWagerTicketPayload) Reset() { + *x = SubAccWagerTicketPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_ticket_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SubAccWagerTicketPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SubAccWagerTicketPayload) ProtoMessage() {} + +// Deprecated: Use SubAccWagerTicketPayload.ProtoReflect.Descriptor instead. +func (*SubAccWagerTicketPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescGZIP(), []int{0} +} + +func (x *SubAccWagerTicketPayload) GetMsg() *v1beta.MsgWager { + if x != nil { + return x.Msg + } + return nil +} + +func (x *SubAccWagerTicketPayload) GetMainaccDeductAmount() string { + if x != nil { + return x.MainaccDeductAmount + } + return "" +} + +func (x *SubAccWagerTicketPayload) GetSubaccDeductAmount() string { + if x != nil { + return x.SubaccDeductAmount + } + return "" +} + +var File_sge_legacy_subaccount_v1beta_ticket_proto protoreflect.FileDescriptor + +var file_sge_legacy_subaccount_v1beta_ticket_proto_rawDesc = []byte{ + 0x0a, 0x29, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, + 0x69, 0x63, 0x6b, 0x65, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1c, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, + 0x1e, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, 0x65, 0x74, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, + 0xf1, 0x01, 0x0a, 0x18, 0x53, 0x75, 0x62, 0x41, 0x63, 0x63, 0x57, 0x61, 0x67, 0x65, 0x72, 0x54, + 0x69, 0x63, 0x6b, 0x65, 0x74, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x31, 0x0a, 0x03, + 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x61, 0x67, 0x65, 0x72, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, + 0x51, 0x0a, 0x15, 0x6d, 0x61, 0x69, 0x6e, 0x61, 0x63, 0x63, 0x5f, 0x64, 0x65, 0x64, 0x75, 0x63, + 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1d, + 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x13, 0x6d, + 0x61, 0x69, 0x6e, 0x61, 0x63, 0x63, 0x44, 0x65, 0x64, 0x75, 0x63, 0x74, 0x41, 0x6d, 0x6f, 0x75, + 0x6e, 0x74, 0x12, 0x4f, 0x0a, 0x14, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x5f, 0x64, 0x65, 0x64, + 0x75, 0x63, 0x74, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0x52, + 0x12, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x44, 0x65, 0x64, 0x75, 0x63, 0x74, 0x41, 0x6d, 0x6f, + 0x75, 0x6e, 0x74, 0x42, 0x90, 0x02, 0x0a, 0x20, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x54, 0x69, 0x63, 0x6b, 0x65, 0x74, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, + 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x3b, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x53, 0xaa, 0x02, 0x1c, 0x53, 0x67, + 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1c, 0x53, 0x67, 0x65, + 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x28, 0x53, 0x67, 0x65, 0x5c, + 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1f, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x3a, 0x3a, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x3a, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescOnce sync.Once + file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescData = file_sge_legacy_subaccount_v1beta_ticket_proto_rawDesc +) + +func file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescGZIP() []byte { + file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescOnce.Do(func() { + file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescData) + }) + return file_sge_legacy_subaccount_v1beta_ticket_proto_rawDescData +} + +var file_sge_legacy_subaccount_v1beta_ticket_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_subaccount_v1beta_ticket_proto_goTypes = []interface{}{ + (*SubAccWagerTicketPayload)(nil), // 0: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload + (*v1beta.MsgWager)(nil), // 1: sge.legacy.bet.v1beta.MsgWager +} +var file_sge_legacy_subaccount_v1beta_ticket_proto_depIdxs = []int32{ + 1, // 0: sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload.msg:type_name -> sge.legacy.bet.v1beta.MsgWager + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_legacy_subaccount_v1beta_ticket_proto_init() } +func file_sge_legacy_subaccount_v1beta_ticket_proto_init() { + if File_sge_legacy_subaccount_v1beta_ticket_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_subaccount_v1beta_ticket_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SubAccWagerTicketPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_subaccount_v1beta_ticket_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_subaccount_v1beta_ticket_proto_goTypes, + DependencyIndexes: file_sge_legacy_subaccount_v1beta_ticket_proto_depIdxs, + MessageInfos: file_sge_legacy_subaccount_v1beta_ticket_proto_msgTypes, + }.Build() + File_sge_legacy_subaccount_v1beta_ticket_proto = out.File + file_sge_legacy_subaccount_v1beta_ticket_proto_rawDesc = nil + file_sge_legacy_subaccount_v1beta_ticket_proto_goTypes = nil + file_sge_legacy_subaccount_v1beta_ticket_proto_depIdxs = nil +} diff --git a/api/sge/legacy/subaccount/v1beta/tx.pulsar.go b/api/sge/legacy/subaccount/v1beta/tx.pulsar.go new file mode 100644 index 00000000..193b97ad --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/tx.pulsar.go @@ -0,0 +1,7265 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package subaccountv1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + v1beta "github.com/sge-network/sge/api/sge/legacy/bet/v1beta" + v1beta1 "github.com/sge-network/sge/api/sge/legacy/house/v1beta" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_MsgCreate_3_list)(nil) + +type _MsgCreate_3_list struct { + list *[]*LockedBalance +} + +func (x *_MsgCreate_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_MsgCreate_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_MsgCreate_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + (*x.list)[i] = concreteValue +} + +func (x *_MsgCreate_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + *x.list = append(*x.list, concreteValue) +} + +func (x *_MsgCreate_3_list) AppendMutable() protoreflect.Value { + v := new(LockedBalance) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_MsgCreate_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_MsgCreate_3_list) NewElement() protoreflect.Value { + v := new(LockedBalance) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_MsgCreate_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_MsgCreate protoreflect.MessageDescriptor + fd_MsgCreate_creator protoreflect.FieldDescriptor + fd_MsgCreate_owner protoreflect.FieldDescriptor + fd_MsgCreate_locked_balances protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgCreate = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgCreate") + fd_MsgCreate_creator = md_MsgCreate.Fields().ByName("creator") + fd_MsgCreate_owner = md_MsgCreate.Fields().ByName("owner") + fd_MsgCreate_locked_balances = md_MsgCreate.Fields().ByName("locked_balances") +} + +var _ protoreflect.Message = (*fastReflection_MsgCreate)(nil) + +type fastReflection_MsgCreate MsgCreate + +func (x *MsgCreate) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgCreate)(x) +} + +func (x *MsgCreate) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgCreate_messageType fastReflection_MsgCreate_messageType +var _ protoreflect.MessageType = fastReflection_MsgCreate_messageType{} + +type fastReflection_MsgCreate_messageType struct{} + +func (x fastReflection_MsgCreate_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgCreate)(nil) +} +func (x fastReflection_MsgCreate_messageType) New() protoreflect.Message { + return new(fastReflection_MsgCreate) +} +func (x fastReflection_MsgCreate_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreate +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgCreate) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreate +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgCreate) Type() protoreflect.MessageType { + return _fastReflection_MsgCreate_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgCreate) New() protoreflect.Message { + return new(fastReflection_MsgCreate) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgCreate) Interface() protoreflect.ProtoMessage { + return (*MsgCreate)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgCreate) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgCreate_creator, value) { + return + } + } + if x.Owner != "" { + value := protoreflect.ValueOfString(x.Owner) + if !f(fd_MsgCreate_owner, value) { + return + } + } + if len(x.LockedBalances) != 0 { + value := protoreflect.ValueOfList(&_MsgCreate_3_list{list: &x.LockedBalances}) + if !f(fd_MsgCreate_locked_balances, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgCreate) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgCreate.creator": + return x.Creator != "" + case "sge.legacy.subaccount.v1beta.MsgCreate.owner": + return x.Owner != "" + case "sge.legacy.subaccount.v1beta.MsgCreate.locked_balances": + return len(x.LockedBalances) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreate")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreate does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreate) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgCreate.creator": + x.Creator = "" + case "sge.legacy.subaccount.v1beta.MsgCreate.owner": + x.Owner = "" + case "sge.legacy.subaccount.v1beta.MsgCreate.locked_balances": + x.LockedBalances = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreate")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreate does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgCreate) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgCreate.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.MsgCreate.owner": + value := x.Owner + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.MsgCreate.locked_balances": + if len(x.LockedBalances) == 0 { + return protoreflect.ValueOfList(&_MsgCreate_3_list{}) + } + listValue := &_MsgCreate_3_list{list: &x.LockedBalances} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreate")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreate does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreate) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgCreate.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.MsgCreate.owner": + x.Owner = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.MsgCreate.locked_balances": + lv := value.List() + clv := lv.(*_MsgCreate_3_list) + x.LockedBalances = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreate")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreate does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreate) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgCreate.locked_balances": + if x.LockedBalances == nil { + x.LockedBalances = []*LockedBalance{} + } + value := &_MsgCreate_3_list{list: &x.LockedBalances} + return protoreflect.ValueOfList(value) + case "sge.legacy.subaccount.v1beta.MsgCreate.creator": + panic(fmt.Errorf("field creator of message sge.legacy.subaccount.v1beta.MsgCreate is not mutable")) + case "sge.legacy.subaccount.v1beta.MsgCreate.owner": + panic(fmt.Errorf("field owner of message sge.legacy.subaccount.v1beta.MsgCreate is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreate")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreate does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgCreate) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgCreate.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.MsgCreate.owner": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.MsgCreate.locked_balances": + list := []*LockedBalance{} + return protoreflect.ValueOfList(&_MsgCreate_3_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreate")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreate does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgCreate) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgCreate", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgCreate) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreate) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgCreate) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgCreate) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgCreate) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Owner) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.LockedBalances) > 0 { + for _, e := range x.LockedBalances { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgCreate) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.LockedBalances) > 0 { + for iNdEx := len(x.LockedBalances) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.LockedBalances[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if len(x.Owner) > 0 { + i -= len(x.Owner) + copy(dAtA[i:], x.Owner) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Owner))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgCreate) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreate: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreate: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Owner", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Owner = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field LockedBalances", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.LockedBalances = append(x.LockedBalances, &LockedBalance{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.LockedBalances[len(x.LockedBalances)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgCreateResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgCreateResponse = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgCreateResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgCreateResponse)(nil) + +type fastReflection_MsgCreateResponse MsgCreateResponse + +func (x *MsgCreateResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgCreateResponse)(x) +} + +func (x *MsgCreateResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgCreateResponse_messageType fastReflection_MsgCreateResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgCreateResponse_messageType{} + +type fastReflection_MsgCreateResponse_messageType struct{} + +func (x fastReflection_MsgCreateResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgCreateResponse)(nil) +} +func (x fastReflection_MsgCreateResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgCreateResponse) +} +func (x fastReflection_MsgCreateResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreateResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgCreateResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgCreateResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgCreateResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgCreateResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgCreateResponse) New() protoreflect.Message { + return new(fastReflection_MsgCreateResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgCreateResponse) Interface() protoreflect.ProtoMessage { + return (*MsgCreateResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgCreateResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgCreateResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreateResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreateResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreateResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreateResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgCreateResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreateResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreateResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreateResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreateResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreateResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreateResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgCreateResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgCreateResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgCreateResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgCreateResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgCreateResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgCreateResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgCreateResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgCreateResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgCreateResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgCreateResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgCreateResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgCreateResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreateResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgCreateResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var _ protoreflect.List = (*_MsgTopUp_3_list)(nil) + +type _MsgTopUp_3_list struct { + list *[]*LockedBalance +} + +func (x *_MsgTopUp_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_MsgTopUp_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_MsgTopUp_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + (*x.list)[i] = concreteValue +} + +func (x *_MsgTopUp_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*LockedBalance) + *x.list = append(*x.list, concreteValue) +} + +func (x *_MsgTopUp_3_list) AppendMutable() protoreflect.Value { + v := new(LockedBalance) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_MsgTopUp_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_MsgTopUp_3_list) NewElement() protoreflect.Value { + v := new(LockedBalance) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_MsgTopUp_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_MsgTopUp protoreflect.MessageDescriptor + fd_MsgTopUp_creator protoreflect.FieldDescriptor + fd_MsgTopUp_address protoreflect.FieldDescriptor + fd_MsgTopUp_locked_balances protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgTopUp = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgTopUp") + fd_MsgTopUp_creator = md_MsgTopUp.Fields().ByName("creator") + fd_MsgTopUp_address = md_MsgTopUp.Fields().ByName("address") + fd_MsgTopUp_locked_balances = md_MsgTopUp.Fields().ByName("locked_balances") +} + +var _ protoreflect.Message = (*fastReflection_MsgTopUp)(nil) + +type fastReflection_MsgTopUp MsgTopUp + +func (x *MsgTopUp) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgTopUp)(x) +} + +func (x *MsgTopUp) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgTopUp_messageType fastReflection_MsgTopUp_messageType +var _ protoreflect.MessageType = fastReflection_MsgTopUp_messageType{} + +type fastReflection_MsgTopUp_messageType struct{} + +func (x fastReflection_MsgTopUp_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgTopUp)(nil) +} +func (x fastReflection_MsgTopUp_messageType) New() protoreflect.Message { + return new(fastReflection_MsgTopUp) +} +func (x fastReflection_MsgTopUp_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgTopUp +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgTopUp) Descriptor() protoreflect.MessageDescriptor { + return md_MsgTopUp +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgTopUp) Type() protoreflect.MessageType { + return _fastReflection_MsgTopUp_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgTopUp) New() protoreflect.Message { + return new(fastReflection_MsgTopUp) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgTopUp) Interface() protoreflect.ProtoMessage { + return (*MsgTopUp)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgTopUp) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgTopUp_creator, value) { + return + } + } + if x.Address != "" { + value := protoreflect.ValueOfString(x.Address) + if !f(fd_MsgTopUp_address, value) { + return + } + } + if len(x.LockedBalances) != 0 { + value := protoreflect.ValueOfList(&_MsgTopUp_3_list{list: &x.LockedBalances}) + if !f(fd_MsgTopUp_locked_balances, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgTopUp) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgTopUp.creator": + return x.Creator != "" + case "sge.legacy.subaccount.v1beta.MsgTopUp.address": + return x.Address != "" + case "sge.legacy.subaccount.v1beta.MsgTopUp.locked_balances": + return len(x.LockedBalances) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUp")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUp does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUp) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgTopUp.creator": + x.Creator = "" + case "sge.legacy.subaccount.v1beta.MsgTopUp.address": + x.Address = "" + case "sge.legacy.subaccount.v1beta.MsgTopUp.locked_balances": + x.LockedBalances = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUp")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUp does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgTopUp) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgTopUp.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.MsgTopUp.address": + value := x.Address + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.MsgTopUp.locked_balances": + if len(x.LockedBalances) == 0 { + return protoreflect.ValueOfList(&_MsgTopUp_3_list{}) + } + listValue := &_MsgTopUp_3_list{list: &x.LockedBalances} + return protoreflect.ValueOfList(listValue) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUp")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUp does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUp) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgTopUp.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.MsgTopUp.address": + x.Address = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.MsgTopUp.locked_balances": + lv := value.List() + clv := lv.(*_MsgTopUp_3_list) + x.LockedBalances = *clv.list + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUp")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUp does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUp) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgTopUp.locked_balances": + if x.LockedBalances == nil { + x.LockedBalances = []*LockedBalance{} + } + value := &_MsgTopUp_3_list{list: &x.LockedBalances} + return protoreflect.ValueOfList(value) + case "sge.legacy.subaccount.v1beta.MsgTopUp.creator": + panic(fmt.Errorf("field creator of message sge.legacy.subaccount.v1beta.MsgTopUp is not mutable")) + case "sge.legacy.subaccount.v1beta.MsgTopUp.address": + panic(fmt.Errorf("field address of message sge.legacy.subaccount.v1beta.MsgTopUp is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUp")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUp does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgTopUp) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgTopUp.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.MsgTopUp.address": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.MsgTopUp.locked_balances": + list := []*LockedBalance{} + return protoreflect.ValueOfList(&_MsgTopUp_3_list{list: &list}) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUp")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUp does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgTopUp) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgTopUp", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgTopUp) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUp) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgTopUp) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgTopUp) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgTopUp) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Address) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if len(x.LockedBalances) > 0 { + for _, e := range x.LockedBalances { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgTopUp) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.LockedBalances) > 0 { + for iNdEx := len(x.LockedBalances) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.LockedBalances[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if len(x.Address) > 0 { + i -= len(x.Address) + copy(dAtA[i:], x.Address) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgTopUp) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgTopUp: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgTopUp: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field LockedBalances", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.LockedBalances = append(x.LockedBalances, &LockedBalance{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.LockedBalances[len(x.LockedBalances)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgTopUpResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgTopUpResponse = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgTopUpResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgTopUpResponse)(nil) + +type fastReflection_MsgTopUpResponse MsgTopUpResponse + +func (x *MsgTopUpResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgTopUpResponse)(x) +} + +func (x *MsgTopUpResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgTopUpResponse_messageType fastReflection_MsgTopUpResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgTopUpResponse_messageType{} + +type fastReflection_MsgTopUpResponse_messageType struct{} + +func (x fastReflection_MsgTopUpResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgTopUpResponse)(nil) +} +func (x fastReflection_MsgTopUpResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgTopUpResponse) +} +func (x fastReflection_MsgTopUpResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgTopUpResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgTopUpResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgTopUpResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgTopUpResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgTopUpResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgTopUpResponse) New() protoreflect.Message { + return new(fastReflection_MsgTopUpResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgTopUpResponse) Interface() protoreflect.ProtoMessage { + return (*MsgTopUpResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgTopUpResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgTopUpResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUpResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUpResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUpResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUpResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUpResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgTopUpResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUpResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUpResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUpResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUpResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUpResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUpResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUpResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUpResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgTopUpResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgTopUpResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgTopUpResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgTopUpResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgTopUpResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgTopUpResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgTopUpResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgTopUpResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgTopUpResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgTopUpResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgTopUpResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgTopUpResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgTopUpResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgTopUpResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdrawUnlockedBalances protoreflect.MessageDescriptor + fd_MsgWithdrawUnlockedBalances_creator protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgWithdrawUnlockedBalances = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgWithdrawUnlockedBalances") + fd_MsgWithdrawUnlockedBalances_creator = md_MsgWithdrawUnlockedBalances.Fields().ByName("creator") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdrawUnlockedBalances)(nil) + +type fastReflection_MsgWithdrawUnlockedBalances MsgWithdrawUnlockedBalances + +func (x *MsgWithdrawUnlockedBalances) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdrawUnlockedBalances)(x) +} + +func (x *MsgWithdrawUnlockedBalances) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdrawUnlockedBalances_messageType fastReflection_MsgWithdrawUnlockedBalances_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdrawUnlockedBalances_messageType{} + +type fastReflection_MsgWithdrawUnlockedBalances_messageType struct{} + +func (x fastReflection_MsgWithdrawUnlockedBalances_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdrawUnlockedBalances)(nil) +} +func (x fastReflection_MsgWithdrawUnlockedBalances_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawUnlockedBalances) +} +func (x fastReflection_MsgWithdrawUnlockedBalances_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawUnlockedBalances +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawUnlockedBalances +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdrawUnlockedBalances_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdrawUnlockedBalances) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawUnlockedBalances) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Interface() protoreflect.ProtoMessage { + return (*MsgWithdrawUnlockedBalances)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgWithdrawUnlockedBalances_creator, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances.creator": + return x.Creator != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances.creator": + x.Creator = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances.creator": + x.Creator = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalances) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances.creator": + panic(fmt.Errorf("field creator of message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdrawUnlockedBalances) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances.creator": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdrawUnlockedBalances) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdrawUnlockedBalances) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalances) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdrawUnlockedBalances) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdrawUnlockedBalances) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdrawUnlockedBalances) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawUnlockedBalances) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawUnlockedBalances) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawUnlockedBalances: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawUnlockedBalances: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWithdrawUnlockedBalancesResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgWithdrawUnlockedBalancesResponse = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgWithdrawUnlockedBalancesResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgWithdrawUnlockedBalancesResponse)(nil) + +type fastReflection_MsgWithdrawUnlockedBalancesResponse MsgWithdrawUnlockedBalancesResponse + +func (x *MsgWithdrawUnlockedBalancesResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWithdrawUnlockedBalancesResponse)(x) +} + +func (x *MsgWithdrawUnlockedBalancesResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType{} + +type fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType struct{} + +func (x fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWithdrawUnlockedBalancesResponse)(nil) +} +func (x fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawUnlockedBalancesResponse) +} +func (x fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawUnlockedBalancesResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWithdrawUnlockedBalancesResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgWithdrawUnlockedBalancesResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) New() protoreflect.Message { + return new(fastReflection_MsgWithdrawUnlockedBalancesResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Interface() protoreflect.ProtoMessage { + return (*MsgWithdrawUnlockedBalancesResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWithdrawUnlockedBalancesResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWithdrawUnlockedBalancesResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawUnlockedBalancesResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWithdrawUnlockedBalancesResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawUnlockedBalancesResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWithdrawUnlockedBalancesResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWager protoreflect.MessageDescriptor + fd_MsgWager_creator protoreflect.FieldDescriptor + fd_MsgWager_ticket protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgWager = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgWager") + fd_MsgWager_creator = md_MsgWager.Fields().ByName("creator") + fd_MsgWager_ticket = md_MsgWager.Fields().ByName("ticket") +} + +var _ protoreflect.Message = (*fastReflection_MsgWager)(nil) + +type fastReflection_MsgWager MsgWager + +func (x *MsgWager) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWager)(x) +} + +func (x *MsgWager) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWager_messageType fastReflection_MsgWager_messageType +var _ protoreflect.MessageType = fastReflection_MsgWager_messageType{} + +type fastReflection_MsgWager_messageType struct{} + +func (x fastReflection_MsgWager_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWager)(nil) +} +func (x fastReflection_MsgWager_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWager) +} +func (x fastReflection_MsgWager_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWager +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWager) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWager +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWager) Type() protoreflect.MessageType { + return _fastReflection_MsgWager_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWager) New() protoreflect.Message { + return new(fastReflection_MsgWager) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWager) Interface() protoreflect.ProtoMessage { + return (*MsgWager)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWager) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Creator != "" { + value := protoreflect.ValueOfString(x.Creator) + if !f(fd_MsgWager_creator, value) { + return + } + } + if x.Ticket != "" { + value := protoreflect.ValueOfString(x.Ticket) + if !f(fd_MsgWager_ticket, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWager) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWager.creator": + return x.Creator != "" + case "sge.legacy.subaccount.v1beta.MsgWager.ticket": + return x.Ticket != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWager.creator": + x.Creator = "" + case "sge.legacy.subaccount.v1beta.MsgWager.ticket": + x.Ticket = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWager) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWager.creator": + value := x.Creator + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.MsgWager.ticket": + value := x.Ticket + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWager does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWager.creator": + x.Creator = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.MsgWager.ticket": + x.Ticket = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWager.creator": + panic(fmt.Errorf("field creator of message sge.legacy.subaccount.v1beta.MsgWager is not mutable")) + case "sge.legacy.subaccount.v1beta.MsgWager.ticket": + panic(fmt.Errorf("field ticket of message sge.legacy.subaccount.v1beta.MsgWager is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWager) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWager.creator": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.MsgWager.ticket": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWager")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWager does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWager) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgWager", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWager) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWager) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWager) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWager) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWager) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Creator) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Ticket) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWager) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Ticket) > 0 { + i -= len(x.Ticket) + copy(dAtA[i:], x.Ticket) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Ticket))) + i-- + dAtA[i] = 0x12 + } + if len(x.Creator) > 0 { + i -= len(x.Creator) + copy(dAtA[i:], x.Creator) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Creator))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWager) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWager: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWager: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Ticket = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgWagerResponse protoreflect.MessageDescriptor + fd_MsgWagerResponse_response protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgWagerResponse = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgWagerResponse") + fd_MsgWagerResponse_response = md_MsgWagerResponse.Fields().ByName("response") +} + +var _ protoreflect.Message = (*fastReflection_MsgWagerResponse)(nil) + +type fastReflection_MsgWagerResponse MsgWagerResponse + +func (x *MsgWagerResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgWagerResponse)(x) +} + +func (x *MsgWagerResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgWagerResponse_messageType fastReflection_MsgWagerResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgWagerResponse_messageType{} + +type fastReflection_MsgWagerResponse_messageType struct{} + +func (x fastReflection_MsgWagerResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgWagerResponse)(nil) +} +func (x fastReflection_MsgWagerResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgWagerResponse) +} +func (x fastReflection_MsgWagerResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWagerResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgWagerResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgWagerResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgWagerResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgWagerResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgWagerResponse) New() protoreflect.Message { + return new(fastReflection_MsgWagerResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgWagerResponse) Interface() protoreflect.ProtoMessage { + return (*MsgWagerResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgWagerResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Response != nil { + value := protoreflect.ValueOfMessage(x.Response.ProtoReflect()) + if !f(fd_MsgWagerResponse_response, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgWagerResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWagerResponse.response": + return x.Response != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWagerResponse.response": + x.Response = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgWagerResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWagerResponse.response": + value := x.Response + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWagerResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWagerResponse.response": + x.Response = value.Message().Interface().(*v1beta.MsgWagerResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWagerResponse.response": + if x.Response == nil { + x.Response = new(v1beta.MsgWagerResponse) + } + return protoreflect.ValueOfMessage(x.Response.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgWagerResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgWagerResponse.response": + m := new(v1beta.MsgWagerResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgWagerResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgWagerResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgWagerResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgWagerResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgWagerResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgWagerResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgWagerResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgWagerResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgWagerResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Response != nil { + l = options.Size(x.Response) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgWagerResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Response != nil { + encoded, err := options.Marshal(x.Response) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgWagerResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWagerResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgWagerResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Response", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Response == nil { + x.Response = &v1beta.MsgWagerResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Response); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgHouseDeposit protoreflect.MessageDescriptor + fd_MsgHouseDeposit_msg protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgHouseDeposit = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgHouseDeposit") + fd_MsgHouseDeposit_msg = md_MsgHouseDeposit.Fields().ByName("msg") +} + +var _ protoreflect.Message = (*fastReflection_MsgHouseDeposit)(nil) + +type fastReflection_MsgHouseDeposit MsgHouseDeposit + +func (x *MsgHouseDeposit) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgHouseDeposit)(x) +} + +func (x *MsgHouseDeposit) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgHouseDeposit_messageType fastReflection_MsgHouseDeposit_messageType +var _ protoreflect.MessageType = fastReflection_MsgHouseDeposit_messageType{} + +type fastReflection_MsgHouseDeposit_messageType struct{} + +func (x fastReflection_MsgHouseDeposit_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgHouseDeposit)(nil) +} +func (x fastReflection_MsgHouseDeposit_messageType) New() protoreflect.Message { + return new(fastReflection_MsgHouseDeposit) +} +func (x fastReflection_MsgHouseDeposit_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseDeposit +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgHouseDeposit) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseDeposit +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgHouseDeposit) Type() protoreflect.MessageType { + return _fastReflection_MsgHouseDeposit_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgHouseDeposit) New() protoreflect.Message { + return new(fastReflection_MsgHouseDeposit) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgHouseDeposit) Interface() protoreflect.ProtoMessage { + return (*MsgHouseDeposit)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgHouseDeposit) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Msg != nil { + value := protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + if !f(fd_MsgHouseDeposit_msg, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgHouseDeposit) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDeposit.msg": + return x.Msg != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDeposit")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDeposit does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDeposit) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDeposit.msg": + x.Msg = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDeposit")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDeposit does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgHouseDeposit) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDeposit.msg": + value := x.Msg + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDeposit")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDeposit does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDeposit) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDeposit.msg": + x.Msg = value.Message().Interface().(*v1beta1.MsgDeposit) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDeposit")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDeposit does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDeposit) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDeposit.msg": + if x.Msg == nil { + x.Msg = new(v1beta1.MsgDeposit) + } + return protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDeposit")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDeposit does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgHouseDeposit) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDeposit.msg": + m := new(v1beta1.MsgDeposit) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDeposit")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDeposit does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgHouseDeposit) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgHouseDeposit", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgHouseDeposit) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDeposit) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgHouseDeposit) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgHouseDeposit) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgHouseDeposit) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Msg != nil { + l = options.Size(x.Msg) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseDeposit) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Msg != nil { + encoded, err := options.Marshal(x.Msg) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseDeposit) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseDeposit: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseDeposit: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Msg == nil { + x.Msg = &v1beta1.MsgDeposit{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Msg); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgHouseDepositResponse protoreflect.MessageDescriptor + fd_MsgHouseDepositResponse_response protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgHouseDepositResponse = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgHouseDepositResponse") + fd_MsgHouseDepositResponse_response = md_MsgHouseDepositResponse.Fields().ByName("response") +} + +var _ protoreflect.Message = (*fastReflection_MsgHouseDepositResponse)(nil) + +type fastReflection_MsgHouseDepositResponse MsgHouseDepositResponse + +func (x *MsgHouseDepositResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgHouseDepositResponse)(x) +} + +func (x *MsgHouseDepositResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgHouseDepositResponse_messageType fastReflection_MsgHouseDepositResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgHouseDepositResponse_messageType{} + +type fastReflection_MsgHouseDepositResponse_messageType struct{} + +func (x fastReflection_MsgHouseDepositResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgHouseDepositResponse)(nil) +} +func (x fastReflection_MsgHouseDepositResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgHouseDepositResponse) +} +func (x fastReflection_MsgHouseDepositResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseDepositResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgHouseDepositResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseDepositResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgHouseDepositResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgHouseDepositResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgHouseDepositResponse) New() protoreflect.Message { + return new(fastReflection_MsgHouseDepositResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgHouseDepositResponse) Interface() protoreflect.ProtoMessage { + return (*MsgHouseDepositResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgHouseDepositResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Response != nil { + value := protoreflect.ValueOfMessage(x.Response.ProtoReflect()) + if !f(fd_MsgHouseDepositResponse_response, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgHouseDepositResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDepositResponse.response": + return x.Response != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDepositResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDepositResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDepositResponse.response": + x.Response = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDepositResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgHouseDepositResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDepositResponse.response": + value := x.Response + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDepositResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDepositResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDepositResponse.response": + x.Response = value.Message().Interface().(*v1beta1.MsgDepositResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDepositResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDepositResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDepositResponse.response": + if x.Response == nil { + x.Response = new(v1beta1.MsgDepositResponse) + } + return protoreflect.ValueOfMessage(x.Response.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDepositResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgHouseDepositResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseDepositResponse.response": + m := new(v1beta1.MsgDepositResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseDepositResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgHouseDepositResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgHouseDepositResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgHouseDepositResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseDepositResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgHouseDepositResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgHouseDepositResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgHouseDepositResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Response != nil { + l = options.Size(x.Response) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseDepositResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Response != nil { + encoded, err := options.Marshal(x.Response) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseDepositResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseDepositResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseDepositResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Response", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Response == nil { + x.Response = &v1beta1.MsgDepositResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Response); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgHouseWithdraw protoreflect.MessageDescriptor + fd_MsgHouseWithdraw_msg protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgHouseWithdraw = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgHouseWithdraw") + fd_MsgHouseWithdraw_msg = md_MsgHouseWithdraw.Fields().ByName("msg") +} + +var _ protoreflect.Message = (*fastReflection_MsgHouseWithdraw)(nil) + +type fastReflection_MsgHouseWithdraw MsgHouseWithdraw + +func (x *MsgHouseWithdraw) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgHouseWithdraw)(x) +} + +func (x *MsgHouseWithdraw) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgHouseWithdraw_messageType fastReflection_MsgHouseWithdraw_messageType +var _ protoreflect.MessageType = fastReflection_MsgHouseWithdraw_messageType{} + +type fastReflection_MsgHouseWithdraw_messageType struct{} + +func (x fastReflection_MsgHouseWithdraw_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgHouseWithdraw)(nil) +} +func (x fastReflection_MsgHouseWithdraw_messageType) New() protoreflect.Message { + return new(fastReflection_MsgHouseWithdraw) +} +func (x fastReflection_MsgHouseWithdraw_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseWithdraw +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgHouseWithdraw) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseWithdraw +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgHouseWithdraw) Type() protoreflect.MessageType { + return _fastReflection_MsgHouseWithdraw_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgHouseWithdraw) New() protoreflect.Message { + return new(fastReflection_MsgHouseWithdraw) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgHouseWithdraw) Interface() protoreflect.ProtoMessage { + return (*MsgHouseWithdraw)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgHouseWithdraw) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Msg != nil { + value := protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + if !f(fd_MsgHouseWithdraw_msg, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgHouseWithdraw) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdraw.msg": + return x.Msg != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdraw does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdraw) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdraw.msg": + x.Msg = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdraw does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgHouseWithdraw) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdraw.msg": + value := x.Msg + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdraw does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdraw) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdraw.msg": + x.Msg = value.Message().Interface().(*v1beta1.MsgWithdraw) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdraw does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdraw) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdraw.msg": + if x.Msg == nil { + x.Msg = new(v1beta1.MsgWithdraw) + } + return protoreflect.ValueOfMessage(x.Msg.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdraw does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgHouseWithdraw) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdraw.msg": + m := new(v1beta1.MsgWithdraw) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdraw")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdraw does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgHouseWithdraw) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgHouseWithdraw", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgHouseWithdraw) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdraw) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgHouseWithdraw) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgHouseWithdraw) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgHouseWithdraw) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Msg != nil { + l = options.Size(x.Msg) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseWithdraw) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Msg != nil { + encoded, err := options.Marshal(x.Msg) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseWithdraw) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseWithdraw: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseWithdraw: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Msg == nil { + x.Msg = &v1beta1.MsgWithdraw{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Msg); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgHouseWithdrawResponse protoreflect.MessageDescriptor + fd_MsgHouseWithdrawResponse_response protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgHouseWithdrawResponse = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgHouseWithdrawResponse") + fd_MsgHouseWithdrawResponse_response = md_MsgHouseWithdrawResponse.Fields().ByName("response") +} + +var _ protoreflect.Message = (*fastReflection_MsgHouseWithdrawResponse)(nil) + +type fastReflection_MsgHouseWithdrawResponse MsgHouseWithdrawResponse + +func (x *MsgHouseWithdrawResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgHouseWithdrawResponse)(x) +} + +func (x *MsgHouseWithdrawResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgHouseWithdrawResponse_messageType fastReflection_MsgHouseWithdrawResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgHouseWithdrawResponse_messageType{} + +type fastReflection_MsgHouseWithdrawResponse_messageType struct{} + +func (x fastReflection_MsgHouseWithdrawResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgHouseWithdrawResponse)(nil) +} +func (x fastReflection_MsgHouseWithdrawResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgHouseWithdrawResponse) +} +func (x fastReflection_MsgHouseWithdrawResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseWithdrawResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgHouseWithdrawResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgHouseWithdrawResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgHouseWithdrawResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgHouseWithdrawResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgHouseWithdrawResponse) New() protoreflect.Message { + return new(fastReflection_MsgHouseWithdrawResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgHouseWithdrawResponse) Interface() protoreflect.ProtoMessage { + return (*MsgHouseWithdrawResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgHouseWithdrawResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Response != nil { + value := protoreflect.ValueOfMessage(x.Response.ProtoReflect()) + if !f(fd_MsgHouseWithdrawResponse_response, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgHouseWithdrawResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse.response": + return x.Response != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdrawResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse.response": + x.Response = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgHouseWithdrawResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse.response": + value := x.Response + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdrawResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse.response": + x.Response = value.Message().Interface().(*v1beta1.MsgWithdrawResponse) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdrawResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse.response": + if x.Response == nil { + x.Response = new(v1beta1.MsgWithdrawResponse) + } + return protoreflect.ValueOfMessage(x.Response.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgHouseWithdrawResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse.response": + m := new(v1beta1.MsgWithdrawResponse) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgHouseWithdrawResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgHouseWithdrawResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgHouseWithdrawResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgHouseWithdrawResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgHouseWithdrawResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgHouseWithdrawResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Response != nil { + l = options.Size(x.Response) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseWithdrawResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Response != nil { + encoded, err := options.Marshal(x.Response) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgHouseWithdrawResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseWithdrawResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgHouseWithdrawResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Response", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Response == nil { + x.Response = &v1beta1.MsgWithdrawResponse{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Response); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.legacy.subaccount.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.legacy.subaccount.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_legacy_subaccount_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_legacy_subaccount_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/subaccount/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgCreate defines the Msg/Create request type. +type MsgCreate struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the msg signer. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // owner is the owner of the subaccount. + Owner string `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"` + // locked_balances is the list of balance locks. + // Fixme: why this attribute needs to be repeated? + LockedBalances []*LockedBalance `protobuf:"bytes,3,rep,name=locked_balances,json=lockedBalances,proto3" json:"locked_balances,omitempty"` +} + +func (x *MsgCreate) Reset() { + *x = MsgCreate{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgCreate) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgCreate) ProtoMessage() {} + +// Deprecated: Use MsgCreate.ProtoReflect.Descriptor instead. +func (*MsgCreate) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgCreate) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgCreate) GetOwner() string { + if x != nil { + return x.Owner + } + return "" +} + +func (x *MsgCreate) GetLockedBalances() []*LockedBalance { + if x != nil { + return x.LockedBalances + } + return nil +} + +// MsgCreateAccountResponse defines the Msg/CreateAccount response type. +type MsgCreateResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgCreateResponse) Reset() { + *x = MsgCreateResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgCreateResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgCreateResponse) ProtoMessage() {} + +// Deprecated: Use MsgCreateResponse.ProtoReflect.Descriptor instead. +func (*MsgCreateResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +// MsgTopUp defines the Msg/TopUp request type. +type MsgTopUp struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the msg signer. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // address is the subaccount address. + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // locked_balances is the list of balance locks. + // Fixme: Are we sending multiple balance update together? If not, then only + // locked balance should be enough + LockedBalances []*LockedBalance `protobuf:"bytes,3,rep,name=locked_balances,json=lockedBalances,proto3" json:"locked_balances,omitempty"` +} + +func (x *MsgTopUp) Reset() { + *x = MsgTopUp{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgTopUp) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgTopUp) ProtoMessage() {} + +// Deprecated: Use MsgTopUp.ProtoReflect.Descriptor instead. +func (*MsgTopUp) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{2} +} + +func (x *MsgTopUp) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgTopUp) GetAddress() string { + if x != nil { + return x.Address + } + return "" +} + +func (x *MsgTopUp) GetLockedBalances() []*LockedBalance { + if x != nil { + return x.LockedBalances + } + return nil +} + +// MsgTopUpResponse defines the Msg/TopUp response type. +type MsgTopUpResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgTopUpResponse) Reset() { + *x = MsgTopUpResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgTopUpResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgTopUpResponse) ProtoMessage() {} + +// Deprecated: Use MsgTopUpResponse.ProtoReflect.Descriptor instead. +func (*MsgTopUpResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{3} +} + +// MsgWithdrawUnlockedBalances defines the Msg/WithdrawUnlockedBalances request +// type. +type MsgWithdrawUnlockedBalances struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the subaccount owner. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` +} + +func (x *MsgWithdrawUnlockedBalances) Reset() { + *x = MsgWithdrawUnlockedBalances{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdrawUnlockedBalances) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdrawUnlockedBalances) ProtoMessage() {} + +// Deprecated: Use MsgWithdrawUnlockedBalances.ProtoReflect.Descriptor instead. +func (*MsgWithdrawUnlockedBalances) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{4} +} + +func (x *MsgWithdrawUnlockedBalances) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +// MsgWithdrawUnlockedBalancesResponse defines the Msg/WithdrawUnlockedBalances +// response type. +type MsgWithdrawUnlockedBalancesResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgWithdrawUnlockedBalancesResponse) Reset() { + *x = MsgWithdrawUnlockedBalancesResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWithdrawUnlockedBalancesResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWithdrawUnlockedBalancesResponse) ProtoMessage() {} + +// Deprecated: Use MsgWithdrawUnlockedBalancesResponse.ProtoReflect.Descriptor instead. +func (*MsgWithdrawUnlockedBalancesResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{5} +} + +// MsgWager wraps the MsgWager message. We need it in order not to have +// double interface registration conflicts. +type MsgWager struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // creator is the subaccount owner. + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + // ticket is the jwt ticket data. + Ticket string `protobuf:"bytes,2,opt,name=ticket,proto3" json:"ticket,omitempty"` +} + +func (x *MsgWager) Reset() { + *x = MsgWager{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWager) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWager) ProtoMessage() {} + +// Deprecated: Use MsgWager.ProtoReflect.Descriptor instead. +func (*MsgWager) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{6} +} + +func (x *MsgWager) GetCreator() string { + if x != nil { + return x.Creator + } + return "" +} + +func (x *MsgWager) GetTicket() string { + if x != nil { + return x.Ticket + } + return "" +} + +// MsgWagerResponse wraps the MsgWagerResponse message. We need it in order not +// to have double interface registration conflicts. +type MsgWagerResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Response *v1beta.MsgWagerResponse `protobuf:"bytes,1,opt,name=response,proto3" json:"response,omitempty"` +} + +func (x *MsgWagerResponse) Reset() { + *x = MsgWagerResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgWagerResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgWagerResponse) ProtoMessage() {} + +// Deprecated: Use MsgWagerResponse.ProtoReflect.Descriptor instead. +func (*MsgWagerResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{7} +} + +func (x *MsgWagerResponse) GetResponse() *v1beta.MsgWagerResponse { + if x != nil { + return x.Response + } + return nil +} + +// MsgHouseDeposit wraps the MsgHouseDeposit message. We need it in order not to +// have double interface registration conflicts. +type MsgHouseDeposit struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Msg *v1beta1.MsgDeposit `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"` +} + +func (x *MsgHouseDeposit) Reset() { + *x = MsgHouseDeposit{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgHouseDeposit) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgHouseDeposit) ProtoMessage() {} + +// Deprecated: Use MsgHouseDeposit.ProtoReflect.Descriptor instead. +func (*MsgHouseDeposit) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{8} +} + +func (x *MsgHouseDeposit) GetMsg() *v1beta1.MsgDeposit { + if x != nil { + return x.Msg + } + return nil +} + +// MsgHouseDepositResponse wraps the MsgHouseDepositResponse message. We need it +// in order not to have double interface registration conflicts. +type MsgHouseDepositResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Response *v1beta1.MsgDepositResponse `protobuf:"bytes,1,opt,name=response,proto3" json:"response,omitempty"` +} + +func (x *MsgHouseDepositResponse) Reset() { + *x = MsgHouseDepositResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgHouseDepositResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgHouseDepositResponse) ProtoMessage() {} + +// Deprecated: Use MsgHouseDepositResponse.ProtoReflect.Descriptor instead. +func (*MsgHouseDepositResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{9} +} + +func (x *MsgHouseDepositResponse) GetResponse() *v1beta1.MsgDepositResponse { + if x != nil { + return x.Response + } + return nil +} + +// MsgHouseWithdraw wraps the MsgHouseWithdraw message. We need it in order not +// to have double interface registration conflicts. +type MsgHouseWithdraw struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Msg *v1beta1.MsgWithdraw `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"` +} + +func (x *MsgHouseWithdraw) Reset() { + *x = MsgHouseWithdraw{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgHouseWithdraw) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgHouseWithdraw) ProtoMessage() {} + +// Deprecated: Use MsgHouseWithdraw.ProtoReflect.Descriptor instead. +func (*MsgHouseWithdraw) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{10} +} + +func (x *MsgHouseWithdraw) GetMsg() *v1beta1.MsgWithdraw { + if x != nil { + return x.Msg + } + return nil +} + +// MsgHouseWithdrawResponse wraps the MsgHouseWithdrawResponse message. We need +// it in order not to have double interface registration conflicts. +type MsgHouseWithdrawResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Response *v1beta1.MsgWithdrawResponse `protobuf:"bytes,1,opt,name=response,proto3" json:"response,omitempty"` +} + +func (x *MsgHouseWithdrawResponse) Reset() { + *x = MsgHouseWithdrawResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgHouseWithdrawResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgHouseWithdrawResponse) ProtoMessage() {} + +// Deprecated: Use MsgHouseWithdrawResponse.ProtoReflect.Descriptor instead. +func (*MsgHouseWithdrawResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{11} +} + +func (x *MsgHouseWithdrawResponse) GetResponse() *v1beta1.MsgWithdrawResponse { + if x != nil { + return x.Response + } + return nil +} + +// MsgUpdateParams is the Msg/UpdateParams request type. +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/bet parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{12} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP(), []int{13} +} + +var File_sge_legacy_subaccount_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_legacy_subaccount_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x25, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, + 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1c, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, + 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x1e, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x62, + 0x65, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x20, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x68, + 0x6f, 0x75, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x2a, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x29, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xd9, 0x01, 0x0a, 0x09, + 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, + 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x2e, 0x0a, + 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, + 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x12, 0x5a, 0x0a, + 0x0f, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, + 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, + 0x6e, 0x63, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0e, 0x6c, 0x6f, 0x63, 0x6b, 0x65, + 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, + 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x13, 0x0a, 0x11, 0x4d, 0x73, 0x67, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xdc, 0x01, 0x0a, + 0x08, 0x4d, 0x73, 0x67, 0x54, 0x6f, 0x70, 0x55, 0x70, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, + 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x32, 0x0a, + 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, + 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x12, 0x5a, 0x0a, 0x0f, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x62, 0x61, 0x6c, 0x61, + 0x6e, 0x63, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4c, 0x6f, 0x63, 0x6b, 0x65, 0x64, + 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x0e, 0x6c, + 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x3a, 0x0c, 0x82, + 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x12, 0x0a, 0x10, 0x4d, + 0x73, 0x67, 0x54, 0x6f, 0x70, 0x55, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x5f, 0x0a, 0x1b, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x55, 0x6e, + 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x32, + 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, + 0x6f, 0x72, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, + 0x22, 0x25, 0x0a, 0x23, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x55, + 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x64, 0x0a, 0x08, 0x4d, 0x73, 0x67, 0x57, 0x61, + 0x67, 0x65, 0x72, 0x12, 0x32, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, + 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, + 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x69, 0x63, 0x6b, 0x65, 0x74, 0x3a, + 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x22, 0x57, 0x0a, + 0x10, 0x4d, 0x73, 0x67, 0x57, 0x61, 0x67, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x43, 0x0a, 0x08, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x2e, 0x62, 0x65, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, + 0x61, 0x67, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x08, 0x72, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x48, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x48, 0x6f, 0x75, + 0x73, 0x65, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x35, 0x0a, 0x03, 0x6d, 0x73, 0x67, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x4d, 0x73, 0x67, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x03, 0x6d, 0x73, 0x67, + 0x22, 0x62, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x44, 0x65, 0x70, 0x6f, + 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x08, 0x72, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x44, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x08, 0x72, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x4a, 0x0a, 0x10, 0x4d, 0x73, 0x67, 0x48, 0x6f, 0x75, 0x73, 0x65, + 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x12, 0x36, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, + 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x52, 0x03, 0x6d, 0x73, 0x67, + 0x22, 0x64, 0x0a, 0x18, 0x4d, 0x73, 0x67, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x48, 0x0a, 0x08, + 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x68, 0x6f, 0x75, 0x73, + 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x08, 0x72, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xb7, 0x01, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, + 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, + 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, + 0x74, 0x79, 0x12, 0x47, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, + 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x3a, 0x23, 0xd2, 0xb4, 0x2d, + 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, + 0x2e, 0x31, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, + 0x22, 0x30, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x3a, 0x15, 0xd2, 0xb4, 0x2d, + 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x31, 0x2e, 0x37, + 0x2e, 0x31, 0x32, 0xe4, 0x06, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x67, 0x0a, 0x06, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x12, 0x27, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x1a, 0x2f, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, + 0x88, 0x02, 0x01, 0x12, 0x64, 0x0a, 0x05, 0x54, 0x6f, 0x70, 0x55, 0x70, 0x12, 0x26, 0x2e, 0x73, + 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x54, + 0x6f, 0x70, 0x55, 0x70, 0x1a, 0x2e, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, + 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x54, 0x6f, 0x70, 0x55, 0x70, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x9d, 0x01, 0x0a, 0x18, 0x57, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, + 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x39, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, + 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, + 0x77, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, + 0x73, 0x1a, 0x41, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, + 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x55, 0x6e, 0x6c, 0x6f, + 0x63, 0x6b, 0x65, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x64, 0x0a, 0x05, 0x57, 0x61, 0x67, + 0x65, 0x72, 0x12, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, + 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x61, 0x67, 0x65, 0x72, 0x1a, 0x2e, 0x2e, 0x73, 0x67, 0x65, + 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x61, 0x67, + 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, + 0x79, 0x0a, 0x0c, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, + 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, + 0x73, 0x67, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x1a, 0x35, + 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, + 0x67, 0x48, 0x6f, 0x75, 0x73, 0x65, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x7c, 0x0a, 0x0d, 0x48, 0x6f, + 0x75, 0x73, 0x65, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x12, 0x2e, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x48, 0x6f, + 0x75, 0x73, 0x65, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x1a, 0x36, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x48, 0x6f, + 0x75, 0x73, 0x65, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x12, 0x8e, 0x01, 0x0a, 0x0c, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, + 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x35, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, + 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x18, 0xca, 0xb4, 0x2d, 0x11, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, + 0x20, 0x31, 0x2e, 0x37, 0x2e, 0x31, 0x88, 0x02, 0x01, 0x42, 0x8c, 0x02, 0x0a, 0x20, 0x63, 0x6f, + 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x73, 0x75, 0x62, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x07, + 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4c, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, + 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x2f, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x73, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x53, 0xaa, 0x02, 0x1c, + 0x53, 0x67, 0x65, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x53, 0x75, 0x62, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x1c, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x28, 0x53, 0x67, + 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1f, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, + 0x67, 0x61, 0x63, 0x79, 0x3a, 0x3a, 0x53, 0x75, 0x62, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_subaccount_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_legacy_subaccount_v1beta_tx_proto_rawDescData = file_sge_legacy_subaccount_v1beta_tx_proto_rawDesc +) + +func file_sge_legacy_subaccount_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_legacy_subaccount_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_legacy_subaccount_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_subaccount_v1beta_tx_proto_rawDescData) + }) + return file_sge_legacy_subaccount_v1beta_tx_proto_rawDescData +} + +var file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 14) +var file_sge_legacy_subaccount_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgCreate)(nil), // 0: sge.legacy.subaccount.v1beta.MsgCreate + (*MsgCreateResponse)(nil), // 1: sge.legacy.subaccount.v1beta.MsgCreateResponse + (*MsgTopUp)(nil), // 2: sge.legacy.subaccount.v1beta.MsgTopUp + (*MsgTopUpResponse)(nil), // 3: sge.legacy.subaccount.v1beta.MsgTopUpResponse + (*MsgWithdrawUnlockedBalances)(nil), // 4: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances + (*MsgWithdrawUnlockedBalancesResponse)(nil), // 5: sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse + (*MsgWager)(nil), // 6: sge.legacy.subaccount.v1beta.MsgWager + (*MsgWagerResponse)(nil), // 7: sge.legacy.subaccount.v1beta.MsgWagerResponse + (*MsgHouseDeposit)(nil), // 8: sge.legacy.subaccount.v1beta.MsgHouseDeposit + (*MsgHouseDepositResponse)(nil), // 9: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse + (*MsgHouseWithdraw)(nil), // 10: sge.legacy.subaccount.v1beta.MsgHouseWithdraw + (*MsgHouseWithdrawResponse)(nil), // 11: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse + (*MsgUpdateParams)(nil), // 12: sge.legacy.subaccount.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 13: sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse + (*LockedBalance)(nil), // 14: sge.legacy.subaccount.v1beta.LockedBalance + (*v1beta.MsgWagerResponse)(nil), // 15: sge.legacy.bet.v1beta.MsgWagerResponse + (*v1beta1.MsgDeposit)(nil), // 16: sge.legacy.house.v1beta.MsgDeposit + (*v1beta1.MsgDepositResponse)(nil), // 17: sge.legacy.house.v1beta.MsgDepositResponse + (*v1beta1.MsgWithdraw)(nil), // 18: sge.legacy.house.v1beta.MsgWithdraw + (*v1beta1.MsgWithdrawResponse)(nil), // 19: sge.legacy.house.v1beta.MsgWithdrawResponse + (*Params)(nil), // 20: sge.legacy.subaccount.v1beta.Params +} +var file_sge_legacy_subaccount_v1beta_tx_proto_depIdxs = []int32{ + 14, // 0: sge.legacy.subaccount.v1beta.MsgCreate.locked_balances:type_name -> sge.legacy.subaccount.v1beta.LockedBalance + 14, // 1: sge.legacy.subaccount.v1beta.MsgTopUp.locked_balances:type_name -> sge.legacy.subaccount.v1beta.LockedBalance + 15, // 2: sge.legacy.subaccount.v1beta.MsgWagerResponse.response:type_name -> sge.legacy.bet.v1beta.MsgWagerResponse + 16, // 3: sge.legacy.subaccount.v1beta.MsgHouseDeposit.msg:type_name -> sge.legacy.house.v1beta.MsgDeposit + 17, // 4: sge.legacy.subaccount.v1beta.MsgHouseDepositResponse.response:type_name -> sge.legacy.house.v1beta.MsgDepositResponse + 18, // 5: sge.legacy.subaccount.v1beta.MsgHouseWithdraw.msg:type_name -> sge.legacy.house.v1beta.MsgWithdraw + 19, // 6: sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse.response:type_name -> sge.legacy.house.v1beta.MsgWithdrawResponse + 20, // 7: sge.legacy.subaccount.v1beta.MsgUpdateParams.params:type_name -> sge.legacy.subaccount.v1beta.Params + 0, // 8: sge.legacy.subaccount.v1beta.Msg.Create:input_type -> sge.legacy.subaccount.v1beta.MsgCreate + 2, // 9: sge.legacy.subaccount.v1beta.Msg.TopUp:input_type -> sge.legacy.subaccount.v1beta.MsgTopUp + 4, // 10: sge.legacy.subaccount.v1beta.Msg.WithdrawUnlockedBalances:input_type -> sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances + 6, // 11: sge.legacy.subaccount.v1beta.Msg.Wager:input_type -> sge.legacy.subaccount.v1beta.MsgWager + 8, // 12: sge.legacy.subaccount.v1beta.Msg.HouseDeposit:input_type -> sge.legacy.subaccount.v1beta.MsgHouseDeposit + 10, // 13: sge.legacy.subaccount.v1beta.Msg.HouseWithdraw:input_type -> sge.legacy.subaccount.v1beta.MsgHouseWithdraw + 12, // 14: sge.legacy.subaccount.v1beta.Msg.UpdateParams:input_type -> sge.legacy.subaccount.v1beta.MsgUpdateParams + 1, // 15: sge.legacy.subaccount.v1beta.Msg.Create:output_type -> sge.legacy.subaccount.v1beta.MsgCreateResponse + 3, // 16: sge.legacy.subaccount.v1beta.Msg.TopUp:output_type -> sge.legacy.subaccount.v1beta.MsgTopUpResponse + 5, // 17: sge.legacy.subaccount.v1beta.Msg.WithdrawUnlockedBalances:output_type -> sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse + 7, // 18: sge.legacy.subaccount.v1beta.Msg.Wager:output_type -> sge.legacy.subaccount.v1beta.MsgWagerResponse + 9, // 19: sge.legacy.subaccount.v1beta.Msg.HouseDeposit:output_type -> sge.legacy.subaccount.v1beta.MsgHouseDepositResponse + 11, // 20: sge.legacy.subaccount.v1beta.Msg.HouseWithdraw:output_type -> sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse + 13, // 21: sge.legacy.subaccount.v1beta.Msg.UpdateParams:output_type -> sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse + 15, // [15:22] is the sub-list for method output_type + 8, // [8:15] is the sub-list for method input_type + 8, // [8:8] is the sub-list for extension type_name + 8, // [8:8] is the sub-list for extension extendee + 0, // [0:8] is the sub-list for field type_name +} + +func init() { file_sge_legacy_subaccount_v1beta_tx_proto_init() } +func file_sge_legacy_subaccount_v1beta_tx_proto_init() { + if File_sge_legacy_subaccount_v1beta_tx_proto != nil { + return + } + file_sge_legacy_subaccount_v1beta_balance_proto_init() + file_sge_legacy_subaccount_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgCreate); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgCreateResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgTopUp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgTopUpResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdrawUnlockedBalances); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWithdrawUnlockedBalancesResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWager); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgWagerResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgHouseDeposit); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgHouseDepositResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgHouseWithdraw); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgHouseWithdrawResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_subaccount_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 14, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_legacy_subaccount_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_legacy_subaccount_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_legacy_subaccount_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_legacy_subaccount_v1beta_tx_proto = out.File + file_sge_legacy_subaccount_v1beta_tx_proto_rawDesc = nil + file_sge_legacy_subaccount_v1beta_tx_proto_goTypes = nil + file_sge_legacy_subaccount_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/legacy/subaccount/v1beta/tx_grpc.pb.go b/api/sge/legacy/subaccount/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..0e1798cd --- /dev/null +++ b/api/sge/legacy/subaccount/v1beta/tx_grpc.pb.go @@ -0,0 +1,372 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/legacy/subaccount/v1beta/tx.proto + +package subaccountv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_Create_FullMethodName = "/sge.legacy.subaccount.v1beta.Msg/Create" + Msg_TopUp_FullMethodName = "/sge.legacy.subaccount.v1beta.Msg/TopUp" + Msg_WithdrawUnlockedBalances_FullMethodName = "/sge.legacy.subaccount.v1beta.Msg/WithdrawUnlockedBalances" + Msg_Wager_FullMethodName = "/sge.legacy.subaccount.v1beta.Msg/Wager" + Msg_HouseDeposit_FullMethodName = "/sge.legacy.subaccount.v1beta.Msg/HouseDeposit" + Msg_HouseWithdraw_FullMethodName = "/sge.legacy.subaccount.v1beta.Msg/HouseWithdraw" + Msg_UpdateParams_FullMethodName = "/sge.legacy.subaccount.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // Deprecated: Do not use. + // Create defines a method for creating a subaccount. + Create(ctx context.Context, in *MsgCreate, opts ...grpc.CallOption) (*MsgCreateResponse, error) + // Deprecated: Do not use. + // TopUp defines a method for topping up a subaccount. + TopUp(ctx context.Context, in *MsgTopUp, opts ...grpc.CallOption) (*MsgTopUpResponse, error) + // Deprecated: Do not use. + // WithdrawUnlockedBalances defines a method for withdrawing unlocked + // balances. + WithdrawUnlockedBalances(ctx context.Context, in *MsgWithdrawUnlockedBalances, opts ...grpc.CallOption) (*MsgWithdrawUnlockedBalancesResponse, error) + // Deprecated: Do not use. + // PlaceBet defines a method for placing a bet using a subaccount. + Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOption) (*MsgWagerResponse, error) + // Deprecated: Do not use. + // HouseDeposit defines a method for depositing funds to provide liquidity to + // a market. + HouseDeposit(ctx context.Context, in *MsgHouseDeposit, opts ...grpc.CallOption) (*MsgHouseDepositResponse, error) + // Deprecated: Do not use. + // HouseWithdraw defines a method for withdrawing funds from a market. + HouseWithdraw(ctx context.Context, in *MsgHouseWithdraw, opts ...grpc.CallOption) (*MsgHouseWithdrawResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/subaccount + // module parameters. The authority is defined in the keeper. + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +// Deprecated: Do not use. +func (c *msgClient) Create(ctx context.Context, in *MsgCreate, opts ...grpc.CallOption) (*MsgCreateResponse, error) { + out := new(MsgCreateResponse) + err := c.cc.Invoke(ctx, Msg_Create_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) TopUp(ctx context.Context, in *MsgTopUp, opts ...grpc.CallOption) (*MsgTopUpResponse, error) { + out := new(MsgTopUpResponse) + err := c.cc.Invoke(ctx, Msg_TopUp_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) WithdrawUnlockedBalances(ctx context.Context, in *MsgWithdrawUnlockedBalances, opts ...grpc.CallOption) (*MsgWithdrawUnlockedBalancesResponse, error) { + out := new(MsgWithdrawUnlockedBalancesResponse) + err := c.cc.Invoke(ctx, Msg_WithdrawUnlockedBalances_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOption) (*MsgWagerResponse, error) { + out := new(MsgWagerResponse) + err := c.cc.Invoke(ctx, Msg_Wager_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) HouseDeposit(ctx context.Context, in *MsgHouseDeposit, opts ...grpc.CallOption) (*MsgHouseDepositResponse, error) { + out := new(MsgHouseDepositResponse) + err := c.cc.Invoke(ctx, Msg_HouseDeposit_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) HouseWithdraw(ctx context.Context, in *MsgHouseWithdraw, opts ...grpc.CallOption) (*MsgHouseWithdrawResponse, error) { + out := new(MsgHouseWithdrawResponse) + err := c.cc.Invoke(ctx, Msg_HouseWithdraw_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Deprecated: Do not use. +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // Deprecated: Do not use. + // Create defines a method for creating a subaccount. + Create(context.Context, *MsgCreate) (*MsgCreateResponse, error) + // Deprecated: Do not use. + // TopUp defines a method for topping up a subaccount. + TopUp(context.Context, *MsgTopUp) (*MsgTopUpResponse, error) + // Deprecated: Do not use. + // WithdrawUnlockedBalances defines a method for withdrawing unlocked + // balances. + WithdrawUnlockedBalances(context.Context, *MsgWithdrawUnlockedBalances) (*MsgWithdrawUnlockedBalancesResponse, error) + // Deprecated: Do not use. + // PlaceBet defines a method for placing a bet using a subaccount. + Wager(context.Context, *MsgWager) (*MsgWagerResponse, error) + // Deprecated: Do not use. + // HouseDeposit defines a method for depositing funds to provide liquidity to + // a market. + HouseDeposit(context.Context, *MsgHouseDeposit) (*MsgHouseDepositResponse, error) + // Deprecated: Do not use. + // HouseWithdraw defines a method for withdrawing funds from a market. + HouseWithdraw(context.Context, *MsgHouseWithdraw) (*MsgHouseWithdrawResponse, error) + // Deprecated: Do not use. + // UpdateParams defines a governance operation for updating the x/subaccount + // module parameters. The authority is defined in the keeper. + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) Create(context.Context, *MsgCreate) (*MsgCreateResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Create not implemented") +} +func (UnimplementedMsgServer) TopUp(context.Context, *MsgTopUp) (*MsgTopUpResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method TopUp not implemented") +} +func (UnimplementedMsgServer) WithdrawUnlockedBalances(context.Context, *MsgWithdrawUnlockedBalances) (*MsgWithdrawUnlockedBalancesResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method WithdrawUnlockedBalances not implemented") +} +func (UnimplementedMsgServer) Wager(context.Context, *MsgWager) (*MsgWagerResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Wager not implemented") +} +func (UnimplementedMsgServer) HouseDeposit(context.Context, *MsgHouseDeposit) (*MsgHouseDepositResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method HouseDeposit not implemented") +} +func (UnimplementedMsgServer) HouseWithdraw(context.Context, *MsgHouseWithdraw) (*MsgHouseWithdrawResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method HouseWithdraw not implemented") +} +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_Create_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgCreate) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Create(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Create_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Create(ctx, req.(*MsgCreate)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_TopUp_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgTopUp) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).TopUp(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_TopUp_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).TopUp(ctx, req.(*MsgTopUp)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_WithdrawUnlockedBalances_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgWithdrawUnlockedBalances) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).WithdrawUnlockedBalances(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_WithdrawUnlockedBalances_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).WithdrawUnlockedBalances(ctx, req.(*MsgWithdrawUnlockedBalances)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_Wager_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgWager) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Wager(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_Wager_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Wager(ctx, req.(*MsgWager)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_HouseDeposit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgHouseDeposit) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).HouseDeposit(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_HouseDeposit_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).HouseDeposit(ctx, req.(*MsgHouseDeposit)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_HouseWithdraw_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgHouseWithdraw) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).HouseWithdraw(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_HouseWithdraw_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).HouseWithdraw(ctx, req.(*MsgHouseWithdraw)) + } + return interceptor(ctx, in, info, handler) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.legacy.subaccount.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Create", + Handler: _Msg_Create_Handler, + }, + { + MethodName: "TopUp", + Handler: _Msg_TopUp_Handler, + }, + { + MethodName: "WithdrawUnlockedBalances", + Handler: _Msg_WithdrawUnlockedBalances_Handler, + }, + { + MethodName: "Wager", + Handler: _Msg_Wager_Handler, + }, + { + MethodName: "HouseDeposit", + Handler: _Msg_HouseDeposit_Handler, + }, + { + MethodName: "HouseWithdraw", + Handler: _Msg_HouseWithdraw_Handler, + }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/legacy/subaccount/v1beta/tx.proto", +} diff --git a/api/sge/legacy/type/v1beta/kyc.pulsar.go b/api/sge/legacy/type/v1beta/kyc.pulsar.go new file mode 100644 index 00000000..2bc1b423 --- /dev/null +++ b/api/sge/legacy/type/v1beta/kyc.pulsar.go @@ -0,0 +1,709 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package typev1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_KycDataPayload protoreflect.MessageDescriptor + fd_KycDataPayload_ignore protoreflect.FieldDescriptor + fd_KycDataPayload_approved protoreflect.FieldDescriptor + fd_KycDataPayload_id protoreflect.FieldDescriptor +) + +func init() { + file_sge_legacy_type_v1beta_kyc_proto_init() + md_KycDataPayload = File_sge_legacy_type_v1beta_kyc_proto.Messages().ByName("KycDataPayload") + fd_KycDataPayload_ignore = md_KycDataPayload.Fields().ByName("ignore") + fd_KycDataPayload_approved = md_KycDataPayload.Fields().ByName("approved") + fd_KycDataPayload_id = md_KycDataPayload.Fields().ByName("id") +} + +var _ protoreflect.Message = (*fastReflection_KycDataPayload)(nil) + +type fastReflection_KycDataPayload KycDataPayload + +func (x *KycDataPayload) ProtoReflect() protoreflect.Message { + return (*fastReflection_KycDataPayload)(x) +} + +func (x *KycDataPayload) slowProtoReflect() protoreflect.Message { + mi := &file_sge_legacy_type_v1beta_kyc_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_KycDataPayload_messageType fastReflection_KycDataPayload_messageType +var _ protoreflect.MessageType = fastReflection_KycDataPayload_messageType{} + +type fastReflection_KycDataPayload_messageType struct{} + +func (x fastReflection_KycDataPayload_messageType) Zero() protoreflect.Message { + return (*fastReflection_KycDataPayload)(nil) +} +func (x fastReflection_KycDataPayload_messageType) New() protoreflect.Message { + return new(fastReflection_KycDataPayload) +} +func (x fastReflection_KycDataPayload_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_KycDataPayload +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_KycDataPayload) Descriptor() protoreflect.MessageDescriptor { + return md_KycDataPayload +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_KycDataPayload) Type() protoreflect.MessageType { + return _fastReflection_KycDataPayload_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_KycDataPayload) New() protoreflect.Message { + return new(fastReflection_KycDataPayload) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_KycDataPayload) Interface() protoreflect.ProtoMessage { + return (*KycDataPayload)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_KycDataPayload) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Ignore != false { + value := protoreflect.ValueOfBool(x.Ignore) + if !f(fd_KycDataPayload_ignore, value) { + return + } + } + if x.Approved != false { + value := protoreflect.ValueOfBool(x.Approved) + if !f(fd_KycDataPayload_approved, value) { + return + } + } + if x.Id != "" { + value := protoreflect.ValueOfString(x.Id) + if !f(fd_KycDataPayload_id, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_KycDataPayload) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.legacy.type.v1beta.KycDataPayload.ignore": + return x.Ignore != false + case "sge.legacy.type.v1beta.KycDataPayload.approved": + return x.Approved != false + case "sge.legacy.type.v1beta.KycDataPayload.id": + return x.Id != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.type.v1beta.KycDataPayload")) + } + panic(fmt.Errorf("message sge.legacy.type.v1beta.KycDataPayload does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KycDataPayload) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.legacy.type.v1beta.KycDataPayload.ignore": + x.Ignore = false + case "sge.legacy.type.v1beta.KycDataPayload.approved": + x.Approved = false + case "sge.legacy.type.v1beta.KycDataPayload.id": + x.Id = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.type.v1beta.KycDataPayload")) + } + panic(fmt.Errorf("message sge.legacy.type.v1beta.KycDataPayload does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_KycDataPayload) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.legacy.type.v1beta.KycDataPayload.ignore": + value := x.Ignore + return protoreflect.ValueOfBool(value) + case "sge.legacy.type.v1beta.KycDataPayload.approved": + value := x.Approved + return protoreflect.ValueOfBool(value) + case "sge.legacy.type.v1beta.KycDataPayload.id": + value := x.Id + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.type.v1beta.KycDataPayload")) + } + panic(fmt.Errorf("message sge.legacy.type.v1beta.KycDataPayload does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KycDataPayload) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.legacy.type.v1beta.KycDataPayload.ignore": + x.Ignore = value.Bool() + case "sge.legacy.type.v1beta.KycDataPayload.approved": + x.Approved = value.Bool() + case "sge.legacy.type.v1beta.KycDataPayload.id": + x.Id = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.type.v1beta.KycDataPayload")) + } + panic(fmt.Errorf("message sge.legacy.type.v1beta.KycDataPayload does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KycDataPayload) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.type.v1beta.KycDataPayload.ignore": + panic(fmt.Errorf("field ignore of message sge.legacy.type.v1beta.KycDataPayload is not mutable")) + case "sge.legacy.type.v1beta.KycDataPayload.approved": + panic(fmt.Errorf("field approved of message sge.legacy.type.v1beta.KycDataPayload is not mutable")) + case "sge.legacy.type.v1beta.KycDataPayload.id": + panic(fmt.Errorf("field id of message sge.legacy.type.v1beta.KycDataPayload is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.type.v1beta.KycDataPayload")) + } + panic(fmt.Errorf("message sge.legacy.type.v1beta.KycDataPayload does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_KycDataPayload) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.legacy.type.v1beta.KycDataPayload.ignore": + return protoreflect.ValueOfBool(false) + case "sge.legacy.type.v1beta.KycDataPayload.approved": + return protoreflect.ValueOfBool(false) + case "sge.legacy.type.v1beta.KycDataPayload.id": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.legacy.type.v1beta.KycDataPayload")) + } + panic(fmt.Errorf("message sge.legacy.type.v1beta.KycDataPayload does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_KycDataPayload) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.legacy.type.v1beta.KycDataPayload", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_KycDataPayload) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_KycDataPayload) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_KycDataPayload) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_KycDataPayload) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*KycDataPayload) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Ignore { + n += 2 + } + if x.Approved { + n += 2 + } + l = len(x.Id) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*KycDataPayload) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Id) > 0 { + i -= len(x.Id) + copy(dAtA[i:], x.Id) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Id))) + i-- + dAtA[i] = 0x1a + } + if x.Approved { + i-- + if x.Approved { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x10 + } + if x.Ignore { + i-- + if x.Ignore { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*KycDataPayload) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: KycDataPayload: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: KycDataPayload: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Ignore", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.Ignore = bool(v != 0) + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Approved", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.Approved = bool(v != 0) + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Id = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/legacy/type/v1beta/kyc.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// KycDataPayload is the KYC info. +type KycDataPayload struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // ignore is true if KYC validation is not required. + Ignore bool `protobuf:"varint,1,opt,name=ignore,proto3" json:"ignore,omitempty"` + // approved represent if KYC validation is approved or not. + Approved bool `protobuf:"varint,2,opt,name=approved,proto3" json:"approved,omitempty"` + // id is the id of the KYC user. + Id string `protobuf:"bytes,3,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *KycDataPayload) Reset() { + *x = KycDataPayload{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_legacy_type_v1beta_kyc_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *KycDataPayload) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*KycDataPayload) ProtoMessage() {} + +// Deprecated: Use KycDataPayload.ProtoReflect.Descriptor instead. +func (*KycDataPayload) Descriptor() ([]byte, []int) { + return file_sge_legacy_type_v1beta_kyc_proto_rawDescGZIP(), []int{0} +} + +func (x *KycDataPayload) GetIgnore() bool { + if x != nil { + return x.Ignore + } + return false +} + +func (x *KycDataPayload) GetApproved() bool { + if x != nil { + return x.Approved + } + return false +} + +func (x *KycDataPayload) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +var File_sge_legacy_type_v1beta_kyc_proto protoreflect.FileDescriptor + +var file_sge_legacy_type_v1beta_kyc_proto_rawDesc = []byte{ + 0x0a, 0x20, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x74, 0x79, 0x70, + 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6b, 0x79, 0x63, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x12, 0x16, 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x74, + 0x79, 0x70, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x7a, 0x0a, 0x0e, 0x4b, + 0x79, 0x63, 0x44, 0x61, 0x74, 0x61, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x16, 0x0a, + 0x06, 0x69, 0x67, 0x6e, 0x6f, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, + 0x67, 0x6e, 0x6f, 0x72, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, + 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x61, 0x70, 0x70, 0x72, 0x6f, 0x76, 0x65, + 0x64, 0x12, 0x34, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x24, 0xe2, + 0xde, 0x1f, 0x02, 0x49, 0x44, 0xea, 0xde, 0x1f, 0x02, 0x69, 0x64, 0xd2, 0xb4, 0x2d, 0x14, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, + 0x69, 0x6e, 0x67, 0x52, 0x02, 0x69, 0x64, 0x42, 0xe3, 0x01, 0x0a, 0x1a, 0x63, 0x6f, 0x6d, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x08, 0x4b, 0x79, 0x63, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x50, 0x01, 0x5a, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, + 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2f, 0x74, 0x79, + 0x70, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x74, 0x79, 0x70, 0x65, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4c, 0x54, 0xaa, 0x02, 0x16, 0x53, 0x67, 0x65, + 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x2e, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0xca, 0x02, 0x16, 0x53, 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x5c, 0x54, 0x79, 0x70, 0x65, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x22, 0x53, + 0x67, 0x65, 0x5c, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x5c, 0x54, 0x79, 0x70, 0x65, 0x5c, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0xea, 0x02, 0x19, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x3a, + 0x3a, 0x54, 0x79, 0x70, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_legacy_type_v1beta_kyc_proto_rawDescOnce sync.Once + file_sge_legacy_type_v1beta_kyc_proto_rawDescData = file_sge_legacy_type_v1beta_kyc_proto_rawDesc +) + +func file_sge_legacy_type_v1beta_kyc_proto_rawDescGZIP() []byte { + file_sge_legacy_type_v1beta_kyc_proto_rawDescOnce.Do(func() { + file_sge_legacy_type_v1beta_kyc_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_legacy_type_v1beta_kyc_proto_rawDescData) + }) + return file_sge_legacy_type_v1beta_kyc_proto_rawDescData +} + +var file_sge_legacy_type_v1beta_kyc_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_legacy_type_v1beta_kyc_proto_goTypes = []interface{}{ + (*KycDataPayload)(nil), // 0: sge.legacy.type.v1beta.KycDataPayload +} +var file_sge_legacy_type_v1beta_kyc_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_legacy_type_v1beta_kyc_proto_init() } +func file_sge_legacy_type_v1beta_kyc_proto_init() { + if File_sge_legacy_type_v1beta_kyc_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_legacy_type_v1beta_kyc_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*KycDataPayload); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_legacy_type_v1beta_kyc_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_legacy_type_v1beta_kyc_proto_goTypes, + DependencyIndexes: file_sge_legacy_type_v1beta_kyc_proto_depIdxs, + MessageInfos: file_sge_legacy_type_v1beta_kyc_proto_msgTypes, + }.Build() + File_sge_legacy_type_v1beta_kyc_proto = out.File + file_sge_legacy_type_v1beta_kyc_proto_rawDesc = nil + file_sge_legacy_type_v1beta_kyc_proto_goTypes = nil + file_sge_legacy_type_v1beta_kyc_proto_depIdxs = nil +} diff --git a/api/sge/mint/module/v1/module.pulsar.go b/api/sge/mint/module/v1/module.pulsar.go new file mode 100644 index 00000000..6005815d --- /dev/null +++ b/api/sge/mint/module/v1/module.pulsar.go @@ -0,0 +1,651 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package modulev1 + +import ( + _ "cosmossdk.io/api/cosmos/app/v1alpha1" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Module protoreflect.MessageDescriptor + fd_Module_fee_collector_name protoreflect.FieldDescriptor + fd_Module_authority protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_module_v1_module_proto_init() + md_Module = File_sge_mint_module_v1_module_proto.Messages().ByName("Module") + fd_Module_fee_collector_name = md_Module.Fields().ByName("fee_collector_name") + fd_Module_authority = md_Module.Fields().ByName("authority") +} + +var _ protoreflect.Message = (*fastReflection_Module)(nil) + +type fastReflection_Module Module + +func (x *Module) ProtoReflect() protoreflect.Message { + return (*fastReflection_Module)(x) +} + +func (x *Module) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_module_v1_module_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Module_messageType fastReflection_Module_messageType +var _ protoreflect.MessageType = fastReflection_Module_messageType{} + +type fastReflection_Module_messageType struct{} + +func (x fastReflection_Module_messageType) Zero() protoreflect.Message { + return (*fastReflection_Module)(nil) +} +func (x fastReflection_Module_messageType) New() protoreflect.Message { + return new(fastReflection_Module) +} +func (x fastReflection_Module_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Module) Descriptor() protoreflect.MessageDescriptor { + return md_Module +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Module) Type() protoreflect.MessageType { + return _fastReflection_Module_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Module) New() protoreflect.Message { + return new(fastReflection_Module) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { + return (*Module)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.FeeCollectorName != "" { + value := protoreflect.ValueOfString(x.FeeCollectorName) + if !f(fd_Module_fee_collector_name, value) { + return + } + } + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_Module_authority, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.module.v1.Module.fee_collector_name": + return x.FeeCollectorName != "" + case "sge.mint.module.v1.Module.authority": + return x.Authority != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.module.v1.Module")) + } + panic(fmt.Errorf("message sge.mint.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.module.v1.Module.fee_collector_name": + x.FeeCollectorName = "" + case "sge.mint.module.v1.Module.authority": + x.Authority = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.module.v1.Module")) + } + panic(fmt.Errorf("message sge.mint.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.module.v1.Module.fee_collector_name": + value := x.FeeCollectorName + return protoreflect.ValueOfString(value) + case "sge.mint.module.v1.Module.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.module.v1.Module")) + } + panic(fmt.Errorf("message sge.mint.module.v1.Module does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.module.v1.Module.fee_collector_name": + x.FeeCollectorName = value.Interface().(string) + case "sge.mint.module.v1.Module.authority": + x.Authority = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.module.v1.Module")) + } + panic(fmt.Errorf("message sge.mint.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.module.v1.Module.fee_collector_name": + panic(fmt.Errorf("field fee_collector_name of message sge.mint.module.v1.Module is not mutable")) + case "sge.mint.module.v1.Module.authority": + panic(fmt.Errorf("field authority of message sge.mint.module.v1.Module is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.module.v1.Module")) + } + panic(fmt.Errorf("message sge.mint.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.module.v1.Module.fee_collector_name": + return protoreflect.ValueOfString("") + case "sge.mint.module.v1.Module.authority": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.module.v1.Module")) + } + panic(fmt.Errorf("message sge.mint.module.v1.Module does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Module) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.module.v1.Module", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Module) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Module) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Module) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.FeeCollectorName) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0x12 + } + if len(x.FeeCollectorName) > 0 { + i -= len(x.FeeCollectorName) + copy(dAtA[i:], x.FeeCollectorName) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FeeCollectorName))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Module) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FeeCollectorName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.FeeCollectorName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/mint/module/v1/module.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Module is the config object of the mint module. +type Module struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + FeeCollectorName string `protobuf:"bytes,1,opt,name=fee_collector_name,json=feeCollectorName,proto3" json:"fee_collector_name,omitempty"` + // authority defines the custom module authority. If not set, defaults to the + // governance module. + Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"` +} + +func (x *Module) Reset() { + *x = Module{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_module_v1_module_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Module) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Module) ProtoMessage() {} + +// Deprecated: Use Module.ProtoReflect.Descriptor instead. +func (*Module) Descriptor() ([]byte, []int) { + return file_sge_mint_module_v1_module_proto_rawDescGZIP(), []int{0} +} + +func (x *Module) GetFeeCollectorName() string { + if x != nil { + return x.FeeCollectorName + } + return "" +} + +func (x *Module) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +var File_sge_mint_module_v1_module_proto protoreflect.FileDescriptor + +var file_sge_mint_module_v1_module_proto_rawDesc = []byte{ + 0x0a, 0x1f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x12, 0x12, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x6d, 0x6f, 0x64, 0x75, + 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, + 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x68, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x12, 0x2c, 0x0a, 0x12, 0x66, 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, + 0x6f, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x66, + 0x65, 0x65, 0x43, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x1c, 0x0a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x3a, 0x12, 0xba, + 0xc0, 0x96, 0xda, 0x01, 0x0c, 0x0a, 0x0a, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x6d, 0x69, 0x6e, + 0x74, 0x42, 0xcc, 0x01, 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, + 0x6e, 0x74, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x76, 0x31, 0x42, 0x0b, 0x4d, 0x6f, + 0x64, 0x75, 0x6c, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3a, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, + 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x6d, + 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x53, 0x4d, 0x4d, 0xaa, 0x02, 0x12, + 0x53, 0x67, 0x65, 0x2e, 0x4d, 0x69, 0x6e, 0x74, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, + 0x56, 0x31, 0xca, 0x02, 0x12, 0x53, 0x67, 0x65, 0x5c, 0x4d, 0x69, 0x6e, 0x74, 0x5c, 0x4d, 0x6f, + 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1e, 0x53, 0x67, 0x65, 0x5c, 0x4d, 0x69, + 0x6e, 0x74, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x15, 0x53, 0x67, 0x65, 0x3a, 0x3a, + 0x4d, 0x69, 0x6e, 0x74, 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_mint_module_v1_module_proto_rawDescOnce sync.Once + file_sge_mint_module_v1_module_proto_rawDescData = file_sge_mint_module_v1_module_proto_rawDesc +) + +func file_sge_mint_module_v1_module_proto_rawDescGZIP() []byte { + file_sge_mint_module_v1_module_proto_rawDescOnce.Do(func() { + file_sge_mint_module_v1_module_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_mint_module_v1_module_proto_rawDescData) + }) + return file_sge_mint_module_v1_module_proto_rawDescData +} + +var file_sge_mint_module_v1_module_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_mint_module_v1_module_proto_goTypes = []interface{}{ + (*Module)(nil), // 0: sge.mint.module.v1.Module +} +var file_sge_mint_module_v1_module_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_mint_module_v1_module_proto_init() } +func file_sge_mint_module_v1_module_proto_init() { + if File_sge_mint_module_v1_module_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_mint_module_v1_module_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Module); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_mint_module_v1_module_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_mint_module_v1_module_proto_goTypes, + DependencyIndexes: file_sge_mint_module_v1_module_proto_depIdxs, + MessageInfos: file_sge_mint_module_v1_module_proto_msgTypes, + }.Build() + File_sge_mint_module_v1_module_proto = out.File + file_sge_mint_module_v1_module_proto_rawDesc = nil + file_sge_mint_module_v1_module_proto_goTypes = nil + file_sge_mint_module_v1_module_proto_depIdxs = nil +} diff --git a/api/sge/mint/v1beta/genesis.pulsar.go b/api/sge/mint/v1beta/genesis.pulsar.go new file mode 100644 index 00000000..08185695 --- /dev/null +++ b/api/sge/mint/v1beta/genesis.pulsar.go @@ -0,0 +1,693 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package mintv1beta + +import ( + _ "cosmossdk.io/api/amino" + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_GenesisState protoreflect.MessageDescriptor + fd_GenesisState_minter protoreflect.FieldDescriptor + fd_GenesisState_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_genesis_proto_init() + md_GenesisState = File_sge_mint_v1beta_genesis_proto.Messages().ByName("GenesisState") + fd_GenesisState_minter = md_GenesisState.Fields().ByName("minter") + fd_GenesisState_params = md_GenesisState.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_GenesisState)(nil) + +type fastReflection_GenesisState GenesisState + +func (x *GenesisState) ProtoReflect() protoreflect.Message { + return (*fastReflection_GenesisState)(x) +} + +func (x *GenesisState) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_genesis_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_GenesisState_messageType fastReflection_GenesisState_messageType +var _ protoreflect.MessageType = fastReflection_GenesisState_messageType{} + +type fastReflection_GenesisState_messageType struct{} + +func (x fastReflection_GenesisState_messageType) Zero() protoreflect.Message { + return (*fastReflection_GenesisState)(nil) +} +func (x fastReflection_GenesisState_messageType) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} +func (x fastReflection_GenesisState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_GenesisState) Descriptor() protoreflect.MessageDescriptor { + return md_GenesisState +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_GenesisState) Type() protoreflect.MessageType { + return _fastReflection_GenesisState_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_GenesisState) New() protoreflect.Message { + return new(fastReflection_GenesisState) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_GenesisState) Interface() protoreflect.ProtoMessage { + return (*GenesisState)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_GenesisState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Minter != nil { + value := protoreflect.ValueOfMessage(x.Minter.ProtoReflect()) + if !f(fd_GenesisState_minter, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_GenesisState_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_GenesisState) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.GenesisState.minter": + return x.Minter != nil + case "sge.mint.v1beta.GenesisState.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.mint.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.GenesisState.minter": + x.Minter = nil + case "sge.mint.v1beta.GenesisState.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.mint.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_GenesisState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.GenesisState.minter": + value := x.Minter + return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "sge.mint.v1beta.GenesisState.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.mint.v1beta.GenesisState does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.GenesisState.minter": + x.Minter = value.Message().Interface().(*Minter) + case "sge.mint.v1beta.GenesisState.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.mint.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.GenesisState.minter": + if x.Minter == nil { + x.Minter = new(Minter) + } + return protoreflect.ValueOfMessage(x.Minter.ProtoReflect()) + case "sge.mint.v1beta.GenesisState.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.mint.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_GenesisState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.GenesisState.minter": + m := new(Minter) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "sge.mint.v1beta.GenesisState.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.GenesisState")) + } + panic(fmt.Errorf("message sge.mint.v1beta.GenesisState does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_GenesisState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.GenesisState", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_GenesisState) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_GenesisState) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_GenesisState) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Minter != nil { + l = options.Size(x.Minter) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if x.Minter != nil { + encoded, err := options.Marshal(x.Minter) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*GenesisState) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Minter", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Minter == nil { + x.Minter = &Minter{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Minter); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/mint/v1beta/genesis.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// GenesisState defines the mint module's genesis state. +type GenesisState struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // minter is a space for holding current inflation information. + Minter *Minter `protobuf:"bytes,1,opt,name=minter,proto3" json:"minter,omitempty"` + // params contains the mint module parameters. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *GenesisState) Reset() { + *x = GenesisState{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_genesis_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GenesisState) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GenesisState) ProtoMessage() {} + +// Deprecated: Use GenesisState.ProtoReflect.Descriptor instead. +func (*GenesisState) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_genesis_proto_rawDescGZIP(), []int{0} +} + +func (x *GenesisState) GetMinter() *Minter { + if x != nil { + return x.Minter + } + return nil +} + +func (x *GenesisState) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +var File_sge_mint_v1beta_genesis_proto protoreflect.FileDescriptor + +var file_sge_mint_v1beta_genesis_proto_rawDesc = []byte{ + 0x0a, 0x1d, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, + 0x0f, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, + 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x73, 0x67, 0x65, 0x2f, 0x6d, + 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x65, + 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, + 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x86, 0x01, 0x0a, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, + 0x73, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x3a, 0x0a, 0x06, 0x6d, 0x69, 0x6e, 0x74, 0x65, 0x72, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, + 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x42, + 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x6d, 0x69, 0x6e, 0x74, + 0x65, 0x72, 0x12, 0x3a, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, + 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0xbc, + 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0c, 0x47, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x50, + 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, + 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, + 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x69, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4d, 0x58, 0xaa, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x2e, 0x4d, 0x69, + 0x6e, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x5c, + 0x4d, 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x1b, 0x53, 0x67, + 0x65, 0x5c, 0x4d, 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x53, 0x67, 0x65, 0x3a, + 0x3a, 0x4d, 0x69, 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_mint_v1beta_genesis_proto_rawDescOnce sync.Once + file_sge_mint_v1beta_genesis_proto_rawDescData = file_sge_mint_v1beta_genesis_proto_rawDesc +) + +func file_sge_mint_v1beta_genesis_proto_rawDescGZIP() []byte { + file_sge_mint_v1beta_genesis_proto_rawDescOnce.Do(func() { + file_sge_mint_v1beta_genesis_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_mint_v1beta_genesis_proto_rawDescData) + }) + return file_sge_mint_v1beta_genesis_proto_rawDescData +} + +var file_sge_mint_v1beta_genesis_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_mint_v1beta_genesis_proto_goTypes = []interface{}{ + (*GenesisState)(nil), // 0: sge.mint.v1beta.GenesisState + (*Minter)(nil), // 1: sge.mint.v1beta.Minter + (*Params)(nil), // 2: sge.mint.v1beta.Params +} +var file_sge_mint_v1beta_genesis_proto_depIdxs = []int32{ + 1, // 0: sge.mint.v1beta.GenesisState.minter:type_name -> sge.mint.v1beta.Minter + 2, // 1: sge.mint.v1beta.GenesisState.params:type_name -> sge.mint.v1beta.Params + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name +} + +func init() { file_sge_mint_v1beta_genesis_proto_init() } +func file_sge_mint_v1beta_genesis_proto_init() { + if File_sge_mint_v1beta_genesis_proto != nil { + return + } + file_sge_mint_v1beta_minter_proto_init() + file_sge_mint_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_mint_v1beta_genesis_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenesisState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_mint_v1beta_genesis_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_mint_v1beta_genesis_proto_goTypes, + DependencyIndexes: file_sge_mint_v1beta_genesis_proto_depIdxs, + MessageInfos: file_sge_mint_v1beta_genesis_proto_msgTypes, + }.Build() + File_sge_mint_v1beta_genesis_proto = out.File + file_sge_mint_v1beta_genesis_proto_rawDesc = nil + file_sge_mint_v1beta_genesis_proto_goTypes = nil + file_sge_mint_v1beta_genesis_proto_depIdxs = nil +} diff --git a/api/sge/mint/v1beta/minter.pulsar.go b/api/sge/mint/v1beta/minter.pulsar.go new file mode 100644 index 00000000..da77d3fe --- /dev/null +++ b/api/sge/mint/v1beta/minter.pulsar.go @@ -0,0 +1,797 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package mintv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Minter protoreflect.MessageDescriptor + fd_Minter_inflation protoreflect.FieldDescriptor + fd_Minter_phase_step protoreflect.FieldDescriptor + fd_Minter_phase_provisions protoreflect.FieldDescriptor + fd_Minter_truncated_tokens protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_minter_proto_init() + md_Minter = File_sge_mint_v1beta_minter_proto.Messages().ByName("Minter") + fd_Minter_inflation = md_Minter.Fields().ByName("inflation") + fd_Minter_phase_step = md_Minter.Fields().ByName("phase_step") + fd_Minter_phase_provisions = md_Minter.Fields().ByName("phase_provisions") + fd_Minter_truncated_tokens = md_Minter.Fields().ByName("truncated_tokens") +} + +var _ protoreflect.Message = (*fastReflection_Minter)(nil) + +type fastReflection_Minter Minter + +func (x *Minter) ProtoReflect() protoreflect.Message { + return (*fastReflection_Minter)(x) +} + +func (x *Minter) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_minter_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Minter_messageType fastReflection_Minter_messageType +var _ protoreflect.MessageType = fastReflection_Minter_messageType{} + +type fastReflection_Minter_messageType struct{} + +func (x fastReflection_Minter_messageType) Zero() protoreflect.Message { + return (*fastReflection_Minter)(nil) +} +func (x fastReflection_Minter_messageType) New() protoreflect.Message { + return new(fastReflection_Minter) +} +func (x fastReflection_Minter_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Minter +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Minter) Descriptor() protoreflect.MessageDescriptor { + return md_Minter +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Minter) Type() protoreflect.MessageType { + return _fastReflection_Minter_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Minter) New() protoreflect.Message { + return new(fastReflection_Minter) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Minter) Interface() protoreflect.ProtoMessage { + return (*Minter)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Minter) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Inflation != "" { + value := protoreflect.ValueOfString(x.Inflation) + if !f(fd_Minter_inflation, value) { + return + } + } + if x.PhaseStep != int32(0) { + value := protoreflect.ValueOfInt32(x.PhaseStep) + if !f(fd_Minter_phase_step, value) { + return + } + } + if x.PhaseProvisions != "" { + value := protoreflect.ValueOfString(x.PhaseProvisions) + if !f(fd_Minter_phase_provisions, value) { + return + } + } + if x.TruncatedTokens != "" { + value := protoreflect.ValueOfString(x.TruncatedTokens) + if !f(fd_Minter_truncated_tokens, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Minter) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.Minter.inflation": + return x.Inflation != "" + case "sge.mint.v1beta.Minter.phase_step": + return x.PhaseStep != int32(0) + case "sge.mint.v1beta.Minter.phase_provisions": + return x.PhaseProvisions != "" + case "sge.mint.v1beta.Minter.truncated_tokens": + return x.TruncatedTokens != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Minter")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Minter does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Minter) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.Minter.inflation": + x.Inflation = "" + case "sge.mint.v1beta.Minter.phase_step": + x.PhaseStep = int32(0) + case "sge.mint.v1beta.Minter.phase_provisions": + x.PhaseProvisions = "" + case "sge.mint.v1beta.Minter.truncated_tokens": + x.TruncatedTokens = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Minter")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Minter does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Minter) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.Minter.inflation": + value := x.Inflation + return protoreflect.ValueOfString(value) + case "sge.mint.v1beta.Minter.phase_step": + value := x.PhaseStep + return protoreflect.ValueOfInt32(value) + case "sge.mint.v1beta.Minter.phase_provisions": + value := x.PhaseProvisions + return protoreflect.ValueOfString(value) + case "sge.mint.v1beta.Minter.truncated_tokens": + value := x.TruncatedTokens + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Minter")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Minter does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Minter) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.Minter.inflation": + x.Inflation = value.Interface().(string) + case "sge.mint.v1beta.Minter.phase_step": + x.PhaseStep = int32(value.Int()) + case "sge.mint.v1beta.Minter.phase_provisions": + x.PhaseProvisions = value.Interface().(string) + case "sge.mint.v1beta.Minter.truncated_tokens": + x.TruncatedTokens = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Minter")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Minter does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Minter) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.Minter.inflation": + panic(fmt.Errorf("field inflation of message sge.mint.v1beta.Minter is not mutable")) + case "sge.mint.v1beta.Minter.phase_step": + panic(fmt.Errorf("field phase_step of message sge.mint.v1beta.Minter is not mutable")) + case "sge.mint.v1beta.Minter.phase_provisions": + panic(fmt.Errorf("field phase_provisions of message sge.mint.v1beta.Minter is not mutable")) + case "sge.mint.v1beta.Minter.truncated_tokens": + panic(fmt.Errorf("field truncated_tokens of message sge.mint.v1beta.Minter is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Minter")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Minter does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Minter) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.Minter.inflation": + return protoreflect.ValueOfString("") + case "sge.mint.v1beta.Minter.phase_step": + return protoreflect.ValueOfInt32(int32(0)) + case "sge.mint.v1beta.Minter.phase_provisions": + return protoreflect.ValueOfString("") + case "sge.mint.v1beta.Minter.truncated_tokens": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Minter")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Minter does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Minter) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.Minter", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Minter) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Minter) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Minter) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Minter) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Minter) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Inflation) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.PhaseStep != 0 { + n += 1 + runtime.Sov(uint64(x.PhaseStep)) + } + l = len(x.PhaseProvisions) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.TruncatedTokens) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Minter) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.TruncatedTokens) > 0 { + i -= len(x.TruncatedTokens) + copy(dAtA[i:], x.TruncatedTokens) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.TruncatedTokens))) + i-- + dAtA[i] = 0x22 + } + if len(x.PhaseProvisions) > 0 { + i -= len(x.PhaseProvisions) + copy(dAtA[i:], x.PhaseProvisions) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PhaseProvisions))) + i-- + dAtA[i] = 0x1a + } + if x.PhaseStep != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.PhaseStep)) + i-- + dAtA[i] = 0x10 + } + if len(x.Inflation) > 0 { + i -= len(x.Inflation) + copy(dAtA[i:], x.Inflation) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Inflation))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Minter) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Minter: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Minter: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Inflation", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Inflation = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PhaseStep", wireType) + } + x.PhaseStep = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.PhaseStep |= int32(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PhaseProvisions", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PhaseProvisions = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TruncatedTokens", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.TruncatedTokens = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/mint/v1beta/minter.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Minter represents the minting state. +type Minter struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // inflation is the current annual inflation rate. + Inflation string `protobuf:"bytes,1,opt,name=inflation,proto3" json:"inflation,omitempty"` + // phase_step is the index of phases slice + 1. + PhaseStep int32 `protobuf:"varint,2,opt,name=phase_step,json=phaseStep,proto3" json:"phase_step,omitempty"` + // phase_provisions is the current phase expected provisions. + PhaseProvisions string `protobuf:"bytes,3,opt,name=phase_provisions,json=phaseProvisions,proto3" json:"phase_provisions,omitempty"` + // truncated_tokens holds current truncated tokens because of Dec to Int + // conversion in the minting. + TruncatedTokens string `protobuf:"bytes,4,opt,name=truncated_tokens,json=truncatedTokens,proto3" json:"truncated_tokens,omitempty"` +} + +func (x *Minter) Reset() { + *x = Minter{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_minter_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Minter) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Minter) ProtoMessage() {} + +// Deprecated: Use Minter.ProtoReflect.Descriptor instead. +func (*Minter) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_minter_proto_rawDescGZIP(), []int{0} +} + +func (x *Minter) GetInflation() string { + if x != nil { + return x.Inflation + } + return "" +} + +func (x *Minter) GetPhaseStep() int32 { + if x != nil { + return x.PhaseStep + } + return 0 +} + +func (x *Minter) GetPhaseProvisions() string { + if x != nil { + return x.PhaseProvisions + } + return "" +} + +func (x *Minter) GetTruncatedTokens() string { + if x != nil { + return x.TruncatedTokens + } + return "" +} + +var File_sge_mint_v1beta_minter_proto protoreflect.FileDescriptor + +var file_sge_mint_v1beta_minter_proto_rawDesc = []byte{ + 0x0a, 0x1c, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, + 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, + 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x22, 0xcf, 0x02, 0x0a, 0x06, 0x4d, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x4f, 0x0a, 0x09, 0x69, + 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x31, + 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x44, 0x65, 0x63, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, + 0x63, 0x52, 0x09, 0x69, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x0a, 0x0a, + 0x70, 0x68, 0x61, 0x73, 0x65, 0x5f, 0x73, 0x74, 0x65, 0x70, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x09, 0x70, 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, 0x65, 0x70, 0x12, 0x77, 0x0a, 0x10, 0x70, + 0x68, 0x61, 0x73, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x4c, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, + 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xf2, 0xde, 0x1f, 0x17, 0x79, 0x61, + 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x68, 0x61, 0x73, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x73, + 0x69, 0x6f, 0x6e, 0x73, 0x22, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x44, 0x65, 0x63, 0x52, 0x0f, 0x70, 0x68, 0x61, 0x73, 0x65, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, + 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x5c, 0x0a, 0x10, 0x74, 0x72, 0x75, 0x6e, 0x63, 0x61, 0x74, 0x65, + 0x64, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x31, + 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, + 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, + 0x44, 0x65, 0x63, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, + 0x63, 0x52, 0x0f, 0x74, 0x72, 0x75, 0x6e, 0x63, 0x61, 0x74, 0x65, 0x64, 0x54, 0x6f, 0x6b, 0x65, + 0x6e, 0x73, 0x42, 0xbb, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, + 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x4d, 0x69, 0x6e, 0x74, + 0x65, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, + 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, + 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x69, 0x6e, 0x74, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, 0x53, 0x4d, 0x58, 0xaa, 0x02, 0x0f, 0x53, 0x67, 0x65, + 0x2e, 0x4d, 0x69, 0x6e, 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x0f, 0x53, + 0x67, 0x65, 0x5c, 0x4d, 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, + 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4d, 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x53, + 0x67, 0x65, 0x3a, 0x3a, 0x4d, 0x69, 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_mint_v1beta_minter_proto_rawDescOnce sync.Once + file_sge_mint_v1beta_minter_proto_rawDescData = file_sge_mint_v1beta_minter_proto_rawDesc +) + +func file_sge_mint_v1beta_minter_proto_rawDescGZIP() []byte { + file_sge_mint_v1beta_minter_proto_rawDescOnce.Do(func() { + file_sge_mint_v1beta_minter_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_mint_v1beta_minter_proto_rawDescData) + }) + return file_sge_mint_v1beta_minter_proto_rawDescData +} + +var file_sge_mint_v1beta_minter_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_mint_v1beta_minter_proto_goTypes = []interface{}{ + (*Minter)(nil), // 0: sge.mint.v1beta.Minter +} +var file_sge_mint_v1beta_minter_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_mint_v1beta_minter_proto_init() } +func file_sge_mint_v1beta_minter_proto_init() { + if File_sge_mint_v1beta_minter_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_mint_v1beta_minter_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Minter); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_mint_v1beta_minter_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_mint_v1beta_minter_proto_goTypes, + DependencyIndexes: file_sge_mint_v1beta_minter_proto_depIdxs, + MessageInfos: file_sge_mint_v1beta_minter_proto_msgTypes, + }.Build() + File_sge_mint_v1beta_minter_proto = out.File + file_sge_mint_v1beta_minter_proto_rawDesc = nil + file_sge_mint_v1beta_minter_proto_goTypes = nil + file_sge_mint_v1beta_minter_proto_depIdxs = nil +} diff --git a/api/sge/mint/v1beta/params.pulsar.go b/api/sge/mint/v1beta/params.pulsar.go new file mode 100644 index 00000000..0a5849c2 --- /dev/null +++ b/api/sge/mint/v1beta/params.pulsar.go @@ -0,0 +1,869 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package mintv1beta + +import ( + fmt "fmt" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var _ protoreflect.List = (*_Params_3_list)(nil) + +type _Params_3_list struct { + list *[]*Phase +} + +func (x *_Params_3_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_Params_3_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) +} + +func (x *_Params_3_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Phase) + (*x.list)[i] = concreteValue +} + +func (x *_Params_3_list) Append(value protoreflect.Value) { + valueUnwrapped := value.Message() + concreteValue := valueUnwrapped.Interface().(*Phase) + *x.list = append(*x.list, concreteValue) +} + +func (x *_Params_3_list) AppendMutable() protoreflect.Value { + v := new(Phase) + *x.list = append(*x.list, v) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_Params_3_list) Truncate(n int) { + for i := n; i < len(*x.list); i++ { + (*x.list)[i] = nil + } + *x.list = (*x.list)[:n] +} + +func (x *_Params_3_list) NewElement() protoreflect.Value { + v := new(Phase) + return protoreflect.ValueOfMessage(v.ProtoReflect()) +} + +func (x *_Params_3_list) IsValid() bool { + return x.list != nil +} + +var ( + md_Params protoreflect.MessageDescriptor + fd_Params_mint_denom protoreflect.FieldDescriptor + fd_Params_blocks_per_year protoreflect.FieldDescriptor + fd_Params_phases protoreflect.FieldDescriptor + fd_Params_exclude_amount protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_params_proto_init() + md_Params = File_sge_mint_v1beta_params_proto.Messages().ByName("Params") + fd_Params_mint_denom = md_Params.Fields().ByName("mint_denom") + fd_Params_blocks_per_year = md_Params.Fields().ByName("blocks_per_year") + fd_Params_phases = md_Params.Fields().ByName("phases") + fd_Params_exclude_amount = md_Params.Fields().ByName("exclude_amount") +} + +var _ protoreflect.Message = (*fastReflection_Params)(nil) + +type fastReflection_Params Params + +func (x *Params) ProtoReflect() protoreflect.Message { + return (*fastReflection_Params)(x) +} + +func (x *Params) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_params_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Params_messageType fastReflection_Params_messageType +var _ protoreflect.MessageType = fastReflection_Params_messageType{} + +type fastReflection_Params_messageType struct{} + +func (x fastReflection_Params_messageType) Zero() protoreflect.Message { + return (*fastReflection_Params)(nil) +} +func (x fastReflection_Params_messageType) New() protoreflect.Message { + return new(fastReflection_Params) +} +func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor { + return md_Params +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Params) Type() protoreflect.MessageType { + return _fastReflection_Params_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Params) New() protoreflect.Message { + return new(fastReflection_Params) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { + return (*Params)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.MintDenom != "" { + value := protoreflect.ValueOfString(x.MintDenom) + if !f(fd_Params_mint_denom, value) { + return + } + } + if x.BlocksPerYear != uint64(0) { + value := protoreflect.ValueOfUint64(x.BlocksPerYear) + if !f(fd_Params_blocks_per_year, value) { + return + } + } + if len(x.Phases) != 0 { + value := protoreflect.ValueOfList(&_Params_3_list{list: &x.Phases}) + if !f(fd_Params_phases, value) { + return + } + } + if x.ExcludeAmount != "" { + value := protoreflect.ValueOfString(x.ExcludeAmount) + if !f(fd_Params_exclude_amount, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.Params.mint_denom": + return x.MintDenom != "" + case "sge.mint.v1beta.Params.blocks_per_year": + return x.BlocksPerYear != uint64(0) + case "sge.mint.v1beta.Params.phases": + return len(x.Phases) != 0 + case "sge.mint.v1beta.Params.exclude_amount": + return x.ExcludeAmount != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Params")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.Params.mint_denom": + x.MintDenom = "" + case "sge.mint.v1beta.Params.blocks_per_year": + x.BlocksPerYear = uint64(0) + case "sge.mint.v1beta.Params.phases": + x.Phases = nil + case "sge.mint.v1beta.Params.exclude_amount": + x.ExcludeAmount = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Params")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.Params.mint_denom": + value := x.MintDenom + return protoreflect.ValueOfString(value) + case "sge.mint.v1beta.Params.blocks_per_year": + value := x.BlocksPerYear + return protoreflect.ValueOfUint64(value) + case "sge.mint.v1beta.Params.phases": + if len(x.Phases) == 0 { + return protoreflect.ValueOfList(&_Params_3_list{}) + } + listValue := &_Params_3_list{list: &x.Phases} + return protoreflect.ValueOfList(listValue) + case "sge.mint.v1beta.Params.exclude_amount": + value := x.ExcludeAmount + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Params")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Params does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.Params.mint_denom": + x.MintDenom = value.Interface().(string) + case "sge.mint.v1beta.Params.blocks_per_year": + x.BlocksPerYear = value.Uint() + case "sge.mint.v1beta.Params.phases": + lv := value.List() + clv := lv.(*_Params_3_list) + x.Phases = *clv.list + case "sge.mint.v1beta.Params.exclude_amount": + x.ExcludeAmount = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Params")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.Params.phases": + if x.Phases == nil { + x.Phases = []*Phase{} + } + value := &_Params_3_list{list: &x.Phases} + return protoreflect.ValueOfList(value) + case "sge.mint.v1beta.Params.mint_denom": + panic(fmt.Errorf("field mint_denom of message sge.mint.v1beta.Params is not mutable")) + case "sge.mint.v1beta.Params.blocks_per_year": + panic(fmt.Errorf("field blocks_per_year of message sge.mint.v1beta.Params is not mutable")) + case "sge.mint.v1beta.Params.exclude_amount": + panic(fmt.Errorf("field exclude_amount of message sge.mint.v1beta.Params is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Params")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.Params.mint_denom": + return protoreflect.ValueOfString("") + case "sge.mint.v1beta.Params.blocks_per_year": + return protoreflect.ValueOfUint64(uint64(0)) + case "sge.mint.v1beta.Params.phases": + list := []*Phase{} + return protoreflect.ValueOfList(&_Params_3_list{list: &list}) + case "sge.mint.v1beta.Params.exclude_amount": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Params")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Params does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.Params", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Params) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.MintDenom) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.BlocksPerYear != 0 { + n += 1 + runtime.Sov(uint64(x.BlocksPerYear)) + } + if len(x.Phases) > 0 { + for _, e := range x.Phases { + l = options.Size(e) + n += 1 + l + runtime.Sov(uint64(l)) + } + } + l = len(x.ExcludeAmount) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.ExcludeAmount) > 0 { + i -= len(x.ExcludeAmount) + copy(dAtA[i:], x.ExcludeAmount) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ExcludeAmount))) + i-- + dAtA[i] = 0x22 + } + if len(x.Phases) > 0 { + for iNdEx := len(x.Phases) - 1; iNdEx >= 0; iNdEx-- { + encoded, err := options.Marshal(x.Phases[iNdEx]) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x1a + } + } + if x.BlocksPerYear != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.BlocksPerYear)) + i-- + dAtA[i] = 0x10 + } + if len(x.MintDenom) > 0 { + i -= len(x.MintDenom) + copy(dAtA[i:], x.MintDenom) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MintDenom))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Params) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MintDenom", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.MintDenom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BlocksPerYear", wireType) + } + x.BlocksPerYear = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.BlocksPerYear |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Phases", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Phases = append(x.Phases, &Phase{}) + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Phases[len(x.Phases)-1]); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExcludeAmount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.ExcludeAmount = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/mint/v1beta/params.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Params define the parameters for the module. +type Params struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // mint_denom is the type of coin to mint. + MintDenom string `protobuf:"bytes,1,opt,name=mint_denom,json=mintDenom,proto3" json:"mint_denom,omitempty"` + // blocks_per_year is expected blocks per year. + BlocksPerYear uint64 `protobuf:"varint,2,opt,name=blocks_per_year,json=blocksPerYear,proto3" json:"blocks_per_year,omitempty"` + // phases contains phases of inflation. + Phases []*Phase `protobuf:"bytes,3,rep,name=phases,proto3" json:"phases,omitempty"` + // exclude_amount is the excluded amount form being calculated in inflation. + ExcludeAmount string `protobuf:"bytes,4,opt,name=exclude_amount,json=excludeAmount,proto3" json:"exclude_amount,omitempty"` +} + +func (x *Params) Reset() { + *x = Params{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_params_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Params) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Params) ProtoMessage() {} + +// Deprecated: Use Params.ProtoReflect.Descriptor instead. +func (*Params) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_params_proto_rawDescGZIP(), []int{0} +} + +func (x *Params) GetMintDenom() string { + if x != nil { + return x.MintDenom + } + return "" +} + +func (x *Params) GetBlocksPerYear() uint64 { + if x != nil { + return x.BlocksPerYear + } + return 0 +} + +func (x *Params) GetPhases() []*Phase { + if x != nil { + return x.Phases + } + return nil +} + +func (x *Params) GetExcludeAmount() string { + if x != nil { + return x.ExcludeAmount + } + return "" +} + +var File_sge_mint_v1beta_params_proto protoreflect.FileDescriptor + +var file_sge_mint_v1beta_params_proto_rawDesc = []byte{ + 0x0a, 0x1c, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, + 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, + 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1b, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x68, 0x61, 0x73, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x22, 0x97, 0x02, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1d, 0x0a, + 0x0a, 0x6d, 0x69, 0x6e, 0x74, 0x5f, 0x64, 0x65, 0x6e, 0x6f, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x6d, 0x69, 0x6e, 0x74, 0x44, 0x65, 0x6e, 0x6f, 0x6d, 0x12, 0x42, 0x0a, 0x0f, + 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x5f, 0x70, 0x65, 0x72, 0x5f, 0x79, 0x65, 0x61, 0x72, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x04, 0x42, 0x1a, 0xf2, 0xde, 0x1f, 0x16, 0x79, 0x61, 0x6d, 0x6c, 0x3a, + 0x22, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x5f, 0x70, 0x65, 0x72, 0x5f, 0x79, 0x65, 0x61, 0x72, + 0x22, 0x52, 0x0d, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x50, 0x65, 0x72, 0x59, 0x65, 0x61, 0x72, + 0x12, 0x45, 0x0a, 0x06, 0x70, 0x68, 0x61, 0x73, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x16, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x50, 0x68, 0x61, 0x73, 0x65, 0x42, 0x15, 0xc8, 0xde, 0x1f, 0x00, 0xf2, 0xde, + 0x1f, 0x0d, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x68, 0x61, 0x73, 0x65, 0x73, 0x22, 0x52, + 0x06, 0x70, 0x68, 0x61, 0x73, 0x65, 0x73, 0x12, 0x5d, 0x0a, 0x0e, 0x65, 0x78, 0x63, 0x6c, 0x75, + 0x64, 0x65, 0x5f, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x36, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x15, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, + 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x49, 0x6e, 0x74, 0xf2, 0xde, + 0x1f, 0x15, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x65, 0x78, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x5f, + 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x52, 0x0d, 0x65, 0x78, 0x63, 0x6c, 0x75, 0x64, 0x65, + 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xbb, 0x01, 0x0a, + 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x42, 0x0b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x69, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4d, 0x58, 0xaa, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x2e, 0x4d, 0x69, 0x6e, 0x74, 0x2e, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x5c, 0x4d, 0x69, 0x6e, + 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4d, + 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4d, 0x69, + 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, +} + +var ( + file_sge_mint_v1beta_params_proto_rawDescOnce sync.Once + file_sge_mint_v1beta_params_proto_rawDescData = file_sge_mint_v1beta_params_proto_rawDesc +) + +func file_sge_mint_v1beta_params_proto_rawDescGZIP() []byte { + file_sge_mint_v1beta_params_proto_rawDescOnce.Do(func() { + file_sge_mint_v1beta_params_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_mint_v1beta_params_proto_rawDescData) + }) + return file_sge_mint_v1beta_params_proto_rawDescData +} + +var file_sge_mint_v1beta_params_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_mint_v1beta_params_proto_goTypes = []interface{}{ + (*Params)(nil), // 0: sge.mint.v1beta.Params + (*Phase)(nil), // 1: sge.mint.v1beta.Phase +} +var file_sge_mint_v1beta_params_proto_depIdxs = []int32{ + 1, // 0: sge.mint.v1beta.Params.phases:type_name -> sge.mint.v1beta.Phase + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_mint_v1beta_params_proto_init() } +func file_sge_mint_v1beta_params_proto_init() { + if File_sge_mint_v1beta_params_proto != nil { + return + } + file_sge_mint_v1beta_phase_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_mint_v1beta_params_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Params); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_mint_v1beta_params_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_mint_v1beta_params_proto_goTypes, + DependencyIndexes: file_sge_mint_v1beta_params_proto_depIdxs, + MessageInfos: file_sge_mint_v1beta_params_proto_msgTypes, + }.Build() + File_sge_mint_v1beta_params_proto = out.File + file_sge_mint_v1beta_params_proto_rawDesc = nil + file_sge_mint_v1beta_params_proto_goTypes = nil + file_sge_mint_v1beta_params_proto_depIdxs = nil +} diff --git a/api/sge/mint/v1beta/phase.pulsar.go b/api/sge/mint/v1beta/phase.pulsar.go new file mode 100644 index 00000000..cf0f88eb --- /dev/null +++ b/api/sge/mint/v1beta/phase.pulsar.go @@ -0,0 +1,660 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package mintv1beta + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_Phase protoreflect.MessageDescriptor + fd_Phase_inflation protoreflect.FieldDescriptor + fd_Phase_year_coefficient protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_phase_proto_init() + md_Phase = File_sge_mint_v1beta_phase_proto.Messages().ByName("Phase") + fd_Phase_inflation = md_Phase.Fields().ByName("inflation") + fd_Phase_year_coefficient = md_Phase.Fields().ByName("year_coefficient") +} + +var _ protoreflect.Message = (*fastReflection_Phase)(nil) + +type fastReflection_Phase Phase + +func (x *Phase) ProtoReflect() protoreflect.Message { + return (*fastReflection_Phase)(x) +} + +func (x *Phase) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_phase_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_Phase_messageType fastReflection_Phase_messageType +var _ protoreflect.MessageType = fastReflection_Phase_messageType{} + +type fastReflection_Phase_messageType struct{} + +func (x fastReflection_Phase_messageType) Zero() protoreflect.Message { + return (*fastReflection_Phase)(nil) +} +func (x fastReflection_Phase_messageType) New() protoreflect.Message { + return new(fastReflection_Phase) +} +func (x fastReflection_Phase_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_Phase +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_Phase) Descriptor() protoreflect.MessageDescriptor { + return md_Phase +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_Phase) Type() protoreflect.MessageType { + return _fastReflection_Phase_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_Phase) New() protoreflect.Message { + return new(fastReflection_Phase) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_Phase) Interface() protoreflect.ProtoMessage { + return (*Phase)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_Phase) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Inflation != "" { + value := protoreflect.ValueOfString(x.Inflation) + if !f(fd_Phase_inflation, value) { + return + } + } + if x.YearCoefficient != "" { + value := protoreflect.ValueOfString(x.YearCoefficient) + if !f(fd_Phase_year_coefficient, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_Phase) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.Phase.inflation": + return x.Inflation != "" + case "sge.mint.v1beta.Phase.year_coefficient": + return x.YearCoefficient != "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Phase")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Phase does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Phase) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.Phase.inflation": + x.Inflation = "" + case "sge.mint.v1beta.Phase.year_coefficient": + x.YearCoefficient = "" + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Phase")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Phase does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_Phase) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.Phase.inflation": + value := x.Inflation + return protoreflect.ValueOfString(value) + case "sge.mint.v1beta.Phase.year_coefficient": + value := x.YearCoefficient + return protoreflect.ValueOfString(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Phase")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Phase does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Phase) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.Phase.inflation": + x.Inflation = value.Interface().(string) + case "sge.mint.v1beta.Phase.year_coefficient": + x.YearCoefficient = value.Interface().(string) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Phase")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Phase does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Phase) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.Phase.inflation": + panic(fmt.Errorf("field inflation of message sge.mint.v1beta.Phase is not mutable")) + case "sge.mint.v1beta.Phase.year_coefficient": + panic(fmt.Errorf("field year_coefficient of message sge.mint.v1beta.Phase is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Phase")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Phase does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_Phase) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.Phase.inflation": + return protoreflect.ValueOfString("") + case "sge.mint.v1beta.Phase.year_coefficient": + return protoreflect.ValueOfString("") + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.Phase")) + } + panic(fmt.Errorf("message sge.mint.v1beta.Phase does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_Phase) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.Phase", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_Phase) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_Phase) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_Phase) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_Phase) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*Phase) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Inflation) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + l = len(x.YearCoefficient) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*Phase) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.YearCoefficient) > 0 { + i -= len(x.YearCoefficient) + copy(dAtA[i:], x.YearCoefficient) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.YearCoefficient))) + i-- + dAtA[i] = 0x12 + } + if len(x.Inflation) > 0 { + i -= len(x.Inflation) + copy(dAtA[i:], x.Inflation) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Inflation))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*Phase) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Phase: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Phase: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Inflation", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Inflation = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field YearCoefficient", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.YearCoefficient = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/mint/v1beta/phase.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Phase defines the phase parameters for the module. +type Phase struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // inflation is the current phase inflation rate. + Inflation string `protobuf:"bytes,1,opt,name=inflation,proto3" json:"inflation,omitempty"` + // year_coefficient is the proportion of a complete year. + YearCoefficient string `protobuf:"bytes,2,opt,name=year_coefficient,json=yearCoefficient,proto3" json:"year_coefficient,omitempty"` +} + +func (x *Phase) Reset() { + *x = Phase{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_phase_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Phase) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Phase) ProtoMessage() {} + +// Deprecated: Use Phase.ProtoReflect.Descriptor instead. +func (*Phase) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_phase_proto_rawDescGZIP(), []int{0} +} + +func (x *Phase) GetInflation() string { + if x != nil { + return x.Inflation + } + return "" +} + +func (x *Phase) GetYearCoefficient() string { + if x != nil { + return x.YearCoefficient + } + return "" +} + +var File_sge_mint_v1beta_phase_proto protoreflect.FileDescriptor + +var file_sge_mint_v1beta_phase_proto_rawDesc = []byte{ + 0x0a, 0x1b, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x70, 0x68, 0x61, 0x73, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, 0x73, + 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x19, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, + 0xeb, 0x01, 0x0a, 0x05, 0x50, 0x68, 0x61, 0x73, 0x65, 0x12, 0x63, 0x0a, 0x09, 0x69, 0x6e, 0x66, + 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x45, 0xc8, 0xde, + 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, + 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, + 0x63, 0xf2, 0xde, 0x1f, 0x10, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x69, 0x6e, 0x66, 0x6c, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x44, 0x65, 0x63, 0x52, 0x09, 0x69, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x77, + 0x0a, 0x10, 0x79, 0x65, 0x61, 0x72, 0x5f, 0x63, 0x6f, 0x65, 0x66, 0x66, 0x69, 0x63, 0x69, 0x65, + 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x4c, 0xc8, 0xde, 0x1f, 0x00, 0xda, 0xde, + 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x6d, + 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x63, 0xf2, 0xde, 0x1f, + 0x17, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x79, 0x65, 0x61, 0x72, 0x5f, 0x63, 0x6f, 0x65, 0x66, + 0x66, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x74, 0x22, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x0f, 0x79, 0x65, 0x61, 0x72, 0x43, 0x6f, 0x65, 0x66, + 0x66, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x74, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xba, 0x01, + 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x50, 0x68, 0x61, 0x73, 0x65, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x69, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, + 0x03, 0x53, 0x4d, 0x58, 0xaa, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x2e, 0x4d, 0x69, 0x6e, 0x74, 0x2e, + 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x5c, 0x4d, 0x69, 0x6e, + 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4d, + 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4d, 0x69, + 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, +} + +var ( + file_sge_mint_v1beta_phase_proto_rawDescOnce sync.Once + file_sge_mint_v1beta_phase_proto_rawDescData = file_sge_mint_v1beta_phase_proto_rawDesc +) + +func file_sge_mint_v1beta_phase_proto_rawDescGZIP() []byte { + file_sge_mint_v1beta_phase_proto_rawDescOnce.Do(func() { + file_sge_mint_v1beta_phase_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_mint_v1beta_phase_proto_rawDescData) + }) + return file_sge_mint_v1beta_phase_proto_rawDescData +} + +var file_sge_mint_v1beta_phase_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_sge_mint_v1beta_phase_proto_goTypes = []interface{}{ + (*Phase)(nil), // 0: sge.mint.v1beta.Phase +} +var file_sge_mint_v1beta_phase_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_sge_mint_v1beta_phase_proto_init() } +func file_sge_mint_v1beta_phase_proto_init() { + if File_sge_mint_v1beta_phase_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_sge_mint_v1beta_phase_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Phase); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_mint_v1beta_phase_proto_rawDesc, + NumEnums: 0, + NumMessages: 1, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_sge_mint_v1beta_phase_proto_goTypes, + DependencyIndexes: file_sge_mint_v1beta_phase_proto_depIdxs, + MessageInfos: file_sge_mint_v1beta_phase_proto_msgTypes, + }.Build() + File_sge_mint_v1beta_phase_proto = out.File + file_sge_mint_v1beta_phase_proto_rawDesc = nil + file_sge_mint_v1beta_phase_proto_goTypes = nil + file_sge_mint_v1beta_phase_proto_depIdxs = nil +} diff --git a/api/sge/mint/v1beta/query.pulsar.go b/api/sge/mint/v1beta/query.pulsar.go new file mode 100644 index 00000000..b66be08e --- /dev/null +++ b/api/sge/mint/v1beta/query.pulsar.go @@ -0,0 +1,4541 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package mintv1beta + +import ( + _ "cosmossdk.io/api/amino" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_QueryParamsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryParamsRequest = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryParamsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsRequest)(nil) + +type fastReflection_QueryParamsRequest QueryParamsRequest + +func (x *QueryParamsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(x) +} + +func (x *QueryParamsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsRequest_messageType fastReflection_QueryParamsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsRequest_messageType{} + +type fastReflection_QueryParamsRequest_messageType struct{} + +func (x fastReflection_QueryParamsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsRequest)(nil) +} +func (x fastReflection_QueryParamsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} +func (x fastReflection_QueryParamsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsRequest) New() protoreflect.Message { + return new(fastReflection_QueryParamsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryParamsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryParamsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryParamsResponse protoreflect.MessageDescriptor + fd_QueryParamsResponse_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryParamsResponse = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryParamsResponse") + fd_QueryParamsResponse_params = md_QueryParamsResponse.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_QueryParamsResponse)(nil) + +type fastReflection_QueryParamsResponse QueryParamsResponse + +func (x *QueryParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(x) +} + +func (x *QueryParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryParamsResponse_messageType fastReflection_QueryParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryParamsResponse_messageType{} + +type fastReflection_QueryParamsResponse_messageType struct{} + +func (x fastReflection_QueryParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryParamsResponse)(nil) +} +func (x fastReflection_QueryParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} +func (x fastReflection_QueryParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryParamsResponse) New() protoreflect.Message { + return new(fastReflection_QueryParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryParamsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_QueryParamsResponse_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.QueryParamsResponse.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryParamsResponse.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.QueryParamsResponse.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryParamsResponse.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryParamsResponse.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryParamsResponse.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryInflationRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryInflationRequest = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryInflationRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryInflationRequest)(nil) + +type fastReflection_QueryInflationRequest QueryInflationRequest + +func (x *QueryInflationRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryInflationRequest)(x) +} + +func (x *QueryInflationRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryInflationRequest_messageType fastReflection_QueryInflationRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryInflationRequest_messageType{} + +type fastReflection_QueryInflationRequest_messageType struct{} + +func (x fastReflection_QueryInflationRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryInflationRequest)(nil) +} +func (x fastReflection_QueryInflationRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryInflationRequest) +} +func (x fastReflection_QueryInflationRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryInflationRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryInflationRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryInflationRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryInflationRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryInflationRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryInflationRequest) New() protoreflect.Message { + return new(fastReflection_QueryInflationRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryInflationRequest) Interface() protoreflect.ProtoMessage { + return (*QueryInflationRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryInflationRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryInflationRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryInflationRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryInflationRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryInflationRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryInflationRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryInflationRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryInflationRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryInflationRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryInflationRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryInflationRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryInflationRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryInflationRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryInflationRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryInflationResponse protoreflect.MessageDescriptor + fd_QueryInflationResponse_inflation protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryInflationResponse = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryInflationResponse") + fd_QueryInflationResponse_inflation = md_QueryInflationResponse.Fields().ByName("inflation") +} + +var _ protoreflect.Message = (*fastReflection_QueryInflationResponse)(nil) + +type fastReflection_QueryInflationResponse QueryInflationResponse + +func (x *QueryInflationResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryInflationResponse)(x) +} + +func (x *QueryInflationResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryInflationResponse_messageType fastReflection_QueryInflationResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryInflationResponse_messageType{} + +type fastReflection_QueryInflationResponse_messageType struct{} + +func (x fastReflection_QueryInflationResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryInflationResponse)(nil) +} +func (x fastReflection_QueryInflationResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryInflationResponse) +} +func (x fastReflection_QueryInflationResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryInflationResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryInflationResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryInflationResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryInflationResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryInflationResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryInflationResponse) New() protoreflect.Message { + return new(fastReflection_QueryInflationResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryInflationResponse) Interface() protoreflect.ProtoMessage { + return (*QueryInflationResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryInflationResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.Inflation) != 0 { + value := protoreflect.ValueOfBytes(x.Inflation) + if !f(fd_QueryInflationResponse_inflation, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryInflationResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.QueryInflationResponse.inflation": + return len(x.Inflation) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryInflationResponse.inflation": + x.Inflation = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryInflationResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.QueryInflationResponse.inflation": + value := x.Inflation + return protoreflect.ValueOfBytes(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryInflationResponse.inflation": + x.Inflation = value.Bytes() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryInflationResponse.inflation": + panic(fmt.Errorf("field inflation of message sge.mint.v1beta.QueryInflationResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryInflationResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryInflationResponse.inflation": + return protoreflect.ValueOfBytes(nil) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryInflationResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryInflationResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryInflationResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryInflationResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryInflationResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryInflationResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryInflationResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryInflationResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryInflationResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Inflation) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryInflationResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.Inflation) > 0 { + i -= len(x.Inflation) + copy(dAtA[i:], x.Inflation) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Inflation))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryInflationResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryInflationResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryInflationResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Inflation", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Inflation = append(x.Inflation[:0], dAtA[iNdEx:postIndex]...) + if x.Inflation == nil { + x.Inflation = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPhaseStepRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryPhaseStepRequest = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryPhaseStepRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryPhaseStepRequest)(nil) + +type fastReflection_QueryPhaseStepRequest QueryPhaseStepRequest + +func (x *QueryPhaseStepRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPhaseStepRequest)(x) +} + +func (x *QueryPhaseStepRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPhaseStepRequest_messageType fastReflection_QueryPhaseStepRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPhaseStepRequest_messageType{} + +type fastReflection_QueryPhaseStepRequest_messageType struct{} + +func (x fastReflection_QueryPhaseStepRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPhaseStepRequest)(nil) +} +func (x fastReflection_QueryPhaseStepRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPhaseStepRequest) +} +func (x fastReflection_QueryPhaseStepRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseStepRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPhaseStepRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseStepRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPhaseStepRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPhaseStepRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPhaseStepRequest) New() protoreflect.Message { + return new(fastReflection_QueryPhaseStepRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPhaseStepRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPhaseStepRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPhaseStepRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPhaseStepRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPhaseStepRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPhaseStepRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPhaseStepRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryPhaseStepRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPhaseStepRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPhaseStepRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPhaseStepRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPhaseStepRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseStepRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseStepRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseStepRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseStepRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPhaseStepResponse protoreflect.MessageDescriptor + fd_QueryPhaseStepResponse_phase_step protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryPhaseStepResponse = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryPhaseStepResponse") + fd_QueryPhaseStepResponse_phase_step = md_QueryPhaseStepResponse.Fields().ByName("phase_step") +} + +var _ protoreflect.Message = (*fastReflection_QueryPhaseStepResponse)(nil) + +type fastReflection_QueryPhaseStepResponse QueryPhaseStepResponse + +func (x *QueryPhaseStepResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPhaseStepResponse)(x) +} + +func (x *QueryPhaseStepResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPhaseStepResponse_messageType fastReflection_QueryPhaseStepResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPhaseStepResponse_messageType{} + +type fastReflection_QueryPhaseStepResponse_messageType struct{} + +func (x fastReflection_QueryPhaseStepResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPhaseStepResponse)(nil) +} +func (x fastReflection_QueryPhaseStepResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPhaseStepResponse) +} +func (x fastReflection_QueryPhaseStepResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseStepResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPhaseStepResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseStepResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPhaseStepResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPhaseStepResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPhaseStepResponse) New() protoreflect.Message { + return new(fastReflection_QueryPhaseStepResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPhaseStepResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPhaseStepResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPhaseStepResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.PhaseStep != int32(0) { + value := protoreflect.ValueOfInt32(x.PhaseStep) + if !f(fd_QueryPhaseStepResponse_phase_step, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPhaseStepResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseStepResponse.phase_step": + return x.PhaseStep != int32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseStepResponse.phase_step": + x.PhaseStep = int32(0) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPhaseStepResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.QueryPhaseStepResponse.phase_step": + value := x.PhaseStep + return protoreflect.ValueOfInt32(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseStepResponse.phase_step": + x.PhaseStep = int32(value.Int()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseStepResponse.phase_step": + panic(fmt.Errorf("field phase_step of message sge.mint.v1beta.QueryPhaseStepResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPhaseStepResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseStepResponse.phase_step": + return protoreflect.ValueOfInt32(int32(0)) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseStepResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseStepResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPhaseStepResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryPhaseStepResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPhaseStepResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseStepResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPhaseStepResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPhaseStepResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPhaseStepResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.PhaseStep != 0 { + n += 1 + runtime.Sov(uint64(x.PhaseStep)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseStepResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.PhaseStep != 0 { + i = runtime.EncodeVarint(dAtA, i, uint64(x.PhaseStep)) + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseStepResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseStepResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseStepResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PhaseStep", wireType) + } + x.PhaseStep = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + x.PhaseStep |= int32(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPhaseProvisionsRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryPhaseProvisionsRequest = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryPhaseProvisionsRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryPhaseProvisionsRequest)(nil) + +type fastReflection_QueryPhaseProvisionsRequest QueryPhaseProvisionsRequest + +func (x *QueryPhaseProvisionsRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPhaseProvisionsRequest)(x) +} + +func (x *QueryPhaseProvisionsRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPhaseProvisionsRequest_messageType fastReflection_QueryPhaseProvisionsRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryPhaseProvisionsRequest_messageType{} + +type fastReflection_QueryPhaseProvisionsRequest_messageType struct{} + +func (x fastReflection_QueryPhaseProvisionsRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPhaseProvisionsRequest)(nil) +} +func (x fastReflection_QueryPhaseProvisionsRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPhaseProvisionsRequest) +} +func (x fastReflection_QueryPhaseProvisionsRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseProvisionsRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPhaseProvisionsRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseProvisionsRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPhaseProvisionsRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryPhaseProvisionsRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPhaseProvisionsRequest) New() protoreflect.Message { + return new(fastReflection_QueryPhaseProvisionsRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPhaseProvisionsRequest) Interface() protoreflect.ProtoMessage { + return (*QueryPhaseProvisionsRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPhaseProvisionsRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPhaseProvisionsRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPhaseProvisionsRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPhaseProvisionsRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPhaseProvisionsRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryPhaseProvisionsRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPhaseProvisionsRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPhaseProvisionsRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPhaseProvisionsRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPhaseProvisionsRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseProvisionsRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseProvisionsRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseProvisionsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseProvisionsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryPhaseProvisionsResponse protoreflect.MessageDescriptor + fd_QueryPhaseProvisionsResponse_phase_provisions protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryPhaseProvisionsResponse = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryPhaseProvisionsResponse") + fd_QueryPhaseProvisionsResponse_phase_provisions = md_QueryPhaseProvisionsResponse.Fields().ByName("phase_provisions") +} + +var _ protoreflect.Message = (*fastReflection_QueryPhaseProvisionsResponse)(nil) + +type fastReflection_QueryPhaseProvisionsResponse QueryPhaseProvisionsResponse + +func (x *QueryPhaseProvisionsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryPhaseProvisionsResponse)(x) +} + +func (x *QueryPhaseProvisionsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryPhaseProvisionsResponse_messageType fastReflection_QueryPhaseProvisionsResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryPhaseProvisionsResponse_messageType{} + +type fastReflection_QueryPhaseProvisionsResponse_messageType struct{} + +func (x fastReflection_QueryPhaseProvisionsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryPhaseProvisionsResponse)(nil) +} +func (x fastReflection_QueryPhaseProvisionsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryPhaseProvisionsResponse) +} +func (x fastReflection_QueryPhaseProvisionsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseProvisionsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryPhaseProvisionsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryPhaseProvisionsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryPhaseProvisionsResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryPhaseProvisionsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryPhaseProvisionsResponse) New() protoreflect.Message { + return new(fastReflection_QueryPhaseProvisionsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryPhaseProvisionsResponse) Interface() protoreflect.ProtoMessage { + return (*QueryPhaseProvisionsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryPhaseProvisionsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if len(x.PhaseProvisions) != 0 { + value := protoreflect.ValueOfBytes(x.PhaseProvisions) + if !f(fd_QueryPhaseProvisionsResponse_phase_provisions, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryPhaseProvisionsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseProvisionsResponse.phase_provisions": + return len(x.PhaseProvisions) != 0 + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseProvisionsResponse.phase_provisions": + x.PhaseProvisions = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryPhaseProvisionsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.QueryPhaseProvisionsResponse.phase_provisions": + value := x.PhaseProvisions + return protoreflect.ValueOfBytes(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseProvisionsResponse.phase_provisions": + x.PhaseProvisions = value.Bytes() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseProvisionsResponse.phase_provisions": + panic(fmt.Errorf("field phase_provisions of message sge.mint.v1beta.QueryPhaseProvisionsResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryPhaseProvisionsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryPhaseProvisionsResponse.phase_provisions": + return protoreflect.ValueOfBytes(nil) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryPhaseProvisionsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryPhaseProvisionsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryPhaseProvisionsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryPhaseProvisionsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryPhaseProvisionsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryPhaseProvisionsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryPhaseProvisionsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryPhaseProvisionsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryPhaseProvisionsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.PhaseProvisions) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseProvisionsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if len(x.PhaseProvisions) > 0 { + i -= len(x.PhaseProvisions) + copy(dAtA[i:], x.PhaseProvisions) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.PhaseProvisions))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryPhaseProvisionsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseProvisionsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryPhaseProvisionsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field PhaseProvisions", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.PhaseProvisions = append(x.PhaseProvisions[:0], dAtA[iNdEx:postIndex]...) + if x.PhaseProvisions == nil { + x.PhaseProvisions = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryEndPhaseStatusRequest protoreflect.MessageDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryEndPhaseStatusRequest = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryEndPhaseStatusRequest") +} + +var _ protoreflect.Message = (*fastReflection_QueryEndPhaseStatusRequest)(nil) + +type fastReflection_QueryEndPhaseStatusRequest QueryEndPhaseStatusRequest + +func (x *QueryEndPhaseStatusRequest) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryEndPhaseStatusRequest)(x) +} + +func (x *QueryEndPhaseStatusRequest) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryEndPhaseStatusRequest_messageType fastReflection_QueryEndPhaseStatusRequest_messageType +var _ protoreflect.MessageType = fastReflection_QueryEndPhaseStatusRequest_messageType{} + +type fastReflection_QueryEndPhaseStatusRequest_messageType struct{} + +func (x fastReflection_QueryEndPhaseStatusRequest_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryEndPhaseStatusRequest)(nil) +} +func (x fastReflection_QueryEndPhaseStatusRequest_messageType) New() protoreflect.Message { + return new(fastReflection_QueryEndPhaseStatusRequest) +} +func (x fastReflection_QueryEndPhaseStatusRequest_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryEndPhaseStatusRequest +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryEndPhaseStatusRequest) Descriptor() protoreflect.MessageDescriptor { + return md_QueryEndPhaseStatusRequest +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryEndPhaseStatusRequest) Type() protoreflect.MessageType { + return _fastReflection_QueryEndPhaseStatusRequest_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryEndPhaseStatusRequest) New() protoreflect.Message { + return new(fastReflection_QueryEndPhaseStatusRequest) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryEndPhaseStatusRequest) Interface() protoreflect.ProtoMessage { + return (*QueryEndPhaseStatusRequest)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryEndPhaseStatusRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryEndPhaseStatusRequest) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusRequest does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusRequest) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusRequest does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryEndPhaseStatusRequest) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusRequest does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusRequest does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusRequest) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusRequest does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryEndPhaseStatusRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusRequest")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusRequest does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryEndPhaseStatusRequest) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryEndPhaseStatusRequest", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryEndPhaseStatusRequest) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusRequest) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryEndPhaseStatusRequest) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryEndPhaseStatusRequest) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryEndPhaseStatusRequest) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryEndPhaseStatusRequest) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryEndPhaseStatusRequest) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryEndPhaseStatusRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryEndPhaseStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_QueryEndPhaseStatusResponse protoreflect.MessageDescriptor + fd_QueryEndPhaseStatusResponse_is_in_end_phase protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_query_proto_init() + md_QueryEndPhaseStatusResponse = File_sge_mint_v1beta_query_proto.Messages().ByName("QueryEndPhaseStatusResponse") + fd_QueryEndPhaseStatusResponse_is_in_end_phase = md_QueryEndPhaseStatusResponse.Fields().ByName("is_in_end_phase") +} + +var _ protoreflect.Message = (*fastReflection_QueryEndPhaseStatusResponse)(nil) + +type fastReflection_QueryEndPhaseStatusResponse QueryEndPhaseStatusResponse + +func (x *QueryEndPhaseStatusResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_QueryEndPhaseStatusResponse)(x) +} + +func (x *QueryEndPhaseStatusResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_QueryEndPhaseStatusResponse_messageType fastReflection_QueryEndPhaseStatusResponse_messageType +var _ protoreflect.MessageType = fastReflection_QueryEndPhaseStatusResponse_messageType{} + +type fastReflection_QueryEndPhaseStatusResponse_messageType struct{} + +func (x fastReflection_QueryEndPhaseStatusResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_QueryEndPhaseStatusResponse)(nil) +} +func (x fastReflection_QueryEndPhaseStatusResponse_messageType) New() protoreflect.Message { + return new(fastReflection_QueryEndPhaseStatusResponse) +} +func (x fastReflection_QueryEndPhaseStatusResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_QueryEndPhaseStatusResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_QueryEndPhaseStatusResponse) Descriptor() protoreflect.MessageDescriptor { + return md_QueryEndPhaseStatusResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_QueryEndPhaseStatusResponse) Type() protoreflect.MessageType { + return _fastReflection_QueryEndPhaseStatusResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_QueryEndPhaseStatusResponse) New() protoreflect.Message { + return new(fastReflection_QueryEndPhaseStatusResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_QueryEndPhaseStatusResponse) Interface() protoreflect.ProtoMessage { + return (*QueryEndPhaseStatusResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_QueryEndPhaseStatusResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.IsInEndPhase != false { + value := protoreflect.ValueOfBool(x.IsInEndPhase) + if !f(fd_QueryEndPhaseStatusResponse_is_in_end_phase, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_QueryEndPhaseStatusResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.QueryEndPhaseStatusResponse.is_in_end_phase": + return x.IsInEndPhase != false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryEndPhaseStatusResponse.is_in_end_phase": + x.IsInEndPhase = false + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_QueryEndPhaseStatusResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.QueryEndPhaseStatusResponse.is_in_end_phase": + value := x.IsInEndPhase + return protoreflect.ValueOfBool(value) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.QueryEndPhaseStatusResponse.is_in_end_phase": + x.IsInEndPhase = value.Bool() + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryEndPhaseStatusResponse.is_in_end_phase": + panic(fmt.Errorf("field is_in_end_phase of message sge.mint.v1beta.QueryEndPhaseStatusResponse is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_QueryEndPhaseStatusResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.QueryEndPhaseStatusResponse.is_in_end_phase": + return protoreflect.ValueOfBool(false) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.QueryEndPhaseStatusResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.QueryEndPhaseStatusResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_QueryEndPhaseStatusResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.QueryEndPhaseStatusResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_QueryEndPhaseStatusResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_QueryEndPhaseStatusResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_QueryEndPhaseStatusResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_QueryEndPhaseStatusResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*QueryEndPhaseStatusResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.IsInEndPhase { + n += 2 + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*QueryEndPhaseStatusResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.IsInEndPhase { + i-- + if x.IsInEndPhase { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x8 + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*QueryEndPhaseStatusResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryEndPhaseStatusResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: QueryEndPhaseStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field IsInEndPhase", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + x.IsInEndPhase = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/mint/v1beta/query.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// QueryParamsRequest is the request type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryParamsRequest) Reset() { + *x = QueryParamsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsRequest) ProtoMessage() {} + +// Deprecated: Use QueryParamsRequest.ProtoReflect.Descriptor instead. +func (*QueryParamsRequest) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{0} +} + +// QueryParamsResponse is the response type for the Query/Params RPC method. +// Query/Params RPC method. +type QueryParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // params contains all of the parameters of this module. + Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *QueryParamsResponse) Reset() { + *x = QueryParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryParamsResponse) ProtoMessage() {} + +// Deprecated: Use QueryParamsResponse.ProtoReflect.Descriptor instead. +func (*QueryParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{1} +} + +func (x *QueryParamsResponse) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// QueryInflationRequest is the request type for the Query/Inflation RPC method. +// Query/Inflation RPC method. +type QueryInflationRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryInflationRequest) Reset() { + *x = QueryInflationRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryInflationRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryInflationRequest) ProtoMessage() {} + +// Deprecated: Use QueryInflationRequest.ProtoReflect.Descriptor instead. +func (*QueryInflationRequest) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{2} +} + +// QueryInflationResponse is the response type for the Query/Inflation RPC +// method. +// Query/Inflation RPC method. +type QueryInflationResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // inflation is the current minting inflation value. + Inflation []byte `protobuf:"bytes,1,opt,name=inflation,proto3" json:"inflation,omitempty"` +} + +func (x *QueryInflationResponse) Reset() { + *x = QueryInflationResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryInflationResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryInflationResponse) ProtoMessage() {} + +// Deprecated: Use QueryInflationResponse.ProtoReflect.Descriptor instead. +func (*QueryInflationResponse) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{3} +} + +func (x *QueryInflationResponse) GetInflation() []byte { + if x != nil { + return x.Inflation + } + return nil +} + +// QueryPhaseStepRequest is the request type for the Query/Inflation RPC method. +// Query/PhaseStep RPC method. +type QueryPhaseStepRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryPhaseStepRequest) Reset() { + *x = QueryPhaseStepRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPhaseStepRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPhaseStepRequest) ProtoMessage() {} + +// Deprecated: Use QueryPhaseStepRequest.ProtoReflect.Descriptor instead. +func (*QueryPhaseStepRequest) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{4} +} + +// QueryPhaseStepResponse is the response type for the Query/Inflation RPC +// method. +// Query/PhaseStep RPC method. +type QueryPhaseStepResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // phase_step is the current phase number of the blockchain. + PhaseStep int32 `protobuf:"varint,1,opt,name=phase_step,json=phaseStep,proto3" json:"phase_step,omitempty"` +} + +func (x *QueryPhaseStepResponse) Reset() { + *x = QueryPhaseStepResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPhaseStepResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPhaseStepResponse) ProtoMessage() {} + +// Deprecated: Use QueryPhaseStepResponse.ProtoReflect.Descriptor instead. +func (*QueryPhaseStepResponse) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{5} +} + +func (x *QueryPhaseStepResponse) GetPhaseStep() int32 { + if x != nil { + return x.PhaseStep + } + return 0 +} + +// QueryPhaseProvisionsRequest is the request type for the +// Query/PhaseProvisions RPC method. +type QueryPhaseProvisionsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryPhaseProvisionsRequest) Reset() { + *x = QueryPhaseProvisionsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPhaseProvisionsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPhaseProvisionsRequest) ProtoMessage() {} + +// Deprecated: Use QueryPhaseProvisionsRequest.ProtoReflect.Descriptor instead. +func (*QueryPhaseProvisionsRequest) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{6} +} + +// QueryPhaseProvisionsResponse is the response type for the +// Query/PhaseProvisions RPC method. +type QueryPhaseProvisionsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // phase_provisions is the current minting phase provisions value. + PhaseProvisions []byte `protobuf:"bytes,1,opt,name=phase_provisions,json=phaseProvisions,proto3" json:"phase_provisions,omitempty"` +} + +func (x *QueryPhaseProvisionsResponse) Reset() { + *x = QueryPhaseProvisionsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryPhaseProvisionsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryPhaseProvisionsResponse) ProtoMessage() {} + +// Deprecated: Use QueryPhaseProvisionsResponse.ProtoReflect.Descriptor instead. +func (*QueryPhaseProvisionsResponse) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{7} +} + +func (x *QueryPhaseProvisionsResponse) GetPhaseProvisions() []byte { + if x != nil { + return x.PhaseProvisions + } + return nil +} + +// QueryEndPhaseStatusRequest is the request type for the Query/Inflation RPC +// method. +// Query/EndPhaseStatus RPC method. +type QueryEndPhaseStatusRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *QueryEndPhaseStatusRequest) Reset() { + *x = QueryEndPhaseStatusRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryEndPhaseStatusRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryEndPhaseStatusRequest) ProtoMessage() {} + +// Deprecated: Use QueryEndPhaseStatusRequest.ProtoReflect.Descriptor instead. +func (*QueryEndPhaseStatusRequest) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{8} +} + +// QueryEndPhaseStatusResponse is the response type for the Query/Inflation RPC +// method. +// Query/EndPhaseStatus RPC method. +type QueryEndPhaseStatusResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // is_in_end_phase is true if there is no more valid phase in the mint + // parameters. + IsInEndPhase bool `protobuf:"varint,1,opt,name=is_in_end_phase,json=isInEndPhase,proto3" json:"is_in_end_phase,omitempty"` +} + +func (x *QueryEndPhaseStatusResponse) Reset() { + *x = QueryEndPhaseStatusResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_query_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *QueryEndPhaseStatusResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*QueryEndPhaseStatusResponse) ProtoMessage() {} + +// Deprecated: Use QueryEndPhaseStatusResponse.ProtoReflect.Descriptor instead. +func (*QueryEndPhaseStatusResponse) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_query_proto_rawDescGZIP(), []int{9} +} + +func (x *QueryEndPhaseStatusResponse) GetIsInEndPhase() bool { + if x != nil { + return x.IsInEndPhase + } + return false +} + +var File_sge_mint_v1beta_query_proto protoreflect.FileDescriptor + +var file_sge_mint_v1beta_query_proto_rawDesc = []byte{ + 0x0a, 0x1b, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, 0x73, + 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, + 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, + 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, + 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x1c, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x14, + 0x0a, 0x12, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x22, 0x51, 0x0a, 0x13, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3a, 0x0a, 0x06, 0x70, + 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x67, + 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, + 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x17, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x49, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x22, 0x6e, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x54, 0x0a, 0x09, 0x69, 0x6e, + 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x36, 0xc8, + 0xde, 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, + 0x2e, 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, + 0x65, 0x63, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, + 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x09, 0x69, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x22, 0x17, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, + 0x65, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x37, 0x0a, 0x16, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x50, 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, 0x65, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x68, 0x61, 0x73, 0x65, 0x5f, 0x73, 0x74, 0x65, + 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x70, 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, + 0x65, 0x70, 0x22, 0x1d, 0x0a, 0x1b, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x68, 0x61, 0x73, 0x65, + 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x22, 0x81, 0x01, 0x0a, 0x1c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x68, 0x61, 0x73, 0x65, + 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x61, 0x0a, 0x10, 0x70, 0x68, 0x61, 0x73, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x76, + 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x36, 0xc8, 0xde, + 0x1f, 0x00, 0xda, 0xde, 0x1f, 0x1b, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, + 0x69, 0x6f, 0x2f, 0x6d, 0x61, 0x74, 0x68, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, + 0x63, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0xa8, + 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x0f, 0x70, 0x68, 0x61, 0x73, 0x65, 0x50, 0x72, 0x6f, 0x76, 0x69, + 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0x1c, 0x0a, 0x1a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, + 0x64, 0x50, 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x22, 0x44, 0x0a, 0x1b, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, 0x64, 0x50, + 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x25, 0x0a, 0x0f, 0x69, 0x73, 0x5f, 0x69, 0x6e, 0x5f, 0x65, 0x6e, 0x64, 0x5f, + 0x70, 0x68, 0x61, 0x73, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x69, 0x73, 0x49, + 0x6e, 0x45, 0x6e, 0x64, 0x50, 0x68, 0x61, 0x73, 0x65, 0x32, 0xc0, 0x05, 0x0a, 0x05, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x12, 0x6d, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x23, 0x2e, + 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x18, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x12, + 0x12, 0x10, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x70, 0x61, 0x72, 0x61, + 0x6d, 0x73, 0x12, 0x84, 0x01, 0x0a, 0x09, 0x49, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x12, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x27, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, + 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x49, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x20, 0x12, 0x1e, 0x2f, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, + 0x69, 0x6e, 0x66, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x84, 0x01, 0x0a, 0x09, 0x50, 0x68, + 0x61, 0x73, 0x65, 0x53, 0x74, 0x65, 0x70, 0x12, 0x26, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, + 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, + 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, 0x65, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x27, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, 0x65, 0x70, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x20, + 0x12, 0x1e, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x70, 0x68, 0x61, 0x73, 0x65, 0x73, 0x74, 0x65, 0x70, + 0x12, 0x9d, 0x01, 0x0a, 0x0f, 0x50, 0x68, 0x61, 0x73, 0x65, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, + 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, + 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x68, 0x61, 0x73, + 0x65, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x68, 0x61, 0x73, 0x65, 0x50, + 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x12, 0x25, 0x2f, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, + 0x70, 0x68, 0x61, 0x73, 0x65, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x73, + 0x12, 0x99, 0x01, 0x0a, 0x0e, 0x45, 0x6e, 0x64, 0x50, 0x68, 0x61, 0x73, 0x65, 0x53, 0x74, 0x61, + 0x74, 0x75, 0x73, 0x12, 0x2b, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, 0x64, 0x50, 0x68, + 0x61, 0x73, 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x2c, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, 0x64, 0x50, 0x68, 0x61, 0x73, 0x65, + 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2c, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x26, 0x12, 0x24, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x65, 0x6e, 0x64, + 0x70, 0x68, 0x61, 0x73, 0x65, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x42, 0xba, 0x01, 0x0a, + 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x42, 0x0a, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x50, 0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, + 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x61, + 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, + 0x74, 0x61, 0x3b, 0x6d, 0x69, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0xa2, 0x02, 0x03, + 0x53, 0x4d, 0x58, 0xaa, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x2e, 0x4d, 0x69, 0x6e, 0x74, 0x2e, 0x56, + 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x5c, 0x4d, 0x69, 0x6e, 0x74, + 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x1b, 0x53, 0x67, 0x65, 0x5c, 0x4d, 0x69, + 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, + 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x53, 0x67, 0x65, 0x3a, 0x3a, 0x4d, 0x69, 0x6e, + 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, +} + +var ( + file_sge_mint_v1beta_query_proto_rawDescOnce sync.Once + file_sge_mint_v1beta_query_proto_rawDescData = file_sge_mint_v1beta_query_proto_rawDesc +) + +func file_sge_mint_v1beta_query_proto_rawDescGZIP() []byte { + file_sge_mint_v1beta_query_proto_rawDescOnce.Do(func() { + file_sge_mint_v1beta_query_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_mint_v1beta_query_proto_rawDescData) + }) + return file_sge_mint_v1beta_query_proto_rawDescData +} + +var file_sge_mint_v1beta_query_proto_msgTypes = make([]protoimpl.MessageInfo, 10) +var file_sge_mint_v1beta_query_proto_goTypes = []interface{}{ + (*QueryParamsRequest)(nil), // 0: sge.mint.v1beta.QueryParamsRequest + (*QueryParamsResponse)(nil), // 1: sge.mint.v1beta.QueryParamsResponse + (*QueryInflationRequest)(nil), // 2: sge.mint.v1beta.QueryInflationRequest + (*QueryInflationResponse)(nil), // 3: sge.mint.v1beta.QueryInflationResponse + (*QueryPhaseStepRequest)(nil), // 4: sge.mint.v1beta.QueryPhaseStepRequest + (*QueryPhaseStepResponse)(nil), // 5: sge.mint.v1beta.QueryPhaseStepResponse + (*QueryPhaseProvisionsRequest)(nil), // 6: sge.mint.v1beta.QueryPhaseProvisionsRequest + (*QueryPhaseProvisionsResponse)(nil), // 7: sge.mint.v1beta.QueryPhaseProvisionsResponse + (*QueryEndPhaseStatusRequest)(nil), // 8: sge.mint.v1beta.QueryEndPhaseStatusRequest + (*QueryEndPhaseStatusResponse)(nil), // 9: sge.mint.v1beta.QueryEndPhaseStatusResponse + (*Params)(nil), // 10: sge.mint.v1beta.Params +} +var file_sge_mint_v1beta_query_proto_depIdxs = []int32{ + 10, // 0: sge.mint.v1beta.QueryParamsResponse.params:type_name -> sge.mint.v1beta.Params + 0, // 1: sge.mint.v1beta.Query.Params:input_type -> sge.mint.v1beta.QueryParamsRequest + 2, // 2: sge.mint.v1beta.Query.Inflation:input_type -> sge.mint.v1beta.QueryInflationRequest + 4, // 3: sge.mint.v1beta.Query.PhaseStep:input_type -> sge.mint.v1beta.QueryPhaseStepRequest + 6, // 4: sge.mint.v1beta.Query.PhaseProvisions:input_type -> sge.mint.v1beta.QueryPhaseProvisionsRequest + 8, // 5: sge.mint.v1beta.Query.EndPhaseStatus:input_type -> sge.mint.v1beta.QueryEndPhaseStatusRequest + 1, // 6: sge.mint.v1beta.Query.Params:output_type -> sge.mint.v1beta.QueryParamsResponse + 3, // 7: sge.mint.v1beta.Query.Inflation:output_type -> sge.mint.v1beta.QueryInflationResponse + 5, // 8: sge.mint.v1beta.Query.PhaseStep:output_type -> sge.mint.v1beta.QueryPhaseStepResponse + 7, // 9: sge.mint.v1beta.Query.PhaseProvisions:output_type -> sge.mint.v1beta.QueryPhaseProvisionsResponse + 9, // 10: sge.mint.v1beta.Query.EndPhaseStatus:output_type -> sge.mint.v1beta.QueryEndPhaseStatusResponse + 6, // [6:11] is the sub-list for method output_type + 1, // [1:6] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_mint_v1beta_query_proto_init() } +func file_sge_mint_v1beta_query_proto_init() { + if File_sge_mint_v1beta_query_proto != nil { + return + } + file_sge_mint_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_mint_v1beta_query_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryInflationRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryInflationResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPhaseStepRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPhaseStepResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPhaseProvisionsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryPhaseProvisionsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryEndPhaseStatusRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_query_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*QueryEndPhaseStatusResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_mint_v1beta_query_proto_rawDesc, + NumEnums: 0, + NumMessages: 10, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_mint_v1beta_query_proto_goTypes, + DependencyIndexes: file_sge_mint_v1beta_query_proto_depIdxs, + MessageInfos: file_sge_mint_v1beta_query_proto_msgTypes, + }.Build() + File_sge_mint_v1beta_query_proto = out.File + file_sge_mint_v1beta_query_proto_rawDesc = nil + file_sge_mint_v1beta_query_proto_goTypes = nil + file_sge_mint_v1beta_query_proto_depIdxs = nil +} diff --git a/api/sge/mint/v1beta/query_grpc.pb.go b/api/sge/mint/v1beta/query_grpc.pb.go new file mode 100644 index 00000000..4caaa7a7 --- /dev/null +++ b/api/sge/mint/v1beta/query_grpc.pb.go @@ -0,0 +1,267 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/mint/v1beta/query.proto + +package mintv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Query_Params_FullMethodName = "/sge.mint.v1beta.Query/Params" + Query_Inflation_FullMethodName = "/sge.mint.v1beta.Query/Inflation" + Query_PhaseStep_FullMethodName = "/sge.mint.v1beta.Query/PhaseStep" + Query_PhaseProvisions_FullMethodName = "/sge.mint.v1beta.Query/PhaseProvisions" + Query_EndPhaseStatus_FullMethodName = "/sge.mint.v1beta.Query/EndPhaseStatus" +) + +// QueryClient is the client API for Query service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type QueryClient interface { + // Params queries the parameters of the module. + Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) + // Inflation returns the current minting inflation value. + Inflation(ctx context.Context, in *QueryInflationRequest, opts ...grpc.CallOption) (*QueryInflationResponse, error) + // PhaseStep returns the current phase step. + PhaseStep(ctx context.Context, in *QueryPhaseStepRequest, opts ...grpc.CallOption) (*QueryPhaseStepResponse, error) + // PhaseProvisions current minting phase provisions value. + PhaseProvisions(ctx context.Context, in *QueryPhaseProvisionsRequest, opts ...grpc.CallOption) (*QueryPhaseProvisionsResponse, error) + // EndPhaseStatus returns the current minting phase status. + EndPhaseStatus(ctx context.Context, in *QueryEndPhaseStatusRequest, opts ...grpc.CallOption) (*QueryEndPhaseStatusResponse, error) +} + +type queryClient struct { + cc grpc.ClientConnInterface +} + +func NewQueryClient(cc grpc.ClientConnInterface) QueryClient { + return &queryClient{cc} +} + +func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { + out := new(QueryParamsResponse) + err := c.cc.Invoke(ctx, Query_Params_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) Inflation(ctx context.Context, in *QueryInflationRequest, opts ...grpc.CallOption) (*QueryInflationResponse, error) { + out := new(QueryInflationResponse) + err := c.cc.Invoke(ctx, Query_Inflation_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) PhaseStep(ctx context.Context, in *QueryPhaseStepRequest, opts ...grpc.CallOption) (*QueryPhaseStepResponse, error) { + out := new(QueryPhaseStepResponse) + err := c.cc.Invoke(ctx, Query_PhaseStep_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) PhaseProvisions(ctx context.Context, in *QueryPhaseProvisionsRequest, opts ...grpc.CallOption) (*QueryPhaseProvisionsResponse, error) { + out := new(QueryPhaseProvisionsResponse) + err := c.cc.Invoke(ctx, Query_PhaseProvisions_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *queryClient) EndPhaseStatus(ctx context.Context, in *QueryEndPhaseStatusRequest, opts ...grpc.CallOption) (*QueryEndPhaseStatusResponse, error) { + out := new(QueryEndPhaseStatusResponse) + err := c.cc.Invoke(ctx, Query_EndPhaseStatus_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// QueryServer is the server API for Query service. +// All implementations must embed UnimplementedQueryServer +// for forward compatibility +type QueryServer interface { + // Params queries the parameters of the module. + Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) + // Inflation returns the current minting inflation value. + Inflation(context.Context, *QueryInflationRequest) (*QueryInflationResponse, error) + // PhaseStep returns the current phase step. + PhaseStep(context.Context, *QueryPhaseStepRequest) (*QueryPhaseStepResponse, error) + // PhaseProvisions current minting phase provisions value. + PhaseProvisions(context.Context, *QueryPhaseProvisionsRequest) (*QueryPhaseProvisionsResponse, error) + // EndPhaseStatus returns the current minting phase status. + EndPhaseStatus(context.Context, *QueryEndPhaseStatusRequest) (*QueryEndPhaseStatusResponse, error) + mustEmbedUnimplementedQueryServer() +} + +// UnimplementedQueryServer must be embedded to have forward compatible implementations. +type UnimplementedQueryServer struct { +} + +func (UnimplementedQueryServer) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") +} +func (UnimplementedQueryServer) Inflation(context.Context, *QueryInflationRequest) (*QueryInflationResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Inflation not implemented") +} +func (UnimplementedQueryServer) PhaseStep(context.Context, *QueryPhaseStepRequest) (*QueryPhaseStepResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PhaseStep not implemented") +} +func (UnimplementedQueryServer) PhaseProvisions(context.Context, *QueryPhaseProvisionsRequest) (*QueryPhaseProvisionsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PhaseProvisions not implemented") +} +func (UnimplementedQueryServer) EndPhaseStatus(context.Context, *QueryEndPhaseStatusRequest) (*QueryEndPhaseStatusResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method EndPhaseStatus not implemented") +} +func (UnimplementedQueryServer) mustEmbedUnimplementedQueryServer() {} + +// UnsafeQueryServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to QueryServer will +// result in compilation errors. +type UnsafeQueryServer interface { + mustEmbedUnimplementedQueryServer() +} + +func RegisterQueryServer(s grpc.ServiceRegistrar, srv QueryServer) { + s.RegisterService(&Query_ServiceDesc, srv) +} + +func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryParamsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Params(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Params_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_Inflation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryInflationRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).Inflation(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_Inflation_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).Inflation(ctx, req.(*QueryInflationRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_PhaseStep_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPhaseStepRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).PhaseStep(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_PhaseStep_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).PhaseStep(ctx, req.(*QueryPhaseStepRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_PhaseProvisions_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPhaseProvisionsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).PhaseProvisions(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_PhaseProvisions_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).PhaseProvisions(ctx, req.(*QueryPhaseProvisionsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Query_EndPhaseStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryEndPhaseStatusRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(QueryServer).EndPhaseStatus(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Query_EndPhaseStatus_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(QueryServer).EndPhaseStatus(ctx, req.(*QueryEndPhaseStatusRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Query_ServiceDesc is the grpc.ServiceDesc for Query service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Query_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.mint.v1beta.Query", + HandlerType: (*QueryServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "Params", + Handler: _Query_Params_Handler, + }, + { + MethodName: "Inflation", + Handler: _Query_Inflation_Handler, + }, + { + MethodName: "PhaseStep", + Handler: _Query_PhaseStep_Handler, + }, + { + MethodName: "PhaseProvisions", + Handler: _Query_PhaseProvisions_Handler, + }, + { + MethodName: "EndPhaseStatus", + Handler: _Query_EndPhaseStatus_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/mint/v1beta/query.proto", +} diff --git a/api/sge/mint/v1beta/tx.pulsar.go b/api/sge/mint/v1beta/tx.pulsar.go new file mode 100644 index 00000000..a68ce514 --- /dev/null +++ b/api/sge/mint/v1beta/tx.pulsar.go @@ -0,0 +1,1095 @@ +// Code generated by protoc-gen-go-pulsar. DO NOT EDIT. +package mintv1beta + +import ( + _ "cosmossdk.io/api/amino" + _ "cosmossdk.io/api/cosmos/msg/v1" + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/gogoproto/gogoproto" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoiface "google.golang.org/protobuf/runtime/protoiface" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + io "io" + reflect "reflect" + sync "sync" +) + +var ( + md_MsgUpdateParams protoreflect.MessageDescriptor + fd_MsgUpdateParams_authority protoreflect.FieldDescriptor + fd_MsgUpdateParams_params protoreflect.FieldDescriptor +) + +func init() { + file_sge_mint_v1beta_tx_proto_init() + md_MsgUpdateParams = File_sge_mint_v1beta_tx_proto.Messages().ByName("MsgUpdateParams") + fd_MsgUpdateParams_authority = md_MsgUpdateParams.Fields().ByName("authority") + fd_MsgUpdateParams_params = md_MsgUpdateParams.Fields().ByName("params") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParams)(nil) + +type fastReflection_MsgUpdateParams MsgUpdateParams + +func (x *MsgUpdateParams) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(x) +} + +func (x *MsgUpdateParams) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_tx_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParams_messageType fastReflection_MsgUpdateParams_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParams_messageType{} + +type fastReflection_MsgUpdateParams_messageType struct{} + +func (x fastReflection_MsgUpdateParams_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParams)(nil) +} +func (x fastReflection_MsgUpdateParams_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} +func (x fastReflection_MsgUpdateParams_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParams) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParams +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParams) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParams_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParams) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParams) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParams) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParams)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.Authority != "" { + value := protoreflect.ValueOfString(x.Authority) + if !f(fd_MsgUpdateParams_authority, value) { + return + } + } + if x.Params != nil { + value := protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + if !f(fd_MsgUpdateParams_params, value) { + return + } + } +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParams) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + case "sge.mint.v1beta.MsgUpdateParams.authority": + return x.Authority != "" + case "sge.mint.v1beta.MsgUpdateParams.params": + return x.Params != nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + case "sge.mint.v1beta.MsgUpdateParams.authority": + x.Authority = "" + case "sge.mint.v1beta.MsgUpdateParams.params": + x.Params = nil + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + case "sge.mint.v1beta.MsgUpdateParams.authority": + value := x.Authority + return protoreflect.ValueOfString(value) + case "sge.mint.v1beta.MsgUpdateParams.params": + value := x.Params + return protoreflect.ValueOfMessage(value.ProtoReflect()) + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParams does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + case "sge.mint.v1beta.MsgUpdateParams.authority": + x.Authority = value.Interface().(string) + case "sge.mint.v1beta.MsgUpdateParams.params": + x.Params = value.Message().Interface().(*Params) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.MsgUpdateParams.params": + if x.Params == nil { + x.Params = new(Params) + } + return protoreflect.ValueOfMessage(x.Params.ProtoReflect()) + case "sge.mint.v1beta.MsgUpdateParams.authority": + panic(fmt.Errorf("field authority of message sge.mint.v1beta.MsgUpdateParams is not mutable")) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + case "sge.mint.v1beta.MsgUpdateParams.authority": + return protoreflect.ValueOfString("") + case "sge.mint.v1beta.MsgUpdateParams.params": + m := new(Params) + return protoreflect.ValueOfMessage(m.ProtoReflect()) + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParams")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParams does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.MsgUpdateParams", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParams) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParams) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParams) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParams) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + l = len(x.Authority) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.Params != nil { + l = options.Size(x.Params) + n += 1 + l + runtime.Sov(uint64(l)) + } + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if x.Params != nil { + encoded, err := options.Marshal(x.Params) + if err != nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, err + } + i -= len(encoded) + copy(dAtA[i:], encoded) + i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) + i-- + dAtA[i] = 0x12 + } + if len(x.Authority) > 0 { + i -= len(x.Authority) + copy(dAtA[i:], x.Authority) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Authority))) + i-- + dAtA[i] = 0xa + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParams) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if x.Params == nil { + x.Params = &Params{} + } + if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Params); err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +var ( + md_MsgUpdateParamsResponse protoreflect.MessageDescriptor +) + +func init() { + file_sge_mint_v1beta_tx_proto_init() + md_MsgUpdateParamsResponse = File_sge_mint_v1beta_tx_proto.Messages().ByName("MsgUpdateParamsResponse") +} + +var _ protoreflect.Message = (*fastReflection_MsgUpdateParamsResponse)(nil) + +type fastReflection_MsgUpdateParamsResponse MsgUpdateParamsResponse + +func (x *MsgUpdateParamsResponse) ProtoReflect() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(x) +} + +func (x *MsgUpdateParamsResponse) slowProtoReflect() protoreflect.Message { + mi := &file_sge_mint_v1beta_tx_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +var _fastReflection_MsgUpdateParamsResponse_messageType fastReflection_MsgUpdateParamsResponse_messageType +var _ protoreflect.MessageType = fastReflection_MsgUpdateParamsResponse_messageType{} + +type fastReflection_MsgUpdateParamsResponse_messageType struct{} + +func (x fastReflection_MsgUpdateParamsResponse_messageType) Zero() protoreflect.Message { + return (*fastReflection_MsgUpdateParamsResponse)(nil) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} +func (x fastReflection_MsgUpdateParamsResponse_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Descriptor returns message descriptor, which contains only the protobuf +// type information for the message. +func (x *fastReflection_MsgUpdateParamsResponse) Descriptor() protoreflect.MessageDescriptor { + return md_MsgUpdateParamsResponse +} + +// Type returns the message type, which encapsulates both Go and protobuf +// type information. If the Go type information is not needed, +// it is recommended that the message descriptor be used instead. +func (x *fastReflection_MsgUpdateParamsResponse) Type() protoreflect.MessageType { + return _fastReflection_MsgUpdateParamsResponse_messageType +} + +// New returns a newly allocated and mutable empty message. +func (x *fastReflection_MsgUpdateParamsResponse) New() protoreflect.Message { + return new(fastReflection_MsgUpdateParamsResponse) +} + +// Interface unwraps the message reflection interface and +// returns the underlying ProtoMessage interface. +func (x *fastReflection_MsgUpdateParamsResponse) Interface() protoreflect.ProtoMessage { + return (*MsgUpdateParamsResponse)(x) +} + +// Range iterates over every populated field in an undefined order, +// calling f for each field descriptor and value encountered. +// Range returns immediately if f returns false. +// While iterating, mutating operations may only be performed +// on the current field descriptor. +func (x *fastReflection_MsgUpdateParamsResponse) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +} + +// Has reports whether a field is populated. +// +// Some fields have the property of nullability where it is possible to +// distinguish between the default value of a field and whether the field +// was explicitly populated with the default value. Singular message fields, +// member fields of a oneof, and proto2 scalar fields are nullable. Such +// fields are populated only if explicitly set. +// +// In other cases (aside from the nullable cases above), +// a proto3 scalar field is populated if it contains a non-zero value, and +// a repeated field is populated if it is non-empty. +func (x *fastReflection_MsgUpdateParamsResponse) Has(fd protoreflect.FieldDescriptor) bool { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Clear clears the field such that a subsequent Has call reports false. +// +// Clearing an extension field clears both the extension type and value +// associated with the given field number. +// +// Clear is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Clear(fd protoreflect.FieldDescriptor) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Get retrieves the value for a field. +// +// For unpopulated scalars, it returns the default value, where +// the default value of a bytes scalar is guaranteed to be a copy. +// For unpopulated composite types, it returns an empty, read-only view +// of the value; to obtain a mutable reference, use Mutable. +func (x *fastReflection_MsgUpdateParamsResponse) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { + switch descriptor.FullName() { + default: + if descriptor.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParamsResponse does not contain field %s", descriptor.FullName())) + } +} + +// Set stores the value for a field. +// +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType. +// When setting a composite type, it is unspecified whether the stored value +// aliases the source's memory in any way. If the composite value is an +// empty, read-only value, then it panics. +// +// Set is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// Mutable returns a mutable reference to a composite type. +// +// If the field is unpopulated, it may allocate a composite value. +// For a field belonging to a oneof, it implicitly clears any other field +// that may be currently set within the same oneof. +// For extension fields, it implicitly stores the provided ExtensionType +// if not already stored. +// It panics if the field does not contain a composite type. +// +// Mutable is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// NewField returns a new value that is assignable to the field +// for the given descriptor. For scalars, this returns the default value. +// For lists, maps, and messages, this returns a new, empty, mutable value. +func (x *fastReflection_MsgUpdateParamsResponse) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { + switch fd.FullName() { + default: + if fd.IsExtension() { + panic(fmt.Errorf("proto3 declared messages do not support extensions: sge.mint.v1beta.MsgUpdateParamsResponse")) + } + panic(fmt.Errorf("message sge.mint.v1beta.MsgUpdateParamsResponse does not contain field %s", fd.FullName())) + } +} + +// WhichOneof reports which field within the oneof is populated, +// returning nil if none are populated. +// It panics if the oneof descriptor does not belong to this message. +func (x *fastReflection_MsgUpdateParamsResponse) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { + switch d.FullName() { + default: + panic(fmt.Errorf("%s is not a oneof field in sge.mint.v1beta.MsgUpdateParamsResponse", d.FullName())) + } + panic("unreachable") +} + +// GetUnknown retrieves the entire list of unknown fields. +// The caller may only mutate the contents of the RawFields +// if the mutated bytes are stored back into the message with SetUnknown. +func (x *fastReflection_MsgUpdateParamsResponse) GetUnknown() protoreflect.RawFields { + return x.unknownFields +} + +// SetUnknown stores an entire list of unknown fields. +// The raw fields must be syntactically valid according to the wire format. +// An implementation may panic if this is not the case. +// Once stored, the caller must not mutate the content of the RawFields. +// An empty RawFields may be passed to clear the fields. +// +// SetUnknown is a mutating operation and unsafe for concurrent use. +func (x *fastReflection_MsgUpdateParamsResponse) SetUnknown(fields protoreflect.RawFields) { + x.unknownFields = fields +} + +// IsValid reports whether the message is valid. +// +// An invalid message is an empty, read-only value. +// +// An invalid message often corresponds to a nil pointer of the concrete +// message type, but the details are implementation dependent. +// Validity is not part of the protobuf data model, and may not +// be preserved in marshaling or other operations. +func (x *fastReflection_MsgUpdateParamsResponse) IsValid() bool { + return x != nil +} + +// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations. +// This method may return nil. +// +// The returned methods type is identical to +// "google.golang.org/protobuf/runtime/protoiface".Methods. +// Consult the protoiface package documentation for details. +func (x *fastReflection_MsgUpdateParamsResponse) ProtoMethods() *protoiface.Methods { + size := func(input protoiface.SizeInput) protoiface.SizeOutput { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: 0, + } + } + options := runtime.SizeInputToOptions(input) + _ = options + var n int + var l int + _ = l + if x.unknownFields != nil { + n += len(x.unknownFields) + } + return protoiface.SizeOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Size: n, + } + } + + marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + options := runtime.MarshalInputToOptions(input) + _ = options + size := options.Size(x) + dAtA := make([]byte, size) + i := len(dAtA) + _ = i + var l int + _ = l + if x.unknownFields != nil { + i -= len(x.unknownFields) + copy(dAtA[i:], x.unknownFields) + } + if input.Buf != nil { + input.Buf = append(input.Buf, dAtA...) + } else { + input.Buf = dAtA + } + return protoiface.MarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Buf: input.Buf, + }, nil + } + unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { + x := input.Message.Interface().(*MsgUpdateParamsResponse) + if x == nil { + return protoiface.UnmarshalOutput{ + NoUnkeyedLiterals: input.NoUnkeyedLiterals, + Flags: input.Flags, + }, nil + } + options := runtime.UnmarshalInputToOptions(input) + _ = options + dAtA := input.Buf + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := runtime.Skip(dAtA[iNdEx:]) + if err != nil { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + if !options.DiscardUnknown { + x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + } + iNdEx += skippy + } + } + + if iNdEx > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil + } + return &protoiface.Methods{ + NoUnkeyedLiterals: struct{}{}, + Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown, + Size: size, + Marshal: marshal, + Unmarshal: unmarshal, + Merge: nil, + CheckInitialized: nil, + } +} + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.0 +// protoc (unknown) +// source: sge/mint/v1beta/tx.proto + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// MsgUpdateParams is the Msg/UpdateParams request type. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParams struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // authority is the address that controls the module (defaults to x/gov unless + // overwritten). + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/mint parameters to update. + // + // NOTE: All parameters must be supplied. + Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"` +} + +func (x *MsgUpdateParams) Reset() { + *x = MsgUpdateParams{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_tx_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParams) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParams) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParams.ProtoReflect.Descriptor instead. +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_tx_proto_rawDescGZIP(), []int{0} +} + +func (x *MsgUpdateParams) GetAuthority() string { + if x != nil { + return x.Authority + } + return "" +} + +func (x *MsgUpdateParams) GetParams() *Params { + if x != nil { + return x.Params + } + return nil +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParamsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MsgUpdateParamsResponse) Reset() { + *x = MsgUpdateParamsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_sge_mint_v1beta_tx_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MsgUpdateParamsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MsgUpdateParamsResponse) ProtoMessage() {} + +// Deprecated: Use MsgUpdateParamsResponse.ProtoReflect.Descriptor instead. +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return file_sge_mint_v1beta_tx_proto_rawDescGZIP(), []int{1} +} + +var File_sge_mint_v1beta_tx_proto protoreflect.FileDescriptor + +var file_sge_mint_v1beta_tx_proto_rawDesc = []byte{ + 0x0a, 0x18, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0f, 0x73, 0x67, 0x65, 0x2e, + 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x1a, 0x11, 0x61, 0x6d, 0x69, + 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, + 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, + 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, + 0x6e, 0x74, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xb4, 0x01, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, + 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, + 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, + 0x74, 0x79, 0x12, 0x3a, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x42, 0x09, 0xc8, 0xde, 0x1f, + 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x3a, 0x2d, + 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x8a, 0xe7, + 0xb0, 0x2a, 0x1a, 0x73, 0x67, 0x65, 0x2f, 0x78, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x4d, 0x73, + 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x19, 0x0a, + 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, 0x68, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, + 0x5a, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, + 0x20, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, + 0x73, 0x1a, 0x28, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, + 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, 0xb0, + 0x2a, 0x01, 0x42, 0xb7, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x67, 0x65, 0x2e, 0x6d, + 0x69, 0x6e, 0x74, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, + 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, + 0x6d, 0x2f, 0x73, 0x67, 0x65, 0x2d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x73, 0x67, + 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x67, 0x65, 0x2f, 0x6d, 0x69, 0x6e, 0x74, 0x2f, 0x76, + 0x31, 0x62, 0x65, 0x74, 0x61, 0x3b, 0x6d, 0x69, 0x6e, 0x74, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, + 0xa2, 0x02, 0x03, 0x53, 0x4d, 0x58, 0xaa, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x2e, 0x4d, 0x69, 0x6e, + 0x74, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xca, 0x02, 0x0f, 0x53, 0x67, 0x65, 0x5c, 0x4d, + 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0xe2, 0x02, 0x1b, 0x53, 0x67, 0x65, + 0x5c, 0x4d, 0x69, 0x6e, 0x74, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x53, 0x67, 0x65, 0x3a, 0x3a, + 0x4d, 0x69, 0x6e, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_sge_mint_v1beta_tx_proto_rawDescOnce sync.Once + file_sge_mint_v1beta_tx_proto_rawDescData = file_sge_mint_v1beta_tx_proto_rawDesc +) + +func file_sge_mint_v1beta_tx_proto_rawDescGZIP() []byte { + file_sge_mint_v1beta_tx_proto_rawDescOnce.Do(func() { + file_sge_mint_v1beta_tx_proto_rawDescData = protoimpl.X.CompressGZIP(file_sge_mint_v1beta_tx_proto_rawDescData) + }) + return file_sge_mint_v1beta_tx_proto_rawDescData +} + +var file_sge_mint_v1beta_tx_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_sge_mint_v1beta_tx_proto_goTypes = []interface{}{ + (*MsgUpdateParams)(nil), // 0: sge.mint.v1beta.MsgUpdateParams + (*MsgUpdateParamsResponse)(nil), // 1: sge.mint.v1beta.MsgUpdateParamsResponse + (*Params)(nil), // 2: sge.mint.v1beta.Params +} +var file_sge_mint_v1beta_tx_proto_depIdxs = []int32{ + 2, // 0: sge.mint.v1beta.MsgUpdateParams.params:type_name -> sge.mint.v1beta.Params + 0, // 1: sge.mint.v1beta.Msg.UpdateParams:input_type -> sge.mint.v1beta.MsgUpdateParams + 1, // 2: sge.mint.v1beta.Msg.UpdateParams:output_type -> sge.mint.v1beta.MsgUpdateParamsResponse + 2, // [2:3] is the sub-list for method output_type + 1, // [1:2] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_sge_mint_v1beta_tx_proto_init() } +func file_sge_mint_v1beta_tx_proto_init() { + if File_sge_mint_v1beta_tx_proto != nil { + return + } + file_sge_mint_v1beta_params_proto_init() + if !protoimpl.UnsafeEnabled { + file_sge_mint_v1beta_tx_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParams); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_sge_mint_v1beta_tx_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MsgUpdateParamsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_sge_mint_v1beta_tx_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_sge_mint_v1beta_tx_proto_goTypes, + DependencyIndexes: file_sge_mint_v1beta_tx_proto_depIdxs, + MessageInfos: file_sge_mint_v1beta_tx_proto_msgTypes, + }.Build() + File_sge_mint_v1beta_tx_proto = out.File + file_sge_mint_v1beta_tx_proto_rawDesc = nil + file_sge_mint_v1beta_tx_proto_goTypes = nil + file_sge_mint_v1beta_tx_proto_depIdxs = nil +} diff --git a/api/sge/mint/v1beta/tx_grpc.pb.go b/api/sge/mint/v1beta/tx_grpc.pb.go new file mode 100644 index 00000000..d8927945 --- /dev/null +++ b/api/sge/mint/v1beta/tx_grpc.pb.go @@ -0,0 +1,117 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.3.0 +// - protoc (unknown) +// source: sge/mint/v1beta/tx.proto + +package mintv1beta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +const ( + Msg_UpdateParams_FullMethodName = "/sge.mint.v1beta.Msg/UpdateParams" +) + +// MsgClient is the client API for Msg service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type MsgClient interface { + // UpdateParams defines a governance operation for updating the x/mint module + // parameters. The authority is defaults to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) +} + +type msgClient struct { + cc grpc.ClientConnInterface +} + +func NewMsgClient(cc grpc.ClientConnInterface) MsgClient { + return &msgClient{cc} +} + +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// MsgServer is the server API for Msg service. +// All implementations must embed UnimplementedMsgServer +// for forward compatibility +type MsgServer interface { + // UpdateParams defines a governance operation for updating the x/mint module + // parameters. The authority is defaults to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) + mustEmbedUnimplementedMsgServer() +} + +// UnimplementedMsgServer must be embedded to have forward compatible implementations. +type UnimplementedMsgServer struct { +} + +func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} +func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {} + +// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to MsgServer will +// result in compilation errors. +type UnsafeMsgServer interface { + mustEmbedUnimplementedMsgServer() +} + +func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) { + s.RegisterService(&Msg_ServiceDesc, srv) +} + +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Msg_UpdateParams_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + +// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Msg_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "sge.mint.v1beta.Msg", + HandlerType: (*MsgServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "sge/mint/v1beta/tx.proto", +} diff --git a/proto/sge/legacy/bet/module/v1/module.proto b/proto/sge/legacy/bet/module/v1/module.proto new file mode 100644 index 00000000..e956f852 --- /dev/null +++ b/proto/sge/legacy/bet/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.legacy.bet.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the bet module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/bet" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/bet/bet.proto b/proto/sge/legacy/bet/v1beta/bet.proto similarity index 96% rename from proto/sgenetwork/sge/bet/bet.proto rename to proto/sge/legacy/bet/v1beta/bet.proto index 785a5583..7510d471 100644 --- a/proto/sgenetwork/sge/bet/bet.proto +++ b/proto/sge/legacy/bet/v1beta/bet.proto @@ -1,11 +1,11 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/bet/odds_type.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/bet/v1beta/odds_type.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // Bet is the transaction order placed by a bettor on a specific event and odd message Bet { @@ -178,7 +178,7 @@ message BetFulfillment { // metadata for bet message MetaData { // selected_odds_type is metadata for bet - sgenetwork.sge.bet.OddsType selected_odds_type = 1; + sge.legacy.bet.v1beta.OddsType selected_odds_type = 1; // selected_odds_value is metadata for bet string selected_odds_value = 2; // is_main_market will tell weather the bet placed on the main market or not diff --git a/proto/sgenetwork/sge/bet/bet_odds.proto b/proto/sge/legacy/bet/v1beta/bet_odds.proto similarity index 94% rename from proto/sgenetwork/sge/bet/bet_odds.proto rename to proto/sge/legacy/bet/v1beta/bet_odds.proto index c0f9e083..284f0007 100644 --- a/proto/sgenetwork/sge/bet/bet_odds.proto +++ b/proto/sge/legacy/bet/v1beta/bet_odds.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // BetOdds is the type to store odds of a market. message BetOdds { diff --git a/proto/sgenetwork/sge/bet/constraints.proto b/proto/sge/legacy/bet/v1beta/constraints.proto similarity index 82% rename from proto/sgenetwork/sge/bet/constraints.proto rename to proto/sge/legacy/bet/v1beta/constraints.proto index 9de48fef..629ae80e 100644 --- a/proto/sgenetwork/sge/bet/constraints.proto +++ b/proto/sge/legacy/bet/v1beta/constraints.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // Constraints is the bet constrains type for the bets message Constraints { diff --git a/proto/sgenetwork/sge/bet/genesis.proto b/proto/sge/legacy/bet/v1beta/genesis.proto similarity index 79% rename from proto/sgenetwork/sge/bet/genesis.proto rename to proto/sge/legacy/bet/v1beta/genesis.proto index 47b5468f..ee173c7d 100644 --- a/proto/sgenetwork/sge/bet/genesis.proto +++ b/proto/sge/legacy/bet/v1beta/genesis.proto @@ -1,12 +1,12 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/bet/params.proto"; -import "sgenetwork/sge/bet/bet.proto"; -import "sgenetwork/sge/bet/stats.proto"; +import "sge/legacy/bet/v1beta/bet.proto"; +import "sge/legacy/bet/v1beta/params.proto"; +import "sge/legacy/bet/v1beta/stats.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // GenesisState defines the bet module's genesis state. message GenesisState { diff --git a/proto/sgenetwork/sge/bet/odds_type.proto b/proto/sge/legacy/bet/v1beta/odds_type.proto similarity index 77% rename from proto/sgenetwork/sge/bet/odds_type.proto rename to proto/sge/legacy/bet/v1beta/odds_type.proto index 20edd555..0730ffcf 100644 --- a/proto/sgenetwork/sge/bet/odds_type.proto +++ b/proto/sge/legacy/bet/v1beta/odds_type.proto @@ -1,7 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // OddsType is the representation of the type of the odds. enum OddsType { diff --git a/proto/sgenetwork/sge/bet/params.proto b/proto/sge/legacy/bet/v1beta/params.proto similarity index 78% rename from proto/sgenetwork/sge/bet/params.proto rename to proto/sge/legacy/bet/v1beta/params.proto index dc203ece..b8259fc3 100644 --- a/proto/sgenetwork/sge/bet/params.proto +++ b/proto/sge/legacy/bet/v1beta/params.proto @@ -1,10 +1,10 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/bet/constraints.proto"; +import "sge/legacy/bet/v1beta/constraints.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // Params defines the parameters for the module. message Params { diff --git a/proto/sgenetwork/sge/bet/query.proto b/proto/sge/legacy/bet/v1beta/query.proto similarity index 94% rename from proto/sgenetwork/sge/bet/query.proto rename to proto/sge/legacy/bet/v1beta/query.proto index 4c0ad37f..36ccbf05 100644 --- a/proto/sgenetwork/sge/bet/query.proto +++ b/proto/sge/legacy/bet/v1beta/query.proto @@ -1,15 +1,15 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; -import "gogoproto/gogo.proto"; +import "cosmos/base/query/v1beta1/pagination.proto"; import "cosmos_proto/cosmos.proto"; +import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "sgenetwork/sge/bet/params.proto"; -import "sgenetwork/sge/bet/bet.proto"; -import "sgenetwork/sge/market/market.proto"; +import "sge/legacy/bet/v1beta/bet.proto"; +import "sge/legacy/bet/v1beta/params.proto"; +import "sge/legacy/market/v1beta/market.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // Query defines the gRPC querier service. service Query { @@ -73,7 +73,7 @@ message QueryBetRequest { // Query/Bet RPC method. message QueryBetResponse { Bet bet = 1 [ (gogoproto.nullable) = false ]; - sgenetwork.sge.market.Market market = 2 [ (gogoproto.nullable) = false ]; + sge.legacy.market.v1beta.Market market = 2 [ (gogoproto.nullable) = false ]; } // QueryBetsRequest is the request type for the bets list query diff --git a/proto/sgenetwork/sge/bet/stats.proto b/proto/sge/legacy/bet/v1beta/stats.proto similarity index 64% rename from proto/sgenetwork/sge/bet/stats.proto rename to proto/sge/legacy/bet/v1beta/stats.proto index 4938dbe3..02d53dd6 100644 --- a/proto/sgenetwork/sge/bet/stats.proto +++ b/proto/sge/legacy/bet/v1beta/stats.proto @@ -1,7 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // BetStats is the type of statistics of the betting in the blockchain state. message BetStats { diff --git a/proto/sgenetwork/sge/bet/ticket.proto b/proto/sge/legacy/bet/v1beta/ticket.proto similarity index 67% rename from proto/sgenetwork/sge/bet/ticket.proto rename to proto/sge/legacy/bet/v1beta/ticket.proto index e73c68a4..212666f0 100644 --- a/proto/sgenetwork/sge/bet/ticket.proto +++ b/proto/sge/legacy/bet/v1beta/ticket.proto @@ -1,20 +1,19 @@ - syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/type/kyc.proto"; -import "sgenetwork/sge/bet/bet.proto"; -import "sgenetwork/sge/bet/bet_odds.proto"; +import "sge/legacy/bet/v1beta/bet.proto"; +import "sge/legacy/bet/v1beta/bet_odds.proto"; +import "sge/legacy/type/v1beta/kyc.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // WagerTicketPayload indicates data of bet placement ticket. message WagerTicketPayload { // selected_odds is the user-selected odds to place bet. BetOdds selected_odds = 1; // kyc_data contains the details of user kyc. - sgenetwork.sge.type.KycDataPayload kyc_data = 2 + sge.legacy.type.v1beta.KycDataPayload kyc_data = 2 [ (gogoproto.nullable) = false ]; // all odds for the selected market. repeated BetOddsCompact all_odds = 4; diff --git a/proto/sgenetwork/sge/bet/tx.proto b/proto/sge/legacy/bet/v1beta/tx.proto similarity index 90% rename from proto/sgenetwork/sge/bet/tx.proto rename to proto/sge/legacy/bet/v1beta/tx.proto index 25aa95ed..f75de4c8 100644 --- a/proto/sgenetwork/sge/bet/tx.proto +++ b/proto/sge/legacy/bet/v1beta/tx.proto @@ -1,14 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/bet/params.proto"; -import "sgenetwork/sge/bet/wager.proto"; +import "sge/legacy/bet/v1beta/params.proto"; +import "sge/legacy/bet/v1beta/wager.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // Msg defines the Msg service. service Msg { diff --git a/proto/sgenetwork/sge/bet/wager.proto b/proto/sge/legacy/bet/v1beta/wager.proto similarity index 84% rename from proto/sgenetwork/sge/bet/wager.proto rename to proto/sge/legacy/bet/v1beta/wager.proto index b44c2900..d8fbd227 100644 --- a/proto/sgenetwork/sge/bet/wager.proto +++ b/proto/sge/legacy/bet/v1beta/wager.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.bet; +package sge.legacy.bet.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/bet/types"; +option go_package = "github.com/sge-network/sge/x/legacy/bet/types"; // WagerProps contains attributes which come in wager tx request. message WagerProps { diff --git a/proto/sge/legacy/house/module/v1/module.proto b/proto/sge/legacy/house/module/v1/module.proto new file mode 100644 index 00000000..89d46eb3 --- /dev/null +++ b/proto/sge/legacy/house/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.legacy.house.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the house module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/house" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/house/authz.proto b/proto/sge/legacy/house/v1beta/authz.proto similarity index 85% rename from proto/sgenetwork/sge/house/authz.proto rename to proto/sge/legacy/house/v1beta/authz.proto index a2fe4d37..46638a41 100644 --- a/proto/sgenetwork/sge/house/authz.proto +++ b/proto/sge/legacy/house/v1beta/authz.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // DepositAuthorization allows the grantee to spend up to spend_limit from // the granter's account for deposit. diff --git a/proto/sgenetwork/sge/house/deposit.proto b/proto/sge/legacy/house/v1beta/deposit.proto similarity index 94% rename from proto/sgenetwork/sge/house/deposit.proto rename to proto/sge/legacy/house/v1beta/deposit.proto index 0d729471..db5bf88d 100644 --- a/proto/sgenetwork/sge/house/deposit.proto +++ b/proto/sge/legacy/house/v1beta/deposit.proto @@ -1,10 +1,10 @@ syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // Deposit represents the deposit against a market held by an account. message Deposit { diff --git a/proto/sgenetwork/sge/house/genesis.proto b/proto/sge/legacy/house/v1beta/genesis.proto similarity index 67% rename from proto/sgenetwork/sge/house/genesis.proto rename to proto/sge/legacy/house/v1beta/genesis.proto index 385ce69b..1627b9fb 100644 --- a/proto/sgenetwork/sge/house/genesis.proto +++ b/proto/sge/legacy/house/v1beta/genesis.proto @@ -1,12 +1,12 @@ syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/house/deposit.proto"; -import "sgenetwork/sge/house/withdraw.proto"; -import "sgenetwork/sge/house/params.proto"; +import "sge/legacy/house/v1beta/deposit.proto"; +import "sge/legacy/house/v1beta/params.proto"; +import "sge/legacy/house/v1beta/withdraw.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // GenesisState defines the house module's genesis state. message GenesisState { diff --git a/proto/sgenetwork/sge/house/params.proto b/proto/sge/legacy/house/v1beta/params.proto similarity index 89% rename from proto/sgenetwork/sge/house/params.proto rename to proto/sge/legacy/house/v1beta/params.proto index 8a59194d..87f4fe55 100644 --- a/proto/sgenetwork/sge/house/params.proto +++ b/proto/sge/legacy/house/v1beta/params.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // Params define the parameters for the house module. message Params { diff --git a/proto/sgenetwork/sge/house/query.proto b/proto/sge/legacy/house/v1beta/query.proto similarity index 94% rename from proto/sgenetwork/sge/house/query.proto rename to proto/sge/legacy/house/v1beta/query.proto index 262811a2..bed82cb9 100644 --- a/proto/sgenetwork/sge/house/query.proto +++ b/proto/sge/legacy/house/v1beta/query.proto @@ -1,15 +1,15 @@ syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; +import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "sgenetwork/sge/house/params.proto"; -import "sgenetwork/sge/house/deposit.proto"; -import "sgenetwork/sge/house/withdraw.proto"; +import "sge/legacy/house/v1beta/deposit.proto"; +import "sge/legacy/house/v1beta/params.proto"; +import "sge/legacy/house/v1beta/withdraw.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // Query defines the gRPC querier service. service Query { @@ -128,4 +128,4 @@ message QueryWithdrawalRequest { message QueryWithdrawalResponse { // withdrawal holds all the withdrawal properties. Withdrawal withdrawal = 1 [ (gogoproto.nullable) = false ]; -} \ No newline at end of file +} diff --git a/proto/sgenetwork/sge/house/ticket.proto b/proto/sge/legacy/house/v1beta/ticket.proto similarity index 77% rename from proto/sgenetwork/sge/house/ticket.proto rename to proto/sge/legacy/house/v1beta/ticket.proto index b7e6a1cd..0da124ed 100644 --- a/proto/sgenetwork/sge/house/ticket.proto +++ b/proto/sge/legacy/house/v1beta/ticket.proto @@ -1,17 +1,16 @@ - syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/type/kyc.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/type/v1beta/kyc.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // DepositTicketPayload indicates data of the deposit ticket. message DepositTicketPayload { // kyc_data contains the details of user kyc. - sgenetwork.sge.type.KycDataPayload kyc_data = 1 + sge.legacy.type.v1beta.KycDataPayload kyc_data = 1 [ (gogoproto.nullable) = false ]; // depositor_address is the account who makes a deposit string depositor_address = 2 [ @@ -23,7 +22,7 @@ message DepositTicketPayload { // WithdrawTicketPayload indicates data of the withdrawal ticket. message WithdrawTicketPayload { // kyc_data contains the details of user kyc. - sgenetwork.sge.type.KycDataPayload kyc_data = 1 + sge.legacy.type.v1beta.KycDataPayload kyc_data = 1 [ (gogoproto.nullable) = false ]; // depositor_address is the account who makes a deposit string depositor_address = 2 [ diff --git a/proto/sgenetwork/sge/house/tx.proto b/proto/sge/legacy/house/v1beta/tx.proto similarity index 96% rename from proto/sgenetwork/sge/house/tx.proto rename to proto/sge/legacy/house/v1beta/tx.proto index af50224f..133d94b7 100644 --- a/proto/sgenetwork/sge/house/tx.proto +++ b/proto/sge/legacy/house/v1beta/tx.proto @@ -1,14 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/house/params.proto"; -import "sgenetwork/sge/house/withdraw.proto"; +import "sge/legacy/house/v1beta/params.proto"; +import "sge/legacy/house/v1beta/withdraw.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // Msg defines the house Msg service. service Msg { diff --git a/proto/sgenetwork/sge/house/withdraw.proto b/proto/sge/legacy/house/v1beta/withdraw.proto similarity index 94% rename from proto/sgenetwork/sge/house/withdraw.proto rename to proto/sge/legacy/house/v1beta/withdraw.proto index 4a873bed..263410f7 100644 --- a/proto/sgenetwork/sge/house/withdraw.proto +++ b/proto/sge/legacy/house/v1beta/withdraw.proto @@ -1,10 +1,10 @@ syntax = "proto3"; -package sgenetwork.sge.house; +package sge.legacy.house.v1beta; import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -option go_package = "github.com/sge-network/sge/x/house/types"; +option go_package = "github.com/sge-network/sge/x/legacy/house/types"; // Withdrawal represents the withdrawal against a deposit. message Withdrawal { diff --git a/proto/sge/legacy/market/module/v1/module.proto b/proto/sge/legacy/market/module/v1/module.proto new file mode 100644 index 00000000..bdc0809c --- /dev/null +++ b/proto/sge/legacy/market/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.legacy.market.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the market module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/market" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/market/genesis.proto b/proto/sge/legacy/market/v1beta/genesis.proto similarity index 66% rename from proto/sgenetwork/sge/market/genesis.proto rename to proto/sge/legacy/market/v1beta/genesis.proto index 039316a6..dc16f25b 100644 --- a/proto/sgenetwork/sge/market/genesis.proto +++ b/proto/sge/legacy/market/v1beta/genesis.proto @@ -1,12 +1,12 @@ syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/market/params.proto"; -import "sgenetwork/sge/market/market.proto"; -import "sgenetwork/sge/market/stats.proto"; +import "sge/legacy/market/v1beta/market.proto"; +import "sge/legacy/market/v1beta/params.proto"; +import "sge/legacy/market/v1beta/stats.proto"; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // GenesisState defines the market module's genesis state. message GenesisState { diff --git a/proto/sgenetwork/sge/market/market.proto b/proto/sge/legacy/market/v1beta/market.proto similarity index 93% rename from proto/sgenetwork/sge/market/market.proto rename to proto/sge/legacy/market/v1beta/market.proto index f3e33b7e..e735ca6e 100644 --- a/proto/sgenetwork/sge/market/market.proto +++ b/proto/sge/legacy/market/v1beta/market.proto @@ -1,11 +1,11 @@ syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/market/odds.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/market/v1beta/odds.proto"; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // Market is the representation of the market to be stored in // the market state. diff --git a/proto/sgenetwork/sge/market/odds.proto b/proto/sge/legacy/market/v1beta/odds.proto similarity index 77% rename from proto/sgenetwork/sge/market/odds.proto rename to proto/sge/legacy/market/v1beta/odds.proto index 9f058f0b..bd016fea 100644 --- a/proto/sgenetwork/sge/market/odds.proto +++ b/proto/sge/legacy/market/v1beta/odds.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // Odds is a representation of market odds. message Odds { diff --git a/proto/sgenetwork/sge/market/params.proto b/proto/sge/legacy/market/v1beta/params.proto similarity index 67% rename from proto/sgenetwork/sge/market/params.proto rename to proto/sge/legacy/market/v1beta/params.proto index 741c7423..4d166d0a 100644 --- a/proto/sgenetwork/sge/market/params.proto +++ b/proto/sge/legacy/market/v1beta/params.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // Params defines the parameters for the module. // It contains bet constraints associated to a market. diff --git a/proto/sgenetwork/sge/market/query.proto b/proto/sge/legacy/market/v1beta/query.proto similarity index 92% rename from proto/sgenetwork/sge/market/query.proto rename to proto/sge/legacy/market/v1beta/query.proto index 07c86fd7..0ad3d875 100644 --- a/proto/sgenetwork/sge/market/query.proto +++ b/proto/sge/legacy/market/v1beta/query.proto @@ -1,13 +1,13 @@ syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; +import "cosmos/base/query/v1beta1/pagination.proto"; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "sgenetwork/sge/market/params.proto"; -import "sgenetwork/sge/market/market.proto"; +import "sge/legacy/market/v1beta/market.proto"; +import "sge/legacy/market/v1beta/params.proto"; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // Query defines the gRPC querier service. service Query { diff --git a/proto/sgenetwork/sge/market/stats.proto b/proto/sge/legacy/market/v1beta/stats.proto similarity index 70% rename from proto/sgenetwork/sge/market/stats.proto rename to proto/sge/legacy/market/v1beta/stats.proto index 343acb52..bb2a5a2d 100644 --- a/proto/sgenetwork/sge/market/stats.proto +++ b/proto/sge/legacy/market/v1beta/stats.proto @@ -1,7 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // MarketStats holds statistics of the market message MarketStats { diff --git a/proto/sgenetwork/sge/market/ticket.proto b/proto/sge/legacy/market/v1beta/ticket.proto similarity index 92% rename from proto/sgenetwork/sge/market/ticket.proto rename to proto/sge/legacy/market/v1beta/ticket.proto index e44f0242..dc55186b 100644 --- a/proto/sgenetwork/sge/market/ticket.proto +++ b/proto/sge/legacy/market/v1beta/ticket.proto @@ -1,12 +1,11 @@ - syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; -import "sgenetwork/sge/market/market.proto"; -import "sgenetwork/sge/market/odds.proto"; import "gogoproto/gogo.proto"; +import "sge/legacy/market/v1beta/market.proto"; +import "sge/legacy/market/v1beta/odds.proto"; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // MarketAddTicketPayload indicates data of add market ticket message MarketAddTicketPayload { diff --git a/proto/sgenetwork/sge/market/tx.proto b/proto/sge/legacy/market/v1beta/tx.proto similarity index 94% rename from proto/sgenetwork/sge/market/tx.proto rename to proto/sge/legacy/market/v1beta/tx.proto index db86633c..84b25dd0 100644 --- a/proto/sgenetwork/sge/market/tx.proto +++ b/proto/sge/legacy/market/v1beta/tx.proto @@ -1,14 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.market; +package sge.legacy.market.v1beta; import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/market/market.proto"; -import "sgenetwork/sge/market/params.proto"; +import "sge/legacy/market/v1beta/market.proto"; +import "sge/legacy/market/v1beta/params.proto"; -option go_package = "github.com/sge-network/sge/x/market/types"; +option go_package = "github.com/sge-network/sge/x/legacy/market/types"; // Msg defines the Msg service. service Msg { diff --git a/proto/sge/legacy/orderbook/module/v1/module.proto b/proto/sge/legacy/orderbook/module/v1/module.proto new file mode 100644 index 00000000..677f6c42 --- /dev/null +++ b/proto/sge/legacy/orderbook/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.legacy.orderbook.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the orderbook module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/orderbook" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/orderbook/exposure.proto b/proto/sge/legacy/orderbook/v1beta/exposure.proto similarity index 95% rename from proto/sgenetwork/sge/orderbook/exposure.proto rename to proto/sge/legacy/orderbook/v1beta/exposure.proto index 48401ca8..da092d02 100644 --- a/proto/sgenetwork/sge/orderbook/exposure.proto +++ b/proto/sge/legacy/orderbook/v1beta/exposure.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // OrderBookOddsExposure represents the exposures taken on odds. message OrderBookOddsExposure { diff --git a/proto/sgenetwork/sge/orderbook/genesis.proto b/proto/sge/legacy/orderbook/v1beta/genesis.proto similarity index 82% rename from proto/sgenetwork/sge/orderbook/genesis.proto rename to proto/sge/legacy/orderbook/v1beta/genesis.proto index 830687d2..8e48e3b1 100644 --- a/proto/sgenetwork/sge/orderbook/genesis.proto +++ b/proto/sge/legacy/orderbook/v1beta/genesis.proto @@ -1,14 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/orderbook/params.proto"; -import "sgenetwork/sge/orderbook/orderbook.proto"; -import "sgenetwork/sge/orderbook/participation.proto"; -import "sgenetwork/sge/orderbook/stats.proto"; -import "sgenetwork/sge/orderbook/exposure.proto"; +import "sge/legacy/orderbook/v1beta/exposure.proto"; +import "sge/legacy/orderbook/v1beta/orderbook.proto"; +import "sge/legacy/orderbook/v1beta/params.proto"; +import "sge/legacy/orderbook/v1beta/participation.proto"; +import "sge/legacy/orderbook/v1beta/stats.proto"; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // GenesisState defines the orderbook module's genesis state. message GenesisState { diff --git a/proto/sgenetwork/sge/orderbook/orderbook.proto b/proto/sge/legacy/orderbook/v1beta/orderbook.proto similarity index 91% rename from proto/sgenetwork/sge/orderbook/orderbook.proto rename to proto/sge/legacy/orderbook/v1beta/orderbook.proto index 2ae61e35..c2e46c95 100644 --- a/proto/sgenetwork/sge/orderbook/orderbook.proto +++ b/proto/sge/legacy/orderbook/v1beta/orderbook.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // OrderBook represents the order book maintained against a market. message OrderBook { diff --git a/proto/sgenetwork/sge/orderbook/params.proto b/proto/sge/legacy/orderbook/v1beta/params.proto similarity index 87% rename from proto/sgenetwork/sge/orderbook/params.proto rename to proto/sge/legacy/orderbook/v1beta/params.proto index 7548cd6e..7251114a 100644 --- a/proto/sgenetwork/sge/orderbook/params.proto +++ b/proto/sge/legacy/orderbook/v1beta/params.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // Params defines the parameters for the orderbook module. message Params { diff --git a/proto/sgenetwork/sge/orderbook/participation.proto b/proto/sge/legacy/orderbook/v1beta/participation.proto similarity index 98% rename from proto/sgenetwork/sge/orderbook/participation.proto rename to proto/sge/legacy/orderbook/v1beta/participation.proto index e6b4a728..39a9ec4b 100644 --- a/proto/sgenetwork/sge/orderbook/participation.proto +++ b/proto/sge/legacy/orderbook/v1beta/participation.proto @@ -1,10 +1,10 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // OrderBookParticipation represents the participants of an order book. message OrderBookParticipation { diff --git a/proto/sgenetwork/sge/orderbook/query.proto b/proto/sge/legacy/orderbook/v1beta/query.proto similarity index 97% rename from proto/sgenetwork/sge/orderbook/query.proto rename to proto/sge/legacy/orderbook/v1beta/query.proto index 537b6d25..636c8a47 100644 --- a/proto/sgenetwork/sge/orderbook/query.proto +++ b/proto/sge/legacy/orderbook/v1beta/query.proto @@ -1,15 +1,15 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; import "cosmos/base/query/v1beta1/pagination.proto"; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "sgenetwork/sge/orderbook/params.proto"; -import "sgenetwork/sge/orderbook/orderbook.proto"; -import "sgenetwork/sge/orderbook/participation.proto"; -import "sgenetwork/sge/orderbook/exposure.proto"; +import "sge/legacy/orderbook/v1beta/exposure.proto"; +import "sge/legacy/orderbook/v1beta/orderbook.proto"; +import "sge/legacy/orderbook/v1beta/params.proto"; +import "sge/legacy/orderbook/v1beta/participation.proto"; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // Query defines the gRPC querier service. service Query { diff --git a/proto/sgenetwork/sge/orderbook/stats.proto b/proto/sge/legacy/orderbook/v1beta/stats.proto similarity index 69% rename from proto/sgenetwork/sge/orderbook/stats.proto rename to proto/sge/legacy/orderbook/v1beta/stats.proto index e544273e..1efbeb8e 100644 --- a/proto/sgenetwork/sge/orderbook/stats.proto +++ b/proto/sge/legacy/orderbook/v1beta/stats.proto @@ -1,7 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // OrderBookStats holds statistics on the order book. message OrderBookStats { diff --git a/proto/sgenetwork/sge/orderbook/tx.proto b/proto/sge/legacy/orderbook/v1beta/tx.proto similarity index 88% rename from proto/sgenetwork/sge/orderbook/tx.proto rename to proto/sge/legacy/orderbook/v1beta/tx.proto index f70c79c9..9df82e30 100644 --- a/proto/sgenetwork/sge/orderbook/tx.proto +++ b/proto/sge/legacy/orderbook/v1beta/tx.proto @@ -1,13 +1,13 @@ syntax = "proto3"; -package sgenetwork.sge.orderbook; +package sge.legacy.orderbook.v1beta; import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/orderbook/params.proto"; +import "sge/legacy/orderbook/v1beta/params.proto"; -option go_package = "github.com/sge-network/sge/x/orderbook/types"; +option go_package = "github.com/sge-network/sge/x/legacy/orderbook/types"; // Msg defines the Msg service. service Msg { diff --git a/proto/sge/legacy/ovm/module/v1/module.proto b/proto/sge/legacy/ovm/module/v1/module.proto new file mode 100644 index 00000000..6198017c --- /dev/null +++ b/proto/sge/legacy/ovm/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.legacy.ovm.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the ovm module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/ovm" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/ovm/genesis.proto b/proto/sge/legacy/ovm/v1beta/genesis.proto similarity index 69% rename from proto/sgenetwork/sge/ovm/genesis.proto rename to proto/sge/legacy/ovm/v1beta/genesis.proto index dd1af1de..53cb0b82 100644 --- a/proto/sgenetwork/sge/ovm/genesis.proto +++ b/proto/sge/legacy/ovm/v1beta/genesis.proto @@ -1,13 +1,13 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/ovm/params.proto"; -import "sgenetwork/sge/ovm/key_vault.proto"; -import "sgenetwork/sge/ovm/proposal.proto"; -import "sgenetwork/sge/ovm/stats.proto"; +import "sge/legacy/ovm/v1beta/key_vault.proto"; +import "sge/legacy/ovm/v1beta/params.proto"; +import "sge/legacy/ovm/v1beta/proposal.proto"; +import "sge/legacy/ovm/v1beta/stats.proto"; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // GenesisState defines the ovm module's genesis state. message GenesisState { diff --git a/proto/sgenetwork/sge/ovm/key_vault.proto b/proto/sge/legacy/ovm/v1beta/key_vault.proto similarity index 65% rename from proto/sgenetwork/sge/ovm/key_vault.proto rename to proto/sge/legacy/ovm/v1beta/key_vault.proto index 9bc9beb9..7a8e0e93 100644 --- a/proto/sgenetwork/sge/ovm/key_vault.proto +++ b/proto/sge/legacy/ovm/v1beta/key_vault.proto @@ -1,7 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // KeyVault is the information of important keys stored in ovm state. message KeyVault { diff --git a/proto/sgenetwork/sge/ovm/params.proto b/proto/sge/legacy/ovm/v1beta/params.proto similarity index 62% rename from proto/sgenetwork/sge/ovm/params.proto rename to proto/sge/legacy/ovm/v1beta/params.proto index d5eefc41..5ed3e1c1 100644 --- a/proto/sgenetwork/sge/ovm/params.proto +++ b/proto/sge/legacy/ovm/v1beta/params.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // Params defines the parameters for the module. message Params { option (gogoproto.goproto_stringer) = false; } diff --git a/proto/sgenetwork/sge/ovm/proposal.proto b/proto/sge/legacy/ovm/v1beta/proposal.proto similarity index 90% rename from proto/sgenetwork/sge/ovm/proposal.proto rename to proto/sge/legacy/ovm/v1beta/proposal.proto index 19e5754a..e4f52e0c 100644 --- a/proto/sgenetwork/sge/ovm/proposal.proto +++ b/proto/sge/legacy/ovm/v1beta/proposal.proto @@ -1,12 +1,12 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/ovm/ticket.proto"; -import "sgenetwork/sge/ovm/vote.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/ovm/v1beta/ticket.proto"; +import "sge/legacy/ovm/v1beta/vote.proto"; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // PublicKeysChangeProposal is the type for the proposal for additions and // removals of pub keys. diff --git a/proto/sgenetwork/sge/ovm/query.proto b/proto/sge/legacy/ovm/v1beta/query.proto similarity index 93% rename from proto/sgenetwork/sge/ovm/query.proto rename to proto/sge/legacy/ovm/v1beta/query.proto index 96e91b26..f3fb48c4 100644 --- a/proto/sgenetwork/sge/ovm/query.proto +++ b/proto/sge/legacy/ovm/v1beta/query.proto @@ -1,13 +1,13 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; -import "gogoproto/gogo.proto"; import "cosmos/base/query/v1beta1/pagination.proto"; +import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "sgenetwork/sge/ovm/params.proto"; -import "sgenetwork/sge/ovm/proposal.proto"; +import "sge/legacy/ovm/v1beta/params.proto"; +import "sge/legacy/ovm/v1beta/proposal.proto"; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // Query defines the gRPC querier service. service Query { diff --git a/proto/sgenetwork/sge/ovm/stats.proto b/proto/sge/legacy/ovm/v1beta/stats.proto similarity index 67% rename from proto/sgenetwork/sge/ovm/stats.proto rename to proto/sge/legacy/ovm/v1beta/stats.proto index 8f79250b..28b34b04 100644 --- a/proto/sgenetwork/sge/ovm/stats.proto +++ b/proto/sge/legacy/ovm/v1beta/stats.proto @@ -1,7 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // ProposalStats is the type for the proposal statistics. message ProposalStats { diff --git a/proto/sgenetwork/sge/ovm/ticket.proto b/proto/sge/legacy/ovm/v1beta/ticket.proto similarity index 80% rename from proto/sgenetwork/sge/ovm/ticket.proto rename to proto/sge/legacy/ovm/v1beta/ticket.proto index 17026555..0e5a3d78 100644 --- a/proto/sgenetwork/sge/ovm/ticket.proto +++ b/proto/sge/legacy/ovm/v1beta/ticket.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; -import "sgenetwork/sge/ovm/vote.proto"; +import "sge/legacy/ovm/v1beta/vote.proto"; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // PubkeysChangeProposalPayload indicates data of public keys changes proposal // ticket. diff --git a/proto/sgenetwork/sge/ovm/tx.proto b/proto/sge/legacy/ovm/v1beta/tx.proto similarity index 95% rename from proto/sgenetwork/sge/ovm/tx.proto rename to proto/sge/legacy/ovm/v1beta/tx.proto index 28edc09b..52f7d961 100644 --- a/proto/sgenetwork/sge/ovm/tx.proto +++ b/proto/sge/legacy/ovm/v1beta/tx.proto @@ -1,13 +1,13 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/ovm/params.proto"; +import "sge/legacy/ovm/v1beta/params.proto"; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // Msg defines the Msg service. service Msg { diff --git a/proto/sgenetwork/sge/ovm/vote.proto b/proto/sge/legacy/ovm/v1beta/vote.proto similarity index 80% rename from proto/sgenetwork/sge/ovm/vote.proto rename to proto/sge/legacy/ovm/v1beta/vote.proto index a54de65f..e3a422a2 100644 --- a/proto/sgenetwork/sge/ovm/vote.proto +++ b/proto/sge/legacy/ovm/v1beta/vote.proto @@ -1,7 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.ovm; +package sge.legacy.ovm.v1beta; -option go_package = "github.com/sge-network/sge/x/ovm/types"; +option go_package = "github.com/sge-network/sge/x/legacy/ovm/types"; // Vote is the type for the proposal vote. message Vote { diff --git a/proto/sge/legacy/reward/module/v1/module.proto b/proto/sge/legacy/reward/module/v1/module.proto new file mode 100644 index 00000000..0e7fe954 --- /dev/null +++ b/proto/sge/legacy/reward/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.legacy.reward.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the reward module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/reward" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/reward/authz.proto b/proto/sge/legacy/reward/v1beta/authz.proto similarity index 90% rename from proto/sgenetwork/sge/reward/authz.proto rename to proto/sge/legacy/reward/v1beta/authz.proto index e45dd744..ddc8047f 100644 --- a/proto/sgenetwork/sge/reward/authz.proto +++ b/proto/sge/legacy/reward/v1beta/authz.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // CreateCampaignAuthorization allows the grantee to spend up to spend_limit // from the granter's account for create campaign. diff --git a/proto/sgenetwork/sge/reward/campaign.proto b/proto/sge/legacy/reward/v1beta/campaign.proto similarity index 94% rename from proto/sgenetwork/sge/reward/campaign.proto rename to proto/sge/legacy/reward/v1beta/campaign.proto index cf4894f9..90a022e5 100644 --- a/proto/sgenetwork/sge/reward/campaign.proto +++ b/proto/sge/legacy/reward/v1beta/campaign.proto @@ -1,11 +1,11 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/reward/reward.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/reward/v1beta/reward.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // Campaign is type for defining the campaign properties. message Campaign { @@ -92,4 +92,4 @@ message CampaignConstraints { (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"max_bet_amount\"" ]; -} \ No newline at end of file +} diff --git a/proto/sgenetwork/sge/reward/genesis.proto b/proto/sge/legacy/reward/v1beta/genesis.proto similarity index 69% rename from proto/sgenetwork/sge/reward/genesis.proto rename to proto/sge/legacy/reward/v1beta/genesis.proto index c1cd542e..ceb913e4 100644 --- a/proto/sgenetwork/sge/reward/genesis.proto +++ b/proto/sge/legacy/reward/v1beta/genesis.proto @@ -1,14 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/reward/params.proto"; -import "sgenetwork/sge/reward/campaign.proto"; -import "sgenetwork/sge/reward/reward.proto"; -import "sgenetwork/sge/reward/promoter.proto"; +import "sge/legacy/reward/v1beta/campaign.proto"; +import "sge/legacy/reward/v1beta/params.proto"; +import "sge/legacy/reward/v1beta/promoter.proto"; +import "sge/legacy/reward/v1beta/reward.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // GenesisState defines the reward module's genesis state. message GenesisState { diff --git a/proto/sgenetwork/sge/reward/params.proto b/proto/sge/legacy/reward/v1beta/params.proto similarity index 61% rename from proto/sgenetwork/sge/reward/params.proto rename to proto/sge/legacy/reward/v1beta/params.proto index c82a1059..78170635 100644 --- a/proto/sgenetwork/sge/reward/params.proto +++ b/proto/sge/legacy/reward/v1beta/params.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // Params defines the parameters for the module. message Params { option (gogoproto.goproto_stringer) = false; } diff --git a/proto/sgenetwork/sge/reward/promoter.proto b/proto/sge/legacy/reward/v1beta/promoter.proto similarity index 90% rename from proto/sgenetwork/sge/reward/promoter.proto rename to proto/sge/legacy/reward/v1beta/promoter.proto index d9933124..4e6bc3f5 100644 --- a/proto/sgenetwork/sge/reward/promoter.proto +++ b/proto/sge/legacy/reward/v1beta/promoter.proto @@ -1,11 +1,11 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/reward/reward.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/reward/v1beta/reward.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // Promoter is type for defining the reward promoter properties and // configuration. @@ -49,4 +49,4 @@ message PromoterByAddress { ]; // address is the address of the promoter account. string address = 2 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; -} \ No newline at end of file +} diff --git a/proto/sgenetwork/sge/reward/query.proto b/proto/sge/legacy/reward/v1beta/query.proto similarity index 95% rename from proto/sgenetwork/sge/reward/query.proto rename to proto/sge/legacy/reward/v1beta/query.proto index a7d4ab99..346f59ed 100644 --- a/proto/sgenetwork/sge/reward/query.proto +++ b/proto/sge/legacy/reward/v1beta/query.proto @@ -1,21 +1,20 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; -import "gogoproto/gogo.proto"; +import "cosmos/base/query/v1beta1/pagination.proto"; import "cosmos_proto/cosmos.proto"; +import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "sgenetwork/sge/reward/params.proto"; -import "sgenetwork/sge/reward/campaign.proto"; -import "sgenetwork/sge/reward/reward.proto"; -import "sgenetwork/sge/reward/promoter.proto"; +import "sge/legacy/reward/v1beta/campaign.proto"; +import "sge/legacy/reward/v1beta/params.proto"; +import "sge/legacy/reward/v1beta/promoter.proto"; +import "sge/legacy/reward/v1beta/reward.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // Query defines the gRPC querier service. service Query { - // Parameters queries the parameters of the module. rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/sge-network/sge/reward/params"; @@ -75,12 +74,12 @@ service Query { "/sge-network/sge/reward/rewards/campaign/{campaign_uid}"; } } + // QueryParamsRequest is request type for the Query/Params RPC method. message QueryParamsRequest {} // QueryParamsResponse is response type for the Query/Params RPC method. message QueryParamsResponse { - // params holds all the parameters of this module. Params params = 1 [ (gogoproto.nullable) = false ]; } diff --git a/proto/sgenetwork/sge/reward/reward.proto b/proto/sge/legacy/reward/v1beta/reward.proto similarity index 95% rename from proto/sgenetwork/sge/reward/reward.proto rename to proto/sge/legacy/reward/v1beta/reward.proto index ca9af0a9..06004645 100644 --- a/proto/sgenetwork/sge/reward/reward.proto +++ b/proto/sge/legacy/reward/v1beta/reward.proto @@ -1,15 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; +import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // Reward is the type for transaction made to reward a user // based on users eligibility. message Reward { - // uid is the unique identifier for a reward. string uid = 1 [ (gogoproto.customname) = "UID", @@ -77,14 +76,14 @@ message RewardAmount { // main_account_percentage transferred to main account address string main_account_percentage = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", + (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"main_account_percentage\"" ]; // subaccount_percentage amount transferred to subaccount address string subaccount_percentage = 5 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", + (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"subaccount_percentage\"" ]; diff --git a/proto/sgenetwork/sge/reward/ticket.proto b/proto/sge/legacy/reward/v1beta/ticket.proto similarity index 92% rename from proto/sgenetwork/sge/reward/ticket.proto rename to proto/sge/legacy/reward/v1beta/ticket.proto index cbe85c67..ebc8d627 100644 --- a/proto/sgenetwork/sge/reward/ticket.proto +++ b/proto/sge/legacy/reward/v1beta/ticket.proto @@ -1,14 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/type/kyc.proto"; -import "sgenetwork/sge/reward/campaign.proto"; -import "sgenetwork/sge/reward/reward.proto"; -import "sgenetwork/sge/reward/promoter.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/reward/v1beta/campaign.proto"; +import "sge/legacy/reward/v1beta/promoter.proto"; +import "sge/legacy/reward/v1beta/reward.proto"; +import "sge/legacy/type/v1beta/kyc.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // CreateCampaignPayload is the type for campaign creation payload. message CreateCampaignPayload { @@ -50,7 +50,6 @@ message CreateCampaignPayload { // UpdateCampaignPayload is the type for campaign update payload. message UpdateCampaignPayload { - // end_ts is the end timestamp of the campaign. uint64 end_ts = 1; @@ -85,7 +84,7 @@ message RewardPayloadCommon { string meta = 3; // kyc_data contains the details of user kyc. - sgenetwork.sge.type.KycDataPayload kyc_data = 4; + sge.legacy.type.v1beta.KycDataPayload kyc_data = 4; } // GrantSignupRewardPayload is the type for signup reward grant payload. @@ -144,4 +143,4 @@ message CreatePromoterPayload { // SetPromoterConfPayload is the payload for the promoter configuration change. message SetPromoterConfPayload { PromoterConf conf = 1 [ (gogoproto.nullable) = false ]; -} \ No newline at end of file +} diff --git a/proto/sgenetwork/sge/reward/tx.proto b/proto/sge/legacy/reward/v1beta/tx.proto similarity index 97% rename from proto/sgenetwork/sge/reward/tx.proto rename to proto/sge/legacy/reward/v1beta/tx.proto index c4fc904e..34b430c9 100644 --- a/proto/sgenetwork/sge/reward/tx.proto +++ b/proto/sge/legacy/reward/v1beta/tx.proto @@ -1,14 +1,14 @@ syntax = "proto3"; -package sgenetwork.sge.reward; +package sge.legacy.reward.v1beta; import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/reward/params.proto"; +import "sge/legacy/reward/v1beta/params.proto"; -option go_package = "github.com/sge-network/sge/x/reward/types"; +option go_package = "github.com/sge-network/sge/x/legacy/reward/types"; // Msg defines the Msg service. service Msg { diff --git a/proto/sge/legacy/subaccount/module/v1/module.proto b/proto/sge/legacy/subaccount/module/v1/module.proto new file mode 100644 index 00000000..537dc9cc --- /dev/null +++ b/proto/sge/legacy/subaccount/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.legacy.subaccount.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the subaccount module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/subaccount" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/subaccount/balance.proto b/proto/sge/legacy/subaccount/v1beta/balance.proto similarity index 93% rename from proto/sgenetwork/sge/subaccount/balance.proto rename to proto/sge/legacy/subaccount/v1beta/balance.proto index 595a1425..64808b3e 100644 --- a/proto/sgenetwork/sge/subaccount/balance.proto +++ b/proto/sge/legacy/subaccount/v1beta/balance.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.subaccount; +package sge.legacy.subaccount.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/subaccount/types"; +option go_package = "github.com/sge-network/sge/x/legacy/subaccount/types"; // AccountSummary defines the balance of a subaccount. message AccountSummary { diff --git a/proto/sgenetwork/sge/subaccount/genesis.proto b/proto/sge/legacy/subaccount/v1beta/genesis.proto similarity index 83% rename from proto/sgenetwork/sge/subaccount/genesis.proto rename to proto/sge/legacy/subaccount/v1beta/genesis.proto index e6ea12b2..755a718a 100644 --- a/proto/sgenetwork/sge/subaccount/genesis.proto +++ b/proto/sge/legacy/subaccount/v1beta/genesis.proto @@ -1,12 +1,12 @@ syntax = "proto3"; -package sgenetwork.sge.subaccount; +package sge.legacy.subaccount.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/subaccount/params.proto"; -import "sgenetwork/sge/subaccount/balance.proto"; +import "gogoproto/gogo.proto"; +import "sge/legacy/subaccount/v1beta/balance.proto"; +import "sge/legacy/subaccount/v1beta/params.proto"; -option go_package = "github.com/sge-network/sge/x/subaccount/types"; +option go_package = "github.com/sge-network/sge/x/legacy/subaccount/types"; // GenesisState defines the subaccount module's genesis state. message GenesisState { @@ -33,4 +33,4 @@ message GenesisSubaccount { // locked_balances defines the lockup of balances history of a subaccount repeated LockedBalance locked_balances = 4 [ (gogoproto.nullable) = false ]; -} \ No newline at end of file +} diff --git a/proto/sgenetwork/sge/subaccount/params.proto b/proto/sge/legacy/subaccount/v1beta/params.proto similarity index 75% rename from proto/sgenetwork/sge/subaccount/params.proto rename to proto/sge/legacy/subaccount/v1beta/params.proto index 22450ca1..146f3b4d 100644 --- a/proto/sgenetwork/sge/subaccount/params.proto +++ b/proto/sge/legacy/subaccount/v1beta/params.proto @@ -1,9 +1,9 @@ syntax = "proto3"; -package sgenetwork.sge.subaccount; +package sge.legacy.subaccount.v1beta; import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/x/subaccount/types"; +option go_package = "github.com/sge-network/sge/x/legacy/subaccount/types"; // Params defines the parameters for the module. message Params { diff --git a/proto/sgenetwork/sge/subaccount/query.proto b/proto/sge/legacy/subaccount/v1beta/query.proto similarity index 70% rename from proto/sgenetwork/sge/subaccount/query.proto rename to proto/sge/legacy/subaccount/v1beta/query.proto index 54bb6a0d..4fdff003 100644 --- a/proto/sgenetwork/sge/subaccount/query.proto +++ b/proto/sge/legacy/subaccount/v1beta/query.proto @@ -1,31 +1,33 @@ syntax = "proto3"; -package sgenetwork.sge.subaccount; +package sge.legacy.subaccount.v1beta; -option go_package = "github.com/sge-network/sge/x/subaccount/types"; - -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; +import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "sgenetwork/sge/subaccount/balance.proto"; -import "sgenetwork/sge/subaccount/params.proto"; +import "sge/legacy/subaccount/v1beta/balance.proto"; +import "sge/legacy/subaccount/v1beta/params.proto"; + +option go_package = "github.com/sge-network/sge/x/legacy/subaccount/types"; // Query defines the gRPC querier service. service Query { // Subaccount fetches a subaccount given the owner. rpc Subaccount(QuerySubaccountRequest) returns (QuerySubaccountResponse) { option (google.api.http).get = "/sge/subaccount/subaccount/{address}"; - }; + } // Params returns the subaccount module parameters. rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/sge/subaccount/params"; - }; + } } // QueryParamsRequest is the request type for the Query/Params RPC method message QueryParamsRequest {} + // QueryParamsResponse is the response type for the Query/Params RPC method message QueryParamsResponse { - sge.subaccount.Params params = 1 [ (gogoproto.nullable) = false ]; + sge.legacy.subaccount.v1beta.Params params = 1 + [ (gogoproto.nullable) = false ]; } // QuerySubaccountRequest is the request type for the Query/Subaccount RPC @@ -34,10 +36,11 @@ message QuerySubaccountRequest { string address = 1; } // QuerySubaccountResponse is the response type for the Query/Subaccount RPC message QuerySubaccountResponse { string address = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; - sge.subaccount.AccountSummary balance = 2 [ (gogoproto.nullable) = false ]; - repeated sge.subaccount.LockedBalance locked_balance = 3 + sge.legacy.subaccount.v1beta.AccountSummary balance = 2 + [ (gogoproto.nullable) = false ]; + repeated sge.legacy.subaccount.v1beta.LockedBalance locked_balance = 3 [ (gogoproto.nullable) = false ]; - repeated sge.subaccount.LockedBalance unlocked_balance = 4 + repeated sge.legacy.subaccount.v1beta.LockedBalance unlocked_balance = 4 [ (gogoproto.nullable) = false ]; string withdrawable_unlocked_balance = 5 [ (gogoproto.customtype) = "cosmossdk.io/math.Int", diff --git a/proto/sgenetwork/sge/subaccount/ticket.proto b/proto/sge/legacy/subaccount/v1beta/ticket.proto similarity index 74% rename from proto/sgenetwork/sge/subaccount/ticket.proto rename to proto/sge/legacy/subaccount/v1beta/ticket.proto index 94f1f38d..7d744988 100644 --- a/proto/sgenetwork/sge/subaccount/ticket.proto +++ b/proto/sge/legacy/subaccount/v1beta/ticket.proto @@ -1,16 +1,15 @@ syntax = "proto3"; -package sgenetwork.sge.subaccount; +package sge.legacy.subaccount.v1beta; import "gogoproto/gogo.proto"; +import "sge/legacy/bet/v1beta/tx.proto"; -import "sgenetwork/sge/bet/tx.proto"; - -option go_package = "github.com/sge-network/sge/x/subaccount/types"; +option go_package = "github.com/sge-network/sge/x/legacy/subaccount/types"; // SubAccWagerTicketPayload indicates data of subaccount wager ticket. message SubAccWagerTicketPayload { // msg holds normal wager message - sgenetwork.sge.bet.MsgWager msg = 1; + sge.legacy.bet.v1beta.MsgWager msg = 1; // mainacc_deduct_amount is amount to be deducted from main account string mainacc_deduct_amount = 2 [ (gogoproto.customtype) = "cosmossdk.io/math.Int", @@ -21,4 +20,4 @@ message SubAccWagerTicketPayload { (gogoproto.customtype) = "cosmossdk.io/math.Int", (gogoproto.nullable) = false ]; -} \ No newline at end of file +} diff --git a/proto/sgenetwork/sge/subaccount/tx.proto b/proto/sge/legacy/subaccount/v1beta/tx.proto similarity index 87% rename from proto/sgenetwork/sge/subaccount/tx.proto rename to proto/sge/legacy/subaccount/v1beta/tx.proto index b763a71b..45ad0f7e 100644 --- a/proto/sgenetwork/sge/subaccount/tx.proto +++ b/proto/sge/legacy/subaccount/v1beta/tx.proto @@ -1,16 +1,16 @@ syntax = "proto3"; -package sgenetwork.sge.subaccount; +package sge.legacy.subaccount.v1beta; import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/bet/tx.proto"; -import "sgenetwork/sge/house/tx.proto"; -import "sgenetwork/sge/subaccount/balance.proto"; -import "sgenetwork/sge/subaccount/params.proto"; +import "sge/legacy/bet/v1beta/tx.proto"; +import "sge/legacy/house/v1beta/tx.proto"; +import "sge/legacy/subaccount/v1beta/balance.proto"; +import "sge/legacy/subaccount/v1beta/params.proto"; -option go_package = "github.com/sge-network/sge/x/subaccount/types"; +option go_package = "github.com/sge-network/sge/x/legacy/subaccount/types"; // Msg defines the Msg service. service Msg { @@ -114,23 +114,29 @@ message MsgWager { // MsgWagerResponse wraps the MsgWagerResponse message. We need it in order not // to have double interface registration conflicts. -message MsgWagerResponse { sgenetwork.sge.bet.MsgWagerResponse response = 1; } +message MsgWagerResponse { + sge.legacy.bet.v1beta.MsgWagerResponse response = 1; +} // MsgHouseDeposit wraps the MsgHouseDeposit message. We need it in order not to // have double interface registration conflicts. -message MsgHouseDeposit { sge.house.MsgDeposit msg = 1; } +message MsgHouseDeposit { sge.legacy.house.v1beta.MsgDeposit msg = 1; } // MsgHouseDepositResponse wraps the MsgHouseDepositResponse message. We need it // in order not to have double interface registration conflicts. -message MsgHouseDepositResponse { sge.house.MsgDepositResponse response = 1; } +message MsgHouseDepositResponse { + sge.legacy.house.v1beta.MsgDepositResponse response = 1; +} // MsgHouseWithdraw wraps the MsgHouseWithdraw message. We need it in order not // to have double interface registration conflicts. -message MsgHouseWithdraw { sge.house.MsgWithdraw msg = 1; } +message MsgHouseWithdraw { sge.legacy.house.v1beta.MsgWithdraw msg = 1; } // MsgHouseWithdrawResponse wraps the MsgHouseWithdrawResponse message. We need // it in order not to have double interface registration conflicts. -message MsgHouseWithdrawResponse { sge.house.MsgWithdrawResponse response = 1; } +message MsgHouseWithdrawResponse { + sge.legacy.house.v1beta.MsgWithdrawResponse response = 1; +} // MsgUpdateParams is the Msg/UpdateParams request type. message MsgUpdateParams { diff --git a/proto/sgenetwork/sge/type/kyc.proto b/proto/sge/legacy/type/v1beta/kyc.proto similarity index 84% rename from proto/sgenetwork/sge/type/kyc.proto rename to proto/sge/legacy/type/v1beta/kyc.proto index 94c0ccaf..0bc8e9fb 100644 --- a/proto/sgenetwork/sge/type/kyc.proto +++ b/proto/sge/legacy/type/v1beta/kyc.proto @@ -1,10 +1,10 @@ syntax = "proto3"; -package sgenetwork.sge.type; +package sge.legacy.type.v1beta; -import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; +import "gogoproto/gogo.proto"; -option go_package = "github.com/sge-network/sge/types"; +option go_package = "github.com/sge-network/sge/types/legacy"; // KycDataPayload is the KYC info. message KycDataPayload { diff --git a/proto/sge/mint/module/v1/module.proto b/proto/sge/mint/module/v1/module.proto new file mode 100644 index 00000000..23952607 --- /dev/null +++ b/proto/sge/mint/module/v1/module.proto @@ -0,0 +1,18 @@ +syntax = "proto3"; + +package sge.mint.module.v1; + +import "cosmos/app/v1alpha1/module.proto"; + +// Module is the config object of the mint module. +message Module { + option (cosmos.app.v1alpha1.module) = { + go_import : "sge/x/mint" + }; + + string fee_collector_name = 1; + + // authority defines the custom module authority. If not set, defaults to the + // governance module. + string authority = 2; +} diff --git a/proto/sgenetwork/sge/mint/genesis.proto b/proto/sge/mint/v1beta/genesis.proto similarity index 50% rename from proto/sgenetwork/sge/mint/genesis.proto rename to proto/sge/mint/v1beta/genesis.proto index c9412faa..31ec064f 100644 --- a/proto/sgenetwork/sge/mint/genesis.proto +++ b/proto/sge/mint/v1beta/genesis.proto @@ -1,16 +1,19 @@ syntax = "proto3"; -package sgenetwork.sge.mint; +package sge.mint.v1beta; +import "amino/amino.proto"; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/mint/params.proto"; -import "sgenetwork/sge/mint/minter.proto"; +import "sge/mint/v1beta/minter.proto"; +import "sge/mint/v1beta/params.proto"; option go_package = "github.com/sge-network/sge/x/mint/types"; // GenesisState defines the mint module's genesis state. message GenesisState { // minter is a space for holding current inflation information. - Minter minter = 1 [ (gogoproto.nullable) = false ]; + Minter minter = 1 + [ (gogoproto.nullable) = false, (amino.dont_omitempty) = true ]; // params contains the mint module parameters. - Params params = 2 [ (gogoproto.nullable) = false ]; + Params params = 2 + [ (gogoproto.nullable) = false, (amino.dont_omitempty) = true ]; } diff --git a/proto/sgenetwork/sge/mint/minter.proto b/proto/sge/mint/v1beta/minter.proto similarity index 82% rename from proto/sgenetwork/sge/mint/minter.proto rename to proto/sge/mint/v1beta/minter.proto index 4ca28787..ef9c79e5 100644 --- a/proto/sgenetwork/sge/mint/minter.proto +++ b/proto/sge/mint/v1beta/minter.proto @@ -1,14 +1,16 @@ syntax = "proto3"; -package sgenetwork.sge.mint; - -option go_package = "github.com/sge-network/sge/x/mint/types"; +package sge.mint.v1beta; +import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; +option go_package = "github.com/sge-network/sge/x/mint/types"; + // Minter represents the minting state. message Minter { // inflation is the current annual inflation rate. string inflation = 1 [ + (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false ]; @@ -16,6 +18,7 @@ message Minter { int32 phase_step = 2; // phase_provisions is the current phase expected provisions. string phase_provisions = 3 [ + (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.moretags) = "yaml:\"phase_provisions\"", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false @@ -23,6 +26,7 @@ message Minter { // truncated_tokens holds current truncated tokens because of Dec to Int // conversion in the minting. string truncated_tokens = 4 [ + (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false ]; diff --git a/proto/sgenetwork/sge/mint/params.proto b/proto/sge/mint/v1beta/params.proto similarity index 89% rename from proto/sgenetwork/sge/mint/params.proto rename to proto/sge/mint/v1beta/params.proto index 5fa68fa4..20f86294 100644 --- a/proto/sgenetwork/sge/mint/params.proto +++ b/proto/sge/mint/v1beta/params.proto @@ -1,8 +1,8 @@ syntax = "proto3"; -package sgenetwork.sge.mint; +package sge.mint.v1beta; import "gogoproto/gogo.proto"; -import "sgenetwork/sge/mint/phase.proto"; +import "sge/mint/v1beta/phase.proto"; option go_package = "github.com/sge-network/sge/x/mint/types"; @@ -13,7 +13,7 @@ message Params { // mint_denom is the type of coin to mint. string mint_denom = 1; // blocks_per_year is expected blocks per year. - int64 blocks_per_year = 2 + uint64 blocks_per_year = 2 [ (gogoproto.moretags) = "yaml:\"blocks_per_year\"" ]; // phases contains phases of inflation. diff --git a/proto/sgenetwork/sge/mint/phase.proto b/proto/sge/mint/v1beta/phase.proto similarity index 82% rename from proto/sgenetwork/sge/mint/phase.proto rename to proto/sge/mint/v1beta/phase.proto index 999f6ee4..b8f939eb 100644 --- a/proto/sgenetwork/sge/mint/phase.proto +++ b/proto/sge/mint/v1beta/phase.proto @@ -1,6 +1,7 @@ syntax = "proto3"; -package sgenetwork.sge.mint; +package sge.mint.v1beta; +import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; option go_package = "github.com/sge-network/sge/x/mint/types"; @@ -11,12 +12,14 @@ message Phase { // inflation is the current phase inflation rate. string inflation = 1 [ + (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.moretags) = "yaml:\"inflation\"", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false ]; // year_coefficient is the proportion of a complete year. string year_coefficient = 2 [ + (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.moretags) = "yaml:\"year_coefficient\"", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", (gogoproto.nullable) = false diff --git a/proto/sgenetwork/sge/mint/query.proto b/proto/sge/mint/v1beta/query.proto similarity index 88% rename from proto/sgenetwork/sge/mint/query.proto rename to proto/sge/mint/v1beta/query.proto index 4d4651bf..2993961b 100644 --- a/proto/sgenetwork/sge/mint/query.proto +++ b/proto/sge/mint/v1beta/query.proto @@ -1,9 +1,11 @@ syntax = "proto3"; -package sgenetwork.sge.mint; +package sge.mint.v1beta; +import "amino/amino.proto"; +import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "sgenetwork/sge/mint/params.proto"; +import "sge/mint/v1beta/params.proto"; option go_package = "github.com/sge-network/sge/x/mint/types"; @@ -45,7 +47,8 @@ message QueryParamsRequest {} // Query/Params RPC method. message QueryParamsResponse { // params contains all of the parameters of this module. - Params params = 1 [ (gogoproto.nullable) = false ]; + Params params = 1 + [ (gogoproto.nullable) = false, (amino.dont_omitempty) = true ]; } // QueryInflationRequest is the request type for the Query/Inflation RPC method. @@ -58,8 +61,10 @@ message QueryInflationRequest {} message QueryInflationResponse { // inflation is the current minting inflation value. bytes inflation = 1 [ + (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", - (gogoproto.nullable) = false + (gogoproto.nullable) = false, + (amino.dont_omitempty) = true ]; } @@ -84,8 +89,10 @@ message QueryPhaseProvisionsRequest {} message QueryPhaseProvisionsResponse { // phase_provisions is the current minting phase provisions value. bytes phase_provisions = 1 [ + (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", - (gogoproto.nullable) = false + (gogoproto.nullable) = false, + (amino.dont_omitempty) = true ]; } diff --git a/proto/sgenetwork/sge/mint/tx.proto b/proto/sge/mint/v1beta/tx.proto similarity index 94% rename from proto/sgenetwork/sge/mint/tx.proto rename to proto/sge/mint/v1beta/tx.proto index 1b118f07..c896eaf3 100644 --- a/proto/sgenetwork/sge/mint/tx.proto +++ b/proto/sge/mint/v1beta/tx.proto @@ -1,13 +1,13 @@ syntax = "proto3"; -package sgenetwork.sge.mint; +package sge.mint.v1beta; -option go_package = "github.com/sge-network/sge/x/mint/types"; - -import "cosmos/msg/v1/msg.proto"; import "amino/amino.proto"; -import "gogoproto/gogo.proto"; +import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; -import "sgenetwork/sge/mint/params.proto"; +import "gogoproto/gogo.proto"; +import "sge/mint/v1beta/params.proto"; + +option go_package = "github.com/sge-network/sge/x/mint/types"; // Msg defines the x/mint Msg service. service Msg { From 3807de06cd68c83509ec0e8ed448da572ef5e132 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Mon, 10 Feb 2025 16:32:18 +0300 Subject: [PATCH 06/16] refactor: move v1 logic to legacy --- tests/e2e/bet/cli_test.go | 16 - tests/e2e/bet/grpc.go | 105 -- tests/e2e/bet/suite.go | 459 -------- tests/e2e/house/cli_test.go | 16 - tests/e2e/house/grpc.go | 103 -- tests/e2e/house/suite.go | 1038 ----------------- tests/e2e/market/cli_test.go | 16 - tests/e2e/market/grpc.go | 47 - tests/e2e/market/suite.go | 212 ---- tests/e2e/reward/cli_test.go | 16 - tests/e2e/reward/grpc.go | 1 - tests/e2e/reward/suite.go | 279 ----- tests/e2e/sdk/account.go | 23 - tests/e2e/sdk/auth.go | 40 - tests/e2e/sdk/balance.go | 54 - tests/e2e/sdk/consts.go | 5 - testutil/network/network.go | 222 ---- testutil/nullify/nullify.go | 59 - testutil/sample/sample.go | 15 +- testutil/simapp/params.go | 46 - testutil/simapp/simapp.go | 405 ------- testutil/simapp/simapp_test.go | 13 - testutil/simapp/test_helpers.go | 131 --- tools/tools.go | 7 +- types/{ => legacy}/kyc.go | 2 +- types/{ => legacy}/kyc.pb.go | 47 +- utils/authorization.go | 9 +- utils/encoding.go | 7 - utils/fund.go | 8 +- utils/str.go | 10 - x/bet/client/cli/query_bet_test.go | 396 ------- x/bet/client/cli/query_test.go | 50 - x/bet/client/cli/tx_bet_test.go | 86 -- x/bet/client/cli/tx_test.go | 45 - x/bet/genesis_test.go | 67 -- x/bet/handler.go | 34 - x/bet/keeper/bet_test.go | 106 -- x/bet/keeper/grpc_query_bet_test.go | 369 ------ x/bet/keeper/keeper_test.go | 196 ---- x/bet/keeper/msg_server_bet_test.go | 195 ---- x/bet/keeper/msg_server_test.go | 19 - x/bet/keeper/params_test.go | 18 - x/bet/keeper/settle_test.go | 320 ----- x/bet/keeper/wager_test.go | 237 ---- x/bet/simulation/decoder_test.go | 93 -- x/bet/simulation/genesis_test.go | 77 -- x/bet/simulation/params_test.go | 37 - x/bet/simulation/proposals_test.go | 50 - x/bet/types/odds_type.pb.go | 83 -- x/house/client/cli/query_deposit_test.go | 221 ---- x/house/client/cli/query_params_test.go | 58 - x/house/client/cli/query_test.go | 49 - x/house/client/cli/query_withdrawal_test.go | 84 -- x/house/client/cli/tx_deposit_test.go | 86 -- x/house/client/cli/tx_test.go | 44 - x/house/client/cli/tx_withdraw_test.go | 93 -- x/house/handler.go | 37 - x/house/keeper/deposit_test.go | 78 -- x/house/keeper/grpc_query_deposit_test.go | 129 -- x/house/keeper/grpc_query_params_test.go | 32 - x/house/keeper/grpc_query_withdrawal_test.go | 134 --- x/house/keeper/keeper_test.go | 39 - x/house/keeper/msg_server_deposit_test.go | 187 --- x/house/keeper/msg_server_test.go | 19 - x/house/keeper/msg_server_withdraw_test.go | 172 --- x/house/keeper/params_test.go | 18 - x/house/keeper/withdrawal_test.go | 48 - x/house/simulation/decoder_test.go | 67 -- x/house/simulation/genesis_test.go | 77 -- x/house/simulation/params_test.go | 36 - x/house/simulation/proposals_test.go | 47 - x/house/types/deposit_authorizaton_test.go | 57 - x/house/types/genesis_test.go | 96 -- x/house/types/message_deposit_test.go | 90 -- x/house/types/message_withdraw_test.go | 116 -- x/house/types/ticket_test.go | 137 --- x/house/types/withdraw_authorizaton_test.go | 57 - x/{ => legacy}/bet/abci.go | 2 +- x/{ => legacy}/bet/client/cli/query.go | 2 +- x/{ => legacy}/bet/client/cli/query_bet.go | 2 +- x/{ => legacy}/bet/client/cli/query_params.go | 2 +- x/{ => legacy}/bet/client/cli/tx.go | 2 +- x/{ => legacy}/bet/client/cli/tx_bet.go | 2 +- x/{ => legacy}/bet/genesis.go | 4 +- x/{ => legacy}/bet/keeper/bet.go | 17 +- .../bet}/keeper/grpc_query.go | 2 +- x/{ => legacy}/bet/keeper/grpc_query_bet.go | 4 +- .../bet}/keeper/grpc_query_params.go | 2 +- x/{ => legacy}/bet/keeper/keeper.go | 6 +- x/{market => legacy/bet}/keeper/msg_server.go | 2 +- x/{ => legacy}/bet/keeper/msg_server_bet.go | 2 +- .../bet}/keeper/msg_server_params.go | 2 +- x/{ => legacy}/bet/keeper/params.go | 2 +- x/{ => legacy}/bet/keeper/settle.go | 7 +- x/{ => legacy}/bet/keeper/stats.go | 2 +- x/{ => legacy}/bet/keeper/view.go | 4 +- x/{ => legacy}/bet/keeper/wager.go | 4 +- x/{ => legacy}/bet/module.go | 23 +- x/{ => legacy}/bet/module_simulation.go | 9 +- x/{ => legacy}/bet/simulation/bet.go | 9 +- x/{ => legacy}/bet/simulation/decoder.go | 2 +- x/{ => legacy}/bet/simulation/errors.go | 0 x/{ => legacy}/bet/simulation/genesis.go | 10 +- x/{ => legacy}/bet/simulation/params.go | 2 +- x/{ => legacy}/bet/simulation/proposals.go | 2 +- x/{ => legacy}/bet/simulation/simap.go | 0 x/{ => legacy}/bet/types/bet.go | 2 +- x/{ => legacy}/bet/types/bet.pb.go | 178 +-- x/{ => legacy}/bet/types/bet_odds.pb.go | 62 +- x/{ => legacy}/bet/types/bet_test.go | 4 +- x/{ => legacy}/bet/types/codec.go | 0 x/{ => legacy}/bet/types/constraints.pb.go | 42 +- x/{ => legacy}/bet/types/errors.go | 0 x/{ => legacy}/bet/types/events.go | 0 x/{ => legacy}/bet/types/expected_keepers.go | 7 +- x/{ => legacy}/bet/types/funder.go | 0 x/{ => legacy}/bet/types/genesis.go | 0 x/{ => legacy}/bet/types/genesis.pb.go | 59 +- x/{ => legacy}/bet/types/genesis_test.go | 2 +- x/{ => legacy}/bet/types/keys.go | 0 x/{ => legacy}/bet/types/messages_bet.go | 0 x/{ => legacy}/bet/types/messages_bet_test.go | 2 +- x/{ => legacy}/bet/types/messages_params.go | 0 x/{ => legacy}/bet/types/odds_type.go | 0 x/legacy/bet/types/odds_type.pb.go | 84 ++ x/{ => legacy}/bet/types/params.go | 0 x/{ => legacy}/bet/types/params.pb.go | 53 +- x/{ => legacy}/bet/types/payout.go | 0 x/{ => legacy}/bet/types/payout_test.go | 2 +- x/{ => legacy}/bet/types/query.pb.go | 222 ++-- x/{ => legacy}/bet/types/query.pb.gw.go | 2 +- x/{ => legacy}/bet/types/stats.pb.go | 33 +- x/{ => legacy}/bet/types/ticket.go | 0 x/{ => legacy}/bet/types/ticket.pb.go | 67 +- x/{ => legacy}/bet/types/ticket_test.go | 4 +- x/{ => legacy}/bet/types/tx.pb.go | 96 +- x/{ => legacy}/bet/types/wager.go | 0 x/{ => legacy}/bet/types/wager.pb.go | 45 +- x/{ => legacy}/bet/types/wager_test.go | 2 +- x/{ => legacy}/house/client/cli/query.go | 2 +- .../house/client/cli/query_deposit.go | 2 +- .../house}/client/cli/query_params.go | 2 +- .../house/client/cli/query_withdrawal.go | 2 +- x/{ => legacy}/house/client/cli/tx.go | 2 +- x/{ => legacy}/house/client/cli/tx_deposit.go | 2 +- .../house/client/cli/tx_withdraw.go | 2 +- x/{ => legacy}/house/genesis.go | 8 +- x/{ => legacy}/house/keeper/deposit.go | 5 +- x/{bet => legacy/house}/keeper/export_test.go | 0 x/{bet => legacy/house}/keeper/grpc_query.go | 2 +- .../house/keeper/grpc_query_deposit.go | 4 +- .../house/keeper/grpc_query_params.go | 2 +- .../house/keeper/grpc_query_withdrawal.go | 4 +- x/{ => legacy}/house/keeper/keeper.go | 4 +- x/{ => legacy}/house/keeper/msg_server.go | 6 +- .../house/keeper/msg_server_deposit.go | 4 +- .../house/keeper/msg_server_params.go | 2 +- .../house/keeper/msg_server_withdraw.go | 4 +- x/{ => legacy}/house/keeper/params.go | 2 +- x/{ => legacy}/house/keeper/view.go | 4 +- x/{ => legacy}/house/keeper/withdrawal.go | 5 +- x/{ => legacy}/house/module.go | 18 +- x/{ => legacy}/house/module_simulation.go | 7 +- x/{ => legacy}/house/simulation/decoder.go | 2 +- x/{ => legacy}/house/simulation/errors.go | 0 x/{ => legacy}/house/simulation/genesis.go | 6 +- x/{ => legacy}/house/simulation/params.go | 2 +- x/{ => legacy}/house/simulation/proposals.go | 2 +- x/{ => legacy}/house/simulation/simap.go | 0 x/{ => legacy}/house/types/authz.pb.go | 51 +- x/{ => legacy}/house/types/codec.go | 0 x/{ => legacy}/house/types/consts.go | 0 x/{ => legacy}/house/types/deposit.go | 0 x/{ => legacy}/house/types/deposit.pb.go | 72 +- .../house/types/deposit_authorizaton.go | 4 +- x/{ => legacy}/house/types/errors.go | 0 x/{ => legacy}/house/types/events.go | 0 .../house/types/expected_keepers.go | 6 +- x/{ => legacy}/house/types/funder.go | 0 x/{ => legacy}/house/types/genesis.go | 0 x/{ => legacy}/house/types/genesis.pb.go | 49 +- x/{ => legacy}/house/types/keys.go | 0 x/{ => legacy}/house/types/message_deposit.go | 0 .../house/types/message_withdraw.go | 0 x/{ => legacy}/house/types/messages_params.go | 0 x/{ => legacy}/house/types/params.go | 0 x/{ => legacy}/house/types/params.pb.go | 57 +- x/{ => legacy}/house/types/query.pb.go | 180 +-- x/{ => legacy}/house/types/query.pb.gw.go | 2 +- x/{ => legacy}/house/types/ticket.go | 0 x/{ => legacy}/house/types/ticket.pb.go | 73 +- x/{ => legacy}/house/types/tx.pb.go | 149 +-- x/{ => legacy}/house/types/withdraw.pb.go | 84 +- .../house/types/withdraw_authorizaton.go | 4 +- x/{ => legacy}/house/types/withdrawal.go | 0 x/{ => legacy}/market/client/cli/query.go | 2 +- .../market/client/cli/query_market.go | 2 +- .../market/client/cli/query_params.go | 2 +- x/{ => legacy}/market/client/cli/tx.go | 2 +- x/{ => legacy}/market/client/cli/tx_market.go | 2 +- .../market/client/cli/tx_resolve_market.go | 2 +- x/{ => legacy}/market/genesis.go | 4 +- .../market}/keeper/export_test.go | 0 .../market}/keeper/grpc_query.go | 2 +- .../market/keeper/grpc_query_market.go | 2 +- .../market/keeper/grpc_query_params.go | 2 +- x/{ => legacy}/market/keeper/keeper.go | 7 +- x/{ => legacy}/market/keeper/market.go | 5 +- .../market}/keeper/msg_server.go | 2 +- .../market/keeper/msg_server_market.go | 2 +- .../keeper/msg_server_market_resolve.go | 2 +- .../market/keeper/msg_server_params.go | 2 +- x/{ovm => legacy/market}/keeper/params.go | 2 +- x/{ => legacy}/market/keeper/stats.go | 2 +- x/{ => legacy}/market/keeper/view.go | 4 +- x/{ => legacy}/market/module.go | 20 +- x/{ => legacy}/market/module_simulation.go | 12 +- x/{ => legacy}/market/simulation/decoder.go | 2 +- x/{ => legacy}/market/simulation/errors.go | 0 x/{ => legacy}/market/simulation/genesis.go | 2 +- x/{ => legacy}/market/simulation/market.go | 4 +- .../market/simulation/market_update.go | 4 +- x/{ => legacy}/market/simulation/params.go | 0 x/{ => legacy}/market/simulation/proposals.go | 2 +- x/{ => legacy}/market/simulation/simap.go | 0 x/{ => legacy}/market/types/codec.go | 0 x/{ => legacy}/market/types/consts.go | 0 x/{ => legacy}/market/types/errors.go | 0 x/{ => legacy}/market/types/events.go | 0 .../market/types/expected_keepers.go | 5 +- x/{ => legacy}/market/types/genesis.go | 0 x/{ => legacy}/market/types/genesis.pb.go | 47 +- x/{ => legacy}/market/types/genesis_test.go | 2 +- x/{ => legacy}/market/types/keys.go | 0 x/{ => legacy}/market/types/market.go | 0 x/{ => legacy}/market/types/market.pb.go | 93 +- x/{ => legacy}/market/types/message_market.go | 0 .../market/types/message_market_resolve.go | 0 .../market/types/messages_params.go | 0 x/{ => legacy}/market/types/odds.pb.go | 40 +- x/{ => legacy}/market/types/params.go | 0 x/{ovm => legacy/market}/types/params.pb.go | 36 +- x/{ => legacy}/market/types/query.pb.go | 136 +-- x/{ => legacy}/market/types/query.pb.gw.go | 2 +- x/{ => legacy}/market/types/stats.pb.go | 37 +- x/{ => legacy}/market/types/ticket.go | 0 x/{ => legacy}/market/types/ticket.pb.go | 84 +- x/{ => legacy}/market/types/tx.pb.go | 136 +-- x/{ => legacy}/orderbook/abci.go | 2 +- x/{ => legacy}/orderbook/client/cli/query.go | 2 +- .../orderbook/client/cli/query_bet.go | 2 +- .../client/cli/query_exposure_odds.go | 2 +- .../cli/query_exposure_participation.go | 2 +- .../orderbook/client/cli/query_orderbook.go | 2 +- .../orderbook}/client/cli/query_params.go | 2 +- .../client/cli/query_participation.go | 2 +- x/{ => legacy}/orderbook/genesis.go | 4 +- x/{ => legacy}/orderbook/keeper/bet_settle.go | 4 +- x/{ => legacy}/orderbook/keeper/bet_wager.go | 4 +- .../orderbook/keeper/export_test.go | 0 .../orderbook/keeper/exposure_odds.go | 7 +- .../keeper/exposure_participation.go | 13 +- x/{ => legacy}/orderbook/keeper/fund.go | 2 +- x/legacy/orderbook/keeper/grpc_query.go | 7 + .../keeper/grpc_query_exposure_odds.go | 4 +- .../grpc_query_exposure_participation.go | 4 +- .../orderbook/keeper/grpc_query_orderbook.go | 4 +- .../orderbook}/keeper/grpc_query_params.go | 2 +- .../keeper/grpc_query_participation.go | 4 +- .../keeper/grpc_query_participation_bet.go | 4 +- x/{ => legacy}/orderbook/keeper/keeper.go | 6 +- x/{ => legacy}/orderbook/keeper/market.go | 2 +- x/legacy/orderbook/keeper/msg_server.go | 17 + .../orderbook/keeper/msg_server_params.go | 27 + x/{ => legacy}/orderbook/keeper/orderbook.go | 5 +- .../orderbook/keeper/orderbook_settle.go | 6 +- x/{ => legacy}/orderbook/keeper/params.go | 2 +- .../orderbook/keeper/participation.go | 11 +- .../orderbook/keeper/participation_bet.go | 5 +- x/{ => legacy}/orderbook/keeper/stats.go | 2 +- x/{ => legacy}/orderbook/keeper/view.go | 4 +- x/{ => legacy}/orderbook/module.go | 23 +- x/{ => legacy}/orderbook/module_simulation.go | 9 +- .../orderbook/simulation/decoder.go | 2 +- x/{ => legacy}/orderbook/simulation/errors.go | 0 .../orderbook/simulation/genesis.go | 8 +- x/{ => legacy}/orderbook/simulation/params.go | 2 +- .../orderbook/simulation/proposals.go | 2 +- .../orderbook}/simulation/simap.go | 0 x/{ => legacy}/orderbook/types/codec.go | 0 x/{ => legacy}/orderbook/types/consts.go | 0 x/{ => legacy}/orderbook/types/errors.go | 0 x/{ => legacy}/orderbook/types/events.go | 0 .../orderbook/types/expected_keepers.go | 22 +- x/{ => legacy}/orderbook/types/exposure.go | 0 x/{ => legacy}/orderbook/types/exposure.pb.go | 79 +- x/{ => legacy}/orderbook/types/funder.go | 0 x/{ => legacy}/orderbook/types/genesis.go | 0 x/{ => legacy}/orderbook/types/genesis.pb.go | 73 +- x/{ => legacy}/orderbook/types/hooks.go | 0 x/{ => legacy}/orderbook/types/keys.go | 0 .../orderbook/types/messages_params.go | 0 x/{ => legacy}/orderbook/types/orderbook.go | 0 .../orderbook/types/orderbook.pb.go | 69 +- x/{ => legacy}/orderbook/types/params.go | 0 x/{ => legacy}/orderbook/types/params.pb.go | 54 +- .../orderbook/types/participation.go | 7 +- .../orderbook/types/participation.pb.go | 128 +- .../orderbook/types/participation_bet.go | 0 x/{ => legacy}/orderbook/types/query.pb.go | 318 ++--- x/{ => legacy}/orderbook/types/query.pb.gw.go | 2 +- x/{ => legacy}/orderbook/types/stats.pb.go | 37 +- x/{ => legacy}/orderbook/types/tx.pb.go | 80 +- x/{ => legacy}/ovm/abci.go | 2 +- x/{ => legacy}/ovm/client/cli/query.go | 2 +- .../ovm}/client/cli/query_params.go | 2 +- .../ovm/client/cli/query_proposal.go | 2 +- .../ovm/client/cli/query_pub_keys.go | 2 +- x/{ => legacy}/ovm/client/cli/tx.go | 2 +- .../ovm/client/cli/tx_pubkeys_proposal.go | 2 +- .../ovm/client/cli/tx_pubkeys_vote.go | 2 +- x/{ => legacy}/ovm/genesis.go | 4 +- .../ovm}/keeper/export_test.go | 0 x/{market => legacy/ovm}/keeper/grpc_query.go | 2 +- .../ovm/keeper/grpc_query_params.go | 2 +- .../ovm/keeper/grpc_query_pubkeys.go | 2 +- .../ovm/keeper/grpc_query_pubkeys_proposal.go | 4 +- x/{ => legacy}/ovm/keeper/keeper.go | 6 +- x/{ => legacy}/ovm/keeper/key_vault.go | 2 +- x/{bet => legacy/ovm}/keeper/msg_server.go | 2 +- .../ovm}/keeper/msg_server_params.go | 2 +- .../ovm/keeper/msg_server_pubkeys_proposal.go | 2 +- x/{ => legacy}/ovm/keeper/msg_server_vote.go | 2 +- x/{market => legacy/ovm}/keeper/params.go | 2 +- x/{ => legacy}/ovm/keeper/proposal.go | 7 +- x/{ => legacy}/ovm/keeper/stats.go | 2 +- x/{ => legacy}/ovm/keeper/ticket.go | 2 +- x/{ => legacy}/ovm/keeper/view.go | 4 +- x/{ => legacy}/ovm/module.go | 23 +- x/{ => legacy}/ovm/module_simulation.go | 8 +- x/{ => legacy}/ovm/simulation/decoder.go | 2 +- x/{ => legacy}/ovm/simulation/errors.go | 0 x/{ => legacy}/ovm/simulation/genesis.go | 2 +- x/{ => legacy}/ovm/simulation/proposal.go | 4 +- .../ovm}/simulation/proposals.go | 2 +- .../ovm}/simulation/simap.go | 0 x/{ => legacy}/ovm/types/codec.go | 0 x/{ => legacy}/ovm/types/consts.go | 0 x/{ => legacy}/ovm/types/errors.go | 0 x/{ => legacy}/ovm/types/events.go | 0 x/{ => legacy}/ovm/types/expected_keepers.go | 8 +- x/{ => legacy}/ovm/types/export_test.go | 0 x/{ => legacy}/ovm/types/genesis.go | 0 x/{ => legacy}/ovm/types/genesis.pb.go | 58 +- x/{ => legacy}/ovm/types/key_vault.go | 0 x/{ => legacy}/ovm/types/key_vault.pb.go | 35 +- x/{ => legacy}/ovm/types/keys.go | 0 .../ovm/types/message_pubkeys_proposal.go | 0 .../ovm/types/message_pubkeys_vote.go | 0 x/{ => legacy}/ovm/types/messages_params.go | 0 x/{ => legacy}/ovm/types/params.go | 0 x/{market => legacy/ovm}/types/params.pb.go | 34 +- x/{ => legacy}/ovm/types/proposal.go | 0 x/{ => legacy}/ovm/types/proposal.pb.go | 105 +- x/{ => legacy}/ovm/types/query.pb.go | 149 +-- x/{ => legacy}/ovm/types/query.pb.gw.go | 2 +- x/{ => legacy}/ovm/types/stats.pb.go | 37 +- x/{ => legacy}/ovm/types/ticket.go | 0 x/{ => legacy}/ovm/types/ticket.pb.go | 56 +- x/{ => legacy}/ovm/types/ticket_jwt.go | 0 x/{ => legacy}/ovm/types/tx.pb.go | 118 +- x/{ => legacy}/ovm/types/vote.go | 0 x/{ => legacy}/ovm/types/vote.pb.go | 51 +- x/{ => legacy}/reward/client/cli/query.go | 2 +- .../reward/client/cli/query_campaign.go | 2 +- .../reward}/client/cli/query_params.go | 2 +- .../reward/client/cli/query_promoter.go | 2 +- .../reward/client/cli/query_reward.go | 2 +- x/{ => legacy}/reward/client/cli/tx.go | 2 +- .../reward/client/cli/tx_campaign.go | 2 +- .../reward/client/cli/tx_promoter.go | 2 +- x/{ => legacy}/reward/client/cli/tx_reward.go | 2 +- x/{ => legacy}/reward/genesis.go | 4 +- x/{ => legacy}/reward/keeper/campaign.go | 5 +- x/{ => legacy}/reward/keeper/distribution.go | 4 +- .../reward}/keeper/export_test.go | 0 x/{ => legacy}/reward/keeper/keeper.go | 9 +- x/{ovm => legacy/reward}/keeper/msg_server.go | 2 +- .../reward/keeper/msg_server_campaign.go | 12 +- x/legacy/reward/keeper/msg_server_params.go | 27 + .../reward/keeper/msg_server_promoter.go | 2 +- .../reward/keeper/msg_server_reward.go | 2 +- x/{ => legacy}/reward/keeper/params.go | 2 +- x/{ => legacy}/reward/keeper/promoter.go | 6 +- x/{ => legacy}/reward/keeper/query.go | 2 +- .../reward/keeper/query_campaign.go | 4 +- .../reward}/keeper/query_params.go | 2 +- .../reward/keeper/query_promoter.go | 4 +- x/{ => legacy}/reward/keeper/query_reward.go | 4 +- x/{ => legacy}/reward/keeper/reward.go | 14 +- x/{ => legacy}/reward/keeper/view.go | 4 +- x/{ => legacy}/reward/module.go | 20 +- x/{ => legacy}/reward/module_simulation.go | 13 +- x/{ => legacy}/reward/simulation/campaign.go | 15 +- x/{ => legacy}/reward/simulation/helpers.go | 0 .../reward}/simulation/proposals.go | 2 +- x/{ => legacy}/reward/types/authz.pb.go | 63 +- x/{ => legacy}/reward/types/campaign.go | 0 x/{ => legacy}/reward/types/campaign.pb.go | 109 +- .../reward/types/campaign_authorizaton.go | 8 +- x/{ => legacy}/reward/types/codec.go | 0 x/{ => legacy}/reward/types/consts.go | 0 x/{ => legacy}/reward/types/errors.go | 2 +- x/{ => legacy}/reward/types/events.go | 0 .../reward/types/expected_keepers.go | 23 +- x/{ => legacy}/reward/types/funder.go | 0 x/{ => legacy}/reward/types/genesis.go | 0 x/{ => legacy}/reward/types/genesis.pb.go | 61 +- x/{ => legacy}/reward/types/genesis_test.go | 2 +- x/{ => legacy}/reward/types/key_campaign.go | 0 x/{ => legacy}/reward/types/key_promoter.go | 0 x/{ => legacy}/reward/types/key_reward.go | 0 x/{ => legacy}/reward/types/keys.go | 0 .../reward/types/messages_campaign.go | 0 .../reward/types/messages_params.go | 0 .../reward/types/messages_promoter.go | 0 .../reward/types/messages_reward.go | 0 x/{ => legacy}/reward/types/params.go | 0 x/{ => legacy}/reward/types/params.pb.go | 33 +- x/{ => legacy}/reward/types/pool.go | 0 x/{ => legacy}/reward/types/pool_test.go | 2 +- x/{ => legacy}/reward/types/promoter.go | 0 x/{ => legacy}/reward/types/promoter.pb.go | 82 +- x/{ => legacy}/reward/types/query.pb.go | 274 ++--- x/{ => legacy}/reward/types/query.pb.gw.go | 2 +- x/{ => legacy}/reward/types/reward.go | 6 +- x/{ => legacy}/reward/types/reward.pb.go | 163 ++- .../reward/types/reward_bet_bonus.go | 6 +- x/{ => legacy}/reward/types/reward_signup.go | 2 +- .../reward/types/reward_signup_affiliatee.go | 2 +- .../reward/types/reward_signup_affiliator.go | 2 +- .../reward/types/reward_signup_referee.go | 2 +- .../reward/types/reward_signup_referrer.go | 2 +- x/{ => legacy}/reward/types/ticket.go | 12 +- x/{ => legacy}/reward/types/ticket.pb.go | 168 +-- x/{ => legacy}/reward/types/ticket_test.go | 2 +- x/{ => legacy}/reward/types/tx.pb.go | 198 ++-- x/{ => legacy}/subaccount/client/cli/query.go | 2 +- .../subaccount}/client/cli/query_params.go | 2 +- x/{ => legacy}/subaccount/client/cli/tx.go | 4 +- x/{ => legacy}/subaccount/genesis.go | 4 +- x/{ => legacy}/subaccount/keeper/balance.go | 4 +- x/{ => legacy}/subaccount/keeper/hooks.go | 2 +- x/{ => legacy}/subaccount/keeper/keeper.go | 6 +- .../subaccount/keeper/msg_server.go | 2 +- .../subaccount/keeper/msg_server_balance.go | 2 +- .../subaccount/keeper/msg_server_bet.go | 6 +- .../subaccount/keeper/msg_server_house.go | 4 +- .../subaccount/keeper/msg_server_params.go | 27 + .../keeper/msg_server_subaccount.go | 2 +- x/{ => legacy}/subaccount/keeper/params.go | 2 +- .../subaccount}/keeper/query_params.go | 2 +- .../subaccount/keeper/query_server.go | 2 +- .../subaccount/keeper/subaccount.go | 5 +- x/{ => legacy}/subaccount/module.go | 20 +- .../subaccount/simulation/decoder.go | 2 +- .../subaccount/simulation/errors.go | 0 .../subaccount/simulation/genesis.go | 6 +- .../subaccount/simulation/proposals.go | 2 +- .../subaccount}/simulation/simap.go | 0 x/{ => legacy}/subaccount/types/accsummary.go | 0 x/{ => legacy}/subaccount/types/address.go | 0 x/{ => legacy}/subaccount/types/balance.pb.go | 77 +- .../subaccount/types/balance_test.go | 2 +- x/{ => legacy}/subaccount/types/codec.go | 0 x/{ => legacy}/subaccount/types/errors.go | 0 x/{ => legacy}/subaccount/types/events.go | 0 .../subaccount/types/expected_keepers.go | 13 +- x/{ => legacy}/subaccount/types/genesis.go | 0 x/{ => legacy}/subaccount/types/genesis.pb.go | 71 +- x/{ => legacy}/subaccount/types/keys.go | 0 .../subaccount/types/messages_balance.go | 0 .../subaccount/types/messages_bet.go | 2 +- .../subaccount/types/messages_house.go | 0 .../subaccount/types/messages_params.go | 0 .../subaccount/types/messages_subaccount.go | 0 x/{ => legacy}/subaccount/types/params.go | 0 x/{ => legacy}/subaccount/types/params.pb.go | 41 +- x/{ => legacy}/subaccount/types/query.pb.go | 104 +- .../subaccount/types/query.pb.gw.go | 2 +- x/{ => legacy}/subaccount/types/ticket.go | 0 x/{ => legacy}/subaccount/types/ticket.pb.go | 53 +- x/{ => legacy}/subaccount/types/tx.pb.go | 206 ++-- x/market/client/cli/query_market_test.go | 95 -- x/market/client/cli/query_params_test.go | 53 - x/market/client/cli/query_test.go | 48 - x/market/client/cli/tx_test.go | 45 - x/market/genesis_test.go | 39 - x/market/handler.go | 41 - x/market/keeper/grpc_query_market_test.go | 67 -- x/market/keeper/grpc_query_params_test.go | 33 - x/market/keeper/keeper_test.go | 33 - x/market/keeper/market_test.go | 117 -- .../keeper/msg_server_market_resolve_test.go | 205 ---- x/market/keeper/msg_server_market_test.go | 189 --- x/market/keeper/msg_server_test.go | 26 - x/market/keeper/params_test.go | 18 - x/market/simulation/decoder_test.go | 71 -- x/market/simulation/genesis_test.go | 74 -- x/market/simulation/params_test.go | 32 - x/market/simulation/proposals_test.go | 43 - x/market/types/message_market_resolve_test.go | 67 -- x/market/types/message_market_test.go | 121 -- x/market/types/ticket_test.go | 339 ------ x/mint/abci.go | 43 +- x/mint/autocli.go | 50 + x/mint/client/cli/query.go | 36 - x/mint/client/cli/query_minter.go | 127 -- x/mint/client/cli/query_minter_test.go | 175 --- x/mint/client/cli/query_params.go | 37 - x/mint/client/cli/query_params_test.go | 61 - x/mint/client/cli/query_test.go | 48 - x/mint/exported/exported.go | 18 + x/mint/genesis.go | 24 - x/mint/genesis_test.go | 28 - x/mint/keeper/genesis.go | 34 + x/mint/keeper/grpc_query.go | 68 +- x/mint/keeper/grpc_query_minter.go | 56 - x/mint/keeper/grpc_query_minter_test.go | 38 - x/mint/keeper/grpc_query_params.go | 26 - x/mint/keeper/grpc_query_params_test.go | 32 - x/mint/keeper/grpc_query_test.go | 87 ++ x/mint/keeper/keeper.go | 99 +- x/mint/keeper/keeper_test.go | 92 +- x/mint/keeper/migrator.go | 29 + x/mint/keeper/minter.go | 62 - x/mint/keeper/minter_test.go | 42 - x/mint/keeper/msg_server.go | 35 +- x/mint/keeper/msg_server_params.go | 28 - x/mint/keeper/msg_server_test.go | 67 ++ x/mint/keeper/params.go | 18 - x/mint/keeper/params_test.go | 18 - x/mint/migrations/v2/migrate.go | 37 + x/mint/migrations/v2/migrator_test.go | 51 + x/mint/module.go | 198 +++- x/mint/module_simulation.go | 47 - x/mint/module_test.go | 20 - x/mint/simulation/decoder.go | 27 - x/mint/simulation/decoder_test.go | 47 - x/mint/simulation/errors.go | 5 - x/mint/simulation/genesis.go | 5 +- x/mint/simulation/genesis_test.go | 4 +- x/mint/simulation/params.go | 30 - x/mint/simulation/params_test.go | 36 - x/mint/simulation/proposals.go | 49 + x/mint/simulation/proposals_test.go | 41 + x/mint/testutil/app_config.go | 24 + x/mint/testutil/expected_keepers_mocks.go | 197 ++++ x/mint/types/codec.go | 24 +- x/mint/types/expected_keepers.go | 15 +- x/mint/types/genesis.go | 15 +- x/mint/types/genesis.pb.go | 42 +- x/mint/types/genesis_test.go | 8 +- x/mint/types/keys.go | 17 +- x/mint/types/minter.pb.go | 54 +- x/mint/types/minter_test.go | 6 +- x/mint/types/msgs.go | 32 - x/mint/types/params.go | 36 +- x/mint/types/params.pb.go | 62 +- x/mint/types/params_legacy.go | 30 + x/mint/types/phase.pb.go | 49 +- x/mint/types/query.pb.go | 157 +-- x/mint/types/query.pb.gw.go | 2 +- x/mint/types/tx.pb.go | 75 +- x/orderbook/client/cli/query_bet_test.go | 135 --- .../client/cli/query_exposure_odds_test.go | 172 --- .../cli/query_exposure_participation_test.go | 251 ---- .../client/cli/query_orderbook_test.go | 170 --- x/orderbook/client/cli/query_params_test.go | 62 - .../client/cli/query_participation_test.go | 190 --- x/orderbook/client/cli/query_test.go | 49 - x/orderbook/handler.go | 32 - x/orderbook/keeper/bet_settle_test.go | 90 -- x/orderbook/keeper/bet_wager_test.go | 512 -------- x/orderbook/keeper/exposure_odds_test.go | 93 -- .../keeper/exposure_participation_test.go | 110 -- x/orderbook/keeper/fund_test.go | 105 -- .../keeper/grpc_query_exposure_odds_test.go | 128 -- .../grpc_query_exposure_participation_test.go | 188 --- .../keeper/grpc_query_orderbook_test.go | 124 -- x/orderbook/keeper/grpc_query_params_test.go | 32 - .../grpc_query_participation_bet_test.go | 74 -- .../keeper/grpc_query_participation_test.go | 128 -- x/orderbook/keeper/keeper_test.go | 32 - x/orderbook/keeper/orderbook_settle_test.go | 89 -- x/orderbook/keeper/orderbook_test.go | 90 -- x/orderbook/keeper/params_test.go | 18 - x/orderbook/keeper/participation_bet_test.go | 44 - x/orderbook/keeper/participation_test.go | 289 ----- x/orderbook/keeper/stats_test.go | 26 - x/orderbook/simulation/decoder_test.go | 129 -- x/orderbook/simulation/genesis_test.go | 78 -- x/orderbook/simulation/params_test.go | 40 - x/orderbook/simulation/proposals_test.go | 46 - x/orderbook/types/genesis_test.go | 143 --- x/ovm/client/cli/query_params_test.go | 53 - x/ovm/client/cli/query_proposal_test.go | 111 -- x/ovm/client/cli/query_pub_keys_test.go | 73 -- x/ovm/client/cli/query_test.go | 48 - x/ovm/client/cli/tx_pubkeys_proposal_test.go | 92 -- x/ovm/client/cli/tx_test.go | 48 - x/ovm/genesis_test.go | 32 - x/ovm/handler.go | 37 - x/ovm/keeper/grpc_query.go | 7 - x/ovm/keeper/grpc_query_params_test.go | 29 - .../grpc_query_pubkeys_proposal_test.go | 81 -- x/ovm/keeper/grpc_query_pubkeys_test.go | 27 - x/ovm/keeper/keeper_test.go | 31 - x/ovm/keeper/key_vault_test.go | 60 - x/ovm/keeper/msg_server_params.go | 27 - .../msg_server_pubkeys_proposal_test.go | 184 --- x/ovm/keeper/msg_server_test.go | 39 - x/ovm/keeper/msg_server_vote_test.go | 118 -- x/ovm/keeper/params_test.go | 18 - x/ovm/keeper/proposal_test.go | 225 ---- x/ovm/keeper/ticket_test.go | 152 --- x/ovm/simulation/decoder_test.go | 79 -- x/ovm/simulation/genesis_test.go | 74 -- x/ovm/simulation/proposals_test.go | 43 - x/ovm/types/genesis_test.go | 90 -- x/ovm/types/key_vault_test.go | 49 - x/ovm/types/message_pubkeys_proposal_test.go | 43 - x/ovm/types/message_pubkeys_vote_test.go | 46 - x/ovm/types/ticket_jwt_test.go | 166 --- x/reward/genesis_test.go | 99 -- x/reward/handler.go | 43 - x/reward/keeper/campaign_test.go | 79 -- x/reward/keeper/export_test.go | 5 - x/reward/keeper/keeper_test.go | 25 - x/reward/keeper/msg_server.go | 17 - x/reward/keeper/msg_server_campaign_test.go | 409 ------- x/reward/keeper/msg_server_params.go | 27 - x/reward/keeper/msg_server_promoter_test.go | 116 -- x/reward/keeper/msg_server_reward_test.go | 988 ---------------- x/reward/keeper/query_campaign_test.go | 126 -- x/reward/simulation/proposals_test.go | 43 - x/reward/types/campaign_authorizaton_test.go | 98 -- x/reward/types/messages_campaign_test.go | 136 --- x/reward/types/messages_promoter_test.go | 62 - x/reward/types/messages_reward_test.go | 74 -- x/subaccount/genesis_test.go | 62 - x/subaccount/handler.go | 50 - x/subaccount/keeper/balance_test.go | 49 - x/subaccount/keeper/export_test.go | 5 - x/subaccount/keeper/keeper_test.go | 20 - .../keeper/msg_server_balance_test.go | 291 ----- x/subaccount/keeper/msg_server_bet_test.go | 286 ----- x/subaccount/keeper/msg_server_house_test.go | 374 ------ x/subaccount/keeper/msg_server_params.go | 27 - .../keeper/msg_server_subaccount_test.go | 144 --- x/subaccount/keeper/msg_server_test.go | 18 - x/subaccount/keeper/params_test.go | 16 - x/subaccount/keeper/query_server_test.go | 73 -- x/subaccount/keeper/subaccount_test.go | 145 --- x/subaccount/simulation/decoder_test.go | 70 -- x/subaccount/simulation/genesis_test.go | 74 -- x/subaccount/simulation/proposals_test.go | 45 - x/subaccount/simulation/simap.go | 15 - x/subaccount/types/messages_balance_test.go | 77 -- .../types/messages_subaccount_test.go | 76 -- 670 files changed, 4892 insertions(+), 24565 deletions(-) delete mode 100644 tests/e2e/bet/cli_test.go delete mode 100644 tests/e2e/bet/grpc.go delete mode 100644 tests/e2e/bet/suite.go delete mode 100644 tests/e2e/house/cli_test.go delete mode 100644 tests/e2e/house/grpc.go delete mode 100644 tests/e2e/house/suite.go delete mode 100644 tests/e2e/market/cli_test.go delete mode 100644 tests/e2e/market/grpc.go delete mode 100644 tests/e2e/market/suite.go delete mode 100644 tests/e2e/reward/cli_test.go delete mode 100644 tests/e2e/reward/grpc.go delete mode 100644 tests/e2e/reward/suite.go delete mode 100644 tests/e2e/sdk/account.go delete mode 100644 tests/e2e/sdk/auth.go delete mode 100644 tests/e2e/sdk/balance.go delete mode 100644 tests/e2e/sdk/consts.go delete mode 100644 testutil/network/network.go delete mode 100644 testutil/nullify/nullify.go delete mode 100644 testutil/simapp/params.go delete mode 100644 testutil/simapp/simapp.go delete mode 100644 testutil/simapp/simapp_test.go delete mode 100644 testutil/simapp/test_helpers.go rename types/{ => legacy}/kyc.go (95%) rename types/{ => legacy}/kyc.pb.go (80%) delete mode 100644 utils/encoding.go delete mode 100644 x/bet/client/cli/query_bet_test.go delete mode 100644 x/bet/client/cli/query_test.go delete mode 100644 x/bet/client/cli/tx_bet_test.go delete mode 100644 x/bet/client/cli/tx_test.go delete mode 100644 x/bet/genesis_test.go delete mode 100644 x/bet/handler.go delete mode 100644 x/bet/keeper/bet_test.go delete mode 100644 x/bet/keeper/grpc_query_bet_test.go delete mode 100644 x/bet/keeper/keeper_test.go delete mode 100644 x/bet/keeper/msg_server_bet_test.go delete mode 100644 x/bet/keeper/msg_server_test.go delete mode 100644 x/bet/keeper/params_test.go delete mode 100644 x/bet/keeper/settle_test.go delete mode 100644 x/bet/keeper/wager_test.go delete mode 100644 x/bet/simulation/decoder_test.go delete mode 100644 x/bet/simulation/genesis_test.go delete mode 100644 x/bet/simulation/params_test.go delete mode 100644 x/bet/simulation/proposals_test.go delete mode 100644 x/bet/types/odds_type.pb.go delete mode 100644 x/house/client/cli/query_deposit_test.go delete mode 100644 x/house/client/cli/query_params_test.go delete mode 100644 x/house/client/cli/query_test.go delete mode 100644 x/house/client/cli/query_withdrawal_test.go delete mode 100644 x/house/client/cli/tx_deposit_test.go delete mode 100644 x/house/client/cli/tx_test.go delete mode 100644 x/house/client/cli/tx_withdraw_test.go delete mode 100644 x/house/handler.go delete mode 100644 x/house/keeper/deposit_test.go delete mode 100644 x/house/keeper/grpc_query_deposit_test.go delete mode 100644 x/house/keeper/grpc_query_params_test.go delete mode 100644 x/house/keeper/grpc_query_withdrawal_test.go delete mode 100644 x/house/keeper/keeper_test.go delete mode 100644 x/house/keeper/msg_server_deposit_test.go delete mode 100644 x/house/keeper/msg_server_test.go delete mode 100644 x/house/keeper/msg_server_withdraw_test.go delete mode 100644 x/house/keeper/params_test.go delete mode 100644 x/house/keeper/withdrawal_test.go delete mode 100644 x/house/simulation/decoder_test.go delete mode 100644 x/house/simulation/genesis_test.go delete mode 100644 x/house/simulation/params_test.go delete mode 100644 x/house/simulation/proposals_test.go delete mode 100644 x/house/types/deposit_authorizaton_test.go delete mode 100644 x/house/types/genesis_test.go delete mode 100644 x/house/types/message_deposit_test.go delete mode 100644 x/house/types/message_withdraw_test.go delete mode 100644 x/house/types/ticket_test.go delete mode 100644 x/house/types/withdraw_authorizaton_test.go rename x/{ => legacy}/bet/abci.go (86%) rename x/{ => legacy}/bet/client/cli/query.go (93%) rename x/{ => legacy}/bet/client/cli/query_bet.go (98%) rename x/{ => legacy}/bet/client/cli/query_params.go (93%) rename x/{ => legacy}/bet/client/cli/tx.go (91%) rename x/{ => legacy}/bet/client/cli/tx_bet.go (96%) rename x/{ => legacy}/bet/genesis.go (94%) rename x/{ => legacy}/bet/keeper/bet.go (90%) rename x/{orderbook => legacy/bet}/keeper/grpc_query.go (56%) rename x/{ => legacy}/bet/keeper/grpc_query_bet.go (98%) rename x/{orderbook => legacy/bet}/keeper/grpc_query_params.go (91%) rename x/{ => legacy}/bet/keeper/keeper.go (92%) rename x/{market => legacy/bet}/keeper/msg_server.go (85%) rename x/{ => legacy}/bet/keeper/msg_server_bet.go (91%) rename x/{orderbook => legacy/bet}/keeper/msg_server_params.go (93%) rename x/{ => legacy}/bet/keeper/params.go (92%) rename x/{ => legacy}/bet/keeper/settle.go (96%) rename x/{ => legacy}/bet/keeper/stats.go (92%) rename x/{ => legacy}/bet/keeper/view.go (93%) rename x/{ => legacy}/bet/keeper/wager.go (95%) rename x/{ => legacy}/bet/module.go (90%) rename x/{ => legacy}/bet/module_simulation.go (84%) rename x/{ => legacy}/bet/simulation/bet.go (85%) rename x/{ => legacy}/bet/simulation/decoder.go (97%) rename x/{ => legacy}/bet/simulation/errors.go (100%) rename x/{ => legacy}/bet/simulation/genesis.go (85%) rename x/{ => legacy}/bet/simulation/params.go (96%) rename x/{ => legacy}/bet/simulation/proposals.go (96%) rename x/{ => legacy}/bet/simulation/simap.go (100%) rename x/{ => legacy}/bet/types/bet.go (96%) rename x/{ => legacy}/bet/types/bet.pb.go (87%) rename x/{ => legacy}/bet/types/bet_odds.pb.go (85%) rename x/{ => legacy}/bet/types/bet_test.go (94%) rename x/{ => legacy}/bet/types/codec.go (100%) rename x/{ => legacy}/bet/types/constraints.pb.go (81%) rename x/{ => legacy}/bet/types/errors.go (100%) rename x/{ => legacy}/bet/types/events.go (100%) rename x/{ => legacy}/bet/types/expected_keepers.go (89%) rename x/{ => legacy}/bet/types/funder.go (100%) rename x/{ => legacy}/bet/types/genesis.go (100%) rename x/{ => legacy}/bet/types/genesis.pb.go (84%) rename x/{ => legacy}/bet/types/genesis_test.go (97%) rename x/{ => legacy}/bet/types/keys.go (100%) rename x/{ => legacy}/bet/types/messages_bet.go (100%) rename x/{ => legacy}/bet/types/messages_bet_test.go (97%) rename x/{ => legacy}/bet/types/messages_params.go (100%) rename x/{ => legacy}/bet/types/odds_type.go (100%) create mode 100644 x/legacy/bet/types/odds_type.pb.go rename x/{ => legacy}/bet/types/params.go (100%) rename x/{ => legacy}/bet/types/params.pb.go (78%) rename x/{ => legacy}/bet/types/payout.go (100%) rename x/{ => legacy}/bet/types/payout_test.go (97%) rename x/{ => legacy}/bet/types/query.pb.go (90%) rename x/{ => legacy}/bet/types/query.pb.gw.go (99%) rename x/{ => legacy}/bet/types/stats.pb.go (82%) rename x/{ => legacy}/bet/types/ticket.go (100%) rename x/{ => legacy}/bet/types/ticket.pb.go (81%) rename x/{ => legacy}/bet/types/ticket_test.go (96%) rename x/{ => legacy}/bet/types/tx.pb.go (85%) rename x/{ => legacy}/bet/types/wager.go (100%) rename x/{ => legacy}/bet/types/wager.pb.go (82%) rename x/{ => legacy}/bet/types/wager_test.go (97%) rename x/{ => legacy}/house/client/cli/query.go (92%) rename x/{ => legacy}/house/client/cli/query_deposit.go (98%) rename x/{orderbook => legacy/house}/client/cli/query_params.go (93%) rename x/{ => legacy}/house/client/cli/query_withdrawal.go (98%) rename x/{ => legacy}/house/client/cli/tx.go (91%) rename x/{ => legacy}/house/client/cli/tx_deposit.go (96%) rename x/{ => legacy}/house/client/cli/tx_withdraw.go (97%) rename x/{ => legacy}/house/genesis.go (74%) rename x/{ => legacy}/house/keeper/deposit.go (93%) rename x/{bet => legacy/house}/keeper/export_test.go (100%) rename x/{bet => legacy/house}/keeper/grpc_query.go (55%) rename x/{ => legacy}/house/keeper/grpc_query_deposit.go (95%) rename x/{ => legacy}/house/keeper/grpc_query_params.go (90%) rename x/{ => legacy}/house/keeper/grpc_query_withdrawal.go (95%) rename x/{ => legacy}/house/keeper/keeper.go (93%) rename x/{ => legacy}/house/keeper/msg_server.go (63%) rename x/{ => legacy}/house/keeper/msg_server_deposit.go (94%) rename x/{ => legacy}/house/keeper/msg_server_params.go (92%) rename x/{ => legacy}/house/keeper/msg_server_withdraw.go (96%) rename x/{ => legacy}/house/keeper/params.go (95%) rename x/{ => legacy}/house/keeper/view.go (85%) rename x/{ => legacy}/house/keeper/withdrawal.go (93%) rename x/{ => legacy}/house/module.go (89%) rename x/{ => legacy}/house/module_simulation.go (84%) rename x/{ => legacy}/house/simulation/decoder.go (94%) rename x/{ => legacy}/house/simulation/errors.go (100%) rename x/{ => legacy}/house/simulation/genesis.go (87%) rename x/{ => legacy}/house/simulation/params.go (92%) rename x/{ => legacy}/house/simulation/proposals.go (96%) rename x/{ => legacy}/house/simulation/simap.go (100%) rename x/{ => legacy}/house/types/authz.pb.go (83%) rename x/{ => legacy}/house/types/codec.go (100%) rename x/{ => legacy}/house/types/consts.go (100%) rename x/{ => legacy}/house/types/deposit.go (100%) rename x/{ => legacy}/house/types/deposit.pb.go (80%) rename x/{ => legacy}/house/types/deposit_authorizaton.go (93%) rename x/{ => legacy}/house/types/errors.go (100%) rename x/{ => legacy}/house/types/events.go (100%) rename x/{ => legacy}/house/types/expected_keepers.go (95%) rename x/{ => legacy}/house/types/funder.go (100%) rename x/{ => legacy}/house/types/genesis.go (100%) rename x/{ => legacy}/house/types/genesis.pb.go (81%) rename x/{ => legacy}/house/types/keys.go (100%) rename x/{ => legacy}/house/types/message_deposit.go (100%) rename x/{ => legacy}/house/types/message_withdraw.go (100%) rename x/{ => legacy}/house/types/messages_params.go (100%) rename x/{ => legacy}/house/types/params.go (100%) rename x/{ => legacy}/house/types/params.pb.go (79%) rename x/{ => legacy}/house/types/query.pb.go (89%) rename x/{ => legacy}/house/types/query.pb.gw.go (99%) rename x/{ => legacy}/house/types/ticket.go (100%) rename x/{ => legacy}/house/types/ticket.pb.go (81%) rename x/{ => legacy}/house/types/tx.pb.go (87%) rename x/{ => legacy}/house/types/withdraw.pb.go (77%) rename x/{ => legacy}/house/types/withdraw_authorizaton.go (93%) rename x/{ => legacy}/house/types/withdrawal.go (100%) rename x/{ => legacy}/market/client/cli/query.go (92%) rename x/{ => legacy}/market/client/cli/query_market.go (97%) rename x/{ => legacy}/market/client/cli/query_params.go (93%) rename x/{ => legacy}/market/client/cli/tx.go (91%) rename x/{ => legacy}/market/client/cli/tx_market.go (96%) rename x/{ => legacy}/market/client/cli/tx_resolve_market.go (94%) rename x/{ => legacy}/market/genesis.go (86%) rename x/{house => legacy/market}/keeper/export_test.go (100%) rename x/{house => legacy/market}/keeper/grpc_query.go (54%) rename x/{ => legacy}/market/keeper/grpc_query_market.go (97%) rename x/{ => legacy}/market/keeper/grpc_query_params.go (91%) rename x/{ => legacy}/market/keeper/keeper.go (92%) rename x/{ => legacy}/market/keeper/market.go (93%) rename x/{orderbook => legacy/market}/keeper/msg_server.go (84%) rename x/{ => legacy}/market/keeper/msg_server_market.go (98%) rename x/{ => legacy}/market/keeper/msg_server_market_resolve.go (96%) rename x/{ => legacy}/market/keeper/msg_server_params.go (92%) rename x/{ovm => legacy/market}/keeper/params.go (87%) rename x/{ => legacy}/market/keeper/stats.go (97%) rename x/{ => legacy}/market/keeper/view.go (85%) rename x/{ => legacy}/market/module.go (90%) rename x/{ => legacy}/market/module_simulation.go (85%) rename x/{ => legacy}/market/simulation/decoder.go (94%) rename x/{ => legacy}/market/simulation/errors.go (100%) rename x/{ => legacy}/market/simulation/genesis.go (89%) rename x/{ => legacy}/market/simulation/market.go (93%) rename x/{ => legacy}/market/simulation/market_update.go (88%) rename x/{ => legacy}/market/simulation/params.go (100%) rename x/{ => legacy}/market/simulation/proposals.go (95%) rename x/{ => legacy}/market/simulation/simap.go (100%) rename x/{ => legacy}/market/types/codec.go (100%) rename x/{ => legacy}/market/types/consts.go (100%) rename x/{ => legacy}/market/types/errors.go (100%) rename x/{ => legacy}/market/types/events.go (100%) rename x/{ => legacy}/market/types/expected_keepers.go (82%) rename x/{ => legacy}/market/types/genesis.go (100%) rename x/{ => legacy}/market/types/genesis.pb.go (82%) rename x/{ => legacy}/market/types/genesis_test.go (94%) rename x/{ => legacy}/market/types/keys.go (100%) rename x/{ => legacy}/market/types/market.go (100%) rename x/{ => legacy}/market/types/market.pb.go (81%) rename x/{ => legacy}/market/types/message_market.go (100%) rename x/{ => legacy}/market/types/message_market_resolve.go (100%) rename x/{ => legacy}/market/types/messages_params.go (100%) rename x/{ => legacy}/market/types/odds.pb.go (82%) rename x/{ => legacy}/market/types/params.go (100%) rename x/{ovm => legacy/market}/types/params.pb.go (79%) rename x/{ => legacy}/market/types/query.pb.go (88%) rename x/{ => legacy}/market/types/query.pb.gw.go (99%) rename x/{ => legacy}/market/types/stats.pb.go (82%) rename x/{ => legacy}/market/types/ticket.go (100%) rename x/{ => legacy}/market/types/ticket.pb.go (87%) rename x/{ => legacy}/market/types/tx.pb.go (90%) rename x/{ => legacy}/orderbook/abci.go (86%) rename x/{ => legacy}/orderbook/client/cli/query.go (94%) rename x/{ => legacy}/orderbook/client/cli/query_bet.go (97%) rename x/{ => legacy}/orderbook/client/cli/query_exposure_odds.go (97%) rename x/{ => legacy}/orderbook/client/cli/query_exposure_participation.go (98%) rename x/{ => legacy}/orderbook/client/cli/query_orderbook.go (97%) rename x/{ovm => legacy/orderbook}/client/cli/query_params.go (93%) rename x/{ => legacy}/orderbook/client/cli/query_participation.go (98%) rename x/{ => legacy}/orderbook/genesis.go (95%) rename x/{ => legacy}/orderbook/keeper/bet_settle.go (96%) rename x/{ => legacy}/orderbook/keeper/bet_wager.go (99%) rename x/{ => legacy}/orderbook/keeper/export_test.go (100%) rename x/{ => legacy}/orderbook/keeper/exposure_odds.go (92%) rename x/{ => legacy}/orderbook/keeper/exposure_participation.go (91%) rename x/{ => legacy}/orderbook/keeper/fund.go (97%) create mode 100644 x/legacy/orderbook/keeper/grpc_query.go rename x/{ => legacy}/orderbook/keeper/grpc_query_exposure_odds.go (96%) rename x/{ => legacy}/orderbook/keeper/grpc_query_exposure_participation.go (98%) rename x/{ => legacy}/orderbook/keeper/grpc_query_orderbook.go (96%) rename x/{bet => legacy/orderbook}/keeper/grpc_query_params.go (90%) rename x/{ => legacy}/orderbook/keeper/grpc_query_participation.go (97%) rename x/{ => legacy}/orderbook/keeper/grpc_query_participation_bet.go (95%) rename x/{ => legacy}/orderbook/keeper/keeper.go (94%) rename x/{ => legacy}/orderbook/keeper/market.go (85%) create mode 100644 x/legacy/orderbook/keeper/msg_server.go create mode 100644 x/legacy/orderbook/keeper/msg_server_params.go rename x/{ => legacy}/orderbook/keeper/orderbook.go (92%) rename x/{ => legacy}/orderbook/keeper/orderbook_settle.go (97%) rename x/{ => legacy}/orderbook/keeper/params.go (94%) rename x/{ => legacy}/orderbook/keeper/participation.go (94%) rename x/{ => legacy}/orderbook/keeper/participation_bet.go (84%) rename x/{ => legacy}/orderbook/keeper/stats.go (97%) rename x/{ => legacy}/orderbook/keeper/view.go (95%) rename x/{ => legacy}/orderbook/module.go (87%) rename x/{ => legacy}/orderbook/module_simulation.go (82%) rename x/{ => legacy}/orderbook/simulation/decoder.go (97%) rename x/{ => legacy}/orderbook/simulation/errors.go (100%) rename x/{ => legacy}/orderbook/simulation/genesis.go (84%) rename x/{ => legacy}/orderbook/simulation/params.go (95%) rename x/{ => legacy}/orderbook/simulation/proposals.go (95%) rename x/{mint => legacy/orderbook}/simulation/simap.go (100%) rename x/{ => legacy}/orderbook/types/codec.go (100%) rename x/{ => legacy}/orderbook/types/consts.go (100%) rename x/{ => legacy}/orderbook/types/errors.go (100%) rename x/{ => legacy}/orderbook/types/events.go (100%) rename x/{ => legacy}/orderbook/types/expected_keepers.go (79%) rename x/{ => legacy}/orderbook/types/exposure.go (100%) rename x/{ => legacy}/orderbook/types/exposure.pb.go (85%) rename x/{ => legacy}/orderbook/types/funder.go (100%) rename x/{ => legacy}/orderbook/types/genesis.go (100%) rename x/{ => legacy}/orderbook/types/genesis.pb.go (86%) rename x/{ => legacy}/orderbook/types/hooks.go (100%) rename x/{ => legacy}/orderbook/types/keys.go (100%) rename x/{ => legacy}/orderbook/types/messages_params.go (100%) rename x/{ => legacy}/orderbook/types/orderbook.go (100%) rename x/{ => legacy}/orderbook/types/orderbook.pb.go (76%) rename x/{ => legacy}/orderbook/types/params.go (100%) rename x/{ => legacy}/orderbook/types/params.pb.go (79%) rename x/{ => legacy}/orderbook/types/participation.go (96%) rename x/{ => legacy}/orderbook/types/participation.pb.go (86%) rename x/{ => legacy}/orderbook/types/participation_bet.go (100%) rename x/{ => legacy}/orderbook/types/query.pb.go (92%) rename x/{ => legacy}/orderbook/types/query.pb.gw.go (99%) rename x/{ => legacy}/orderbook/types/stats.pb.go (82%) rename x/{ => legacy}/orderbook/types/tx.pb.go (81%) rename x/{ => legacy}/ovm/abci.go (86%) rename x/{ => legacy}/ovm/client/cli/query.go (92%) rename x/{house => legacy/ovm}/client/cli/query_params.go (93%) rename x/{ => legacy}/ovm/client/cli/query_proposal.go (97%) rename x/{ => legacy}/ovm/client/cli/query_pub_keys.go (94%) rename x/{ => legacy}/ovm/client/cli/tx.go (92%) rename x/{ => legacy}/ovm/client/cli/tx_pubkeys_proposal.go (95%) rename x/{ => legacy}/ovm/client/cli/tx_pubkeys_vote.go (95%) rename x/{ => legacy}/ovm/genesis.go (92%) rename x/{market => legacy/ovm}/keeper/export_test.go (100%) rename x/{market => legacy/ovm}/keeper/grpc_query.go (56%) rename x/{ => legacy}/ovm/keeper/grpc_query_params.go (91%) rename x/{ => legacy}/ovm/keeper/grpc_query_pubkeys.go (92%) rename x/{ => legacy}/ovm/keeper/grpc_query_pubkeys_proposal.go (95%) rename x/{ => legacy}/ovm/keeper/keeper.go (89%) rename x/{ => legacy}/ovm/keeper/key_vault.go (92%) rename x/{bet => legacy/ovm}/keeper/msg_server.go (85%) rename x/{bet => legacy/ovm}/keeper/msg_server_params.go (93%) rename x/{ => legacy}/ovm/keeper/msg_server_pubkeys_proposal.go (96%) rename x/{ => legacy}/ovm/keeper/msg_server_vote.go (98%) rename x/{market => legacy/ovm}/keeper/params.go (88%) rename x/{ => legacy}/ovm/keeper/proposal.go (95%) rename x/{ => legacy}/ovm/keeper/stats.go (92%) rename x/{ => legacy}/ovm/keeper/ticket.go (98%) rename x/{ => legacy}/ovm/keeper/view.go (90%) rename x/{ => legacy}/ovm/module.go (90%) rename x/{ => legacy}/ovm/module_simulation.go (89%) rename x/{ => legacy}/ovm/simulation/decoder.go (95%) rename x/{ => legacy}/ovm/simulation/errors.go (100%) rename x/{ => legacy}/ovm/simulation/genesis.go (90%) rename x/{ => legacy}/ovm/simulation/proposal.go (90%) rename x/{reward => legacy/ovm}/simulation/proposals.go (95%) rename x/{orderbook => legacy/ovm}/simulation/simap.go (100%) rename x/{ => legacy}/ovm/types/codec.go (100%) rename x/{ => legacy}/ovm/types/consts.go (100%) rename x/{ => legacy}/ovm/types/errors.go (100%) rename x/{ => legacy}/ovm/types/events.go (100%) rename x/{ => legacy}/ovm/types/expected_keepers.go (70%) rename x/{ => legacy}/ovm/types/export_test.go (100%) rename x/{ => legacy}/ovm/types/genesis.go (100%) rename x/{ => legacy}/ovm/types/genesis.pb.go (81%) rename x/{ => legacy}/ovm/types/key_vault.go (100%) rename x/{ => legacy}/ovm/types/key_vault.pb.go (82%) rename x/{ => legacy}/ovm/types/keys.go (100%) rename x/{ => legacy}/ovm/types/message_pubkeys_proposal.go (100%) rename x/{ => legacy}/ovm/types/message_pubkeys_vote.go (100%) rename x/{ => legacy}/ovm/types/messages_params.go (100%) rename x/{ => legacy}/ovm/types/params.go (100%) rename x/{market => legacy/ovm}/types/params.pb.go (80%) rename x/{ => legacy}/ovm/types/proposal.go (100%) rename x/{ => legacy}/ovm/types/proposal.pb.go (79%) rename x/{ => legacy}/ovm/types/query.pb.go (88%) rename x/{ => legacy}/ovm/types/query.pb.gw.go (99%) rename x/{ => legacy}/ovm/types/stats.pb.go (81%) rename x/{ => legacy}/ovm/types/ticket.go (100%) rename x/{ => legacy}/ovm/types/ticket.pb.go (84%) rename x/{ => legacy}/ovm/types/ticket_jwt.go (100%) rename x/{ => legacy}/ovm/types/tx.pb.go (88%) rename x/{ => legacy}/ovm/types/vote.go (100%) rename x/{ => legacy}/ovm/types/vote.pb.go (78%) rename x/{ => legacy}/reward/client/cli/query.go (94%) rename x/{ => legacy}/reward/client/cli/query_campaign.go (96%) rename x/{subaccount => legacy/reward}/client/cli/query_params.go (92%) rename x/{ => legacy}/reward/client/cli/query_promoter.go (96%) rename x/{ => legacy}/reward/client/cli/query_reward.go (98%) rename x/{ => legacy}/reward/client/cli/tx.go (94%) rename x/{ => legacy}/reward/client/cli/tx_campaign.go (98%) rename x/{ => legacy}/reward/client/cli/tx_promoter.go (97%) rename x/{ => legacy}/reward/client/cli/tx_reward.go (95%) rename x/{ => legacy}/reward/genesis.go (94%) rename x/{ => legacy}/reward/keeper/campaign.go (90%) rename x/{ => legacy}/reward/keeper/distribution.go (91%) rename x/{ovm => legacy/reward}/keeper/export_test.go (100%) rename x/{ => legacy}/reward/keeper/keeper.go (92%) rename x/{ovm => legacy/reward}/keeper/msg_server.go (84%) rename x/{ => legacy}/reward/keeper/msg_server_campaign.go (95%) create mode 100644 x/legacy/reward/keeper/msg_server_params.go rename x/{ => legacy}/reward/keeper/msg_server_promoter.go (97%) rename x/{ => legacy}/reward/keeper/msg_server_reward.go (98%) rename x/{ => legacy}/reward/keeper/params.go (86%) rename x/{ => legacy}/reward/keeper/promoter.go (92%) rename x/{ => legacy}/reward/keeper/query.go (54%) rename x/{ => legacy}/reward/keeper/query_campaign.go (94%) rename x/{subaccount => legacy/reward}/keeper/query_params.go (89%) rename x/{ => legacy}/reward/keeper/query_promoter.go (95%) rename x/{ => legacy}/reward/keeper/query_reward.go (97%) rename x/{ => legacy}/reward/keeper/reward.go (91%) rename x/{ => legacy}/reward/keeper/view.go (95%) rename x/{ => legacy}/reward/module.go (91%) rename x/{ => legacy}/reward/module_simulation.go (85%) rename x/{ => legacy}/reward/simulation/campaign.go (89%) rename x/{ => legacy}/reward/simulation/helpers.go (100%) rename x/{ovm => legacy/reward}/simulation/proposals.go (95%) rename x/{ => legacy}/reward/types/authz.pb.go (86%) rename x/{ => legacy}/reward/types/campaign.go (100%) rename x/{ => legacy}/reward/types/campaign.pb.go (86%) rename x/{ => legacy}/reward/types/campaign_authorizaton.go (93%) rename x/{ => legacy}/reward/types/codec.go (100%) rename x/{ => legacy}/reward/types/consts.go (100%) rename x/{ => legacy}/reward/types/errors.go (98%) rename x/{ => legacy}/reward/types/events.go (100%) rename x/{ => legacy}/reward/types/expected_keepers.go (76%) rename x/{ => legacy}/reward/types/funder.go (100%) rename x/{ => legacy}/reward/types/genesis.go (100%) rename x/{ => legacy}/reward/types/genesis.pb.go (85%) rename x/{ => legacy}/reward/types/genesis_test.go (97%) rename x/{ => legacy}/reward/types/key_campaign.go (100%) rename x/{ => legacy}/reward/types/key_promoter.go (100%) rename x/{ => legacy}/reward/types/key_reward.go (100%) rename x/{ => legacy}/reward/types/keys.go (100%) rename x/{ => legacy}/reward/types/messages_campaign.go (100%) rename x/{ => legacy}/reward/types/messages_params.go (100%) rename x/{ => legacy}/reward/types/messages_promoter.go (100%) rename x/{ => legacy}/reward/types/messages_reward.go (100%) rename x/{ => legacy}/reward/types/params.go (100%) rename x/{ => legacy}/reward/types/params.pb.go (79%) rename x/{ => legacy}/reward/types/pool.go (100%) rename x/{ => legacy}/reward/types/pool_test.go (93%) rename x/{ => legacy}/reward/types/promoter.go (100%) rename x/{ => legacy}/reward/types/promoter.pb.go (87%) rename x/{ => legacy}/reward/types/query.pb.go (91%) rename x/{ => legacy}/reward/types/query.pb.gw.go (99%) rename x/{ => legacy}/reward/types/reward.go (94%) rename x/{ => legacy}/reward/types/reward.pb.go (83%) rename x/{ => legacy}/reward/types/reward_bet_bonus.go (95%) rename x/{ => legacy}/reward/types/reward_signup.go (97%) rename x/{ => legacy}/reward/types/reward_signup_affiliatee.go (98%) rename x/{ => legacy}/reward/types/reward_signup_affiliator.go (98%) rename x/{ => legacy}/reward/types/reward_signup_referee.go (98%) rename x/{ => legacy}/reward/types/reward_signup_referrer.go (98%) rename x/{ => legacy}/reward/types/ticket.go (92%) rename x/{ => legacy}/reward/types/ticket.pb.go (89%) rename x/{ => legacy}/reward/types/ticket_test.go (98%) rename x/{ => legacy}/reward/types/tx.pb.go (90%) rename x/{ => legacy}/subaccount/client/cli/query.go (96%) rename x/{reward => legacy/subaccount}/client/cli/query_params.go (92%) rename x/{ => legacy}/subaccount/client/cli/tx.go (98%) rename x/{ => legacy}/subaccount/genesis.go (88%) rename x/{ => legacy}/subaccount/keeper/balance.go (98%) rename x/{ => legacy}/subaccount/keeper/hooks.go (97%) rename x/{ => legacy}/subaccount/keeper/keeper.go (90%) rename x/{ => legacy}/subaccount/keeper/msg_server.go (84%) rename x/{ => legacy}/subaccount/keeper/msg_server_balance.go (95%) rename x/{ => legacy}/subaccount/keeper/msg_server_bet.go (91%) rename x/{ => legacy}/subaccount/keeper/msg_server_house.go (96%) create mode 100644 x/legacy/subaccount/keeper/msg_server_params.go rename x/{ => legacy}/subaccount/keeper/msg_server_subaccount.go (92%) rename x/{ => legacy}/subaccount/keeper/params.go (92%) rename x/{reward => legacy/subaccount}/keeper/query_params.go (89%) rename x/{ => legacy}/subaccount/keeper/query_server.go (96%) rename x/{ => legacy}/subaccount/keeper/subaccount.go (96%) rename x/{ => legacy}/subaccount/module.go (89%) rename x/{ => legacy}/subaccount/simulation/decoder.go (96%) rename x/{ => legacy}/subaccount/simulation/errors.go (100%) rename x/{ => legacy}/subaccount/simulation/genesis.go (87%) rename x/{ => legacy}/subaccount/simulation/proposals.go (95%) rename x/{ovm => legacy/subaccount}/simulation/simap.go (100%) rename x/{ => legacy}/subaccount/types/accsummary.go (100%) rename x/{ => legacy}/subaccount/types/address.go (100%) rename x/{ => legacy}/subaccount/types/balance.pb.go (83%) rename x/{ => legacy}/subaccount/types/balance_test.go (94%) rename x/{ => legacy}/subaccount/types/codec.go (100%) rename x/{ => legacy}/subaccount/types/errors.go (100%) rename x/{ => legacy}/subaccount/types/events.go (100%) rename x/{ => legacy}/subaccount/types/expected_keepers.go (79%) rename x/{ => legacy}/subaccount/types/genesis.go (100%) rename x/{ => legacy}/subaccount/types/genesis.pb.go (85%) rename x/{ => legacy}/subaccount/types/keys.go (100%) rename x/{ => legacy}/subaccount/types/messages_balance.go (100%) rename x/{ => legacy}/subaccount/types/messages_bet.go (96%) rename x/{ => legacy}/subaccount/types/messages_house.go (100%) rename x/{ => legacy}/subaccount/types/messages_params.go (100%) rename x/{ => legacy}/subaccount/types/messages_subaccount.go (100%) rename x/{ => legacy}/subaccount/types/params.go (100%) rename x/{ => legacy}/subaccount/types/params.pb.go (80%) rename x/{ => legacy}/subaccount/types/query.pb.go (85%) rename x/{ => legacy}/subaccount/types/query.pb.gw.go (99%) rename x/{ => legacy}/subaccount/types/ticket.go (100%) rename x/{ => legacy}/subaccount/types/ticket.pb.go (80%) rename x/{ => legacy}/subaccount/types/tx.pb.go (89%) delete mode 100644 x/market/client/cli/query_market_test.go delete mode 100644 x/market/client/cli/query_params_test.go delete mode 100644 x/market/client/cli/query_test.go delete mode 100644 x/market/client/cli/tx_test.go delete mode 100644 x/market/genesis_test.go delete mode 100644 x/market/handler.go delete mode 100644 x/market/keeper/grpc_query_market_test.go delete mode 100644 x/market/keeper/grpc_query_params_test.go delete mode 100644 x/market/keeper/keeper_test.go delete mode 100644 x/market/keeper/market_test.go delete mode 100644 x/market/keeper/msg_server_market_resolve_test.go delete mode 100644 x/market/keeper/msg_server_market_test.go delete mode 100644 x/market/keeper/msg_server_test.go delete mode 100644 x/market/keeper/params_test.go delete mode 100644 x/market/simulation/decoder_test.go delete mode 100644 x/market/simulation/genesis_test.go delete mode 100644 x/market/simulation/params_test.go delete mode 100644 x/market/simulation/proposals_test.go delete mode 100644 x/market/types/message_market_resolve_test.go delete mode 100644 x/market/types/message_market_test.go delete mode 100644 x/market/types/ticket_test.go create mode 100644 x/mint/autocli.go delete mode 100644 x/mint/client/cli/query.go delete mode 100644 x/mint/client/cli/query_minter.go delete mode 100644 x/mint/client/cli/query_minter_test.go delete mode 100644 x/mint/client/cli/query_params.go delete mode 100644 x/mint/client/cli/query_params_test.go delete mode 100644 x/mint/client/cli/query_test.go create mode 100644 x/mint/exported/exported.go delete mode 100644 x/mint/genesis.go delete mode 100644 x/mint/genesis_test.go create mode 100644 x/mint/keeper/genesis.go delete mode 100644 x/mint/keeper/grpc_query_minter.go delete mode 100644 x/mint/keeper/grpc_query_minter_test.go delete mode 100644 x/mint/keeper/grpc_query_params.go delete mode 100644 x/mint/keeper/grpc_query_params_test.go create mode 100644 x/mint/keeper/grpc_query_test.go create mode 100644 x/mint/keeper/migrator.go delete mode 100644 x/mint/keeper/minter.go delete mode 100644 x/mint/keeper/minter_test.go delete mode 100644 x/mint/keeper/msg_server_params.go create mode 100644 x/mint/keeper/msg_server_test.go delete mode 100644 x/mint/keeper/params.go delete mode 100644 x/mint/keeper/params_test.go create mode 100644 x/mint/migrations/v2/migrate.go create mode 100644 x/mint/migrations/v2/migrator_test.go delete mode 100644 x/mint/module_simulation.go delete mode 100644 x/mint/module_test.go delete mode 100644 x/mint/simulation/decoder.go delete mode 100644 x/mint/simulation/decoder_test.go delete mode 100644 x/mint/simulation/errors.go delete mode 100644 x/mint/simulation/params.go delete mode 100644 x/mint/simulation/params_test.go create mode 100644 x/mint/simulation/proposals.go create mode 100644 x/mint/simulation/proposals_test.go create mode 100644 x/mint/testutil/app_config.go create mode 100644 x/mint/testutil/expected_keepers_mocks.go delete mode 100644 x/mint/types/msgs.go create mode 100644 x/mint/types/params_legacy.go delete mode 100644 x/orderbook/client/cli/query_bet_test.go delete mode 100644 x/orderbook/client/cli/query_exposure_odds_test.go delete mode 100644 x/orderbook/client/cli/query_exposure_participation_test.go delete mode 100644 x/orderbook/client/cli/query_orderbook_test.go delete mode 100644 x/orderbook/client/cli/query_params_test.go delete mode 100644 x/orderbook/client/cli/query_participation_test.go delete mode 100644 x/orderbook/client/cli/query_test.go delete mode 100644 x/orderbook/handler.go delete mode 100644 x/orderbook/keeper/bet_settle_test.go delete mode 100644 x/orderbook/keeper/bet_wager_test.go delete mode 100644 x/orderbook/keeper/exposure_odds_test.go delete mode 100644 x/orderbook/keeper/exposure_participation_test.go delete mode 100644 x/orderbook/keeper/fund_test.go delete mode 100644 x/orderbook/keeper/grpc_query_exposure_odds_test.go delete mode 100644 x/orderbook/keeper/grpc_query_exposure_participation_test.go delete mode 100644 x/orderbook/keeper/grpc_query_orderbook_test.go delete mode 100644 x/orderbook/keeper/grpc_query_params_test.go delete mode 100644 x/orderbook/keeper/grpc_query_participation_bet_test.go delete mode 100644 x/orderbook/keeper/grpc_query_participation_test.go delete mode 100644 x/orderbook/keeper/keeper_test.go delete mode 100644 x/orderbook/keeper/orderbook_settle_test.go delete mode 100644 x/orderbook/keeper/orderbook_test.go delete mode 100644 x/orderbook/keeper/params_test.go delete mode 100644 x/orderbook/keeper/participation_bet_test.go delete mode 100644 x/orderbook/keeper/participation_test.go delete mode 100644 x/orderbook/keeper/stats_test.go delete mode 100644 x/orderbook/simulation/decoder_test.go delete mode 100644 x/orderbook/simulation/genesis_test.go delete mode 100644 x/orderbook/simulation/params_test.go delete mode 100644 x/orderbook/simulation/proposals_test.go delete mode 100644 x/orderbook/types/genesis_test.go delete mode 100644 x/ovm/client/cli/query_params_test.go delete mode 100644 x/ovm/client/cli/query_proposal_test.go delete mode 100644 x/ovm/client/cli/query_pub_keys_test.go delete mode 100644 x/ovm/client/cli/query_test.go delete mode 100644 x/ovm/client/cli/tx_pubkeys_proposal_test.go delete mode 100644 x/ovm/client/cli/tx_test.go delete mode 100644 x/ovm/genesis_test.go delete mode 100644 x/ovm/handler.go delete mode 100644 x/ovm/keeper/grpc_query.go delete mode 100644 x/ovm/keeper/grpc_query_params_test.go delete mode 100644 x/ovm/keeper/grpc_query_pubkeys_proposal_test.go delete mode 100644 x/ovm/keeper/grpc_query_pubkeys_test.go delete mode 100644 x/ovm/keeper/keeper_test.go delete mode 100644 x/ovm/keeper/key_vault_test.go delete mode 100644 x/ovm/keeper/msg_server_params.go delete mode 100644 x/ovm/keeper/msg_server_pubkeys_proposal_test.go delete mode 100644 x/ovm/keeper/msg_server_test.go delete mode 100644 x/ovm/keeper/msg_server_vote_test.go delete mode 100644 x/ovm/keeper/params_test.go delete mode 100644 x/ovm/keeper/proposal_test.go delete mode 100644 x/ovm/keeper/ticket_test.go delete mode 100644 x/ovm/simulation/decoder_test.go delete mode 100644 x/ovm/simulation/genesis_test.go delete mode 100644 x/ovm/simulation/proposals_test.go delete mode 100644 x/ovm/types/genesis_test.go delete mode 100644 x/ovm/types/key_vault_test.go delete mode 100644 x/ovm/types/message_pubkeys_proposal_test.go delete mode 100644 x/ovm/types/message_pubkeys_vote_test.go delete mode 100644 x/ovm/types/ticket_jwt_test.go delete mode 100644 x/reward/genesis_test.go delete mode 100644 x/reward/handler.go delete mode 100644 x/reward/keeper/campaign_test.go delete mode 100644 x/reward/keeper/export_test.go delete mode 100644 x/reward/keeper/keeper_test.go delete mode 100644 x/reward/keeper/msg_server.go delete mode 100644 x/reward/keeper/msg_server_campaign_test.go delete mode 100644 x/reward/keeper/msg_server_params.go delete mode 100644 x/reward/keeper/msg_server_promoter_test.go delete mode 100644 x/reward/keeper/msg_server_reward_test.go delete mode 100644 x/reward/keeper/query_campaign_test.go delete mode 100644 x/reward/simulation/proposals_test.go delete mode 100644 x/reward/types/campaign_authorizaton_test.go delete mode 100644 x/reward/types/messages_campaign_test.go delete mode 100644 x/reward/types/messages_promoter_test.go delete mode 100644 x/reward/types/messages_reward_test.go delete mode 100644 x/subaccount/genesis_test.go delete mode 100644 x/subaccount/handler.go delete mode 100644 x/subaccount/keeper/balance_test.go delete mode 100644 x/subaccount/keeper/export_test.go delete mode 100644 x/subaccount/keeper/keeper_test.go delete mode 100644 x/subaccount/keeper/msg_server_balance_test.go delete mode 100644 x/subaccount/keeper/msg_server_bet_test.go delete mode 100644 x/subaccount/keeper/msg_server_house_test.go delete mode 100644 x/subaccount/keeper/msg_server_params.go delete mode 100644 x/subaccount/keeper/msg_server_subaccount_test.go delete mode 100644 x/subaccount/keeper/msg_server_test.go delete mode 100644 x/subaccount/keeper/params_test.go delete mode 100644 x/subaccount/keeper/query_server_test.go delete mode 100644 x/subaccount/keeper/subaccount_test.go delete mode 100644 x/subaccount/simulation/decoder_test.go delete mode 100644 x/subaccount/simulation/genesis_test.go delete mode 100644 x/subaccount/simulation/proposals_test.go delete mode 100644 x/subaccount/simulation/simap.go delete mode 100644 x/subaccount/types/messages_balance_test.go delete mode 100644 x/subaccount/types/messages_subaccount_test.go diff --git a/tests/e2e/bet/cli_test.go b/tests/e2e/bet/cli_test.go deleted file mode 100644 index 72228e20..00000000 --- a/tests/e2e/bet/cli_test.go +++ /dev/null @@ -1,16 +0,0 @@ -package client_test - -import ( - "testing" - - "github.com/stretchr/testify/suite" - - client "github.com/sge-network/sge/tests/e2e/bet" - "github.com/sge-network/sge/testutil/network" -) - -func TestE2ETestSuite(t *testing.T) { - cfg := network.DefaultConfig() - cfg.NumValidators = 1 - suite.Run(t, client.NewE2ETestSuite(cfg)) -} diff --git a/tests/e2e/bet/grpc.go b/tests/e2e/bet/grpc.go deleted file mode 100644 index 55c1bfbf..00000000 --- a/tests/e2e/bet/grpc.go +++ /dev/null @@ -1,105 +0,0 @@ -package client - -import ( - "fmt" - - "github.com/cosmos/gogoproto/proto" - - "github.com/cosmos/cosmos-sdk/testutil" - grpctypes "github.com/cosmos/cosmos-sdk/types/grpc" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/x/bet/types" -) - -func (s *E2ETestSuite) TestBetsGRPCHandler() { - val := s.network.Validators[0] - baseURL := val.APIAddress - - testCases := []struct { - name string - url string - headers map[string]string - respType proto.Message - expected proto.Message - }{ - { - "test GRPC Bet by UID", - fmt.Sprintf("%s/sge/bet/%s/%s", baseURL, dummyBetCreator, dummyBetUID), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryBetResponse{}, - &types.QueryBetResponse{ - Bet: genesis.BetList[0], - Market: dummyMarket, - }, - }, - { - "test GRPC sorted Bet by creator", - fmt.Sprintf("%s/sge/bet/creator/%s/bets", baseURL, dummyBetCreator), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryBetsByCreatorResponse{}, - &types.QueryBetsByCreatorResponse{ - Bet: genesis.BetList, - Pagination: &query.PageResponse{ - Total: 1, - }, - }, - }, - { - "test GRPC Bet by UID", - fmt.Sprintf("%s/sge/bet/bets", baseURL), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryBetsResponse{}, - &types.QueryBetsResponse{ - Bet: genesis.BetList, - Pagination: &query.PageResponse{ - Total: 1, - }, - }, - }, - { - "test GRPC pending bets by market", - fmt.Sprintf("%s/sge/bet/bets/pending/%s", baseURL, dummyMarketUID), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryPendingBetsResponse{}, - &types.QueryPendingBetsResponse{ - Bet: genesis.BetList, - Pagination: &query.PageResponse{ - Total: 1, - }, - }, - }, - { - "test GRPC settled bets by market", - fmt.Sprintf("%s/sge/bet/bets/settled/%d", baseURL, 1), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QuerySettledBetsOfHeightResponse{}, - &types.QuerySettledBetsOfHeightResponse{ - Bet: genesis.BetList, - Pagination: &query.PageResponse{ - Total: 1, - }, - }, - }, - } - - for _, tc := range testCases { - s.Run(tc.name, func() { - resp, err := testutil.GetRequestWithHeaders(tc.url, tc.headers) - s.Require().NoError(err) - - s.Require().NoError(val.ClientCtx.Codec.UnmarshalJSON(resp, tc.respType)) - s.Require().Equal(tc.expected.String(), tc.respType.String()) - }) - } -} diff --git a/tests/e2e/bet/suite.go b/tests/e2e/bet/suite.go deleted file mode 100644 index 9aba0e1c..00000000 --- a/tests/e2e/bet/suite.go +++ /dev/null @@ -1,459 +0,0 @@ -package client - -import ( - "fmt" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - "github.com/stretchr/testify/suite" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/gogoproto/proto" - - e2esdk "github.com/sge-network/sge/tests/e2e/sdk" - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/bet/client/cli" - "github.com/sge-network/sge/x/bet/types" - housecli "github.com/sge-network/sge/x/house/client/cli" - marketcli "github.com/sge-network/sge/x/market/client/cli" - markettypes "github.com/sge-network/sge/x/market/types" -) - -var ( - genesis types.GenesisState - - dummyMarket = markettypes.Market{} - dummyBetCreator = sample.AccAddress() - dummyBetUID = uuid.NewString() - dummyMarketUID = uuid.NewString() - - oddsUID1 = "9991c60f-2025-48ce-ae79-1dc110f16900" - oddsValue1 = sdkmath.LegacyNewDecWithPrec(14, 1) // 1.4 - oddsUID2 = "9991c60f-2025-48ce-ae79-1dc110f16901" - oddsValue2 = sdkmath.LegacyNewDecWithPrec(13, 1) // 1.3 - oddsUID3 = "9991c60f-2025-48ce-ae79-1dc110f16902" - maxLossMultiplier = sdkmath.LegacyNewDecWithPrec(10, 2) - - betFees = sdkmath.NewInt(10) - fees = int64(10) - marketUID = uuid.NewString() - marketStartDate = uint64(time.Now().Unix()) - marketEndDate = uint64(time.Now().Add(time.Minute * time.Duration(120)).Unix()) - depositAmount = sdkmath.NewInt(100000) - - wagerDate = time.Now().Add(time.Minute * time.Duration(180)).Unix() - wagerAmount = sdkmath.NewInt(100) - - acc1 = sdk.AccAddress{} - acc1Balance = sdkmath.ZeroInt() - - acc2 = sdk.AccAddress{} - acc2Balance = sdkmath.ZeroInt() -) - -type E2ETestSuite struct { - suite.Suite - - cfg network.Config - network *network.Network -} - -func NewE2ETestSuite(cfg network.Config) *E2ETestSuite { - return &E2ETestSuite{cfg: cfg} -} - -func (s *E2ETestSuite) SetupSuite() { - s.T().Log("setting up e2e test suite") - - genesisState := s.cfg.GenesisState - - var marketGenesis markettypes.GenesisState - s.Require().NoError(s.cfg.Codec.UnmarshalJSON(genesisState[markettypes.ModuleName], &marketGenesis)) - - dummyMarket = markettypes.Market{ - Creator: sample.AccAddress(), - UID: dummyMarketUID, - StartTS: uint64(time.Now().Unix()), - EndTS: uint64(time.Now().Add(time.Minute * time.Duration(120)).Unix()), - Odds: []*markettypes.Odds{ - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16904", - Meta: "Home", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16905", - Meta: "Draw", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16906", - Meta: "Away", - }, - }, - WinnerOddsUIDs: []string{}, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "dummy market", - BookUID: dummyMarketUID, - } - marketGenesis.MarketList = []markettypes.Market{dummyMarket} - marketGenesisBz, err := s.cfg.Codec.MarshalJSON(&marketGenesis) - s.Require().NoError(err) - genesisState[markettypes.ModuleName] = marketGenesisBz - - s.Require().NoError(s.cfg.Codec.UnmarshalJSON(genesisState[types.ModuleName], &genesis)) - - genesis.BetList = []types.Bet{ - { - Creator: dummyBetCreator, - UID: dummyBetUID, - OddsUID: marketGenesis.MarketList[0].OddsUIDS()[0], - OddsValue: "0.5", - Fee: sdkmath.NewInt(10), - Status: types.Bet_STATUS_SETTLED, - Result: types.Bet_RESULT_WON, - CreatedAt: wagerDate, - SettlementHeight: 1, - MaxLossMultiplier: sdkmath.LegacyNewDecWithPrec(10, 2), - Meta: types.MetaData{ - SelectedOddsType: types.OddsType_ODDS_TYPE_DECIMAL, - SelectedOddsValue: "0.5", - IsMainMarket: false, - }, - BetFulfillment: []*types.BetFulfillment{}, - MarketUID: dummyMarketUID, - Amount: wagerAmount, - }, - } - - genesis.Uid2IdList = []types.UID2ID{ - { - UID: dummyBetUID, - ID: 1, - }, - } - - genesis.PendingBetList = []types.PendingBet{ - { - UID: dummyBetUID, - Creator: dummyBetCreator, - }, - } - - genesis.SettledBetList = []types.SettledBet{ - { - UID: dummyBetUID, - BettorAddress: dummyBetCreator, - }, - } - - genesis.Stats = types.BetStats{ - Count: 1, - } - - genesis.Params = types.Params{ - BatchSettlementCount: uint32(1000), - MaxBetByUidQueryCount: uint32(1000), - Constraints: types.Constraints{ - MinAmount: sdkmath.NewInt(100), - Fee: betFees, - }, - } - - genesisBz, err := s.cfg.Codec.MarshalJSON(&genesis) - s.Require().NoError(err) - genesisState[types.ModuleName] = genesisBz - s.cfg.GenesisState = genesisState - - s.network = network.New(s.T(), s.cfg) - - s.Require().NoError(s.network.WaitForNextBlock()) -} - -func (s *E2ETestSuite) TestWagerTxCmd() { - val := s.network.Validators[0] - - clientCtx := val.ClientCtx - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": marketUID, - "start_ts": marketStartDate, - "end_ts": marketEndDate, - "odds": []markettypes.Odds{ - { - UID: oddsUID1, - Meta: "Home", - }, - { - UID: oddsUID2, - Meta: "Draw", - }, - { - UID: oddsUID3, - Meta: "Away", - }, - }, - "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - "meta": "sample 3way market", - }) - require.Nil(s.T(), err) - - args := []string{ - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, marketcli.CmdAdd(), args) - s.Require().NoError(err) - respType := sdk.TxResponse{} - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - } - s.Require().NoError(s.network.WaitForNextBlock()) - - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - "depositor_address": val.Address.String(), - }) - require.Nil(s.T(), err) - - bz, err := clitestutil.ExecTestCLICmd(clientCtx, housecli.CmdDeposit(), []string{ - marketUID, - depositAmount.String(), - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }) - s.Require().NoError(err) - - var respType sdk.TxResponse - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(uint32(0), txResp.Code) - } - - acc1initialBalance := 1000 - acc1 = e2esdk.CreateAccount(val, "acc1") - e2esdk.SendToken(val, acc1, acc1initialBalance) - s.Require().NoError(s.network.WaitForNextBlock()) - acc1Balance = e2esdk.GetSGEBalance(clientCtx, acc1.String()) - - acc2initialBalance := 1000 - acc2 = e2esdk.CreateAccount(val, "acc2") - e2esdk.SendToken(val, acc2, acc2initialBalance) - s.Require().NoError(s.network.WaitForNextBlock()) - acc2Balance = e2esdk.GetSGEBalance(clientCtx, acc2.String()) - - testCases := []struct { - name string - uid string - marketUID string - amount sdkmath.Int - ticketClaims jwt.MapClaims - args []string - expectErr bool - expectedCode uint32 - expectedErrMsg string - respType proto.Message - }{ - { - "valid transaction for acc1", - uuid.NewString(), - marketUID, - wagerAmount, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: acc1.String(), - }, - "selected_odds": types.BetOdds{ - UID: oddsUID1, - MarketUID: marketUID, - Value: oddsValue1.String(), - MaxLossMultiplier: maxLossMultiplier, - }, - "all_odds": []types.BetOddsCompact{ - {UID: oddsUID1, MaxLossMultiplier: maxLossMultiplier}, - {UID: oddsUID2, MaxLossMultiplier: maxLossMultiplier}, - {UID: oddsUID3, MaxLossMultiplier: maxLossMultiplier}, - }, - "meta": types.MetaData{ - SelectedOddsType: types.OddsType_ODDS_TYPE_DECIMAL, - SelectedOddsValue: oddsValue1.String(), - IsMainMarket: false, - }, - "context": "sample context", - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, "acc1"), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - { - "valid transaction for acc2", - uuid.NewString(), - marketUID, - wagerAmount, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: acc2.String(), - }, - "selected_odds": types.BetOdds{ - UID: oddsUID2, - MarketUID: marketUID, - Value: oddsValue2.String(), - MaxLossMultiplier: maxLossMultiplier, - }, - "all_odds": []types.BetOddsCompact{ - {UID: oddsUID1, MaxLossMultiplier: maxLossMultiplier}, - {UID: oddsUID2, MaxLossMultiplier: maxLossMultiplier}, - {UID: oddsUID3, MaxLossMultiplier: maxLossMultiplier}, - }, - "meta": types.MetaData{ - SelectedOddsType: types.OddsType_ODDS_TYPE_DECIMAL, - SelectedOddsValue: oddsValue2.String(), - IsMainMarket: false, - }, - "context": "sample context", - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, "acc2"), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - } - - for _, tc := range testCases { - s.Require().NoError(s.network.WaitForNextBlock()) - s.Run(tc.name, func() { - ticket, err := simapp.CreateJwtTicket(tc.ticketClaims) - require.Nil(s.T(), err) - - tc.args = append([]string{ - tc.uid, - tc.amount.String(), - ticket, - }, tc.args...) - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdWager(), tc.args) - - if tc.expectErr { - s.Require().Error(err) - s.T().Logf("error captured: %s", tc.name) - } else { - s.Require().NoError(err) - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), tc.respType), bz.String()) - respType, ok := tc.respType.(*sdk.TxResponse) - s.Require().True(ok) - s.Require().Equal(tc.expectedCode, respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(tc.expectedCode, txResp.Code) - if tc.expectedErrMsg != "" { - s.Require().Contains(txResp.RawLog, tc.expectedErrMsg) - } - } - }) - } - - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": marketUID, - "resolution_ts": uint64(time.Now().Unix()), - "winner_odds_uids": []string{oddsUID1}, - "status": markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - require.Nil(s.T(), err) - - bz, err := clitestutil.ExecTestCLICmd(clientCtx, marketcli.CmdResolve(), []string{ - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }) - s.Require().NoError(err) - - var respType sdk.TxResponse - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - - s.Require().NoError(s.network.WaitForNextBlock()) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(uint32(0), txResp.Code) - s.T().Logf("==== success deposit create test case finished") - } - - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdListBet(), []string{fmt.Sprintf("--%s=json", flags.FlagOutput)}) - s.Require().NoError(err) - respType := types.QueryBetsResponse{} - err = clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType) - s.Require().NoError(err) - - s.Require().Equal(3, len(respType.Bet)) - - for _, b := range respType.Bet { - s.Require().Equal(types.Bet_STATUS_SETTLED, b.Status) - } - - payout1 := oddsValue1.Mul(wagerAmount.Sub(betFees).ToLegacyDec()).TruncateInt().Sub(wagerAmount) - expectedAcc1Balance := acc1Balance.Add(payout1).Sub(sdkmath.NewInt(fees)) - acc1Balance = e2esdk.GetSGEBalance(clientCtx, acc1.String()) - s.Require().Equal(expectedAcc1Balance, acc1Balance) - - expectedAcc2Balance := acc2Balance.Sub(wagerAmount).Sub(sdkmath.NewInt(fees)) - acc2Balance = e2esdk.GetSGEBalance(clientCtx, acc2.String()) - s.Require().Equal(expectedAcc2Balance, acc2Balance) -} diff --git a/tests/e2e/house/cli_test.go b/tests/e2e/house/cli_test.go deleted file mode 100644 index 6e37be14..00000000 --- a/tests/e2e/house/cli_test.go +++ /dev/null @@ -1,16 +0,0 @@ -package client_test - -import ( - "testing" - - "github.com/stretchr/testify/suite" - - client "github.com/sge-network/sge/tests/e2e/house" - "github.com/sge-network/sge/testutil/network" -) - -func TestE2ETestSuite(t *testing.T) { - cfg := network.DefaultConfig() - cfg.NumValidators = 1 - suite.Run(t, client.NewE2ETestSuite(cfg)) -} diff --git a/tests/e2e/house/grpc.go b/tests/e2e/house/grpc.go deleted file mode 100644 index 9227caab..00000000 --- a/tests/e2e/house/grpc.go +++ /dev/null @@ -1,103 +0,0 @@ -package client - -import ( - "fmt" - - "github.com/cosmos/gogoproto/proto" - - "github.com/cosmos/cosmos-sdk/testutil" - grpctypes "github.com/cosmos/cosmos-sdk/types/grpc" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/x/house/types" -) - -func (s *E2ETestSuite) TestDepositsGRPCHandler() { - val := s.network.Validators[0] - baseURL := val.APIAddress - - testCases := []struct { - name string - url string - headers map[string]string - respType proto.Message - expected proto.Message - }{ - { - "test GRPC all deposits", - fmt.Sprintf("%s/sge/house/deposits", baseURL), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryDepositsResponse{}, - &types.QueryDepositsResponse{ - Deposits: genesis.DepositList, - Pagination: &query.PageResponse{ - Total: 1, - }, - }, - }, - { - "test GRPC deposits of certain creator", - fmt.Sprintf("%s/sge/house/deposits/%s", baseURL, dummyDepositor), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryDepositsByAccountResponse{}, - &types.QueryDepositsByAccountResponse{ - Deposits: genesis.DepositList, - Pagination: &query.PageResponse{ - Total: 1, - }, - }, - }, - } - - for _, tc := range testCases { - s.Run(tc.name, func() { - resp, err := testutil.GetRequestWithHeaders(tc.url, tc.headers) - s.Require().NoError(err) - - s.Require().NoError(val.ClientCtx.Codec.UnmarshalJSON(resp, tc.respType)) - s.Require().Equal(tc.expected.String(), tc.respType.String()) - }) - } -} - -func (s *E2ETestSuite) TestGRPCHandler() { - val := s.network.Validators[0] - baseURL := val.APIAddress - - testCases := []struct { - name string - url string - headers map[string]string - respType proto.Message - expected proto.Message - }{ - { - "test GRPC all withdraws", - fmt.Sprintf("%s/sge/house/withdrawals/%s", baseURL, dummyDepositor), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryWithdrawalsByAccountResponse{}, - &types.QueryWithdrawalsByAccountResponse{ - Withdrawals: genesis.WithdrawalList, - Pagination: &query.PageResponse{ - Total: 1, - }, - }, - }, - } - - for _, tc := range testCases { - s.Run(tc.name, func() { - resp, err := testutil.GetRequestWithHeaders(tc.url, tc.headers) - s.Require().NoError(err) - - s.Require().NoError(val.ClientCtx.Codec.UnmarshalJSON(resp, tc.respType)) - s.Require().Equal(tc.expected.String(), tc.respType.String()) - }) - } -} diff --git a/tests/e2e/house/suite.go b/tests/e2e/house/suite.go deleted file mode 100644 index d2443a43..00000000 --- a/tests/e2e/house/suite.go +++ /dev/null @@ -1,1038 +0,0 @@ -package client - -import ( - "fmt" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "github.com/stretchr/testify/suite" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/cosmos/gogoproto/proto" - - e2esdk "github.com/sge-network/sge/tests/e2e/sdk" - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/house/client/cli" - "github.com/sge-network/sge/x/house/types" - marketcli "github.com/sge-network/sge/x/market/client/cli" - markettypes "github.com/sge-network/sge/x/market/types" -) - -var ( - genesis types.GenesisState - dummyDepositor = sample.AccAddress() - - fees = int64(10) - marketUID = uuid.NewString() - marketStartDate = uint64(time.Now().Unix()) - marketEndDate = uint64(time.Now().Add(time.Minute * time.Duration(120)).Unix()) - depositAmount = sdkmath.NewInt(100) - - valBalance = sdkmath.NewInt(400000000) - - acc1 = sdk.AccAddress{} - acc1Balance = sdkmath.ZeroInt() - - acc2 = sdk.AccAddress{} - acc2Balance = sdkmath.ZeroInt() -) - -type E2ETestSuite struct { - suite.Suite - - cfg network.Config - network *network.Network -} - -func NewE2ETestSuite(cfg network.Config) *E2ETestSuite { - return &E2ETestSuite{cfg: cfg} -} - -func (s *E2ETestSuite) SetupSuite() { - s.T().Log("setting up e2e test suite") - - genesisState := s.cfg.GenesisState - - var marketGenesis markettypes.GenesisState - s.Require().NoError(s.cfg.Codec.UnmarshalJSON(genesisState[markettypes.ModuleName], &marketGenesis)) - - dummyMarketUID := uuid.NewString() - marketGenesis.MarketList = []markettypes.Market{ - { - Creator: sample.AccAddress(), - UID: dummyMarketUID, - StartTS: uint64(time.Now().Unix()), - EndTS: uint64(time.Now().Add(time.Minute * time.Duration(120)).Unix()), - Odds: []*markettypes.Odds{ - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16900", - Meta: "Home", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16901", - Meta: "Draw", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16901", - Meta: "Away", - }, - }, - WinnerOddsUIDs: []string{}, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "dummy market", - BookUID: dummyMarketUID, - }, - } - marketGenesisBz, err := s.cfg.Codec.MarshalJSON(&marketGenesis) - s.Require().NoError(err) - genesisState[markettypes.ModuleName] = marketGenesisBz - - s.Require().NoError(s.cfg.Codec.UnmarshalJSON(genesisState[types.ModuleName], &genesis)) - - genesis.DepositList = []types.Deposit{ - { - Creator: sample.AccAddress(), - DepositorAddress: dummyDepositor, - MarketUID: marketUID, - ParticipationIndex: 0, - Amount: sdkmath.NewInt(10000), - WithdrawalCount: 0, - TotalWithdrawalAmount: sdkmath.ZeroInt(), - }, - } - - genesis.WithdrawalList = []types.Withdrawal{ - { - ID: 1, - Creator: sample.AccAddress(), - Address: dummyDepositor, - MarketUID: marketUID, - ParticipationIndex: 0, - Amount: sdkmath.NewInt(10000), - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - }, - } - - genesis.Params = types.Params{ - MinDeposit: sdkmath.NewInt(100), - HouseParticipationFee: sdk.NewDecWithPrec(0, 2), - MaxWithdrawalCount: 2, - } - - genesisBz, err := s.cfg.Codec.MarshalJSON(&genesis) - s.Require().NoError(err) - genesisState[types.ModuleName] = genesisBz - s.cfg.GenesisState = genesisState - - s.network = network.New(s.T(), s.cfg) - - s.Require().NoError(s.network.WaitForNextBlock()) -} - -func (s *E2ETestSuite) TestDepositTxCmd() { - s.T().Log("==== new house deposit command test started") - val := s.network.Validators[0] - - clientCtx := val.ClientCtx - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": marketUID, - "start_ts": marketStartDate, - "end_ts": marketEndDate, - "odds": []markettypes.Odds{ - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16990", - Meta: "Home", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16991", - Meta: "Draw", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16992", - Meta: "Away", - }, - }, - "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - "meta": "sample 3way market", - }) - require.Nil(s.T(), err) - - args := []string{ - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, marketcli.CmdAdd(), args) - s.Require().NoError(err) - respType := sdk.TxResponse{} - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - } - s.Require().NoError(s.network.WaitForNextBlock()) - - expectedValBalance := valBalance.Sub(sdkmath.NewInt(fees)) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - - acc1initialBalance := 1000 - acc1 = e2esdk.CreateAccount(val, "acc1") - e2esdk.SendToken(val, acc1, acc1initialBalance) - s.Require().NoError(s.network.WaitForNextBlock()) - - expectedValBalance = valBalance.Sub(sdkmath.NewInt(int64(acc1initialBalance))).Sub(sdkmath.NewInt(fees)) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - - testCases := []struct { - name string - marketUID string - amount sdkmath.Int - ticketClaims jwt.MapClaims - args []string - expectErr bool - expectedCode uint32 - expectedErrMsg string - respType proto.Message - }{ - { - "valid transaction for val", - marketUID, - depositAmount, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - "depositor_address": val.Address.String(), - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - { - "invalid transaction for acc1", - marketUID, - sdkmath.NewInt(100000000), - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: acc1.String(), - }, - "depositor_address": acc1.String(), - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, "acc1"), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - true, - sdkerrtypes.ErrInsufficientFunds.ABCICode(), - "", - &sdk.TxResponse{}, - }, - { - "valid transaction for acc1", - marketUID, - depositAmount, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: acc1.String(), - }, - "depositor_address": acc1.String(), - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, "acc1"), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - } - - for _, tc := range testCases { - s.Require().NoError(s.network.WaitForNextBlock()) - s.Run(tc.name, func() { - ticket, err := simapp.CreateJwtTicket(tc.ticketClaims) - require.Nil(s.T(), err) - - tc.args = append([]string{ - tc.marketUID, - tc.amount.String(), - ticket, - }, tc.args...) - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdDeposit(), tc.args) - - if tc.expectErr { - s.Require().Error(err) - s.T().Logf("error captured: %s", tc.name) - } else { - s.Require().NoError(err) - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), tc.respType), bz.String()) - respType, ok := tc.respType.(*sdk.TxResponse) - s.Require().True(ok) - s.Require().Equal(tc.expectedCode, respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(tc.expectedCode, txResp.Code) - if tc.expectedErrMsg != "" { - s.Require().Contains(txResp.RawLog, tc.expectedErrMsg) - } - s.T().Logf("==== success deposit create test case finished: %s", tc.name) - } - }) - } - - depositFeeAmount := sdk.NewDecFromInt(depositAmount).Mul(genesis.Params.HouseParticipationFee).TruncateInt() - - expectedValBalance = valBalance.Sub(depositAmount).Sub(depositFeeAmount).Sub(sdkmath.NewInt(fees)) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - s.T().Logf("==== bank val balance checked after deposit to the market: %s", valBalance) - - acc1Balance = e2esdk.GetSGEBalance(clientCtx, acc1.String()) - expectedBalance := sdkmath.NewInt(int64(acc1initialBalance)).Sub(depositAmount).Sub(depositFeeAmount).Sub(sdkmath.NewInt(fees)) - s.Require().Equal(expectedBalance, acc1Balance) - s.T().Logf("==== bank acc1 balance checked after deposit to the market: %s", acc1Balance) - - depositsBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDeposits(), []string{ - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposits := types.QueryDepositsResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositsBz.Bytes(), &deposits) - require.NoError(s.T(), err) - - require.Equal(s.T(), 3, len(deposits.Deposits)) - - depositBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDepositsByAccount(), []string{ - acc1.String(), - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposit := types.QueryDepositsByAccountResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositBz.Bytes(), &deposit) - require.NoError(s.T(), err) - - require.Equal(s.T(), []types.Deposit{ - { - Creator: acc1.String(), - DepositorAddress: acc1.String(), - MarketUID: marketUID, - ParticipationIndex: 2, - Amount: depositAmount, - WithdrawalCount: 0, - TotalWithdrawalAmount: sdkmath.ZeroInt(), - }, - }, deposit.Deposits) - require.Equal(s.T(), acc1.String(), deposit.Deposits[0].DepositorAddress) - s.T().Log("==== state modifications checked after deposit to the market") - - s.T().Log("==== new deposit test passed successfully") -} - -func (s *E2ETestSuite) TestDepositWithAuthzTxCmd() { - s.T().Log("==== new house deposit with authorization command test started") - val := s.network.Validators[0] - - clientCtx := val.ClientCtx - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": marketUID, - "start_ts": marketStartDate, - "end_ts": marketEndDate, - "odds": []markettypes.Odds{ - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16990", - Meta: "Home", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16991", - Meta: "Draw", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16992", - Meta: "Away", - }, - }, - "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - "meta": "sample 3way market", - }) - require.Nil(s.T(), err) - - args := []string{ - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, marketcli.CmdAdd(), args) - s.Require().NoError(err) - respType := sdk.TxResponse{} - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - } - s.Require().NoError(s.network.WaitForNextBlock()) - - expectedValBalance := valBalance.Sub(sdkmath.NewInt(fees)) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - - e2esdk.SetGenericAuthorization(val, acc1, sdk.MsgTypeURL(&types.MsgDeposit{})) - s.Require().NoError(s.network.WaitForNextBlock()) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - - testCases := []struct { - name string - marketUID string - amount sdkmath.Int - ticketClaims jwt.MapClaims - args []string - expectErr bool - expectedCode uint32 - expectedErrMsg string - respType proto.Message - }{ - { - "valid transaction for acc1", - marketUID, - depositAmount, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - "depositor_address": val.Address.String(), - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, "acc1"), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - } - - for _, tc := range testCases { - s.Require().NoError(s.network.WaitForNextBlock()) - s.Run(tc.name, func() { - ticket, err := simapp.CreateJwtTicket(tc.ticketClaims) - require.Nil(s.T(), err) - - tc.args = append([]string{ - tc.marketUID, - tc.amount.String(), - ticket, - }, tc.args...) - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdDeposit(), tc.args) - - if tc.expectErr { - s.Require().Error(err) - s.T().Logf("error captured: %s", tc.name) - } else { - s.Require().NoError(err) - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), tc.respType), bz.String()) - respType, ok := tc.respType.(*sdk.TxResponse) - s.Require().True(ok) - s.Require().Equal(tc.expectedCode, respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(tc.expectedCode, txResp.Code) - if tc.expectedErrMsg != "" { - s.Require().Contains(txResp.RawLog, tc.expectedErrMsg) - } - s.T().Logf("==== success deposit create test case finished: %s", tc.name) - } - }) - } - - depositFeeAmount := sdk.NewDecFromInt(depositAmount).Mul(genesis.Params.HouseParticipationFee).TruncateInt() - - expectedValBalance = valBalance.Sub(depositAmount).Sub(depositFeeAmount) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - s.T().Logf("==== bank val balance checked after deposit to the market: %s", valBalance) - - expectedAcc1Balance := acc1Balance.Sub(sdkmath.NewInt(fees)) - acc1Balance = e2esdk.GetSGEBalance(clientCtx, acc1.String()) - s.Require().Equal(expectedAcc1Balance, acc1Balance) - s.T().Logf("==== bank acc1 balance checked after deposit to the market: %s", acc1Balance) - - depositsBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDeposits(), []string{ - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposits := types.QueryDepositsResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositsBz.Bytes(), &deposits) - require.NoError(s.T(), err) - - require.Equal(s.T(), 4, len(deposits.Deposits)) - - depositBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDepositsByAccount(), []string{ - val.Address.String(), - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposit := types.QueryDepositsByAccountResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositBz.Bytes(), &deposit) - require.NoError(s.T(), err) - - require.Equal(s.T(), []types.Deposit{ - { - Creator: val.Address.String(), - DepositorAddress: val.Address.String(), - MarketUID: marketUID, - ParticipationIndex: 1, - Amount: depositAmount, - WithdrawalCount: 0, - TotalWithdrawalAmount: sdkmath.ZeroInt(), - }, - { - Creator: acc1.String(), - DepositorAddress: val.Address.String(), - MarketUID: marketUID, - ParticipationIndex: 3, - Amount: depositAmount, - WithdrawalCount: 0, - TotalWithdrawalAmount: sdkmath.ZeroInt(), - }, - }, deposit.Deposits) - require.Equal(s.T(), val.Address.String(), deposit.Deposits[0].DepositorAddress) - s.T().Log("==== state modifications checked after deposit to the market") - - s.T().Log("==== new deposit with authorization test passed successfully") -} - -func (s *E2ETestSuite) TestWithdrawTxCmd() { - s.T().Log("==== new house deposit command test started") - val := s.network.Validators[0] - - clientCtx := val.ClientCtx - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": marketUID, - "start_ts": marketStartDate, - "end_ts": marketEndDate, - "odds": []markettypes.Odds{ - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16990", - Meta: "Home", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16991", - Meta: "Draw", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16992", - Meta: "Away", - }, - }, - "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - "meta": "sample 3way market", - }) - require.Nil(s.T(), err) - - args := []string{ - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, marketcli.CmdAdd(), args) - s.Require().NoError(err) - respType := sdk.TxResponse{} - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - } - s.Require().NoError(s.network.WaitForNextBlock()) - - expectedValBalance := valBalance.Sub(sdkmath.NewInt(fees)) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - "depositor_address": val.Address.String(), - }) - require.Nil(s.T(), err) - - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdDeposit(), []string{ - marketUID, - depositAmount.String(), - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }) - s.Require().NoError(err) - - var respType sdk.TxResponse - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(uint32(0), txResp.Code) - s.T().Logf("==== success deposit create test case finished") - } - - depositFeeAmount := sdk.NewDecFromInt(depositAmount).Mul(genesis.Params.HouseParticipationFee).TruncateInt() - - expectedValBalance = valBalance.Sub(depositAmount).Sub(depositFeeAmount).Sub(sdkmath.NewInt(fees)) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - s.T().Logf("==== bank val balance checked after deposit to the market: %s", valBalance) - - depositsBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDeposits(), []string{ - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposits := types.QueryDepositsResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositsBz.Bytes(), &deposits) - require.NoError(s.T(), err) - - require.Equal(s.T(), 5, len(deposits.Deposits)) - - depositBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDepositsByAccount(), []string{ - acc1.String(), - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposit := types.QueryDepositsByAccountResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositBz.Bytes(), &deposit) - require.NoError(s.T(), err) - - require.Equal(s.T(), []types.Deposit{ - { - Creator: acc1.String(), - DepositorAddress: acc1.String(), - MarketUID: marketUID, - ParticipationIndex: 2, - Amount: depositAmount, - WithdrawalCount: 0, - TotalWithdrawalAmount: sdkmath.ZeroInt(), - }, - }, deposit.Deposits) - require.Equal(s.T(), acc1.String(), deposit.Deposits[0].DepositorAddress) - s.T().Log("==== state modifications checked after deposit to the market") - - firstWithdrawAmount := depositAmount.Sub(sdkmath.NewInt(10)) - testCases := []struct { - name string - marketUID string - participationIndex uint64 - ticketClaims jwt.MapClaims - mode types.WithdrawalMode - amount sdkmath.Int - args []string - expectErr bool - expectedCode uint32 - expectedErrMsg string - respType proto.Message - }{ - { - "invalid transaction with large amount for val", - marketUID, - 4, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - }, - types.WithdrawalMode_WITHDRAWAL_MODE_PARTIAL, - sdkmath.NewInt(10000000000), - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - true, - 0, - "withdrawal is more than unused amount", - &sdk.TxResponse{}, - }, - { - "valid transaction for val", - marketUID, - 4, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - }, - types.WithdrawalMode_WITHDRAWAL_MODE_PARTIAL, - firstWithdrawAmount, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - { - "second valid transaction for val with the rest of the amount", - marketUID, - 4, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - }, - types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - sdkmath.Int{}, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - } - - for _, tc := range testCases { - s.Require().NoError(s.network.WaitForNextBlock()) - s.Run(tc.name, func() { - ticket, err := simapp.CreateJwtTicket(tc.ticketClaims) - require.Nil(s.T(), err) - - tc.args = append([]string{ - tc.marketUID, - cast.ToString(tc.participationIndex), - ticket, - cast.ToString(int32(tc.mode)), - tc.amount.String(), - }, tc.args...) - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdWithdraw(), tc.args) - - if tc.expectErr { - s.Require().Error(err) - s.T().Logf("error captured: %s", tc.name) - } else { - s.Require().NoError(err) - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), tc.respType), bz.String()) - respType, ok := tc.respType.(*sdk.TxResponse) - s.Require().True(ok) - s.Require().Equal(tc.expectedCode, respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(tc.expectedCode, txResp.Code) - if tc.expectedErrMsg != "" { - s.Require().Contains(txResp.RawLog, tc.expectedErrMsg) - } - s.T().Logf("==== success deposit create test case finished: %s", tc.name) - } - }) - } - - s.T().Log("==== new deposit test passed successfully") -} - -func (s *E2ETestSuite) TestWithdrawWithAuthzTxCmd() { - s.T().Log("==== new house deposit command test started") - val := s.network.Validators[0] - - clientCtx := val.ClientCtx - // { - // ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - // "exp": time.Now().Add(time.Minute * 5).Unix(), - // "iat": time.Now().Unix(), - // "uid": marketUID, - // "start_ts": marketStartDate, - // "end_ts": marketEndDate, - // "odds": []markettypes.Odds{ - // { - // UID: "9991c60f-2025-48ce-ae79-1dc110f16990", - // Meta: "Home", - // }, - // { - // UID: "9991c60f-2025-48ce-ae79-1dc110f16991", - // Meta: "Draw", - // }, - // { - // UID: "9991c60f-2025-48ce-ae79-1dc110f16992", - // Meta: "Away", - // }, - // }, - // "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - // "meta": "sample 3way market", - // }) - // require.Nil(s.T(), err) - - // args := []string{ - // ticket, - // fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - // fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - // fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - // fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - // } - // bz, err := clitestutil.ExecTestCLICmd(clientCtx, marketcli.CmdAdd(), args) - // s.Require().NoError(err) - // respType := sdk.TxResponse{} - // s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - // s.Require().Equal(uint32(0), respType.Code) - // } - // s.Require().NoError(s.network.WaitForNextBlock()) - - acc2initialBalance := 1000 - acc2 = e2esdk.CreateAccount(val, "acc2") - e2esdk.SendToken(val, acc2, acc2initialBalance) - s.Require().NoError(s.network.WaitForNextBlock()) - acc2Balance = e2esdk.GetSGEBalance(clientCtx, acc2.String()) - - e2esdk.SetGenericAuthorization(val, acc2, sdk.MsgTypeURL(&types.MsgWithdraw{})) - s.Require().NoError(s.network.WaitForNextBlock()) - - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - "depositor_address": val.Address.String(), - }) - require.Nil(s.T(), err) - - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdDeposit(), []string{ - marketUID, - depositAmount.String(), - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }) - s.Require().NoError(err) - - var respType sdk.TxResponse - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(uint32(0), txResp.Code) - s.T().Logf("==== success deposit create test case finished") - } - - depositFeeAmount := sdk.NewDecFromInt(depositAmount).Mul(genesis.Params.HouseParticipationFee).TruncateInt() - - expectedValBalance := valBalance.Sub(depositAmount).Sub(depositFeeAmount).Sub(sdkmath.NewInt(fees)) - valBalance = e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedValBalance, valBalance) - s.T().Logf("==== bank val balance checked after deposit to the market: %s", valBalance) - - depositsBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDeposits(), []string{ - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposits := types.QueryDepositsResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositsBz.Bytes(), &deposits) - require.NoError(s.T(), err) - - require.Equal(s.T(), 6, len(deposits.Deposits)) - - depositBz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.GetCmdQueryDepositsByAccount(), []string{ - val.Address.String(), - fmt.Sprintf("--%s=json", flags.FlagOutput), - }) - require.NoError(s.T(), err) - deposit := types.QueryDepositsByAccountResponse{} - err = clientCtx.Codec.UnmarshalJSON(depositBz.Bytes(), &deposit) - require.NoError(s.T(), err) - - require.Equal(s.T(), val.Address.String(), deposit.Deposits[0].DepositorAddress) - s.T().Log("==== state modifications checked after deposit to the market") - - firstWithdrawAmount := depositAmount.Sub(sdkmath.NewInt(10)) - testCases := []struct { - name string - marketUID string - participationIndex uint64 - ticketClaims jwt.MapClaims - mode types.WithdrawalMode - amount sdkmath.Int - args []string - expectErr bool - expectedCode uint32 - expectedErrMsg string - respType proto.Message - }{ - { - "valid transaction for acc2", - marketUID, - 5, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - "depositor_address": val.Address.String(), - }, - types.WithdrawalMode_WITHDRAWAL_MODE_PARTIAL, - firstWithdrawAmount, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, "acc2"), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - } - - for _, tc := range testCases { - s.Require().NoError(s.network.WaitForNextBlock()) - s.Run(tc.name, func() { - ticket, err := simapp.CreateJwtTicket(tc.ticketClaims) - require.Nil(s.T(), err) - - tc.args = append([]string{ - tc.marketUID, - cast.ToString(tc.participationIndex), - ticket, - cast.ToString(int32(tc.mode)), - tc.amount.String(), - }, tc.args...) - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdWithdraw(), tc.args) - - if tc.expectErr { - s.Require().Error(err) - s.T().Logf("error captured: %s", tc.name) - } else { - s.Require().NoError(err) - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), tc.respType), bz.String()) - respType, ok := tc.respType.(*sdk.TxResponse) - s.Require().True(ok) - s.Require().Equal(tc.expectedCode, respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(tc.expectedCode, txResp.Code) - if tc.expectedErrMsg != "" { - s.Require().Contains(txResp.RawLog, tc.expectedErrMsg) - } - s.T().Logf("==== success deposit create test case finished: %s", tc.name) - } - }) - } - - expectedAcc2Balance := acc2Balance.Sub(sdkmath.NewInt(fees)) - acc2Balance = e2esdk.GetSGEBalance(clientCtx, acc2.String()) - s.Require().Equal(expectedAcc2Balance, acc2Balance) - - s.T().Log("==== new deposit test passed successfully") -} diff --git a/tests/e2e/market/cli_test.go b/tests/e2e/market/cli_test.go deleted file mode 100644 index 18c7022a..00000000 --- a/tests/e2e/market/cli_test.go +++ /dev/null @@ -1,16 +0,0 @@ -package client_test - -import ( - "testing" - - "github.com/stretchr/testify/suite" - - client "github.com/sge-network/sge/tests/e2e/market" - "github.com/sge-network/sge/testutil/network" -) - -func TestE2ETestSuite(t *testing.T) { - cfg := network.DefaultConfig() - cfg.NumValidators = 1 - suite.Run(t, client.NewE2ETestSuite(cfg)) -} diff --git a/tests/e2e/market/grpc.go b/tests/e2e/market/grpc.go deleted file mode 100644 index 872c396c..00000000 --- a/tests/e2e/market/grpc.go +++ /dev/null @@ -1,47 +0,0 @@ -package client - -import ( - "fmt" - - "github.com/cosmos/gogoproto/proto" - - "github.com/cosmos/cosmos-sdk/testutil" - grpctypes "github.com/cosmos/cosmos-sdk/types/grpc" - - "github.com/sge-network/sge/x/market/types" -) - -func (s *E2ETestSuite) TestMarketsGRPCHandler() { - val := s.network.Validators[0] - baseURL := val.APIAddress - - testCases := []struct { - name string - url string - headers map[string]string - respType proto.Message - expected proto.Message - }{ - { - "test GRPC Market by UID", - fmt.Sprintf("%s/sge/market/%s", baseURL, dummyMarketUID), - map[string]string{ - grpctypes.GRPCBlockHeightHeader: "1", - }, - &types.QueryMarketResponse{}, - &types.QueryMarketResponse{ - Market: dummyMarket, - }, - }, - } - - for _, tc := range testCases { - s.Run(tc.name, func() { - resp, err := testutil.GetRequestWithHeaders(tc.url, tc.headers) - s.Require().NoError(err) - - s.Require().NoError(val.ClientCtx.Codec.UnmarshalJSON(resp, tc.respType)) - s.Require().Equal(tc.expected.String(), tc.respType.String()) - }) - } -} diff --git a/tests/e2e/market/suite.go b/tests/e2e/market/suite.go deleted file mode 100644 index 3e167ec6..00000000 --- a/tests/e2e/market/suite.go +++ /dev/null @@ -1,212 +0,0 @@ -package client - -import ( - "fmt" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - "github.com/stretchr/testify/suite" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/gogoproto/proto" - - e2esdk "github.com/sge-network/sge/tests/e2e/sdk" - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/market/client/cli" - "github.com/sge-network/sge/x/market/types" -) - -var ( - genesis types.GenesisState - - dummyMarket = types.Market{} - dummyMarketUID = uuid.NewString() - - oddsUID1 = "9991c60f-2025-48ce-ae79-1dc110f16900" - oddsUID2 = "9991c60f-2025-48ce-ae79-1dc110f16901" - oddsUID3 = "9991c60f-2025-48ce-ae79-1dc110f16902" - - fees = int64(10) - marketUID = uuid.NewString() - marketStartDate = uint64(time.Now().Unix()) - marketEndDate = uint64(time.Now().Add(time.Minute * time.Duration(120)).Unix()) -) - -type E2ETestSuite struct { - suite.Suite - - cfg network.Config - network *network.Network -} - -func NewE2ETestSuite(cfg network.Config) *E2ETestSuite { - return &E2ETestSuite{cfg: cfg} -} - -func (s *E2ETestSuite) SetupSuite() { - s.T().Log("setting up e2e test suite") - - genesisState := s.cfg.GenesisState - - s.Require().NoError(s.cfg.Codec.UnmarshalJSON(genesisState[types.ModuleName], &genesis)) - - dummyMarket = types.Market{ - Creator: sample.AccAddress(), - UID: dummyMarketUID, - StartTS: uint64(time.Now().Unix()), - EndTS: uint64(time.Now().Add(time.Minute * time.Duration(120)).Unix()), - Odds: []*types.Odds{ - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16904", - Meta: "Home", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16905", - Meta: "Draw", - }, - { - UID: "9991c60f-2025-48ce-ae79-1dc110f16906", - Meta: "Away", - }, - }, - WinnerOddsUIDs: []string{}, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "dummy market", - BookUID: dummyMarketUID, - } - genesis.MarketList = []types.Market{dummyMarket} - - genesis.Stats = types.MarketStats{ - // ResolvedUnsettled: []string{dummyMarketUID}, - } - - // genesis.Params = types.Params{} - - genesisBz, err := s.cfg.Codec.MarshalJSON(&genesis) - s.Require().NoError(err) - genesisState[types.ModuleName] = genesisBz - s.cfg.GenesisState = genesisState - - s.network = network.New(s.T(), s.cfg) - - s.Require().NoError(s.network.WaitForNextBlock()) -} - -func (s *E2ETestSuite) TestMarketAddTxCmd() { - val := s.network.Validators[0] - - clientCtx := val.ClientCtx - - valBalance := e2esdk.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(sdkmath.NewInt(400000000), valBalance) - - testCases := []struct { - name string - ticketClaims jwt.MapClaims - args []string - expectErr bool - expectedCode uint32 - expectedErrMsg string - respType proto.Message - }{ - { - "invalid transaction for val", - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": marketUID, - "start_ts": marketStartDate, - "end_ts": marketEndDate, - "odds": []types.Odds{}, - "status": types.MarketStatus_MARKET_STATUS_ACTIVE, - "meta": "sample 3way market", - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - true, - 0, - "", - &sdk.TxResponse{}, - }, - { - "valid transaction for val", - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": marketUID, - "start_ts": marketStartDate, - "end_ts": marketEndDate, - "odds": []types.Odds{ - { - UID: oddsUID1, - Meta: "Home", - }, - { - UID: oddsUID2, - Meta: "Draw", - }, - { - UID: oddsUID3, - Meta: "Away", - }, - }, - "status": types.MarketStatus_MARKET_STATUS_ACTIVE, - "meta": "sample 3way market", - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagGas, flags.GasFlagAuto), - fmt.Sprintf("--%s=%s", flags.FlagGasAdjustment, "1.15"), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(fees))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - } - - for _, tc := range testCases { - s.Require().NoError(s.network.WaitForNextBlock()) - s.Run(tc.name, func() { - ticket, err := simapp.CreateJwtTicket(tc.ticketClaims) - require.Nil(s.T(), err) - - tc.args = append([]string{ticket}, tc.args...) - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdAdd(), tc.args) - - if tc.expectErr { - s.Require().Error(err) - s.T().Logf("error captured: %s", tc.name) - } else { - s.Require().NoError(err) - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), tc.respType), bz.String()) - respType, ok := tc.respType.(*sdk.TxResponse) - s.Require().True(ok) - s.Require().Equal(tc.expectedCode, respType.Code) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(tc.expectedCode, txResp.Code) - if tc.expectedErrMsg != "" { - s.Require().Contains(txResp.RawLog, tc.expectedErrMsg) - } - } - }) - } -} diff --git a/tests/e2e/reward/cli_test.go b/tests/e2e/reward/cli_test.go deleted file mode 100644 index 06d65961..00000000 --- a/tests/e2e/reward/cli_test.go +++ /dev/null @@ -1,16 +0,0 @@ -package client_test - -import ( - "testing" - - "github.com/stretchr/testify/suite" - - client "github.com/sge-network/sge/tests/e2e/reward" - "github.com/sge-network/sge/testutil/network" -) - -func TestE2ETestSuite(t *testing.T) { - cfg := network.DefaultConfig() - cfg.NumValidators = 1 - suite.Run(t, client.NewE2ETestSuite(cfg)) -} diff --git a/tests/e2e/reward/grpc.go b/tests/e2e/reward/grpc.go deleted file mode 100644 index da13c8ef..00000000 --- a/tests/e2e/reward/grpc.go +++ /dev/null @@ -1 +0,0 @@ -package client diff --git a/tests/e2e/reward/suite.go b/tests/e2e/reward/suite.go deleted file mode 100644 index 8f792e15..00000000 --- a/tests/e2e/reward/suite.go +++ /dev/null @@ -1,279 +0,0 @@ -package client - -import ( - "fmt" - "time" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/gogoproto/proto" - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - "github.com/stretchr/testify/suite" - - sdkcli "github.com/sge-network/sge/tests/e2e/sdk" - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/reward/client/cli" - "github.com/sge-network/sge/x/reward/types" - subaccountcli "github.com/sge-network/sge/x/subaccount/client/cli" - subaccounttypes "github.com/sge-network/sge/x/subaccount/types" -) - -var ( - genesis types.GenesisState - fees = int64(10) - promoterUID = uuid.NewString() - campaignStartDate = uint64(time.Now().Unix()) - campaignEndDate = time.Now().Add(time.Minute * time.Duration(120)).Unix() - campaignFunds = sdkmath.NewInt(100000000) -) - -type E2ETestSuite struct { - suite.Suite - - cfg network.Config - network *network.Network -} - -func NewE2ETestSuite(cfg network.Config) *E2ETestSuite { - return &E2ETestSuite{cfg: cfg} -} - -func (s *E2ETestSuite) SetupSuite() { - s.T().Log("setting up e2e test suite") - - genesisState := s.cfg.GenesisState - s.Require().NoError(s.cfg.Codec.UnmarshalJSON(genesisState[types.ModuleName], &genesis)) - - genesisBz, err := s.cfg.Codec.MarshalJSON(&genesis) - s.Require().NoError(err) - genesisState[types.ModuleName] = genesisBz - s.cfg.GenesisState = genesisState - - s.network = network.New(s.T(), s.cfg) - s.Require().NoError(s.network.WaitForNextBlock()) -} - -func (s *E2ETestSuite) TestNewCampaignTxCmd() { - s.T().Log("==== new campaign create command test started") - val := s.network.Validators[0] - - clientCtx := val.ClientCtx - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "uid": promoterUID, - "conf": types.PromoterConf{ - CategoryCap: []types.CategoryCap{{ - Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, - CapPerAcc: 1, - }}, - }, - }) - require.Nil(s.T(), err) - - args := []string{ - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(10))).String()), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdCreatePromoter(), args) - s.Require().NoError(err) - respType := sdk.TxResponse{} - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - s.Require().Equal(uint32(0), respType.Code) - } - - valBalance := sdkcli.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(sdkmath.NewInt(400000000), valBalance) - - campaignUID := uuid.NewString() - testCases := []struct { - name string - uid string - totalFunds sdkmath.Int - ticketClaims jwt.MapClaims - args []string - expectErr bool - expectedCode uint32 - expectedErrMsg string - respType proto.Message - }{ - { - "not enough balance to charge pool", - campaignUID, - sdkmath.NewInt(4000000000), - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": val.Address, - "start_ts": campaignStartDate, - "end_ts": campaignEndDate, - "category": types.RewardCategory_REWARD_CATEGORY_SIGNUP, - "reward_type": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_amount_type": types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED, - "reward_amount": types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(1000), - }, - "is_active": true, - "meta": "sample signup campaign", - "cap_count": 1, - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(10))).String()), - }, - false, - types.ErrInFundingCampaignPool.ABCICode(), - "", - &sdk.TxResponse{}, - }, - { - "valid transaction", - campaignUID, - campaignFunds, - jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": val.Address, - "start_ts": campaignStartDate, - "end_ts": campaignEndDate, - "category": types.RewardCategory_REWARD_CATEGORY_SIGNUP, - "reward_type": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_amount_type": types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED, - "reward_amount": types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(1000), - }, - "is_active": true, - "meta": "sample signup campaign", - "cap_count": 1, - }, - []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(10))).String()), - }, - false, - 0, - "", - &sdk.TxResponse{}, - }, - } - - for _, tc := range testCases { - s.Require().NoError(s.network.WaitForNextBlock()) - s.Run(tc.name, func() { - clientCtx := val.ClientCtx - - ticket, err := simapp.CreateJwtTicket(tc.ticketClaims) - require.Nil(s.T(), err) - - tc.args = append([]string{ - tc.uid, - tc.totalFunds.String(), - ticket, - }, tc.args...) - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdCreateCampaign(), tc.args) - - if tc.expectErr { - s.Require().Error(err) - s.T().Logf("error captured: %s", tc.name) - } else { - s.Require().NoError(err) - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), tc.respType), bz.String()) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, tc.respType.(*sdk.TxResponse).TxHash) - s.Require().NoError(err) - s.Require().Equal(tc.expectedCode, txResp.Code) - if tc.expectedErrMsg != "" { - s.Require().Contains(txResp.RawLog, tc.expectedErrMsg) - } - s.T().Logf("==== success campaign create test case finished: %s", tc.name) - } - }) - } - - s.Require().NoError(s.network.WaitForNextBlock()) - expectedBalance := valBalance.Sub(campaignFunds).Sub(sdk.NewInt(fees * 3)) - valBalance = sdkcli.GetSGEBalance(clientCtx, val.Address.String()) - s.Require().Equal(expectedBalance, valBalance) - s.T().Logf("==== bank balance checked after creating the campaign: %s", valBalance) - - { - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: val.Address.String(), - SourceUID: "", - Meta: "signup reward campaign", - KycData: &sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: val.Address.String(), - }, - }, - }) - require.Nil(s.T(), err) - - rewardUID := uuid.NewString() - args := []string{ - rewardUID, - campaignUID, - ticket, - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(s.cfg.BondDenom, sdkmath.NewInt(10))).String()), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, cli.CmdGrantReward(), args) - s.Require().NoError(err) - respType := sdk.TxResponse{} - - s.Require().NoError(clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType), bz.String()) - - txResp, err := clitestutil.GetTxResponse(s.network, clientCtx, respType.TxHash) - s.Require().NoError(err) - s.Require().Equal(uint32(0), txResp.Code) - s.T().Logf("==== success reward grant test case finished: %s", rewardUID) - } - - valBalance = sdkcli.GetSGEBalance(clientCtx, val.Address.String()) - expectedBalance = expectedBalance.Sub(sdkmath.NewInt(10)) - s.Require().Equal(expectedBalance, valBalance) - s.T().Logf("==== bank balance checked after creating the campaign: %s", valBalance) - - args := []string{ - val.Address.String(), - fmt.Sprintf("--%s=json", flags.FlagOutput), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, subaccountcli.QuerySubaccount(), args) - if err != nil { - panic(err) - } - respType := subaccounttypes.QuerySubaccountResponse{} - err = clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType) - if err != nil { - panic(err) - } - - subaccountBalance := sdkcli.GetSGEBalance(clientCtx, respType.Address) - s.Require().Equal(sdkmath.NewInt(100), subaccountBalance) - s.T().Logf("==== bank balance checked after creating the campaign: %s", subaccountBalance) - - s.T().Log("==== new campaign create command test passed successfully") -} diff --git a/tests/e2e/sdk/account.go b/tests/e2e/sdk/account.go deleted file mode 100644 index 00083d0e..00000000 --- a/tests/e2e/sdk/account.go +++ /dev/null @@ -1,23 +0,0 @@ -package sdk - -import ( - "github.com/cosmos/cosmos-sdk/crypto/hd" - "github.com/cosmos/cosmos-sdk/crypto/keyring" - sdknetwork "github.com/cosmos/cosmos-sdk/testutil/network" - sdk "github.com/cosmos/cosmos-sdk/types" -) - -func CreateAccount(val *sdknetwork.Validator, uid string) sdk.AccAddress { - // Create new account in the keyring. - k, _, err := val.ClientCtx.Keyring.NewMnemonic(uid, keyring.English, sdk.FullFundraiserPath, keyring.DefaultBIP39Passphrase, hd.Secp256k1) - if err != nil { - panic(err) - } - - addr, err := k.GetAddress() - if err != nil { - panic(err) - } - - return addr -} diff --git a/tests/e2e/sdk/auth.go b/tests/e2e/sdk/auth.go deleted file mode 100644 index a0873195..00000000 --- a/tests/e2e/sdk/auth.go +++ /dev/null @@ -1,40 +0,0 @@ -package sdk - -import ( - "fmt" - "strings" - "time" - - "github.com/cosmos/cosmos-sdk/client/flags" - sdknetwork "github.com/cosmos/cosmos-sdk/testutil/network" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/authz/client/cli" - authzclitestutil "github.com/cosmos/cosmos-sdk/x/authz/client/testutil" - "github.com/sge-network/sge/app/params" -) - -func SetGenericAuthorization(val *sdknetwork.Validator, grantee sdk.AccAddress, typeMsg string) { - twoHours := time.Now().Add(time.Minute * 120).Unix() - - // Send some funds to the new account. - out, err := authzclitestutil.CreateGrant( - val.ClientCtx, - []string{ - grantee.String(), - "generic", - fmt.Sprintf("--%s=%s", cli.FlagMsgType, typeMsg), - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%d", cli.FlagExpiration, twoHours), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, fees)).String()), - }, - ) - if err != nil { - panic(err) - } - - if !strings.Contains(out.String(), `"code":0`) { - panic(fmt.Sprintf("failed to send tokens: %s", out.String())) - } -} diff --git a/tests/e2e/sdk/balance.go b/tests/e2e/sdk/balance.go deleted file mode 100644 index 170f57a5..00000000 --- a/tests/e2e/sdk/balance.go +++ /dev/null @@ -1,54 +0,0 @@ -package sdk - -import ( - "fmt" - "strings" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdknetwork "github.com/cosmos/cosmos-sdk/testutil/network" - sdk "github.com/cosmos/cosmos-sdk/types" - bankcli "github.com/cosmos/cosmos-sdk/x/bank/client/cli" - "github.com/sge-network/sge/app/params" -) - -func GetSGEBalance(clientCtx client.Context, address string) sdkmath.Int { - args := []string{ - address, - fmt.Sprintf("--%s=json", flags.FlagOutput), - fmt.Sprintf("--%s=usge", bankcli.FlagDenom), - } - bz, err := clitestutil.ExecTestCLICmd(clientCtx, bankcli.GetBalancesCmd(), args) - if err != nil { - panic(err) - } - respType := sdk.Coin{} - err = clientCtx.Codec.UnmarshalJSON(bz.Bytes(), &respType) - if err != nil { - panic(err) - } - - return respType.Amount -} - -func SendToken(val *sdknetwork.Validator, acc sdk.AccAddress, amount int) { - // Send some funds to the new account. - out, err := clitestutil.MsgSendExec( - val.ClientCtx, - val.Address, - acc, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(int64(amount)))), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf("--%s=%s", flags.FlagFees, sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, fees)).String()), - ) - if err != nil { - panic(err) - } - - if !strings.Contains(out.String(), `"code":0`) { - panic(fmt.Sprintf("failed to send tokens: %s", out.String())) - } -} diff --git a/tests/e2e/sdk/consts.go b/tests/e2e/sdk/consts.go deleted file mode 100644 index 494cb602..00000000 --- a/tests/e2e/sdk/consts.go +++ /dev/null @@ -1,5 +0,0 @@ -package sdk - -import sdkmath "cosmossdk.io/math" - -var fees = sdkmath.NewInt(10) diff --git a/testutil/network/network.go b/testutil/network/network.go deleted file mode 100644 index 95a61f03..00000000 --- a/testutil/network/network.go +++ /dev/null @@ -1,222 +0,0 @@ -package network - -import ( - "fmt" - "testing" - "time" - - tmdb "github.com/cometbft/cometbft-db" - tmrand "github.com/cometbft/cometbft/libs/rand" - "github.com/cosmos/cosmos-sdk/baseapp" - "github.com/cosmos/cosmos-sdk/crypto/hd" - "github.com/cosmos/cosmos-sdk/crypto/keyring" - servertypes "github.com/cosmos/cosmos-sdk/server/types" - pruningtypes "github.com/cosmos/cosmos-sdk/store/pruning/types" - "github.com/cosmos/cosmos-sdk/testutil/network" - simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - - wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/simapp" - ovmtypes "github.com/sge-network/sge/x/ovm/types" -) - -type ( - // Network represents network for simulations - Network = network.Network - // Config represents configurations of simulations - Config = network.Config -) - -// New creates instance with fully configured cosmos network. -// Accepts optional config, that will be used in place of the DefaultConfig() if provided. -func New(t *testing.T, configs ...network.Config) *network.Network { - if len(configs) > 1 { - panic("at most one config should be provided") - } - var cfg network.Config - if len(configs) == 0 { - cfg = DefaultConfig() - } else { - cfg = configs[0] - } - // baseDir := t.TempDir() - - // nodeDirName := fmt.Sprintf("node%d", 0) - // node0Dir := filepath.Join(baseDir, nodeDirName, "simcli") - - // buf := bufio.NewReader(os.Stdin) - // kb, err := keyring.New(sdk.KeyringServiceName(), keyring.BackendTest, node0Dir, buf, cfg.Codec, cfg.KeyringOptions...) - // if err != nil { - // panic(err) - // } - - // keyringAlgos, _ := kb.SupportedAlgorithms() - // algo, err := keyring.NewSigningAlgoFromString(cfg.SigningAlgo, keyringAlgos) - // if err != nil { - // panic(err) - // } - - // addr, secret, err := testutil.GenerateSaveCoinKey(kb, nodeDirName, "", true, algo) - // if err != nil { - // panic(err) - // } - - // info := map[string]string{"secret": secret} - // infoBz, err := json.Marshal(info) - // if err != nil { - // panic(err) - // } - - // // save private key seed words - // err = simapp.WriteKeyringFile(fmt.Sprintf("%v.json", "key_seed"), node0Dir, infoBz) - // if err != nil { - // panic(err) - // } - - net, err := network.New(t, t.TempDir(), cfg) - if err != nil { - panic(err) - } - - t.Cleanup(net.Cleanup) - return net -} - -// DefaultConfig will initialize config for the network with custom application, -// genesis and single validator. All other parameters are inherited from cosmos-sdk/testutil/network.DefaultConfig -func DefaultConfig() network.Config { - var ( - encoding = app.MakeEncodingConfig() - chainID = "chain-" + tmrand.NewRand().Str(6) - ) - - // simapp.GenerateSimappUsers() - - // Initialize test app by genesis account - // genAccs := simapp.GenerateSimappGenesisAccounts() - - // Create testapp instance - // balances := simapp.GenerateSimappUserBalances() - - defGen := app.ModuleBasics.DefaultGenesis(encoding.Marshaler) - { - // modify the staking denom in the genesis - stakingGenState := defGen[stakingtypes.ModuleName] - var newStakingGenState stakingtypes.GenesisState - - if err := encoding.Marshaler.UnmarshalJSON(stakingGenState, &newStakingGenState); err != nil { - panic(err) - } - - // change to default bond denom - newStakingGenState.Params.BondDenom = params.DefaultBondDenom - - var err error - defGen[stakingtypes.ModuleName], err = encoding.Marshaler.MarshalJSON(&newStakingGenState) - if err != nil { - panic(err) - } - } - // { - // authGenState := defGen[authtypes.ModuleName] - // var newAuthGenState authtypes.GenesisState - - // if err := encoding.Marshaler.UnmarshalJSON(authGenState, &newAuthGenState); err != nil { - // panic(err) - // } - - // for _, v := range genAccs { - // anyVal, err := codectypes.NewAnyWithValue(v) - // if err != nil { - // panic(err) - // } - // newAuthGenState.Accounts = append(newAuthGenState.Accounts, anyVal) - // } - - // var err error - // defGen[authtypes.ModuleName], err = encoding.Marshaler.MarshalJSON(&newAuthGenState) - // if err != nil { - // panic(err) - // } - // } - // { - // bankGenState := defGen[banktypes.ModuleName] - // var newBankGenState banktypes.GenesisState - - // if err := encoding.Marshaler.UnmarshalJSON(bankGenState, &newBankGenState); err != nil { - // panic(err) - // } - - // newBankGenState.Balances = append(newBankGenState.Balances, balances...) - - // // totalSupply := sdk.NewCoins() - // // for _, b := range balances { - // // totalSupply = totalSupply.Add(b.Coins...) - // // } - // // newBankGenState.Supply = totalSupply - - // var err error - // defGen[banktypes.ModuleName], err = encoding.Marshaler.MarshalJSON(&newBankGenState) - // if err != nil { - // panic(err) - // } - - // // stateBytes, err := json.MarshalIndent(genesisState, "", " ") - // // if err != nil { - // // panic(err) - // // } - // } - - { - ovmGenesisState := &ovmtypes.GenesisState{ - KeyVault: ovmtypes.KeyVault{ - PublicKeys: simapp.GenerateOvmPublicKeys(ovmtypes.MinPubKeysCount), - }, - } - defGen[ovmtypes.ModuleName] = encoding.Marshaler.MustMarshalJSON(ovmGenesisState) - } - - return network.Config{ - Codec: encoding.Marshaler, - TxConfig: encoding.TxConfig, - LegacyAmino: encoding.Amino, - InterfaceRegistry: encoding.InterfaceRegistry, - AccountRetriever: authtypes.AccountRetriever{}, - AppConstructor: func(val network.ValidatorI) servertypes.Application { - return app.NewSgeApp( - val.GetCtx().Logger, - tmdb.NewMemDB(), - nil, - true, - map[int64]bool{}, - val.GetCtx().Config.RootDir, - 0, - encoding, - simtestutil.EmptyAppOptions{}, - []wasmkeeper.Option{}, - baseapp.SetPruning(pruningtypes.NewPruningOptionsFromString(val.GetAppConfig().Pruning)), - baseapp.SetMinGasPrices(val.GetAppConfig().MinGasPrices), - baseapp.SetChainID(chainID), - ) - }, - GenesisState: defGen, - TimeoutCommit: 2 * time.Second, - ChainID: chainID, - NumValidators: 1, - BondDenom: params.DefaultBondDenom, - MinGasPrices: fmt.Sprintf("0.000006%s", params.DefaultBondDenom), - AccountTokens: sdk.TokensFromConsensusPower(1000, sdk.DefaultPowerReduction), - StakingTokens: sdk.TokensFromConsensusPower(500, sdk.DefaultPowerReduction), - BondedTokens: sdk.TokensFromConsensusPower(100, sdk.DefaultPowerReduction), - PruningStrategy: pruningtypes.PruningOptionNothing, - CleanupDir: true, - SigningAlgo: string(hd.Secp256k1Type), - KeyringOptions: []keyring.Option{}, - } -} diff --git a/testutil/nullify/nullify.go b/testutil/nullify/nullify.go deleted file mode 100644 index 2ac4b41b..00000000 --- a/testutil/nullify/nullify.go +++ /dev/null @@ -1,59 +0,0 @@ -// Package nullify provides methods to init nil values structs for test assertion. -package nullify - -import ( - "reflect" - "unsafe" - - sdk "github.com/cosmos/cosmos-sdk/types" -) - -var ( - coinType = reflect.TypeOf(sdk.Coin{}) - coinsType = reflect.TypeOf(sdk.Coins{}) -) - -// Fill analyze all struct fields and slices with -// reflection and initialize the nil and empty slices, -// structs, and pointers. -func Fill(x interface{}) interface{} { - v := reflect.Indirect(reflect.ValueOf(x)) - switch v.Kind() { - case reflect.Slice: - for i := 0; i < v.Len(); i++ { - obj := v.Index(i) - - objPt := reflect.NewAt(obj.Type(), unsafe.Pointer(obj.UnsafeAddr())).Interface() - objPt = Fill(objPt) - obj.Set(reflect.ValueOf(objPt)) - } - case reflect.Struct: - for i := 0; i < v.NumField(); i++ { - f := reflect.Indirect(v.Field(i)) - if !f.CanSet() { - continue - } - switch f.Kind() { - case reflect.Slice: - f.Set(reflect.MakeSlice(f.Type(), 0, 0)) - case reflect.Struct: - switch f.Type() { - case coinType: - coin := reflect.New(coinType).Interface() - s := reflect.ValueOf(coin).Elem() - f.Set(s) - case coinsType: - coins := reflect.New(coinsType).Interface() - s := reflect.ValueOf(coins).Elem() - f.Set(s) - default: - - objPt := reflect.NewAt(f.Type(), unsafe.Pointer(f.UnsafeAddr())).Interface() - s := Fill(objPt) - f.Set(reflect.ValueOf(s)) - } - } - } - } - return reflect.Indirect(v).Interface() -} diff --git a/testutil/sample/sample.go b/testutil/sample/sample.go index aa98dd16..98f2153e 100644 --- a/testutil/sample/sample.go +++ b/testutil/sample/sample.go @@ -5,20 +5,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" ) -// AccAddress returns a sample account address as string +// AccAddress returns a sample account address func AccAddress() string { - return NativeAccAddress().String() -} - -func NativeAccAddress() sdk.AccAddress { pk := ed25519.GenPrivKey().PubKey() addr := pk.Address() - return sdk.AccAddress(addr) -} - -// ValAddress returns a sample validator address -func ValAddress() string { - pk := ed25519.GenPrivKey().PubKey() - addr, _ := sdk.Bech32ifyAddressBytes("cosmosvaloper", pk.Address().Bytes()) - return addr + return sdk.AccAddress(addr).String() } diff --git a/testutil/simapp/params.go b/testutil/simapp/params.go deleted file mode 100644 index 41bc5db6..00000000 --- a/testutil/simapp/params.go +++ /dev/null @@ -1,46 +0,0 @@ -package simapp - -import ( - "crypto/ed25519" - - sdkmath "cosmossdk.io/math" - "github.com/cometbft/cometbft/crypto/secp256k1" - "github.com/cosmos/cosmos-sdk/crypto/types" - sdk "github.com/cosmos/cosmos-sdk/types" -) - -const ( - usernamePrefix = "user" -) - -// TestUser is simapp user type for testing -type TestUser struct { - PrvKey secp256k1.PrivKey - Address sdk.AccAddress - Balance int64 -} - -// TestValidator is simapp validator type for testing -type TestValidator struct { - PubKey types.PubKey - Address sdk.ValAddress - ConsAddress sdk.ConsAddress - Power sdkmath.Int -} - -var ( - // TestParamUsers represents the map of simapp users - TestParamUsers = make(map[string]TestUser) - - // TestParamValidatorAddresses represents the map of test validators - TestParamValidatorAddresses = make(map[string]TestValidator) - - // TestOVMPublicKeys represents test public keys needed for ovm - TestOVMPublicKeys []ed25519.PublicKey - - // TestOVMPrivateKeys represents test private keys needed for ovm - TestOVMPrivateKeys []ed25519.PrivateKey -) - -// GenesisModuleAccountsBalances holds the test genesis module accounts balance map. -var GenesisModuleAccountsBalances = map[string]int64{} diff --git a/testutil/simapp/simapp.go b/testutil/simapp/simapp.go deleted file mode 100644 index 8f68e3dd..00000000 --- a/testutil/simapp/simapp.go +++ /dev/null @@ -1,405 +0,0 @@ -package simapp - -import ( - "crypto/ed25519" - "crypto/rand" - "crypto/x509" - "encoding/json" - "testing" - "time" - - sdkmath "cosmossdk.io/math" - tmdb "github.com/cometbft/cometbft-db" - abci "github.com/cometbft/cometbft/abci/types" - "github.com/cometbft/cometbft/crypto/secp256k1" - "github.com/cometbft/cometbft/libs/log" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - tmtypes "github.com/cometbft/cometbft/types" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - stakingKeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" - stakingtestutil "github.com/cosmos/cosmos-sdk/x/staking/testutil" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - - wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/utils" - mintmoduletypes "github.com/sge-network/sge/x/mint/types" - ovmtypes "github.com/sge-network/sge/x/ovm/types" - "github.com/spf13/cast" -) - -// TestApp is used as a container of the sge app -type TestApp struct { - app.SgeApp -} - -// Options defines options related to simapp initialization -type Options struct { - CreateGenesisValidators bool -} - -// setup initializes new test app instance -func setup(withGenesis bool, invCheckPeriod uint) (*TestApp, app.GenesisState) { - db := tmdb.NewMemDB() - encCdc := app.MakeEncodingConfig() - appInstance := app.NewSgeApp( - log.NewNopLogger(), - db, - nil, - true, - map[int64]bool{}, - "", - invCheckPeriod, - encCdc, - simtestutil.EmptyAppOptions{}, - []wasmkeeper.Option{}, - ) - if withGenesis { - return &TestApp{SgeApp: *appInstance}, app.NewDefaultGenesisState() - } - return &TestApp{SgeApp: *appInstance}, app.GenesisState{} -} - -// SetupWithGenesisAccounts sets up the genesis accounts for testing -func SetupWithGenesisAccounts( - genAccs []authtypes.GenesisAccount, - options Options, - balances ...banktypes.Balance, -) *TestApp { - appInstance, genesisState := setup(true, 0) - - authGenesis := authtypes.NewGenesisState(authtypes.DefaultParams(), genAccs) - genesisState[authtypes.ModuleName] = appInstance.AppCodec().MustMarshalJSON(authGenesis) - - var validatorUpdates []abci.ValidatorUpdate - if options.CreateGenesisValidators { - var moduleBalance banktypes.Balance - var stakingGenesis *stakingtypes.GenesisState - - stakingGenesis, validatorUpdates, moduleBalance = stakingDefaultTestGenesis(appInstance) - genesisState[stakingtypes.ModuleName] = appInstance.AppCodec().MustMarshalJSON(stakingGenesis) - - balances = append(balances, moduleBalance) - } - - totalSupply := sdk.NewCoins() - for _, b := range balances { - totalSupply = totalSupply.Add(b.Coins...) - } - - bankGenesis := banktypes.NewGenesisState( - banktypes.DefaultGenesisState().Params, - balances, - totalSupply, - []banktypes.Metadata{}, - []banktypes.SendEnabled{}, - ) - genesisState[banktypes.ModuleName] = appInstance.AppCodec().MustMarshalJSON(bankGenesis) - - { - publicKeys := GenerateOvmPublicKeys(ovmtypes.MinPubKeysCount) - - ovmGenesisState := &ovmtypes.GenesisState{ - KeyVault: ovmtypes.KeyVault{ - PublicKeys: publicKeys, - }, - } - genesisState[ovmtypes.ModuleName] = appInstance.AppCodec().MustMarshalJSON(ovmGenesisState) - } - - stateBytes, err := json.MarshalIndent(genesisState, "", " ") - if err != nil { - panic(err) - } - - appInstance.InitChain( - abci.RequestInitChain{ - Validators: validatorUpdates, - ConsensusParams: DefaultConsensusParams, - AppStateBytes: stateBytes, - }, - ) - - appInstance.Commit() - appInstance.BeginBlock( - abci.RequestBeginBlock{Header: tmproto.Header{ - Height: appInstance.LastBlockHeight() + 1, - AppHash: appInstance.LastCommitID().Hash, - }}, - ) - - return appInstance -} - -// GetTestObjects gets the test objects and ingredients for testing phase start with default options -func GetTestObjects() (*TestApp, sdk.Context, error) { - // return - return GetTestObjectsWithOptions(Options{ - CreateGenesisValidators: true, - }) -} - -// GetTestObjectsWithOptions gets the test objects and ingredients for testing phase start with custom options -func GetTestObjectsWithOptions(options Options) (*TestApp, sdk.Context, error) { - generateSimappUsers() - - // Initialize test app by genesis account - genAccs := generateSimappGenesisAccounts() - - // Create testapp instance - balances := generateSimappUserBalances() - - tApp := SetupWithGenesisAccounts(genAccs, options, balances...) - - // Create the context - ctx := tApp.NewContext(true, tmproto.Header{Height: tApp.LastBlockHeight()}) - - setMinterParams(tApp, ctx) - - if err := generateSimappAccountCoins(&ctx, tApp); err != nil { - return &TestApp{}, sdk.Context{}, err - } - - return tApp, ctx, nil -} - -func setMinterParams(tApp *TestApp, ctx sdk.Context) { - tApp.MintKeeper.SetParams(ctx, mintmoduletypes.DefaultParams()) - tApp.MintKeeper.SetMinter(ctx, mintmoduletypes.DefaultInitialMinter()) -} - -func generateSimappUsers() { - createIncrementalAccounts(10) - for i := 0; i < 10; i++ { - prvKey := secp256k1.GenPrivKey() - TestParamUsers[usernamePrefix+cast.ToString(i)] = TestUser{ - PrvKey: prvKey, - Address: sdk.AccAddress(prvKey.PubKey().Address()), - Balance: 1000000000, - } - } -} - -func generateSimappUserBalances() (balances []banktypes.Balance) { - genTokens := sdk.TokensFromConsensusPower(1, sdk.DefaultPowerReduction) - genCoin := sdk.NewCoin(params.DefaultBondDenom, genTokens) - sdkgenCoin := sdk.NewCoin(sdk.DefaultBondDenom, sdkmath.NewInt(1000000000)) - for _, v := range TestParamUsers { - balances = append(balances, banktypes.Balance{ - Address: v.Address.String(), - Coins: sdk.Coins{sdkgenCoin, genCoin}, - }) - } - return balances -} - -func generateSimappGenesisAccounts() (genAccs []authtypes.GenesisAccount) { - for _, v := range TestParamUsers { - genAccs = append(genAccs, &authtypes.BaseAccount{Address: v.Address.String()}) - } - return genAccs -} - -func generateSimappAccountCoins(ctx *sdk.Context, tApp *TestApp) error { - for _, v := range TestParamUsers { - if err := SetAccountCoins(ctx, tApp.BankKeeper, v.Address, v.Balance); err != nil { - return err - } - } - return nil -} - -// SetAccountCoins sets the balance of accounts for testing -func SetAccountCoins(ctx *sdk.Context, k bankkeeper.Keeper, addr sdk.AccAddress, amount int64) error { - coin := sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(amount))) - err := k.MintCoins(*ctx, mintmoduletypes.ModuleName, coin) - if err != nil { - return err - } - err = k.SendCoinsFromModuleToAccount(*ctx, mintmoduletypes.ModuleName, addr, coin) - if err != nil { - return err - } - return nil -} - -// SetModuleAccountCoins sets the balance of accounts for testing -func SetModuleAccountCoins( - ctx *sdk.Context, - k bankkeeper.Keeper, - moduleName string, - amount int64, -) error { - coin := sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(amount))) - err := k.MintCoins(*ctx, mintmoduletypes.ModuleName, coin) - if err != nil { - return err - } - err = k.SendCoinsFromModuleToModule(*ctx, mintmoduletypes.ModuleName, moduleName, coin) - if err != nil { - return err - } - return nil -} - -// DefaultConsensusParams parameters for tendermint consensus -var DefaultConsensusParams = &tmproto.ConsensusParams{ - Block: &tmproto.BlockParams{ - MaxBytes: 200000, - MaxGas: 2000000, - }, - Evidence: &tmproto.EvidenceParams{ - MaxAgeNumBlocks: 302400, - MaxAgeDuration: 504 * time.Hour, // 3 weeks is the max duration - MaxBytes: 10000, - }, - Validator: &tmproto.ValidatorParams{ - PubKeyTypes: []string{ - tmtypes.ABCIPubKeyTypeEd25519, - }, - }, -} - -func stakingDefaultTestGenesis( - tApp *TestApp, -) (*stakingtypes.GenesisState, []abci.ValidatorUpdate, banktypes.Balance) { - defaultParams := stakingtypes.DefaultParams() - defaultParams.BondDenom = params.DefaultBondDenom - - addr1 := TestParamUsers["user1"].Address - addr2 := TestParamUsers["user2"].Address - - p1 := int64(8) - p2 := int64(2) - - pks := simtestutil.CreateTestPubKeys(2) - valConsPk1 := pks[0] - valConsPk2 := pks[1] - - valPower1 := sdk.TokensFromConsensusPower(p1, sdk.DefaultPowerReduction) - valPower2 := sdk.TokensFromConsensusPower(p2, sdk.DefaultPowerReduction) - - var validators []stakingtypes.Validator - var delegations []stakingtypes.Delegation - - pk0, err := codectypes.NewAnyWithValue(valConsPk1) - if err != nil { - panic(err) - } - pk1, err := codectypes.NewAnyWithValue(valConsPk2) - if err != nil { - panic(err) - } - - // initialize the validators - bondedVal1 := stakingtypes.Validator{ - OperatorAddress: sdk.ValAddress(addr1).String(), - ConsensusPubkey: pk0, - Status: stakingtypes.Bonded, - Tokens: valPower1, - DelegatorShares: sdkmath.LegacyNewDecFromInt(valPower1), - Description: stakingtypes.NewDescription("hoop", "", "", "", ""), - Commission: stakingtypes.NewCommission( - sdkmath.LegacyNewDecWithPrec(5, 1), - sdkmath.LegacyNewDecWithPrec(5, 1), - sdkmath.LegacyNewDec(0), - ), - } - bondedVal2 := stakingtypes.Validator{ - OperatorAddress: sdk.ValAddress(addr2).String(), - ConsensusPubkey: pk1, - Status: stakingtypes.Bonded, - Tokens: valPower2, - DelegatorShares: sdkmath.LegacyNewDecFromInt(valPower2), - Description: stakingtypes.NewDescription("bloop", "", "", "", ""), - Commission: stakingtypes.NewCommission( - sdkmath.LegacyNewDecWithPrec(5, 1), - sdkmath.LegacyNewDecWithPrec(5, 1), - sdkmath.LegacyNewDec(0), - ), - } - - // append new bonded validators to the list - validators = append(validators, bondedVal1, bondedVal2) - // mint coins in the bonded pool representing the validators coins - - var valudatorUpdates []abci.ValidatorUpdate - valudatorUpdates = append( - valudatorUpdates, - bondedVal1.ABCIValidatorUpdate(sdk.DefaultPowerReduction), - ) - delegations = append(delegations, stakingtypes.Delegation{ - DelegatorAddress: addr1.String(), - ValidatorAddress: bondedVal1.OperatorAddress, - Shares: bondedVal1.DelegatorShares, - }) - valudatorUpdates = append( - valudatorUpdates, - bondedVal2.ABCIValidatorUpdate(sdk.DefaultPowerReduction), - ) - delegations = append(delegations, stakingtypes.Delegation{ - DelegatorAddress: addr2.String(), - ValidatorAddress: bondedVal2.OperatorAddress, - Shares: bondedVal2.DelegatorShares, - }) - - moduleAddress := tApp.AccountKeeper.GetModuleAddress(stakingtypes.BondedPoolName) - moduleBalance := banktypes.Balance{ - Address: moduleAddress.String(), - Coins: sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, valPower1.Add(valPower2))), - } - - TestParamValidatorAddresses["val1"] = TestValidator{ - PubKey: valConsPk1, - Address: bondedVal1.GetOperator(), - ConsAddress: sdk.ConsAddress(valConsPk1.Address()), - Power: valPower1, - } - TestParamValidatorAddresses["val2"] = TestValidator{ - PubKey: valConsPk2, - Address: bondedVal2.GetOperator(), - ConsAddress: sdk.ConsAddress(valConsPk2.Address()), - Power: valPower2, - } - - genesisState := stakingtypes.NewGenesisState(defaultParams, validators, delegations) - return genesisState, valudatorUpdates, moduleBalance -} - -// NewStakingHelper creates staking Handler wrapper for tests -func NewStakingHelper(t *testing.T, ctx sdk.Context, k stakingKeeper.Keeper) *stakingtestutil.Helper { - helper := stakingtestutil.NewHelper(t, ctx, &k) - helper.Commission = validatorDefaultCommission() - helper.Denom = params.DefaultBondDenom - return helper -} - -func validatorDefaultCommission() stakingtypes.CommissionRates { - return stakingtypes.NewCommissionRates( - sdkmath.LegacyMustNewDecFromStr("0.1"), - sdkmath.LegacyMustNewDecFromStr("0.2"), - sdkmath.LegacyMustNewDecFromStr("0.01"), - ) -} - -func GenerateOvmPublicKeys(n int) (pubKeys []string) { - TestOVMPublicKeys = make([]ed25519.PublicKey, n) - TestOVMPrivateKeys = make([]ed25519.PrivateKey, n) - for i := 0; i < n; i++ { - TestOVMPublicKeys[i], TestOVMPrivateKeys[i], _ = ed25519.GenerateKey(rand.Reader) - bs, err := x509.MarshalPKIXPublicKey(TestOVMPublicKeys[i]) - if err != nil { - panic(err) - } - pubKeys = append(pubKeys, string(utils.NewPubKeyMemory(bs))) - } - - return pubKeys -} diff --git a/testutil/simapp/simapp_test.go b/testutil/simapp/simapp_test.go deleted file mode 100644 index 16889217..00000000 --- a/testutil/simapp/simapp_test.go +++ /dev/null @@ -1,13 +0,0 @@ -package simapp_test - -import ( - "testing" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/stretchr/testify/require" -) - -func TestGetTestObjects(t *testing.T) { - _, _, err := simapp.GetTestObjects() - require.NoError(t, err) -} diff --git a/testutil/simapp/test_helpers.go b/testutil/simapp/test_helpers.go deleted file mode 100644 index 18e23d10..00000000 --- a/testutil/simapp/test_helpers.go +++ /dev/null @@ -1,131 +0,0 @@ -package simapp - -import ( - "bytes" - "crypto/rand" - "encoding/base64" - "encoding/hex" - "fmt" - "math" - "os" - "path/filepath" - - "github.com/golang-jwt/jwt" - "github.com/spf13/cast" - - sdkerrors "cosmossdk.io/errors" - "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" - cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" -) - -// PKs is a slice of public keys for test -var PKs = createTestPubKeys(500) - -func CreateJwtTicket(claim jwt.MapClaims) (string, error) { - token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, claim) - return token.SignedString(TestOVMPrivateKeys[0]) -} - -// createIncrementalAccounts is a strategy used by addTestAddrs() in order to generated addresses in ascending order. -func createIncrementalAccounts(accNum int) []sdk.AccAddress { - var addresses []sdk.AccAddress - var buffer bytes.Buffer - - // start at 100 so we can make up to 999 test addresses with valid test addresses - for i := 100; i < (accNum + 100); i++ { - numString := cast.ToString(i) - buffer.WriteString("A58856F0FD53BF058B4909A21AEC019107BA6") // base address string - - buffer.WriteString(numString) // adding on final two digits to make addresses unique - res, _ := sdk.AccAddressFromHexUnsafe(buffer.String()) - bech := res.String() - addr, _ := testAddr(buffer.String(), bech) - - addresses = append(addresses, addr) - buffer.Reset() - } - - return addresses -} - -// testAddr returns sample account address -func testAddr(addr, bech string) (sdk.AccAddress, error) { - res, err := sdk.AccAddressFromHexUnsafe(addr) - if err != nil { - return nil, err - } - bechexpected := res.String() - if bech != bechexpected { - return nil, fmt.Errorf("bech encoding doesn't match reference") - } - - bechres, err := sdk.AccAddressFromBech32(bech) - if err != nil { - return nil, err - } - if !bytes.Equal(bechres, res) { - return nil, err - } - - return res, nil -} - -// createTestPubKeys returns a total of numPubKeys public keys in ascending order. -func createTestPubKeys(numPubKeys int) []cryptotypes.PubKey { - var publicKeys []cryptotypes.PubKey - var buffer bytes.Buffer - - // start at 10 to avoid changing 1 to 01, 2 to 02, etc - for i := 100; i < (numPubKeys + 100); i++ { - numString := cast.ToString(i) - buffer.WriteString( - "0B485CFC0EECC619440448436F8FC9DF40566F2369E72400281454CB552AF", - ) // base pubkey string - buffer.WriteString( - numString, - ) // adding on final two digits to make pubkeys unique - publicKeys = append(publicKeys, newPubKeyFromHex(buffer.String())) - buffer.Reset() - } - return publicKeys -} - -// newPubKeyFromHex returns a PubKey from a hex string. -func newPubKeyFromHex(pk string) (res cryptotypes.PubKey) { - pkBytes, err := hex.DecodeString(pk) - if err != nil { - panic(err) - } - if len(pkBytes) != ed25519.PubKeySize { - panic(sdkerrors.Wrap(sdkerrtypes.ErrInvalidPubKey, "invalid pubkey size")) - } - return &ed25519.PubKey{Key: pkBytes} -} - -func RandomString(length int) string { - buff := make([]byte, int(math.Ceil(float64(length)/float64(1.33333333333)))) - _, err := rand.Read(buff) - if err != nil { - panic(err) - } - str := base64.RawURLEncoding.EncodeToString(buff) - return str[:length] // strip 1 extra character we get from odd length results -} - -func WriteKeyringFile(name string, dir string, contents []byte) error { - file := filepath.Join(dir, name) - - //#nosec - if err := os.MkdirAll(dir, 0o755); err != nil { - return fmt.Errorf("could not create directory %q: %w", dir, err) - } - - //#nosec - if err := os.WriteFile(file, contents, 0o644); err != nil { - return err - } - - return nil -} diff --git a/tools/tools.go b/tools/tools.go index 6e7a12d4..04e44843 100644 --- a/tools/tools.go +++ b/tools/tools.go @@ -3,9 +3,12 @@ package tools import ( + _ "github.com/bufbuild/buf/cmd/buf" + _ "github.com/cosmos/cosmos-proto/cmd/protoc-gen-go-pulsar" _ "github.com/cosmos/gogoproto/protoc-gen-gocosmos" - _ "github.com/golang/protobuf/protoc-gen-go" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-grpc-gateway" - _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger" _ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2" + _ "golang.org/x/tools/cmd/goimports" + _ "google.golang.org/grpc/cmd/protoc-gen-go-grpc" + _ "google.golang.org/protobuf/cmd/protoc-gen-go" ) diff --git a/types/kyc.go b/types/legacy/kyc.go similarity index 95% rename from types/kyc.go rename to types/legacy/kyc.go index e38e36d1..fd0c6062 100644 --- a/types/kyc.go +++ b/types/legacy/kyc.go @@ -1,4 +1,4 @@ -package types +package legacy // Validate checks whether the kyc data is valid for a particular bettor // if the kyc is required diff --git a/types/kyc.pb.go b/types/legacy/kyc.pb.go similarity index 80% rename from types/kyc.pb.go rename to types/legacy/kyc.pb.go index 56f6e4f4..fec60e06 100644 --- a/types/kyc.pb.go +++ b/types/legacy/kyc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/type/kyc.proto +// source: sge/legacy/type/v1beta/kyc.proto -package types +package legacy import ( fmt "fmt" @@ -38,7 +38,7 @@ func (m *KycDataPayload) Reset() { *m = KycDataPayload{} } func (m *KycDataPayload) String() string { return proto.CompactTextString(m) } func (*KycDataPayload) ProtoMessage() {} func (*KycDataPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_2be32303a1d48b19, []int{0} + return fileDescriptor_aa5c67f03d1411a5, []int{0} } func (m *KycDataPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -89,29 +89,30 @@ func (m *KycDataPayload) GetID() string { } func init() { - proto.RegisterType((*KycDataPayload)(nil), "sgenetwork.sge.type.KycDataPayload") + proto.RegisterType((*KycDataPayload)(nil), "sge.legacy.type.v1beta.KycDataPayload") } -func init() { proto.RegisterFile("sgenetwork/sge/type/kyc.proto", fileDescriptor_2be32303a1d48b19) } +func init() { proto.RegisterFile("sge/legacy/type/v1beta/kyc.proto", fileDescriptor_aa5c67f03d1411a5) } -var fileDescriptor_2be32303a1d48b19 = []byte{ - // 249 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2d, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x2f, 0xa9, 0x2c, 0x48, 0xd5, - 0xcf, 0xae, 0x4c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x46, 0x48, 0xeb, 0x15, 0xa7, - 0xa7, 0xea, 0x81, 0xa4, 0xa5, 0x44, 0xd2, 0xf3, 0xd3, 0xf3, 0xc1, 0xf2, 0xfa, 0x20, 0x16, 0x44, - 0xa9, 0x94, 0x64, 0x72, 0x7e, 0x71, 0x6e, 0x7e, 0x71, 0x3c, 0x44, 0x02, 0xc2, 0x81, 0x48, 0x29, - 0x55, 0x71, 0xf1, 0x79, 0x57, 0x26, 0xbb, 0x24, 0x96, 0x24, 0x06, 0x24, 0x56, 0xe6, 0xe4, 0x27, - 0xa6, 0x08, 0x89, 0x71, 0xb1, 0x65, 0xa6, 0xe7, 0xe5, 0x17, 0xa5, 0x4a, 0x30, 0x2a, 0x30, 0x6a, - 0x70, 0x04, 0x41, 0x79, 0x42, 0x52, 0x5c, 0x1c, 0x89, 0x05, 0x05, 0x45, 0xf9, 0x65, 0xa9, 0x29, - 0x12, 0x4c, 0x60, 0x19, 0x38, 0x5f, 0xc8, 0x84, 0x8b, 0x29, 0x33, 0x45, 0x82, 0x59, 0x81, 0x51, - 0x83, 0xd3, 0x49, 0xe5, 0xd1, 0x3d, 0x79, 0x26, 0x4f, 0x97, 0x57, 0xf7, 0xe4, 0x99, 0x32, 0x53, - 0x2e, 0x6d, 0xd1, 0x15, 0x81, 0xda, 0xe7, 0x98, 0x92, 0x52, 0x94, 0x5a, 0x5c, 0x1c, 0x5c, 0x52, - 0x94, 0x99, 0x97, 0x1e, 0xc4, 0x94, 0x99, 0xe2, 0x64, 0x75, 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, - 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x4e, 0x78, 0x2c, 0xc7, 0x70, 0xe1, 0xb1, 0x1c, 0xc3, 0x8d, - 0xc7, 0x72, 0x0c, 0x51, 0x0a, 0xe9, 0x99, 0x25, 0x19, 0xa5, 0x49, 0x7a, 0xc9, 0xf9, 0xb9, 0x20, - 0xaf, 0xeb, 0xa2, 0x07, 0x43, 0x71, 0x12, 0x1b, 0xd8, 0xf9, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, - 0xff, 0xf7, 0x7f, 0x43, 0x34, 0x25, 0x01, 0x00, 0x00, +var fileDescriptor_aa5c67f03d1411a5 = []byte{ + // 268 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x28, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0x2f, 0xa9, 0x2c, 0x48, 0xd5, 0x2f, 0x33, 0x4c, 0x4a, + 0x2d, 0x49, 0xd4, 0xcf, 0xae, 0x4c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x2b, 0x4e, + 0x4f, 0xd5, 0x83, 0xa8, 0xd0, 0x03, 0xa9, 0xd0, 0x83, 0xa8, 0x90, 0x92, 0x4c, 0xce, 0x2f, 0xce, + 0xcd, 0x2f, 0x8e, 0x07, 0xab, 0xd2, 0x87, 0x70, 0x20, 0x5a, 0xa4, 0x44, 0xd2, 0xf3, 0xd3, 0xf3, + 0x21, 0xe2, 0x20, 0x16, 0x44, 0x54, 0xa9, 0x8a, 0x8b, 0xcf, 0xbb, 0x32, 0xd9, 0x25, 0xb1, 0x24, + 0x31, 0x20, 0xb1, 0x32, 0x27, 0x3f, 0x31, 0x45, 0x48, 0x8c, 0x8b, 0x2d, 0x33, 0x3d, 0x2f, 0xbf, + 0x28, 0x55, 0x82, 0x51, 0x81, 0x51, 0x83, 0x23, 0x08, 0xca, 0x13, 0x92, 0xe2, 0xe2, 0x48, 0x2c, + 0x28, 0x28, 0xca, 0x2f, 0x4b, 0x4d, 0x91, 0x60, 0x02, 0xcb, 0xc0, 0xf9, 0x42, 0x26, 0x5c, 0x4c, + 0x99, 0x29, 0x12, 0xcc, 0x0a, 0x8c, 0x1a, 0x9c, 0x4e, 0x2a, 0x8f, 0xee, 0xc9, 0x33, 0x79, 0xba, + 0xbc, 0xba, 0x27, 0xcf, 0x94, 0x99, 0x72, 0x69, 0x8b, 0xae, 0x08, 0xd4, 0x15, 0x8e, 0x29, 0x29, + 0x45, 0xa9, 0xc5, 0xc5, 0xc1, 0x25, 0x45, 0x99, 0x79, 0xe9, 0x41, 0x4c, 0x99, 0x29, 0x4e, 0x8e, + 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, + 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x9e, 0x9e, 0x59, 0x92, 0x51, + 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0xab, 0x5f, 0x9c, 0x9e, 0xaa, 0x9b, 0x97, 0x5a, 0x52, 0x9e, 0x5f, + 0x94, 0x0d, 0x62, 0x83, 0x03, 0xa4, 0x18, 0x1a, 0x3a, 0x49, 0x6c, 0x60, 0x5f, 0x18, 0x03, 0x02, + 0x00, 0x00, 0xff, 0xff, 0x50, 0x42, 0xe3, 0xf4, 0x32, 0x01, 0x00, 0x00, } func (m *KycDataPayload) Marshal() (dAtA []byte, err error) { diff --git a/utils/authorization.go b/utils/authorization.go index 724ce0f7..2980524e 100644 --- a/utils/authorization.go +++ b/utils/authorization.go @@ -1,6 +1,7 @@ package utils import ( + "context" "time" sdkerrors "cosmossdk.io/errors" @@ -13,27 +14,27 @@ import ( // AuthzKeeper defines the expected authz keeper. type AuthzKeeper interface { GetAuthorization( - ctx sdk.Context, + ctx context.Context, grantee sdk.AccAddress, granter sdk.AccAddress, msgType string, ) (authz.Authorization, *time.Time) SaveGrant( - ctx sdk.Context, + ctx context.Context, grantee, granter sdk.AccAddress, authorization authz.Authorization, expiration *time.Time, ) error DeleteGrant( - ctx sdk.Context, + ctx context.Context, grantee, granter sdk.AccAddress, msgType string, ) error } func ValidateMsgAuthorization( + ctx context.Context, authzKeeper AuthzKeeper, - ctx sdk.Context, creator, depositor string, msg sdk.Msg, errAuthorizationNotFound, errAuthorizationNotAccepted error, diff --git a/utils/encoding.go b/utils/encoding.go deleted file mode 100644 index b0c8cfd6..00000000 --- a/utils/encoding.go +++ /dev/null @@ -1,7 +0,0 @@ -package utils - -import "encoding/pem" - -func NewPubKeyMemory(bs []byte) []byte { - return pem.EncodeToMemory(&pem.Block{Type: "PUBLIC KEY", Bytes: bs}) -} diff --git a/utils/fund.go b/utils/fund.go index 124ebe72..135bb3c0 100644 --- a/utils/fund.go +++ b/utils/fund.go @@ -1,6 +1,8 @@ package utils import ( + "context" + sdkerrors "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" @@ -30,9 +32,9 @@ type AccountKeeper interface { // BankKeeper defines the expected bank keeper methods. type BankKeeper interface { - SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, ecipientModule string, amt sdk.Coins) error - SendCoinsFromModuleToModule(ctx sdk.Context, senderModule, recipientModule string, amt sdk.Coins) error - SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error + SendCoinsFromAccountToModule(ctx context.Context, senderAddr sdk.AccAddress, ecipientModule string, amt sdk.Coins) error + SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt sdk.Coins) error + SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error } // Fund transfers the input amount from sender to the module account. diff --git a/utils/str.go b/utils/str.go index 93a1c4f7..51649d22 100644 --- a/utils/str.go +++ b/utils/str.go @@ -24,16 +24,6 @@ func RemoveDuplicateStrs(strSlice []string) (list []string) { return } -// RemoveStr removes an item from string slice. -func RemoveStr(s []string, r string) []string { - for i, v := range s { - if v == r { - return append(s[:i], s[i+1:]...) - } - } - return s -} - // PopStrAtIndex pops an string item from string slice by index. func PopStrAtIndex(s []string, i uint32) ([]string, string) { popElem := s[i] diff --git a/x/bet/client/cli/query_bet_test.go b/x/bet/client/cli/query_bet_test.go deleted file mode 100644 index 8d290631..00000000 --- a/x/bet/client/cli/query_bet_test.go +++ /dev/null @@ -1,396 +0,0 @@ -package cli_test - -import ( - "fmt" - "strings" - "testing" - "time" - - sdkmath "cosmossdk.io/math" - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/bet/client/cli" - "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" -) - -const testMarketUID = "5db09053-2901-4110-8fb5-c14e21f8d555" - -func networkWithBetObjects(t *testing.T, n int) (*network.Network, []types.Bet) { - t.Helper() - cfg := network.DefaultConfig() - - // market module state - marketState := markettypes.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[markettypes.ModuleName], &marketState)) - - market := markettypes.Market{ - UID: testMarketUID, - Creator: simapp.TestParamUsers["user1"].Address.String(), - StartTS: 1111111111, - EndTS: uint64(time.Now().Unix()) + 5000, - Odds: []*markettypes.Odds{ - {UID: "6db09053-2901-4110-8fb5-c14e21f8d666", Meta: "Odds 1"}, - {UID: "5e31c60f-2025-48ce-ae79-1dc110f16358", Meta: "Odds 2"}, - {UID: "6e31c60f-2025-48ce-ae79-1dc110f16354", Meta: "Odds 3"}, - }, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - } - nullify.Fill(&market) - marketState.MarketList = []markettypes.Market{market} - - marketBuf, err := cfg.Codec.MarshalJSON(&marketState) - require.NoError(t, err) - cfg.GenesisState[markettypes.ModuleName] = marketBuf - - // bet module state - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - bet := types.Bet{ - Creator: testAddress, - UID: uuid.NewString(), - MarketUID: market.UID, - OddsValue: "10", - Amount: sdkmath.NewInt(10), - Fee: sdkmath.NewInt(1), - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - } - nullify.Fill(&bet) - - state.BetList = append(state.BetList, bet) - state.PendingBetList = append( - state.PendingBetList, - types.PendingBet{UID: bet.UID, Creator: testAddress}, - ) - state.SettledBetList = append( - state.SettledBetList, - types.SettledBet{UID: bet.UID, BettorAddress: testAddress}, - ) - - id := uint64(i + 1) - state.Uid2IdList = append(state.Uid2IdList, types.UID2ID{UID: bet.UID, ID: id}) - } - state.Stats = types.BetStats{Count: 5} - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), state.BetList -} - -func TestQueryBet(t *testing.T) { - net, objs := networkWithBetObjects(t, 5) - - t.Run("ShowBet", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - for _, tc := range []struct { - desc string - uid string - creator string - - args []string - err error - obj types.Bet - }{ - { - desc: "found", - creator: testAddress, - uid: objs[0].UID, - - args: common, - obj: objs[0], - }, - { - desc: "not found", - creator: "", - uid: cast.ToString(100000), - - args: common, - err: status.Error(codes.NotFound, "not found"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.creator, - tc.uid, - } - args = append(args, tc.args...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdShowBet(), args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.ErrorIs(t, stat.Err(), tc.err) - } else { - require.NoError(t, err) - var resp types.QueryBetResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NotNil(t, resp.Bet) - require.Equal(t, - nullify.Fill(&tc.obj), - nullify.Fill(&resp.Bet), - ) - } - }) - } - }) - - t.Run("ListBet", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListBet(), args) - require.NoError(t, err) - var resp types.QueryBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListBet(), args) - require.NoError(t, err) - var resp types.QueryBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListBet(), args) - require.NoError(t, err) - var resp types.QueryBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - }) - }) - - t.Run("ListBetByCreator", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testAddress, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListBetByCreator(), args) - require.NoError(t, err) - var resp types.QueryBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListBetByCreator(), args) - require.NoError(t, err) - var resp types.QueryBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListBetByCreator(), args) - require.NoError(t, err) - var resp types.QueryBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - }) - }) - - t.Run("ListPendingBetOfMarket", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testMarketUID, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListPendingBets(), args) - require.NoError(t, err) - var resp types.QueryPendingBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListPendingBets(), args) - require.NoError(t, err) - var resp types.QueryPendingBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListPendingBets(), args) - require.NoError(t, err) - var resp types.QueryPendingBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.Bet), - ) - }) - }) - - t.Run("ListBetByUIDs", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - var items []string - for _, v := range objs { - items = append(items, testAddress+":"+v.UID) - } - - for _, tc := range []struct { - desc string - items []string - - args []string - err error - obj []types.Bet - }{ - { - desc: "found", - items: items, - - args: common, - obj: objs, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - strings.Join(tc.items, ","), - } - args = append(args, tc.args...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdListBetByUIDs(), args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.ErrorIs(t, stat.Err(), tc.err) - } else { - require.NoError(t, err) - var resp types.QueryBetsByUIDsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NotNil(t, resp.Bets) - require.Equal(t, - nullify.Fill(&tc.obj), - nullify.Fill(&resp.Bets), - ) - } - }) - } - }) -} diff --git a/x/bet/client/cli/query_test.go b/x/bet/client/cli/query_test.go deleted file mode 100644 index 1cf6cc48..00000000 --- a/x/bet/client/cli/query_test.go +++ /dev/null @@ -1,50 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/bet/client/cli" -) - -const testAddress = "cosmos1s4ycalgh3gjemd4hmqcvcgmnf647rnd0tpg2w9" - -func TestGetQueryCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetQueryCmd(""), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True( - t, - strings.HasPrefix(string(res.Bytes()), "Querying commands for the bet module"), - ) - }) - } -} diff --git a/x/bet/client/cli/tx_bet_test.go b/x/bet/client/cli/tx_bet_test.go deleted file mode 100644 index 4263ad50..00000000 --- a/x/bet/client/cli/tx_bet_test.go +++ /dev/null @@ -1,86 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/bet/client/cli" -) - -func TestTXBetCLI(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - commonArgs := []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf( - "--%s=%s", - flags.FlagFees, - sdk.NewCoins(sdk.NewCoin(net.Config.BondDenom, sdkmath.NewInt(10))).String(), - ), - } - - t.Run("wager", func(t *testing.T) { - for _, tc := range []struct { - desc string - uid string - amount string - ticket string - - err error - code uint32 - }{ - { - uid: "6e31c60f-2025-48ce-ae79-1dc110f16355", - amount: "555", - ticket: "ticket", - - desc: "valid", - }, - { - uid: "invalidUID", - amount: "555", - ticket: "ticket", - - desc: "validation failed", - err: fmt.Errorf("any error"), - }, - { - uid: "6e31c60f-2025-48ce-ae79-1dc110f16355", - amount: "invalidAmount", - ticket: "ticket", - - desc: "invalid amuont", - err: fmt.Errorf("any error"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.uid, - tc.amount, - tc.ticket, - } - args = append(args, commonArgs...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdWager(), args) - if tc.err != nil { - require.NotNil(t, err) - } else { - require.NoError(t, err) - var resp sdk.TxResponse - require.NoError(t, ctx.Codec.UnmarshalJSON(out.Bytes(), &resp)) - } - }) - } - }) -} diff --git a/x/bet/client/cli/tx_test.go b/x/bet/client/cli/tx_test.go deleted file mode 100644 index 3dadcacb..00000000 --- a/x/bet/client/cli/tx_test.go +++ /dev/null @@ -1,45 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/bet/client/cli" -) - -func TestGetTxCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetTxCmd(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True(t, strings.HasPrefix(string(res.Bytes()), "bet transactions subcommands")) - }) - } -} diff --git a/x/bet/genesis_test.go b/x/bet/genesis_test.go deleted file mode 100644 index cd49dd64..00000000 --- a/x/bet/genesis_test.go +++ /dev/null @@ -1,67 +0,0 @@ -package bet_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - - "github.com/sge-network/sge/x/bet" - "github.com/sge-network/sge/x/bet/types" -) - -func TestGenesis(t *testing.T) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - genesisState := types.GenesisState{ - Params: types.DefaultParams(), - - BetList: []types.Bet{ - { - UID: "0", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - { - UID: "1", - Creator: simapp.TestParamUsers["user2"].Address.String(), - }, - }, - Uid2IdList: []types.UID2ID{ - { - UID: "0", - ID: 1, - }, - { - UID: "1", - ID: 2, - }, - }, - PendingBetList: []types.PendingBet{ - { - UID: "1", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - }, - SettledBetList: []types.SettledBet{ - { - UID: "1", - BettorAddress: simapp.TestParamUsers["user1"].Address.String(), - }, - }, - Stats: types.BetStats{ - Count: 2, - }, - } - - bet.InitGenesis(ctx, *tApp.BetKeeper, genesisState) - got := bet.ExportGenesis(ctx, *tApp.BetKeeper) - require.NotNil(t, got) - - nullify.Fill(&genesisState) - nullify.Fill(got) - - require.ElementsMatch(t, genesisState.BetList, got.BetList) -} diff --git a/x/bet/handler.go b/x/bet/handler.go deleted file mode 100644 index fba87cea..00000000 --- a/x/bet/handler.go +++ /dev/null @@ -1,34 +0,0 @@ -package bet - -import ( - "fmt" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/x/bet/keeper" - "github.com/sge-network/sge/x/bet/types" -) - -// NewHandler returns sdk.handler instance with configured message handler function -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - - switch msg := msg.(type) { - case *types.MsgWager: - res, err := msgServer.Wager(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdateParams: - res, err := msgServer.UpdateParams(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrtypes.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/bet/keeper/bet_test.go b/x/bet/keeper/bet_test.go deleted file mode 100644 index 7f5ef1a2..00000000 --- a/x/bet/keeper/bet_test.go +++ /dev/null @@ -1,106 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/bet/keeper" - "github.com/sge-network/sge/x/bet/types" -) - -func createNBet( - tApp *simapp.TestApp, - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.Bet { - items := make([]types.Bet, n) - testCreator = simapp.TestParamUsers["user1"].Address.String() - tApp.MarketKeeper.SetMarket(ctx, testMarket) - - for i := range items { - items[i].UID = cast.ToString(i) - items[i].Creator = testCreator - items[i].OddsValue = "10" - items[i].Amount = sdkmath.NewInt(10) - items[i].Fee = sdkmath.NewInt(1) - items[i].MarketUID = testMarketUID - items[i].MaxLossMultiplier = sdkmath.LegacyNewDec(10) - - id := uint64(i + 1) - keeper.SetBet(ctx, items[i], id) - keeper.SetPendingBet(ctx, &types.PendingBet{ - UID: items[i].UID, - Creator: testCreator, - }, id, testMarketUID) - } - return items -} - -func TestBetGet(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - items := createNBet(tApp, k, ctx, 10) - testCreator = simapp.TestParamUsers["user1"].Address.String() - - rst, found := k.GetBet(ctx, - testCreator, - 10000, - ) - var expectedResp types.Bet - require.False(t, found) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - for i, item := range items { - rst, found := k.GetBet(ctx, - testCreator, - uint64(i+1), - ) - require.True(t, found) - require.Equal(t, - nullify.Fill(item), - nullify.Fill(rst), - ) - } -} - -func TestBetGetAll(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - items := createNBet(tApp, k, ctx, 10) - - bets, err := k.GetBets(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(bets), - ) -} - -// TestSortBetGetAll checks if incremental id is genereted correctly -func TestSortBetGetAll(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - items := createNBet(tApp, k, ctx, 10000) - - bets, err := k.GetBets(ctx) - lastBetID := uint64(0) - for _, b := range bets { - uuid2ID, found := k.GetBetID(ctx, b.UID) - require.True(t, found) - require.Greater(t, uuid2ID.ID, lastBetID) - lastBetID = uuid2ID.ID - } - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(bets), - ) -} diff --git a/x/bet/keeper/grpc_query_bet_test.go b/x/bet/keeper/grpc_query_bet_test.go deleted file mode 100644 index 12526df8..00000000 --- a/x/bet/keeper/grpc_query_bet_test.go +++ /dev/null @@ -1,369 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/bet/types" -) - -func TestBetQuerySingle(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNBet(tApp, k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryBetRequest - response *types.QueryBetResponse - err error - }{ - { - desc: "First", - request: &types.QueryBetRequest{ - Creator: testCreator, - Uid: msgs[0].UID, - }, - response: &types.QueryBetResponse{Bet: msgs[0], Market: testMarket}, - }, - { - desc: "Second", - request: &types.QueryBetRequest{ - Creator: testCreator, - Uid: msgs[1].UID, - }, - response: &types.QueryBetResponse{Bet: msgs[1], Market: testMarket}, - }, - { - desc: "KeyNotFound", - request: &types.QueryBetRequest{ - Uid: cast.ToString(100000), - }, - err: status.Error(codes.NotFound, "not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.Bet(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} - -func TestBetQueryPaginated(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNBet(tApp, k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryBetsRequest { - return &types.QueryBetsRequest{ - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.Bets(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.Bets(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.Bets(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.Bets(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} - -// TestBetQueryPaginatedReverse test if IDs are sorted reveresely -func TestBetQueryPaginatedReverse(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNBet(tApp, k, ctx, 100) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryBetsRequest { - return &types.QueryBetsRequest{ - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - Reverse: true, - }, - } - } - t.Run("Sorted", func(t *testing.T) { - resp, err := k.Bets(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - - lastBetID := resp.Pagination.Total + 1 - for _, b := range resp.Bet { - uuid2ID, found := k.GetBetID(ctx, b.UID) - require.True(t, found) - require.Less(t, uuid2ID.ID, lastBetID) - lastBetID = uuid2ID.ID - } - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.Bets(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} - -func TestBetsByCreatorQueryPaginated(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNBet(tApp, k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryBetsByCreatorRequest { - return &types.QueryBetsByCreatorRequest{ - Creator: simapp.TestParamUsers["user1"].Address.String(), - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.BetsByCreator(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.BetsByCreator(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.BetsByCreator(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.Bets(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} - -func TestBetByCreatorQueryPaginatedReverse(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNBet(tApp, k, ctx, 100) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryBetsByCreatorRequest { - return &types.QueryBetsByCreatorRequest{ - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - Reverse: true, - }, - } - } - t.Run("Sorted", func(t *testing.T) { - resp, err := k.BetsByCreator(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - - lastBetID := resp.Pagination.Total + 1 - for _, b := range resp.Bet { - uuid2ID, found := k.GetBetID(ctx, b.UID) - require.True(t, found) - require.Less(t, uuid2ID.ID, lastBetID) - lastBetID = uuid2ID.ID - } - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.Bets(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} - -func TestBetByUIDsQuery(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNBet(tApp, k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryBetsByUIDsRequest - response *types.QueryBetsByUIDsResponse - err error - }{ - { - desc: "First", - request: &types.QueryBetsByUIDsRequest{ - Items: []string{ - simapp.TestParamUsers["user1"].Address.String() + ":" + msgs[0].UID, - }, - }, - response: &types.QueryBetsByUIDsResponse{Bets: []types.Bet{msgs[0]}}, - }, - { - desc: "Second", - request: &types.QueryBetsByUIDsRequest{ - Items: []string{ - simapp.TestParamUsers["user1"].Address.String() + ":" + msgs[1].UID, - }, - }, - response: &types.QueryBetsByUIDsResponse{Bets: []types.Bet{msgs[1]}}, - }, - { - desc: "NotFound", - request: &types.QueryBetsByUIDsRequest{ - Items: []string{ - simapp.TestParamUsers["user1"].Address.String() + ":" + "100000", - }, - }, - response: &types.QueryBetsByUIDsResponse{Bets: []types.Bet{}, NotFoundBetUids: []string{"100000"}}, - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.BetsByUIDs(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} - -func TestPendingBetsOfMarketQueryPaginated(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNBet(tApp, k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryPendingBetsRequest { - return &types.QueryPendingBetsRequest{ - MarketUid: testMarketUID, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.PendingBets(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.PendingBets(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Bet), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.PendingBets(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Bet), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.Bets(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/bet/keeper/keeper_test.go b/x/bet/keeper/keeper_test.go deleted file mode 100644 index 47732bd6..00000000 --- a/x/bet/keeper/keeper_test.go +++ /dev/null @@ -1,196 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/testutil/simapp" - - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/bet/keeper" - "github.com/sge-network/sge/x/bet/types" - marketkeeper "github.com/sge-network/sge/x/market/keeper" - markettypes "github.com/sge-network/sge/x/market/types" -) - -var ( - testMarketUID = "5db09053-2901-4110-8fb5-c14e21f8d555" - testOddsUID1 = "6db09053-2901-4110-8fb5-c14e21f8d666" - testOddsUID2 = "5e31c60f-2025-48ce-ae79-1dc110f16358" - testOddsUID3 = "6e31c60f-2025-48ce-ae79-1dc110f16354" - testMarketOdds = []*markettypes.Odds{ - {UID: testOddsUID1, Meta: "Odds 1"}, - {UID: testOddsUID2, Meta: "Odds 2"}, - {UID: testOddsUID3, Meta: "Odds 3"}, - } - testSelectedBetOdds = &types.BetOdds{ - UID: testOddsUID1, - MarketUID: testMarketUID, - Value: "4.20", - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - } - testBetOdds = &[]types.BetOdds{ - { - UID: testOddsUID1, - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - { - UID: testOddsUID2, - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - { - UID: testOddsUID3, - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - } - testCreator string - testBet *types.MsgWager - testAddMarket *markettypes.MsgAdd - - testMarket = markettypes.Market{ - UID: testMarketUID, - Creator: simapp.TestParamUsers["user1"].Address.String(), - StartTS: 1111111111, - EndTS: uint64(time.Now().Unix()) + 5000, - Odds: testMarketOdds, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - } -) - -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp, tApp.BetKeeper, ctx -} - -func setupKeeper(t testing.TB) (*keeper.KeeperTest, sdk.Context) { - _, k, ctx := setupKeeperAndApp(t) - - return k, ctx -} - -func addTestMarket(t testing.TB, tApp *simapp.TestApp, ctx sdk.Context) { - testCreator = simapp.TestParamUsers["user1"].Address.String() - testAddMarketClaim := jwt.MapClaims{ - "uid": testMarketUID, - "start_ts": 1111111111, - "end_ts": uint64(ctx.BlockTime().Unix()) + 1000, - "odds": testMarketOdds, - "exp": 9999999999, - "iat": 7777777777, - "meta": "Winner of x:y", - "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - } - testAddMarketTicket, err := createJwtTicket(testAddMarketClaim) - require.Nil(t, err) - - testAddMarket = &markettypes.MsgAdd{ - Creator: testCreator, - Ticket: testAddMarketTicket, - } - wctx := sdk.WrapSDKContext(ctx) - marketSrv := marketkeeper.NewMsgServerImpl(*tApp.MarketKeeper) - resAddMarket, err := marketSrv.Add(wctx, testAddMarket) - require.Nil(t, err) - require.NotNil(t, resAddMarket) -} - -func addTestMarketBatch( - t testing.TB, - tApp *simapp.TestApp, - ctx sdk.Context, - count int, -) (uids []string) { - for i := 0; i < count; i++ { - testCreator = simapp.TestParamUsers["user"+cast.ToString(i)].Address.String() - uid := uuid.NewString() - uids = append(uids, uid) - testAddMarketClaim := jwt.MapClaims{ - "uid": uid, - "start_ts": 1111111111, - "end_ts": uint64(ctx.BlockTime().Unix()) + 1000, - "odds": testMarketOdds, - "exp": 9999999999, - "iat": 7777777777, - "meta": "Winner of x:y", - "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - } - testAddMarketTicket, err := createJwtTicket(testAddMarketClaim) - require.Nil(t, err) - - testAddMarket = &markettypes.MsgAdd{ - Creator: testCreator, - Ticket: testAddMarketTicket, - } - wctx := sdk.WrapSDKContext(ctx) - marketSrv := marketkeeper.NewMsgServerImpl(*tApp.MarketKeeper) - resAddMarket, err := marketSrv.Add(wctx, testAddMarket) - require.Nil(t, err) - require.NotNil(t, resAddMarket) - } - - return uids -} - -func placeTestBet( - ctx sdk.Context, - t testing.TB, - tApp *simapp.TestApp, - betUID string, - selectedOdds *types.BetOdds, -) { - testCreator = simapp.TestParamUsers["user1"].Address.String() - wctx := sdk.WrapSDKContext(ctx) - betSrv := keeper.NewMsgServerImpl(*tApp.BetKeeper) - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: testCreator, - } - - if selectedOdds == nil { - selectedOdds = testSelectedBetOdds - } - - testWagerClaim := jwt.MapClaims{ - "exp": 9999999999, - "iat": 7777777777, - "selected_odds": selectedOdds, - "kyc_data": testKyc, - "all_odds": testBetOdds, - } - testWagerTicket, err := createJwtTicket(testWagerClaim) - require.Nil(t, err) - - testBet = &types.MsgWager{ - Creator: testCreator, - Props: &types.WagerProps{ - UID: betUID, - Amount: sdkmath.NewInt(1000000), - Ticket: testWagerTicket, - }, - } - resWagerBet, err := betSrv.Wager(wctx, testBet) - require.Nil(t, err) - require.NotNil(t, resWagerBet) -} - -func createJwtTicket(claim jwt.MapClaims) (string, error) { - token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, claim) - return token.SignedString(simapp.TestOVMPrivateKeys[0]) -} - -func TestLogger(t *testing.T) { - k, ctx := setupKeeper(t) - logger := k.Logger(ctx) - require.NotNil(t, logger) - - logger.Debug("test log") -} diff --git a/x/bet/keeper/msg_server_bet_test.go b/x/bet/keeper/msg_server_bet_test.go deleted file mode 100644 index 9f9b2aa3..00000000 --- a/x/bet/keeper/msg_server_bet_test.go +++ /dev/null @@ -1,195 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/golang-jwt/jwt" - - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" -) - -func TestBetMsgServerWager(t *testing.T) { - tApp, k, msgk, ctx, wctx := setupMsgServerAndApp(t) - creator := simapp.TestParamUsers["user1"] - var err error - - t.Run("Redundant UID", func(t *testing.T) { - betItem := types.Bet{UID: "betUID"} - inputMsg := &types.MsgWager{ - Creator: creator.Address.String(), - Props: &types.WagerProps{ - UID: betItem.UID, - }, - } - - k.SetBet(ctx, betItem, 1) - _, err := msgk.Wager(wctx, inputMsg) - require.ErrorIs(t, types.ErrDuplicateUID, err) - }) - - t.Run("Error in verifying ticket", func(t *testing.T) { - inputBet := &types.MsgWager{ - Creator: creator.Address.String(), - Props: &types.WagerProps{ - UID: "betUID_1", - Amount: sdkmath.NewInt(500), - Ticket: "wrongTicket", - }, - } - - _, err = msgk.Wager(wctx, inputBet) - require.ErrorIs(t, types.ErrInTicketVerification, err) - }) - - t.Run("Error in ticket fields validation", func(t *testing.T) { - selectedBetOdds := *testSelectedBetOdds - - selectedBetOdds.MarketUID = "" - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: creator.Address.String(), - } - wagerClaim := jwt.MapClaims{ - "exp": 9999999999, - "iat": 1111111111, - "selected_odds": selectedBetOdds, - "kyc_data": testKyc, - "all_odds": testBetOdds, - } - wagerTicket, err := createJwtTicket(wagerClaim) - require.Nil(t, err) - - inputBet := &types.MsgWager{ - Creator: creator.Address.String(), - - Props: &types.WagerProps{ - UID: "betUID_1", - Amount: sdkmath.NewInt(500), - Ticket: wagerTicket, - }, - } - - _, err = msgk.Wager(wctx, inputBet) - require.ErrorIs(t, types.ErrInTicketValidation, err) - }) - - t.Run("No matching market", func(t *testing.T) { - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: creator.Address.String(), - } - wagerClaim := jwt.MapClaims{ - "exp": 9999999999, - "iat": 1111111111, - "selected_odds": testSelectedBetOdds, - "kyc_data": testKyc, - "all_odds": testBetOdds, - } - wagerTicket, err := createJwtTicket(wagerClaim) - require.Nil(t, err) - - inputBet := &types.MsgWager{ - Creator: creator.Address.String(), - - Props: &types.WagerProps{ - UID: "betUID_1", - Amount: sdkmath.NewInt(500), - Ticket: wagerTicket, - }, - } - - _, err = msgk.Wager(wctx, inputBet) - require.ErrorIs(t, types.ErrNoMatchingMarket, err) - }) - - t.Run("Success", func(t *testing.T) { - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: creator.Address.String(), - } - wagerClaim := jwt.MapClaims{ - "exp": 9999999999, - "iat": 1111111111, - "selected_odds": testSelectedBetOdds, - "kyc_data": testKyc, - "all_odds": testBetOdds, - } - wagerTicket, err := createJwtTicket(wagerClaim) - require.Nil(t, err) - - inputBet := &types.MsgWager{ - Creator: creator.Address.String(), - Props: &types.WagerProps{ - UID: "BetUID_2", - Amount: sdkmath.NewInt(1000000), - Ticket: wagerTicket, - }, - } - - marketItem := markettypes.Market{ - UID: testMarketUID, - Creator: testCreator, - StartTS: 1111111111, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - } - - tApp.MarketKeeper.SetMarket(ctx, marketItem) - - var oddsUIDs []string - for _, v := range marketItem.Odds { - oddsUIDs = append(oddsUIDs, v.UID) - } - err = tApp.OrderbookKeeper.InitiateOrderBook(ctx, marketItem.UID, oddsUIDs) - require.NoError(t, err) - - _, err = tApp.OrderbookKeeper.InitiateOrderBookParticipation( - ctx, - simapp.TestParamUsers["user1"].Address, - marketItem.UID, - sdkmath.NewInt(100000000), - sdkmath.NewInt(1), - ) - require.NoError(t, err) - - _, err = msgk.Wager(wctx, inputBet) - require.NoError(t, err) - rst, found := k.GetBet(ctx, - creator.Address.String(), - 1, - ) - require.True(t, found) - require.Equal(t, inputBet.Creator, rst.Creator) - - uid2ID, found := k.GetBetID(ctx, inputBet.Props.UID) - require.True(t, found) - require.Equal(t, types.UID2ID{UID: inputBet.Props.UID, ID: 1}, uid2ID) - - stats := k.GetBetStats(ctx) - require.Equal(t, types.BetStats{Count: 1}, stats) - - inputBet.Props.UID = "BetUID_3" - _, err = msgk.Wager(wctx, inputBet) - require.NoError(t, err) - rst, found = k.GetBet(ctx, - creator.Address.String(), - 2, - ) - require.True(t, found) - require.Equal(t, inputBet.Creator, rst.Creator) - - uid2ID, found = k.GetBetID(ctx, inputBet.Props.UID) - require.True(t, found) - require.Equal(t, types.UID2ID{UID: inputBet.Props.UID, ID: 2}, uid2ID) - - stats = k.GetBetStats(ctx) - require.Equal(t, types.BetStats{Count: 2}, stats) - }) -} diff --git a/x/bet/keeper/msg_server_test.go b/x/bet/keeper/msg_server_test.go deleted file mode 100644 index c9dd94c6..00000000 --- a/x/bet/keeper/msg_server_test.go +++ /dev/null @@ -1,19 +0,0 @@ -package keeper_test - -import ( - "context" - "testing" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/bet/keeper" - "github.com/sge-network/sge/x/bet/types" -) - -func setupMsgServerAndApp( - t testing.TB, -) (*simapp.TestApp, *keeper.KeeperTest, types.MsgServer, sdk.Context, context.Context) { - tApp, k, ctx := setupKeeperAndApp(t) - return tApp, k, keeper.NewMsgServerImpl(*k), ctx, sdk.WrapSDKContext(ctx) -} diff --git a/x/bet/keeper/params_test.go b/x/bet/keeper/params_test.go deleted file mode 100644 index 58a809d9..00000000 --- a/x/bet/keeper/params_test.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/bet/types" -) - -func TestGetParams(t *testing.T) { - k, ctx := setupKeeper(t) - params := types.DefaultParams() - - k.SetParams(ctx, params) - - require.EqualValues(t, params, k.GetParams(ctx)) -} diff --git a/x/bet/keeper/settle_test.go b/x/bet/keeper/settle_test.go deleted file mode 100644 index 7bba1932..00000000 --- a/x/bet/keeper/settle_test.go +++ /dev/null @@ -1,320 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" -) - -func TestSettleBet(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - testCreator = simapp.TestParamUsers["user1"].Address.String() - addTestMarket(t, tApp, ctx) - - tcs := []struct { - desc string - betUID string - updateMarket *markettypes.Market - bet *types.Bet - err error - }{ - { - desc: "invalid betUID", - betUID: "invalidUID", - err: types.ErrInvalidBetUID, - }, - { - desc: "not found bet", - betUID: "0db09053-2901-4110-8fb5-c14e21f8d400", - err: types.ErrNoMatchingBet, - }, - { - desc: "invalid creator", - bet: &types.Bet{ - UID: "0db09053-2901-4110-8fb5-c14e21f8d400", - MarketUID: "nonExistMarket", - Creator: "invalid creator", - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - desc: "failed in checking status", - bet: &types.Bet{ - MarketUID: testMarketUID, - OddsValue: "10", - Amount: sdkmath.NewInt(1000000), - Creator: testCreator, - OddsUID: testOddsUID1, - Status: types.Bet_STATUS_SETTLED, - }, - err: types.ErrBetIsSettled, - }, - { - desc: "not found market", - bet: &types.Bet{ - UID: "0db09053-2901-4110-8fb5-c14e21f8d400", - MarketUID: "nonExistMarket", - Creator: testCreator, - }, - err: types.ErrNoMatchingMarket, - }, - { - desc: "market is aborted", - bet: &types.Bet{ - MarketUID: testMarketUID, - OddsValue: "10", - Amount: sdkmath.NewInt(1000000), - Creator: testCreator, - OddsUID: testOddsUID1, - }, - updateMarket: &markettypes.Market{ - UID: testMarketUID, - Creator: testCreator, - StartTS: 1111111111, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - - Status: markettypes.MarketStatus_MARKET_STATUS_ABORTED, - }, - }, - { - desc: "market is canceled", - bet: &types.Bet{ - MarketUID: testMarketUID, - OddsValue: "10", - Amount: sdkmath.NewInt(1000000), - Creator: testCreator, - OddsUID: testOddsUID1, - }, - updateMarket: &markettypes.Market{ - UID: testMarketUID, - Creator: testCreator, - StartTS: 1111111111, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - - Status: markettypes.MarketStatus_MARKET_STATUS_CANCELED, - }, - }, - { - desc: "result is not declared", - bet: &types.Bet{ - MarketUID: testMarketUID, - OddsValue: "10", - Amount: sdkmath.NewInt(1000000), - Creator: testCreator, - OddsUID: testOddsUID1, - }, - updateMarket: &markettypes.Market{ - UID: testMarketUID, - Creator: testCreator, - StartTS: 1111111111, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - }, - err: types.ErrResultNotDeclared, - }, - { - desc: "success", - bet: &types.Bet{ - MarketUID: testMarketUID, - OddsValue: "10", - Amount: sdkmath.NewInt(1000000), - Creator: testCreator, - OddsUID: testOddsUID1, - - Result: types.Bet_RESULT_WON, - }, - updateMarket: &markettypes.Market{ - UID: testMarketUID, - Creator: testCreator, - StartTS: 1111111111, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - }, - } - - for _, tc := range tcs { - t.Run(tc.desc, func(t *testing.T) { - betUID := uuid.NewString() - - if tc.bet != nil { - resetMarket := markettypes.Market{ - UID: testMarketUID, - Creator: testCreator, - StartTS: 1111111111, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - } - tApp.MarketKeeper.SetMarket(ctx, resetMarket) - - if resetMarket.Status == markettypes.MarketStatus_MARKET_STATUS_ACTIVE { - _, err := tApp.OrderbookKeeper.InitiateOrderBookParticipation( - ctx, - simapp.TestParamUsers["user1"].Address, - resetMarket.UID, - sdkmath.NewInt(100000000), - sdkmath.NewInt(1), - ) - require.NoError(t, err) - } - - tc.bet.UID = betUID - placeTestBet(ctx, t, tApp, betUID, nil) - k.SetBet(ctx, *tc.bet, 1) - } - - if tc.updateMarket != nil { - tApp.MarketKeeper.SetMarket(ctx, *tc.updateMarket) - } - - if tc.betUID != "" { - betUID = tc.betUID - } - - if tc.bet == nil { - tc.bet = &types.Bet{ - Creator: "", - } - } - - err := k.Settle(ctx, tc.bet.Creator, betUID) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - return - } - - require.NoError(t, err) - }) - } -} - -func TestBatchSettleBet(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - - p := k.GetParams(ctx) - p.BatchSettlementCount = 7 - k.SetParams(ctx, p) - - marketCount := 5 - participationCount := 3 - marketBetCount := 10 - allBetCount := marketCount * marketBetCount - blockCount := allBetCount/int(p.BatchSettlementCount) + 1 - - marketUIDs := addTestMarketBatch(t, tApp, ctx, marketCount) - for _, marketUID := range marketUIDs { - market, found := tApp.MarketKeeper.GetMarket(ctx, marketUID) - require.True(t, found) - - market.Status = markettypes.MarketStatus_MARKET_STATUS_ACTIVE - tApp.MarketKeeper.SetMarket(ctx, market) - - depositorUser := 2 - for i := depositorUser; i <= depositorUser+participationCount; i++ { - _, err := tApp.OrderbookKeeper.InitiateOrderBookParticipation( - ctx, - simapp.TestParamUsers["user"+cast.ToString(i)].Address, - market.UID, - sdkmath.NewInt(100000000), - sdkmath.NewInt(1), - ) - require.NoError(t, err) - } - - for i := 0; i < marketBetCount; i++ { - placeTestBet(ctx, t, tApp, - uuid.NewString(), - &types.BetOdds{ - UID: testOddsUID1, - MarketUID: marketUID, - Value: "4.20", - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - ) - } - } - - allPendingBets, err := k.GetPendingBets(ctx) - require.NoError(t, err) - require.Equal(t, allBetCount, len(allPendingBets)) - - for _, marketUID := range marketUIDs[:len(marketUIDs)-2] { - market, found := tApp.MarketKeeper.GetMarket(ctx, marketUID) - require.True(t, found) - tApp.MarketKeeper.Resolve(ctx, market, &markettypes.MarketResolutionTicketPayload{ - UID: marketUID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID1, testOddsUID2, testOddsUID3}, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - } - - market, found := tApp.MarketKeeper.GetMarket(ctx, marketUIDs[len(marketUIDs)-2]) - require.True(t, found) - tApp.MarketKeeper.Resolve(ctx, market, &markettypes.MarketResolutionTicketPayload{ - UID: marketUIDs[len(marketUIDs)-2], - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - Status: markettypes.MarketStatus_MARKET_STATUS_CANCELED, - }) - - market, found = tApp.MarketKeeper.GetMarket(ctx, marketUIDs[len(marketUIDs)-1]) - require.True(t, found) - tApp.MarketKeeper.Resolve(ctx, market, &markettypes.MarketResolutionTicketPayload{ - UID: marketUIDs[len(marketUIDs)-1], - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - Status: markettypes.MarketStatus_MARKET_STATUS_ABORTED, - }) - - for i := 1; i <= blockCount; i++ { - ctx = ctx.WithBlockHeight(int64(i)) - err := k.BatchMarketSettlements(ctx) - require.NoError(t, err) - - pendingBets, err := k.GetPendingBets(ctx) - require.NoError(t, err) - - settledBets, err := k.GetSettledBets(ctx) - require.NoError(t, err) - - marketStats := tApp.MarketKeeper.GetMarketStats(ctx) - - t.Logf( - "block: %d, pending bets: %d, settled bets: %d, resolved markets: %v\n", - i, - len(pendingBets), - len(settledBets), - marketStats.ResolvedUnsettled, - ) - require.GreaterOrEqual(t, int(p.BatchSettlementCount)*i, len(settledBets)) - } - - allPendingBets, err = k.GetPendingBets(ctx) - require.NoError(t, err) - require.Equal(t, 0, len(allPendingBets)) - - allSettledBets, err := k.GetSettledBets(ctx) - require.NoError(t, err) - require.Equal(t, allBetCount, len(allSettledBets)) - - allBets, err := k.GetBets(ctx) - require.NoError(t, err) - for _, bet := range allBets { - require.NotEqual(t, 0, bet.SettlementHeight) - } -} diff --git a/x/bet/keeper/wager_test.go b/x/bet/keeper/wager_test.go deleted file mode 100644 index 11fc0464..00000000 --- a/x/bet/keeper/wager_test.go +++ /dev/null @@ -1,237 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" -) - -func TestWager(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - ctx = ctx.WithBlockTime(time.Now()) - tcs := []struct { - desc string - bet *types.Bet - err error - market *markettypes.Market - activeBetOdds []*types.BetOdds - betOdds map[string]*types.BetOddsCompact - }{ - { - desc: "invalid creator address", - bet: &types.Bet{ - UID: "betUID", - MarketUID: "notExistMarketUID", - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - desc: "not found market", - bet: &types.Bet{ - UID: "betUID", - MarketUID: "notExistMarketUID", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - err: types.ErrNoMatchingMarket, - }, - { - desc: "inactive market", - market: &markettypes.Market{ - UID: "uid_inactive", - Status: markettypes.MarketStatus_MARKET_STATUS_INACTIVE, - }, - bet: &types.Bet{ - UID: "betUID", - MarketUID: "uid_inactive", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - err: types.ErrInactiveMarket, - }, - { - desc: "not active market", - market: &markettypes.Market{ - UID: "uid_declared", - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - bet: &types.Bet{ - UID: "betUID", - MarketUID: "uid_declared", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - err: types.ErrInactiveMarket, - }, - { - desc: "expired market", - market: &markettypes.Market{ - UID: "uid_expired", - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - EndTS: 0o00000000, - }, - bet: &types.Bet{ - UID: "betUID", - MarketUID: "uid_expired", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - err: types.ErrEndTSIsPassed, - }, - { - desc: "not exist odds", - market: &markettypes.Market{ - UID: "uid_oddsNotexist", - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: []*markettypes.Odds{ - {UID: "odds1"}, - {UID: "odds2"}, - }, - }, - activeBetOdds: []*types.BetOdds{ - {UID: "odds1", MarketUID: "uid_oddsNotexist", Value: "2.52"}, - {UID: "odds2", MarketUID: "uid_oddsNotexist", Value: "1.50"}, - }, - bet: &types.Bet{ - UID: "betUID", - MarketUID: "uid_oddsNotexist", - OddsUID: "notExistOdds", - Amount: sdkmath.NewInt(1000), - OddsValue: "5", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - err: types.ErrOddsUIDNotExist, - }, - { - desc: "low bet amount", - market: &markettypes.Market{ - UID: "uid_lowBetAmount", - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: []*markettypes.Odds{ - {UID: "odds1"}, - {UID: "odds2"}, - }, - }, - activeBetOdds: []*types.BetOdds{ - {UID: "odds1", MarketUID: "uid_lowBetAmount", Value: "2.52"}, - {UID: "odds2", MarketUID: "uid_lowBetAmount", Value: "1.50"}, - }, - bet: &types.Bet{ - UID: "betUID", - MarketUID: "uid_lowBetAmount", - OddsUID: "odds1", - Amount: sdkmath.NewInt(100), - OddsValue: "5", - Creator: simapp.TestParamUsers["user1"].Address.String(), - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - err: types.ErrBetAmountIsLow, - }, - { - desc: "success", - market: &markettypes.Market{ - UID: "uid_success", - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - EndTS: uint64(ctx.BlockTime().Unix()) + 1000, - Odds: []*markettypes.Odds{ - {UID: "odds1"}, - {UID: "odds2"}, - }, - }, - activeBetOdds: []*types.BetOdds{ - { - UID: "odds1", - MarketUID: "uid_success", - Value: "2.52", - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - { - UID: "odds2", - MarketUID: "uid_success", - Value: "1.50", - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - }, - bet: &types.Bet{ - UID: "betUID", - MarketUID: "uid_success", - OddsUID: "odds1", - Amount: sdkmath.NewInt(1000000), - OddsValue: "5", - Creator: simapp.TestParamUsers["user1"].Address.String(), - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - betOdds: map[string]*types.BetOddsCompact{ - "odds1": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1")}, - "odds2": {UID: "odds1", MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("1.0")}, - }, - }, - } - - for _, tc := range tcs { - t.Run(tc.desc, func(t *testing.T) { - if tc.market != nil { - tApp.MarketKeeper.SetMarket(ctx, *tc.market) - - var oddsUIDs []string - for _, v := range tc.market.Odds { - oddsUIDs = append(oddsUIDs, v.UID) - } - err := tApp.OrderbookKeeper.InitiateOrderBook(ctx, tc.market.UID, oddsUIDs) - require.NoError(t, err) - - if tc.market.Status == markettypes.MarketStatus_MARKET_STATUS_ACTIVE { - _, err = tApp.OrderbookKeeper.InitiateOrderBookParticipation( - ctx, - simapp.TestParamUsers["user1"].Address, - tc.market.UID, - sdkmath.NewInt(100000000), - sdkmath.NewInt(1), - ) - require.NoError(t, err) - } - } - - err := k.Wager(ctx, tc.bet, tc.betOdds) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - return - } - - require.NoError(t, err) - }) - } -} diff --git a/x/bet/simulation/decoder_test.go b/x/bet/simulation/decoder_test.go deleted file mode 100644 index 100e7d5f..00000000 --- a/x/bet/simulation/decoder_test.go +++ /dev/null @@ -1,93 +0,0 @@ -package simulation_test - -import ( - "fmt" - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/types/kv" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/bet/simulation" - "github.com/sge-network/sge/x/bet/types" -) - -func TestDecodeStore(t *testing.T) { - cdc := app.MakeEncodingConfig().Marshaler - dec := simulation.NewDecodeStore(cdc) - - bet := types.NewBet( - sample.AccAddress(), - &types.WagerProps{ - UID: uuid.NewString(), - Amount: sdkmath.NewInt(10), - Ticket: "", - }, - &types.BetOdds{ - UID: uuid.NewString(), - MarketUID: uuid.NewString(), - Value: "100", - MaxLossMultiplier: sdkmath.LegacyNewDec(1), - }, - types.MetaData{ - SelectedOddsType: types.OddsType_ODDS_TYPE_DECIMAL, - SelectedOddsValue: "1.5", - }, - ) - - betUID := types.UID2ID{ - UID: bet.UID, - ID: 1, - } - - betStats := types.BetStats{ - Count: 1, - } - - pendingBet := types.PendingBet{ - UID: bet.UID, - Creator: bet.Creator, - } - - settledBet := types.SettledBet{ - UID: bet.UID, - BettorAddress: bet.Creator, - } - - kvPairs := kv.Pairs{ - Pairs: []kv.Pair{ - {Key: types.BetListPrefix, Value: cdc.MustMarshal(bet)}, - {Key: types.BetIDListPrefix, Value: cdc.MustMarshal(&betUID)}, - {Key: types.BetStatsKey, Value: cdc.MustMarshal(&betStats)}, - {Key: types.PendingBetListPrefix, Value: cdc.MustMarshal(&pendingBet)}, - {Key: types.SettledBetListPrefix, Value: cdc.MustMarshal(&settledBet)}, - {Key: []byte{0x99}, Value: []byte{0x99}}, - }, - } - tests := []struct { - name string - expectedLog string - }{ - {"bet", fmt.Sprintf("%v\n%v", *bet, *bet)}, - {"bet_uid", fmt.Sprintf("%v\n%v", betUID, betUID)}, - {"bet_stats", fmt.Sprintf("%v\n%v", betStats, betStats)}, - {"pending_bets", fmt.Sprintf("%v\n%v", pendingBet, pendingBet)}, - {"settled_bets", fmt.Sprintf("%v\n%v", settledBet, settledBet)}, - {"other", ""}, - } - - for i, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - switch i { - case len(tests) - 1: - require.Panics(t, func() { dec(kvPairs.Pairs[i], kvPairs.Pairs[i]) }, tt.name) - default: - require.Equal(t, tt.expectedLog, dec(kvPairs.Pairs[i], kvPairs.Pairs[i]), tt.name) - } - }) - } -} diff --git a/x/bet/simulation/genesis_test.go b/x/bet/simulation/genesis_test.go deleted file mode 100644 index e0fdb911..00000000 --- a/x/bet/simulation/genesis_test.go +++ /dev/null @@ -1,77 +0,0 @@ -package simulation_test - -import ( - "encoding/json" - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/codec" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/types/module" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - - "github.com/sge-network/sge/x/bet/simulation" - "github.com/sge-network/sge/x/bet/types" -) - -// TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. -// Abnormal scenarios are not tested here. -func TestRandomizedGenState(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - simState := module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - NumBonded: 3, - Accounts: simtypes.RandomAccounts(r, 3), - InitialStake: sdkmath.NewInt(1000), - GenState: make(map[string]json.RawMessage), - } - - simulation.RandomizedGenState(&simState) - - var betGenesis types.GenesisState - simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &betGenesis) - - require.Equal(t, uint32(1000), betGenesis.Params.BatchSettlementCount) - require.Equal(t, uint32(10), betGenesis.Params.MaxBetByUidQueryCount) -} - -// TestRandomizedGenState tests abnormal scenarios of applying RandomizedGenState. -func TestRandomizedGenState1(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - // all these tests will panic - tests := []struct { - simState module.SimulationState - panicMsg string - }{ - { // panic => reason: incomplete initialization of the simState - module.SimulationState{}, "invalid memory address or nil pointer dereference"}, - { // panic => reason: incomplete initialization of the simState - module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - }, "assignment to entry in nil map"}, - } - - for _, tt := range tests { - simTest := tt.simState - require.Panicsf(t, func() { simulation.RandomizedGenState(&simTest) }, tt.panicMsg) - } -} diff --git a/x/bet/simulation/params_test.go b/x/bet/simulation/params_test.go deleted file mode 100644 index fa3cb84e..00000000 --- a/x/bet/simulation/params_test.go +++ /dev/null @@ -1,37 +0,0 @@ -package simulation_test - -import ( - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/bet/simulation" -) - -func TestParamChanges(t *testing.T) { - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - expected := []struct { - composedKey string - key string - subspace string - }{ - {"bet/BatchSettlementCount", "BatchSettlementCount", "bet"}, - {"bet/MaxBetByUidQueryCount", "MaxBetByUidQueryCount", "bet"}, - {"bet/MinAmount", "MinAmount", "bet"}, - {"bet/Fee", "Fee", "bet"}, - } - - paramChanges := simulation.ParamChanges(r) - require.Len(t, paramChanges, 4) - - for i, p := range paramChanges { - require.Equal(t, expected[i].composedKey, p.ComposedKey()) - require.Equal(t, expected[i].key, p.Key()) - require.Equal(t, expected[i].subspace, p.Subspace()) - } -} diff --git a/x/bet/simulation/proposals_test.go b/x/bet/simulation/proposals_test.go deleted file mode 100644 index 6e7a8b5e..00000000 --- a/x/bet/simulation/proposals_test.go +++ /dev/null @@ -1,50 +0,0 @@ -package simulation_test - -import ( - "fmt" - "math/rand" - "testing" - - sdkmath "cosmossdk.io/math" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/address" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/bet/simulation" - "github.com/sge-network/sge/x/bet/types" -) - -func TestProposalMsgs(t *testing.T) { - // initialize parameters - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - ctx := sdk.NewContext(nil, tmproto.Header{}, true, nil) - accounts := simtypes.RandomAccounts(r, 3) - - // execute ProposalMsgs function - weightedProposalMsgs := simulation.ProposalMsgs() - require.Equal(t, len(weightedProposalMsgs), 1) - - w0 := weightedProposalMsgs[0] - - // tests w0 interface: - require.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) - require.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) - - msg := w0.MsgSimulatorFn()(r, ctx, accounts) - msgUpdateParams, ok := msg.(*types.MsgUpdateParams) - require.True(t, ok) - - fmt.Println(msgUpdateParams) - require.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) - require.Equal(t, uint32(2540), msgUpdateParams.Params.BatchSettlementCount) - require.Equal(t, uint32(456), msgUpdateParams.Params.MaxBetByUidQueryCount) - require.Equal(t, types.Constraints{ - MinAmount: sdkmath.NewInt(300), - Fee: sdkmath.NewInt(59), - }, msgUpdateParams.Params.Constraints) -} diff --git a/x/bet/types/odds_type.pb.go b/x/bet/types/odds_type.pb.go deleted file mode 100644 index a168cf0b..00000000 --- a/x/bet/types/odds_type.pb.go +++ /dev/null @@ -1,83 +0,0 @@ -// Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/odds_type.proto - -package types - -import ( - fmt "fmt" - proto "github.com/cosmos/gogoproto/proto" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package - -// OddsType is the representation of the type of the odds. -type OddsType int32 - -const ( - // invalid odds type - OddsType_ODDS_TYPE_UNSPECIFIED OddsType = 0 - // decimal odds type (european) - OddsType_ODDS_TYPE_DECIMAL OddsType = 1 - // fractional odds type (british) - OddsType_ODDS_TYPE_FRACTIONAL OddsType = 2 - // moneyline odds type (american) - OddsType_ODDS_TYPE_MONEYLINE OddsType = 3 -) - -var OddsType_name = map[int32]string{ - 0: "ODDS_TYPE_UNSPECIFIED", - 1: "ODDS_TYPE_DECIMAL", - 2: "ODDS_TYPE_FRACTIONAL", - 3: "ODDS_TYPE_MONEYLINE", -} - -var OddsType_value = map[string]int32{ - "ODDS_TYPE_UNSPECIFIED": 0, - "ODDS_TYPE_DECIMAL": 1, - "ODDS_TYPE_FRACTIONAL": 2, - "ODDS_TYPE_MONEYLINE": 3, -} - -func (x OddsType) String() string { - return proto.EnumName(OddsType_name, int32(x)) -} - -func (OddsType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_8499746baf6d0fd2, []int{0} -} - -func init() { - proto.RegisterEnum("sgenetwork.sge.bet.OddsType", OddsType_name, OddsType_value) -} - -func init() { - proto.RegisterFile("sgenetwork/sge/bet/odds_type.proto", fileDescriptor_8499746baf6d0fd2) -} - -var fileDescriptor_8499746baf6d0fd2 = []byte{ - // 218 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2a, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x4f, 0x4a, 0x2d, 0xd1, 0xcf, - 0x4f, 0x49, 0x29, 0x8e, 0x2f, 0xa9, 0x2c, 0x48, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, - 0x42, 0xa8, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0x4b, 0x4a, 0x2d, 0xd1, 0xca, 0xe7, 0xe2, 0xf0, 0x4f, - 0x49, 0x29, 0x0e, 0xa9, 0x2c, 0x48, 0x15, 0x92, 0xe4, 0x12, 0xf5, 0x77, 0x71, 0x09, 0x8e, 0x0f, - 0x89, 0x0c, 0x70, 0x8d, 0x0f, 0xf5, 0x0b, 0x0e, 0x70, 0x75, 0xf6, 0x74, 0xf3, 0x74, 0x75, 0x11, - 0x60, 0x10, 0x12, 0xe5, 0x12, 0x44, 0x48, 0xb9, 0xb8, 0x3a, 0x7b, 0xfa, 0x3a, 0xfa, 0x08, 0x30, - 0x0a, 0x49, 0x70, 0x89, 0x20, 0x84, 0xdd, 0x82, 0x1c, 0x9d, 0x43, 0x3c, 0xfd, 0xfd, 0x1c, 0x7d, - 0x04, 0x98, 0x84, 0xc4, 0xb9, 0x84, 0x11, 0x32, 0xbe, 0xfe, 0x7e, 0xae, 0x91, 0x3e, 0x9e, 0x7e, - 0xae, 0x02, 0xcc, 0x4e, 0x0e, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, - 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, - 0x96, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0x0b, 0xf2, 0x82, 0x2e, 0xb2, 0x77, - 0x2a, 0xc0, 0x1e, 0x02, 0xf9, 0xa5, 0x38, 0x89, 0x0d, 0xec, 0x1b, 0x63, 0x40, 0x00, 0x00, 0x00, - 0xff, 0xff, 0x6c, 0x31, 0xec, 0xd9, 0xf3, 0x00, 0x00, 0x00, -} diff --git a/x/house/client/cli/query_deposit_test.go b/x/house/client/cli/query_deposit_test.go deleted file mode 100644 index e9a79ebd..00000000 --- a/x/house/client/cli/query_deposit_test.go +++ /dev/null @@ -1,221 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - "time" - - sdkmath "cosmossdk.io/math" - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/house/client/cli" - "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" -) - -const testMarketUID = "5db09053-2901-4110-8fb5-c14e21f8d555" - -func networkWithDepositObjects(t *testing.T, n int) (*network.Network, []types.Deposit, []types.Withdrawal) { - t.Helper() - cfg := network.DefaultConfig() - - // market module state - marketState := markettypes.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[markettypes.ModuleName], &marketState)) - - market := markettypes.Market{ - UID: testMarketUID, - Creator: simapp.TestParamUsers["user1"].Address.String(), - StartTS: 1111111111, - EndTS: uint64(time.Now().Unix()) + 5000, - Odds: []*markettypes.Odds{ - {UID: "6db09053-2901-4110-8fb5-c14e21f8d666", Meta: "Odds 1"}, - {UID: "5e31c60f-2025-48ce-ae79-1dc110f16358", Meta: "Odds 2"}, - {UID: "6e31c60f-2025-48ce-ae79-1dc110f16354", Meta: "Odds 3"}, - }, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - } - nullify.Fill(&market) - marketState.MarketList = []markettypes.Market{market} - - marketBuf, err := cfg.Codec.MarshalJSON(&marketState) - require.NoError(t, err) - cfg.GenesisState[markettypes.ModuleName] = marketBuf - - // house module state - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - deposit := types.Deposit{ - Creator: testAddress, - DepositorAddress: testAddress, - MarketUID: market.UID, - ParticipationIndex: cast.ToUint64(i + 1), - Amount: sdkmath.NewInt(10), - WithdrawalCount: 0, - TotalWithdrawalAmount: sdkmath.NewInt(0), - } - nullify.Fill(&deposit) - - withdrawal := types.Withdrawal{ - Creator: testAddress, - Address: deposit.DepositorAddress, - ID: cast.ToUint64(i + 1), - MarketUID: deposit.MarketUID, - ParticipationIndex: deposit.ParticipationIndex, - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - Amount: deposit.Amount, - } - nullify.Fill(&withdrawal) - - state.DepositList = append(state.DepositList, deposit) - state.WithdrawalList = append(state.WithdrawalList, withdrawal) - } - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), state.DepositList, state.WithdrawalList -} - -func TestQueryDeposit(t *testing.T) { - net, objs, _ := networkWithDepositObjects(t, 5) - - t.Run("ListDeposits", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryDeposits(), args) - require.NoError(t, err) - var resp types.QueryDepositsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Deposits), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryDeposits(), args) - require.NoError(t, err) - var resp types.QueryDepositsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Deposits), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryDeposits(), args) - require.NoError(t, err) - var resp types.QueryDepositsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.Deposits), - ) - }) - }) - - t.Run("ListDepositsByDepositor", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testAddress, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryDepositsByAccount(), args) - require.NoError(t, err) - var resp types.QueryDepositsByAccountResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Deposits), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryDepositsByAccount(), args) - require.NoError(t, err) - var resp types.QueryDepositsByAccountResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Deposits), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryDepositsByAccount(), args) - require.NoError(t, err) - var resp types.QueryDepositsByAccountResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.Deposits), - ) - }) - }) -} diff --git a/x/house/client/cli/query_params_test.go b/x/house/client/cli/query_params_test.go deleted file mode 100644 index d5a6171b..00000000 --- a/x/house/client/cli/query_params_test.go +++ /dev/null @@ -1,58 +0,0 @@ -package cli_test - -import ( - "encoding/json" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/house/client/cli" - "github.com/sge-network/sge/x/house/types" -) - -func TestQueryParams(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdQueryParams(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - var params types.QueryParamsResponse - err = json.Unmarshal(res.Bytes(), ¶ms) - // command-line response, wraps the primitive numbers in double quotes, so it is not unmarshall-able. - require.EqualError( - t, - err, - "json: cannot unmarshal string into Go struct field Params.params.max_withdrawal_count of type uint64", - ) - - defaultParams := types.DefaultParams() - defaultParams.MaxWithdrawalCount = 0 - require.Equal(t, types.QueryParamsResponse{ - Params: defaultParams, - }, params) - }) - } -} diff --git a/x/house/client/cli/query_test.go b/x/house/client/cli/query_test.go deleted file mode 100644 index 1f9d1b79..00000000 --- a/x/house/client/cli/query_test.go +++ /dev/null @@ -1,49 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - "github.com/sge-network/sge/testutil/network" - - "github.com/sge-network/sge/x/house/client/cli" -) - -const testAddress = "cosmos1s4ycalgh3gjemd4hmqcvcgmnf647rnd0tpg2w9" - -func TestGetQueryCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetQueryCmd(""), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True( - t, - strings.HasPrefix(string(res.Bytes()), "Querying commands for the house module"), - ) - }) - } -} diff --git a/x/house/client/cli/query_withdrawal_test.go b/x/house/client/cli/query_withdrawal_test.go deleted file mode 100644 index 87c733d6..00000000 --- a/x/house/client/cli/query_withdrawal_test.go +++ /dev/null @@ -1,84 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/house/client/cli" - "github.com/sge-network/sge/x/house/types" - "github.com/stretchr/testify/require" -) - -func TestQueryWithdraw(t *testing.T) { - net, _, objs := networkWithDepositObjects(t, 5) - - t.Run("ListWithdrawalsByAccount", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testAddress, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryWithdrawalsByAccount(), args) - require.NoError(t, err) - var resp types.QueryWithdrawalsByAccountResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Withdrawals), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Withdrawals), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryWithdrawalsByAccount(), args) - require.NoError(t, err) - var resp types.QueryWithdrawalsByAccountResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Withdrawals), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Withdrawals), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryWithdrawalsByAccount(), args) - require.NoError(t, err) - var resp types.QueryWithdrawalsByAccountResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.Withdrawals), - ) - }) - }) -} diff --git a/x/house/client/cli/tx_deposit_test.go b/x/house/client/cli/tx_deposit_test.go deleted file mode 100644 index 78b80db5..00000000 --- a/x/house/client/cli/tx_deposit_test.go +++ /dev/null @@ -1,86 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/house/client/cli" -) - -func TestTXDepositCLI(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - commonArgs := []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf( - "--%s=%s", - flags.FlagFees, - sdk.NewCoins(sdk.NewCoin(net.Config.BondDenom, sdkmath.NewInt(10))).String(), - ), - } - - t.Run("Deposit", func(t *testing.T) { - for _, tc := range []struct { - desc string - marketUID string - amount string - ticket string - - err error - code uint32 - }{ - { - marketUID: "6e31c60f-2025-48ce-ae79-1dc110f16355", - amount: "555", - ticket: "ticket", - - desc: "valid", - }, - { - marketUID: "invalidUID", - amount: "555", - ticket: "ticket", - - desc: "validation failed", - err: fmt.Errorf("any error"), - }, - { - marketUID: "6e31c60f-2025-48ce-ae79-1dc110f16355", - amount: "invalidAmount", - ticket: "ticket", - - desc: "invalid amuont", - err: fmt.Errorf("any error"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.marketUID, - tc.amount, - tc.ticket, - } - args = append(args, commonArgs...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdDeposit(), args) - if tc.err != nil { - require.NotNil(t, err) - } else { - require.NoError(t, err) - var resp sdk.TxResponse - require.NoError(t, ctx.Codec.UnmarshalJSON(out.Bytes(), &resp)) - } - }) - } - }) -} diff --git a/x/house/client/cli/tx_test.go b/x/house/client/cli/tx_test.go deleted file mode 100644 index 4021e3ab..00000000 --- a/x/house/client/cli/tx_test.go +++ /dev/null @@ -1,44 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/house/client/cli" -) - -func TestGetTxCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.NewTxCmd(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True(t, strings.HasPrefix(string(res.Bytes()), "House transaction subcommands")) - }) - } -} diff --git a/x/house/client/cli/tx_withdraw_test.go b/x/house/client/cli/tx_withdraw_test.go deleted file mode 100644 index 92b7eb9c..00000000 --- a/x/house/client/cli/tx_withdraw_test.go +++ /dev/null @@ -1,93 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/house/client/cli" -) - -func TestTXWithdrawCLI(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - commonArgs := []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf( - "--%s=%s", - flags.FlagFees, - sdk.NewCoins(sdk.NewCoin(net.Config.BondDenom, sdkmath.NewInt(10))).String(), - ), - } - - t.Run("Withdraw", func(t *testing.T) { - for _, tc := range []struct { - desc string - marketUID string - participationIndex uint64 - mode int32 - amount string - ticket string - - err error - code uint32 - }{ - { - marketUID: "6e31c60f-2025-48ce-ae79-1dc110f16355", - amount: "555", - participationIndex: 1, - mode: 1, - ticket: "ticket", - - desc: "valid", - }, - { - marketUID: "invalidUID", - amount: "555", - ticket: "ticket", - - desc: "validation failed", - err: fmt.Errorf("any error"), - }, - { - marketUID: "6e31c60f-2025-48ce-ae79-1dc110f16355", - amount: "invalidAmount", - ticket: "ticket", - - desc: "invalid amuont", - err: fmt.Errorf("any error"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.marketUID, - cast.ToString(tc.participationIndex), - tc.ticket, - cast.ToString(tc.mode), - tc.amount, - } - args = append(args, commonArgs...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdWithdraw(), args) - if tc.err != nil { - require.NotNil(t, err) - } else { - require.NoError(t, err) - var resp sdk.TxResponse - require.NoError(t, ctx.Codec.UnmarshalJSON(out.Bytes(), &resp)) - } - }) - } - }) -} diff --git a/x/house/handler.go b/x/house/handler.go deleted file mode 100644 index f91f412d..00000000 --- a/x/house/handler.go +++ /dev/null @@ -1,37 +0,0 @@ -package house - -import ( - "fmt" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/x/house/keeper" - "github.com/sge-network/sge/x/house/types" -) - -// NewHandler returns sdk.handler instance with configured message handler function -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - - switch msg := msg.(type) { - case *types.MsgDeposit: - res, err := msgServer.Deposit(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgWithdraw: - res, err := msgServer.Withdraw(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdateParams: - res, err := msgServer.UpdateParams(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrtypes.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/house/keeper/deposit_test.go b/x/house/keeper/deposit_test.go deleted file mode 100644 index 196b919d..00000000 --- a/x/house/keeper/deposit_test.go +++ /dev/null @@ -1,78 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/house/keeper" - "github.com/sge-network/sge/x/house/types" -) - -func createNDeposits( - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.Deposit { - items := make([]types.Deposit, n) - - for i := range items { - items[i].Creator = sample.AccAddress() - items[i].MarketUID = testMarketUID - items[i].ParticipationIndex = uint64(i + 1) - items[i].DepositorAddress = testDepositorAddress - items[i].Amount = sdkmath.NewInt(100) - items[i].TotalWithdrawalAmount = sdkmath.NewInt(0) - - keeper.SetDeposit(ctx, items[i]) - } - return items -} - -func TestDepositGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNDeposits(k, ctx, 10) - - rst, found := k.GetDeposit(ctx, - uuid.NewString(), - uuid.NewString(), - 1, - ) - var expectedResp types.Deposit - require.False(t, found) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - for _, item := range items { - rst, found := k.GetDeposit(ctx, - item.DepositorAddress, - item.MarketUID, - item.ParticipationIndex, - ) - require.True(t, found) - require.Equal(t, - nullify.Fill(item), - nullify.Fill(rst), - ) - } -} - -func TestDepositGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNDeposits(k, ctx, 10) - - deposits, err := k.GetAllDeposits(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(deposits), - ) -} diff --git a/x/house/keeper/grpc_query_deposit_test.go b/x/house/keeper/grpc_query_deposit_test.go deleted file mode 100644 index 0fafeae7..00000000 --- a/x/house/keeper/grpc_query_deposit_test.go +++ /dev/null @@ -1,129 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/house/types" -) - -func TestDepositsQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNDeposits(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryDepositsRequest { - return &types.QueryDepositsRequest{ - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.Deposits(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Deposits), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.Deposits(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Deposits), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.Deposits(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Deposits), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.Deposits(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} - -func TestDepositsByAccountQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNDeposits(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryDepositsByAccountRequest { - return &types.QueryDepositsByAccountRequest{ - Address: testDepositorAddress, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.DepositsByAccount(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Deposits), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.DepositsByAccount(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Deposits), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Deposits), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.DepositsByAccount(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Deposits), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.DepositsByAccount(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/house/keeper/grpc_query_params_test.go b/x/house/keeper/grpc_query_params_test.go deleted file mode 100644 index 022197e2..00000000 --- a/x/house/keeper/grpc_query_params_test.go +++ /dev/null @@ -1,32 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/house/types" -) - -func TestParamsQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - response, err := k.Params(wctx, &types.QueryParamsRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryParamsResponse{Params: params}, response) -} - -func TestParamsInvalidQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - _, err := k.Params(wctx, nil) - require.Error(t, err) -} diff --git a/x/house/keeper/grpc_query_withdrawal_test.go b/x/house/keeper/grpc_query_withdrawal_test.go deleted file mode 100644 index 3fdaca3f..00000000 --- a/x/house/keeper/grpc_query_withdrawal_test.go +++ /dev/null @@ -1,134 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/house/types" -) - -func TestWithdrawQuerySingle(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNWithdrawals(k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryWithdrawalRequest - response *types.QueryWithdrawalResponse - err error - }{ - { - desc: "First", - request: &types.QueryWithdrawalRequest{ - DepositorAddress: msgs[0].Address, - MarketUid: msgs[0].MarketUID, - ParticipationIndex: msgs[0].ParticipationIndex, - Id: msgs[0].ID, - }, - response: &types.QueryWithdrawalResponse{Withdrawal: msgs[0]}, - }, - { - desc: "Second", - request: &types.QueryWithdrawalRequest{ - DepositorAddress: msgs[1].Address, - MarketUid: msgs[1].MarketUID, - ParticipationIndex: msgs[1].ParticipationIndex, - Id: msgs[1].ID, - }, - response: &types.QueryWithdrawalResponse{Withdrawal: msgs[1]}, - }, - { - desc: "KeyNotFound", - request: &types.QueryWithdrawalRequest{ - DepositorAddress: msgs[0].Address, - MarketUid: uuid.NewString(), - ParticipationIndex: msgs[0].ParticipationIndex, - Id: msgs[0].ID, - }, - err: status.Error(codes.NotFound, "not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.Withdrawal(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} - -func TestWithdrawByAccountQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNWithdrawals(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryWithdrawalsByAccountRequest { - return &types.QueryWithdrawalsByAccountRequest{ - Address: testDepositorAddress, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.WithdrawalsByAccount(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Withdrawals), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Withdrawals), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.WithdrawalsByAccount(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Withdrawals), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Withdrawals), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.WithdrawalsByAccount(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Withdrawals), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.WithdrawalsByAccount(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/house/keeper/keeper_test.go b/x/house/keeper/keeper_test.go deleted file mode 100644 index 28d8d928..00000000 --- a/x/house/keeper/keeper_test.go +++ /dev/null @@ -1,39 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/house/keeper" - markettypes "github.com/sge-network/sge/x/market/types" -) - -var ( - testMarketUID = uuid.NewString() - testDepositorAddress = sample.AccAddress() - testMarketOdds = []*markettypes.Odds{ - {UID: uuid.NewString(), Meta: "Odds 1"}, - {UID: uuid.NewString(), Meta: "Odds 2"}, - {UID: uuid.NewString(), Meta: "Odds 3"}, - } -) - -func setupKeeper(t testing.TB) (*keeper.KeeperTest, sdk.Context) { - _, k, ctx := setupKeeperAndApp(t) - - return k, ctx -} - -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp, tApp.HouseKeeper, ctx.WithBlockTime(time.Now()) -} diff --git a/x/house/keeper/msg_server_deposit_test.go b/x/house/keeper/msg_server_deposit_test.go deleted file mode 100644 index c6facf98..00000000 --- a/x/house/keeper/msg_server_deposit_test.go +++ /dev/null @@ -1,187 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" -) - -func TestMsgServerDeposit(t *testing.T) { - tApp, k, msgk, ctx, wctx := setupMsgServerAndApp(t) - creator := simapp.TestParamUsers["user1"] - depositor := simapp.TestParamUsers["user2"] - // var err error - - marketItem := markettypes.Market{ - UID: testMarketUID, - Creator: creator.Address.String(), - StartTS: cast.ToUint64(time.Now().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - } - - tApp.MarketKeeper.SetMarket(ctx, marketItem) - - var oddsUIDs []string - for _, v := range marketItem.Odds { - oddsUIDs = append(oddsUIDs, v.UID) - } - err := tApp.OrderbookKeeper.InitiateOrderBook(ctx, marketItem.UID, oddsUIDs) - require.NoError(t, err) - - t.Run("min deposit", func(t *testing.T) { - inputDeposit := &types.MsgDeposit{ - Creator: creator.Address.String(), - Amount: sdkmath.NewInt(1), - } - - _, err := msgk.Deposit(wctx, inputDeposit) - require.ErrorIs(t, types.ErrDepositTooSmall, err) - }) - - t.Run("no ticket", func(t *testing.T) { - inputDeposit := &types.MsgDeposit{ - Creator: creator.Address.String(), - Amount: sdkmath.NewInt(1000), - } - - _, err := msgk.Deposit(wctx, inputDeposit) - require.ErrorIs(t, types.ErrInTicketVerification, err) - }) - - t.Run("no authorization found", func(t *testing.T) { - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: creator.Address.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": testKyc, - "depositor_address": depositor.Address.String(), - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputDeposit := &types.MsgDeposit{ - Creator: creator.Address.String(), - MarketUID: testMarketUID, - Amount: sdkmath.NewInt(1000), - Ticket: ticket, - } - - _, err = msgk.Deposit(wctx, inputDeposit) - require.ErrorIs(t, types.ErrAuthorizationNotFound, err) - }) - - t.Run("success without authorization", func(t *testing.T) { - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: depositor.Address.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": testKyc, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputDeposit := &types.MsgDeposit{ - Creator: depositor.Address.String(), - MarketUID: testMarketUID, - Amount: sdkmath.NewInt(1000), - Ticket: ticket, - } - - depResp, err := msgk.Deposit(wctx, inputDeposit) - require.NoError(t, err) - rst, found := k.GetDeposit(ctx, - depositor.Address.String(), - testMarketUID, - depResp.ParticipationIndex, - ) - require.True(t, found) - require.Equal(t, inputDeposit.Creator, rst.Creator) - }) - - t.Run("success with authorization", func(t *testing.T) { - grantAmount := sdkmath.NewInt(1000) - - expTime := time.Now().Add(5 * time.Minute) - err := tApp.AuthzKeeper.SaveGrant(ctx, - creator.Address, - depositor.Address, - types.NewDepositAuthorization(grantAmount), - &expTime, - ) - require.NoError(t, err) - - authzBefore, _ := tApp.AuthzKeeper.GetAuthorization( - ctx, - creator.Address, - depositor.Address, - sdk.MsgTypeURL(&types.MsgDeposit{}), - ) - authzBeforeW, ok := authzBefore.(*types.DepositAuthorization) - require.True(t, ok) - require.Equal(t, grantAmount, authzBeforeW.SpendLimit) - - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: depositor.Address.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "depositor_address": depositor.Address.String(), - "kyc_data": testKyc, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputDeposit := &types.MsgDeposit{ - Creator: creator.Address.String(), - MarketUID: testMarketUID, - Amount: sdkmath.NewInt(1000), - Ticket: ticket, - } - - depResp, err := msgk.Deposit(wctx, inputDeposit) - require.NoError(t, err) - rst, found := k.GetDeposit(ctx, - depositor.Address.String(), - testMarketUID, - depResp.ParticipationIndex, - ) - require.True(t, found) - require.Equal(t, inputDeposit.Creator, rst.Creator) - - participation, found := tApp.OrderbookKeeper.GetOrderBookParticipation( - ctx, - testMarketUID, - depResp.ParticipationIndex, - ) - require.True(t, found) - require.Equal(t, inputDeposit.Amount, participation.Liquidity.Add(participation.Fee)) - - authzAfter, _ := tApp.AuthzKeeper.GetAuthorization(ctx, - creator.Address, - depositor.Address, - sdk.MsgTypeURL(&types.MsgDeposit{}), - ) - require.Nil(t, authzAfter) - }) -} diff --git a/x/house/keeper/msg_server_test.go b/x/house/keeper/msg_server_test.go deleted file mode 100644 index 89704cd2..00000000 --- a/x/house/keeper/msg_server_test.go +++ /dev/null @@ -1,19 +0,0 @@ -package keeper_test - -import ( - "context" - "testing" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/house/keeper" - "github.com/sge-network/sge/x/house/types" -) - -func setupMsgServerAndApp( - t testing.TB, -) (*simapp.TestApp, *keeper.KeeperTest, types.MsgServer, sdk.Context, context.Context) { - tApp, k, ctx := setupKeeperAndApp(t) - return tApp, k, keeper.NewMsgServerImpl(*k), ctx, sdk.WrapSDKContext(ctx) -} diff --git a/x/house/keeper/msg_server_withdraw_test.go b/x/house/keeper/msg_server_withdraw_test.go deleted file mode 100644 index beb60a44..00000000 --- a/x/house/keeper/msg_server_withdraw_test.go +++ /dev/null @@ -1,172 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" -) - -func TestMsgServerWithdraw(t *testing.T) { - tApp, k, msgk, ctx, wctx := setupMsgServerAndApp(t) - creator := simapp.TestParamUsers["user1"] - depositor := simapp.TestParamUsers["user2"] - // var err error - - marketItem := markettypes.Market{ - UID: testMarketUID, - Creator: creator.Address.String(), - StartTS: cast.ToUint64(time.Now().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Unix()) + 1000, - Odds: testMarketOdds, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - } - - tApp.MarketKeeper.SetMarket(ctx, marketItem) - - var oddsUIDs []string - for _, v := range marketItem.Odds { - oddsUIDs = append(oddsUIDs, v.UID) - } - err := tApp.OrderbookKeeper.InitiateOrderBook(ctx, marketItem.UID, oddsUIDs) - require.NoError(t, err) - - expTime := time.Now().Add(5 * time.Minute) - err = tApp.AuthzKeeper.SaveGrant(ctx, - creator.Address, - depositor.Address, - types.NewDepositAuthorization(sdkmath.NewInt(1000)), - &expTime, - ) - require.NoError(t, err) - - depositKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: depositor.Address.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "depositor_address": depositor.Address.String(), - "kyc_data": depositKyc, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputDeposit := &types.MsgDeposit{ - Creator: creator.Address.String(), - MarketUID: testMarketUID, - Amount: sdkmath.NewInt(1000), - Ticket: ticket, - } - - deposit, err := msgk.Deposit(wctx, inputDeposit) - require.NoError(t, err) - - t.Run("no ticket", func(t *testing.T) { - inputWithdraw := &types.MsgWithdraw{ - Creator: creator.Address.String(), - Amount: sdkmath.NewInt(1), - } - - _, err := msgk.Withdraw(wctx, inputWithdraw) - require.ErrorIs(t, types.ErrInTicketVerification, err) - }) - - t.Run("no authorization found", func(t *testing.T) { - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: depositor.Address.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": testKyc, - "depositor_address": depositor.Address.String(), - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputWithdraw := &types.MsgWithdraw{ - Creator: creator.Address.String(), - MarketUID: testMarketUID, - ParticipationIndex: deposit.ParticipationIndex, - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - Amount: sdkmath.NewInt(1000), - Ticket: ticket, - } - - _, err = msgk.Withdraw(wctx, inputWithdraw) - require.ErrorIs(t, types.ErrAuthorizationNotFound, err) - }) - - t.Run("success", func(t *testing.T) { - grantAmount := sdkmath.NewInt(1000) - expTime := time.Now().Add(5 * time.Minute) - err := tApp.AuthzKeeper.SaveGrant(ctx, - creator.Address, - depositor.Address, - types.NewWithdrawAuthorization(grantAmount), - &expTime, - ) - require.NoError(t, err) - - authzBefore, _ := tApp.AuthzKeeper.GetAuthorization( - ctx, - creator.Address, - depositor.Address, - sdk.MsgTypeURL(&types.MsgWithdraw{}), - ) - authzBeforeW, ok := authzBefore.(*types.WithdrawAuthorization) - require.True(t, ok) - require.Equal(t, grantAmount, authzBeforeW.WithdrawLimit) - - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: depositor.Address.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "depositor_address": depositor.Address.String(), - "kyc_data": testKyc, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputWithdraw := &types.MsgWithdraw{ - Creator: creator.Address.String(), - MarketUID: testMarketUID, - Amount: sdkmath.NewInt(1000), - ParticipationIndex: deposit.ParticipationIndex, - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - Ticket: ticket, - } - - _, err = msgk.Withdraw(wctx, inputWithdraw) - require.NoError(t, err) - rst, err := k.GetAllWithdrawals(ctx) - require.NoError(t, err) - require.Equal(t, inputWithdraw.ParticipationIndex, rst[0].ParticipationIndex) - - authzAfter, _ := tApp.AuthzKeeper.GetAuthorization(ctx, - creator.Address, - depositor.Address, - sdk.MsgTypeURL(&types.MsgWithdraw{}), - ) - authzAfterW, ok := authzAfter.(*types.WithdrawAuthorization) - require.True(t, ok) - expectedAuthzGrant := grantAmount.Sub(sdkmath.NewInt(rst[0].Amount.Int64())) - require.Equal(t, expectedAuthzGrant, authzAfterW.WithdrawLimit) - }) -} diff --git a/x/house/keeper/params_test.go b/x/house/keeper/params_test.go deleted file mode 100644 index 184ad637..00000000 --- a/x/house/keeper/params_test.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/house/types" -) - -func TestGetParams(t *testing.T) { - k, ctx := setupKeeper(t) - params := types.DefaultParams() - - k.SetParams(ctx, params) - - require.EqualValues(t, params, k.GetParams(ctx)) -} diff --git a/x/house/keeper/withdrawal_test.go b/x/house/keeper/withdrawal_test.go deleted file mode 100644 index 34d135ed..00000000 --- a/x/house/keeper/withdrawal_test.go +++ /dev/null @@ -1,48 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/house/keeper" - "github.com/sge-network/sge/x/house/types" -) - -func createNWithdrawals( - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.Withdrawal { - items := make([]types.Withdrawal, n) - - for i := range items { - items[i].ID = uint64(i) - items[i].Creator = sample.AccAddress() - items[i].Address = testDepositorAddress - items[i].MarketUID = testMarketUID - items[i].ParticipationIndex = uint64(i + 1) - items[i].Mode = types.WithdrawalMode_WITHDRAWAL_MODE_FULL - items[i].Amount = sdkmath.NewInt(100) - - keeper.SetWithdrawal(ctx, items[i]) - } - return items -} - -func TestWithdrawalGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNWithdrawals(k, ctx, 10) - - deposits, err := k.GetAllWithdrawals(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(deposits), - ) -} diff --git a/x/house/simulation/decoder_test.go b/x/house/simulation/decoder_test.go deleted file mode 100644 index d2101423..00000000 --- a/x/house/simulation/decoder_test.go +++ /dev/null @@ -1,67 +0,0 @@ -package simulation_test - -import ( - "fmt" - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/types/kv" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/house/simulation" - "github.com/sge-network/sge/x/house/types" -) - -func TestDecodeStore(t *testing.T) { - cdc := app.MakeEncodingConfig().Marshaler - dec := simulation.NewDecodeStore(cdc) - - deposit := types.NewDeposit( - sample.AccAddress(), - sample.AccAddress(), - uuid.NewString(), - sdkmath.NewInt(100), - sdkmath.NewInt(1000), - 1, - ) - - withdraw := types.Withdrawal{ - ID: 1, - Address: deposit.Creator, - MarketUID: deposit.MarketUID, - ParticipationIndex: 1, - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - Amount: sdkmath.NewInt(100), - } - - kvPairs := kv.Pairs{ - Pairs: []kv.Pair{ - {Key: types.DepositKeyPrefix, Value: cdc.MustMarshal(&deposit)}, - {Key: types.WithdrawalKeyPrefix, Value: cdc.MustMarshal(&withdraw)}, - {Key: []byte{0x99}, Value: []byte{0x99}}, - }, - } - tests := []struct { - name string - expectedLog string - }{ - {"deposit", fmt.Sprintf("%v\n%v", deposit, deposit)}, - {"withdraw", fmt.Sprintf("%v\n%v", withdraw, withdraw)}, - {"other", ""}, - } - - for i, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - switch i { - case len(tests) - 1: - require.Panics(t, func() { dec(kvPairs.Pairs[i], kvPairs.Pairs[i]) }, tt.name) - default: - require.Equal(t, tt.expectedLog, dec(kvPairs.Pairs[i], kvPairs.Pairs[i]), tt.name) - } - }) - } -} diff --git a/x/house/simulation/genesis_test.go b/x/house/simulation/genesis_test.go deleted file mode 100644 index 7f555469..00000000 --- a/x/house/simulation/genesis_test.go +++ /dev/null @@ -1,77 +0,0 @@ -package simulation_test - -import ( - "encoding/json" - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/codec" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/types/module" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - - "github.com/sge-network/sge/x/house/simulation" - "github.com/sge-network/sge/x/house/types" -) - -// TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. -// Abnormal scenarios are not tested here. -func TestRandomizedGenState(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - simState := module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - NumBonded: 3, - Accounts: simtypes.RandomAccounts(r, 3), - InitialStake: sdkmath.NewInt(1000), - GenState: make(map[string]json.RawMessage), - } - - simulation.RandomizedGenState(&simState) - - var houseGenesis types.GenesisState - simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &houseGenesis) - - require.Equal(t, sdkmath.LegacyNewDecWithPrec(1, 1), houseGenesis.Params.HouseParticipationFee) - require.Equal(t, sdkmath.NewInt(100), houseGenesis.Params.MinDeposit) -} - -// TestRandomizedGenState tests abnormal scenarios of applying RandomizedGenState. -func TestRandomizedGenState1(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - // all these tests will panic - tests := []struct { - simState module.SimulationState - panicMsg string - }{ - { // panic => reason: incomplete initialization of the simState - module.SimulationState{}, "invalid memory address or nil pointer dereference"}, - { // panic => reason: incomplete initialization of the simState - module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - }, "assignment to entry in nil map"}, - } - - for _, tt := range tests { - simTest := tt.simState - require.Panicsf(t, func() { simulation.RandomizedGenState(&simTest) }, tt.panicMsg) - } -} diff --git a/x/house/simulation/params_test.go b/x/house/simulation/params_test.go deleted file mode 100644 index 9ebbce8e..00000000 --- a/x/house/simulation/params_test.go +++ /dev/null @@ -1,36 +0,0 @@ -package simulation_test - -import ( - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/house/simulation" -) - -func TestParamChangest(t *testing.T) { - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - expected := []struct { - composedKey string - key string - simValue string - subspace string - }{ - {"house/MinDeposit", "MinDeposit", "\"23\"", "house"}, - } - - paramChanges := simulation.ParamChanges(r) - require.Len(t, paramChanges, 1) - - for i, p := range paramChanges { - require.Equal(t, expected[i].composedKey, p.ComposedKey()) - require.Equal(t, expected[i].key, p.Key()) - require.Equal(t, expected[i].simValue, p.SimValue()(r)) - require.Equal(t, expected[i].subspace, p.Subspace()) - } -} diff --git a/x/house/simulation/proposals_test.go b/x/house/simulation/proposals_test.go deleted file mode 100644 index 37ee4b9b..00000000 --- a/x/house/simulation/proposals_test.go +++ /dev/null @@ -1,47 +0,0 @@ -package simulation_test - -import ( - "fmt" - "math/rand" - "testing" - - sdkmath "cosmossdk.io/math" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/address" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/house/simulation" - "github.com/sge-network/sge/x/house/types" -) - -func TestProposalMsgs(t *testing.T) { - // initialize parameters - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - ctx := sdk.NewContext(nil, tmproto.Header{}, true, nil) - accounts := simtypes.RandomAccounts(r, 3) - - // execute ProposalMsgs function - weightedProposalMsgs := simulation.ProposalMsgs() - require.Equal(t, len(weightedProposalMsgs), 1) - - w0 := weightedProposalMsgs[0] - - // tests w0 interface: - require.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) - require.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) - - msg := w0.MsgSimulatorFn()(r, ctx, accounts) - msgUpdateParams, ok := msg.(*types.MsgUpdateParams) - require.True(t, ok) - - fmt.Println(msgUpdateParams) - require.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) - require.Equal(t, uint64(2540), msgUpdateParams.Params.MaxWithdrawalCount) - require.Equal(t, sdkmath.LegacyNewDecWithPrec(456, 2), msgUpdateParams.Params.HouseParticipationFee) - require.Equal(t, sdkmath.NewInt(300), msgUpdateParams.Params.MinDeposit) -} diff --git a/x/house/types/deposit_authorizaton_test.go b/x/house/types/deposit_authorizaton_test.go deleted file mode 100644 index dfd395c6..00000000 --- a/x/house/types/deposit_authorizaton_test.go +++ /dev/null @@ -1,57 +0,0 @@ -package types_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - authz "github.com/cosmos/cosmos-sdk/x/authz" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/house/types" -) - -func TestDepositGrantValidateBasic(t *testing.T) { - tests := []struct { - name string - spendLimit sdkmath.Int - expiration time.Time - err error - }{ - { - name: "invalid coins", - spendLimit: sdkmath.Int{}, - expiration: time.Now().Add(5 * time.Minute), - err: sdkerrtypes.ErrInvalidCoins, - }, - { - name: "valid", - spendLimit: sdkmath.NewInt(10000), - expiration: time.Now().Add(5 * time.Minute), - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - expTime := tt.expiration - msgGrant, err := authz.NewMsgGrant( - sdk.MustAccAddressFromBech32(sample.AccAddress()), - sdk.MustAccAddressFromBech32(sample.AccAddress()), - &types.DepositAuthorization{ - SpendLimit: tt.spendLimit, - }, - &expTime) - require.NoError(t, err) - - err = msgGrant.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/house/types/genesis_test.go b/x/house/types/genesis_test.go deleted file mode 100644 index b702a5b8..00000000 --- a/x/house/types/genesis_test.go +++ /dev/null @@ -1,96 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - - "github.com/sge-network/sge/x/house/types" -) - -const ( - testAddress = "cosmos1s4ycalgh3gjemd4hmqcvcgmnf647rnd0tpg2w9" -) - -func TestGenesisState_Validate(t *testing.T) { - MarketUID := uuid.NewString() - validState := types.GenesisState{ - DepositList: []types.Deposit{ - { - Creator: testAddress, - MarketUID: MarketUID, - ParticipationIndex: 1, - Amount: sdkmath.NewInt(10), - WithdrawalCount: 1, - TotalWithdrawalAmount: sdkmath.NewInt(10), - }, - }, - WithdrawalList: []types.Withdrawal{ - { - ID: 1, - Address: testAddress, - MarketUID: MarketUID, - ParticipationIndex: 1, - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - Amount: sdkmath.NewInt(10), - }, - }, - Params: types.DefaultParams(), - } - - wrongIndex := validState - wrongIndex.WithdrawalList = []types.Withdrawal{validState.WithdrawalList[0]} - wrongIndex.WithdrawalList[0].ParticipationIndex = 2 - - wrongMarket := validState - wrongMarket.WithdrawalList = []types.Withdrawal{validState.WithdrawalList[0]} - wrongMarket.WithdrawalList[0].MarketUID = uuid.NewString() - - wrongCreator := validState - wrongCreator.WithdrawalList = []types.Withdrawal{validState.WithdrawalList[0]} - wrongCreator.WithdrawalList[0].Address = "new address" - - for _, tc := range []struct { - desc string - genState *types.GenesisState - valid bool - }{ - { - desc: "default is valid", - genState: types.DefaultGenesis(), - valid: true, - }, - { - desc: "valid genesis state", - genState: &validState, - valid: true, - }, - { - desc: "wrong participation index", - genState: &wrongIndex, - valid: false, - }, - { - desc: "wrong market", - genState: &wrongMarket, - valid: false, - }, - { - desc: "wrong creator", - genState: &wrongCreator, - valid: false, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - err := tc.genState.Validate() - if tc.valid { - require.NoError(t, err) - } else { - require.Error(t, err) - } - }) - } -} diff --git a/x/house/types/message_deposit_test.go b/x/house/types/message_deposit_test.go deleted file mode 100644 index b5604ea9..00000000 --- a/x/house/types/message_deposit_test.go +++ /dev/null @@ -1,90 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/house/types" -) - -func TestMsgDepositValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgDeposit - err error - }{ - { - name: "invalid creator", - msg: types.MsgDeposit{ - Creator: "invalid_address", - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "valid", - msg: types.MsgDeposit{ - Creator: sample.AccAddress(), - MarketUID: uuid.NewString(), - Amount: sdkmath.NewInt(100), - Ticket: "Ticket", - }, - }, - { - name: "invalid market UID", - msg: types.MsgDeposit{ - Creator: sample.AccAddress(), - MarketUID: "Invalid UID", - }, - err: types.ErrInvalidMarketUID, - }, - { - name: "invalid amount", - msg: types.MsgDeposit{ - Creator: sample.AccAddress(), - MarketUID: uuid.NewString(), - Amount: sdkmath.ZeroInt(), - Ticket: "Ticket", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestNewDeposit(t *testing.T) { - t.Run("valid", func(t *testing.T) { - expected := types.Deposit{ - Creator: uuid.NewString(), - DepositorAddress: uuid.NewString(), - MarketUID: uuid.NewString(), - Amount: sdkmath.NewInt(100), - ParticipationIndex: 0, - WithdrawalCount: 0, - TotalWithdrawalAmount: sdkmath.ZeroInt(), - } - res := types.NewDeposit( - expected.Creator, - expected.DepositorAddress, - expected.MarketUID, - expected.Amount, - expected.TotalWithdrawalAmount, - expected.WithdrawalCount, - ) - require.Equal(t, expected, res) - }) -} diff --git a/x/house/types/message_withdraw_test.go b/x/house/types/message_withdraw_test.go deleted file mode 100644 index 04ed2215..00000000 --- a/x/house/types/message_withdraw_test.go +++ /dev/null @@ -1,116 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/house/types" -) - -func TestMsgWithdrawValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgWithdraw - err error - }{ - { - name: "invalid creator", - msg: types.MsgWithdraw{ - Creator: "invalid_address", - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "valid", - msg: types.MsgWithdraw{ - Creator: sample.AccAddress(), - MarketUID: uuid.NewString(), - Amount: sdkmath.NewInt(100), - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - ParticipationIndex: 1, - Ticket: "Ticket", - }, - }, - { - name: "invalid withdrawal mode", - msg: types.MsgWithdraw{ - Creator: sample.AccAddress(), - MarketUID: uuid.NewString(), - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_UNSPECIFIED, - }, - err: types.ErrInvalidWithdrawMode, - }, - { - name: "invalid participation index", - msg: types.MsgWithdraw{ - Creator: sample.AccAddress(), - MarketUID: uuid.NewString(), - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - ParticipationIndex: 0, - Ticket: "Ticket", - }, - err: types.ErrInvalidIndex, - }, - { - name: "invalid market UID", - msg: types.MsgWithdraw{ - Creator: sample.AccAddress(), - MarketUID: "Invalid UID", - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - }, - err: types.ErrInvalidMarketUID, - }, - { - name: "invalid amount", - msg: types.MsgWithdraw{ - Creator: sample.AccAddress(), - MarketUID: uuid.NewString(), - Amount: sdkmath.NewInt(-1), - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_PARTIAL, - ParticipationIndex: 1, - Ticket: "Ticket", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestNewWithdraw(t *testing.T) { - t.Run("valid", func(t *testing.T) { - expected := types.Withdrawal{ - ID: 1, - Creator: uuid.NewString(), - MarketUID: uuid.NewString(), - Amount: sdkmath.NewInt(100), - ParticipationIndex: 0, - Address: sample.AccAddress(), - Mode: types.WithdrawalMode_WITHDRAWAL_MODE_FULL, - } - res := types.NewWithdrawal( - expected.ID, - expected.Creator, - expected.Address, - expected.MarketUID, - 0, - expected.Amount, - expected.Mode, - ) - require.Equal(t, expected, res) - }) -} diff --git a/x/house/types/ticket_test.go b/x/house/types/ticket_test.go deleted file mode 100644 index b17a92f6..00000000 --- a/x/house/types/ticket_test.go +++ /dev/null @@ -1,137 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/house/types" -) - -func TestDepositTicketPayloadValidation(t *testing.T) { - depositor := sample.AccAddress() - tests := []struct { - name string - payload types.DepositTicketPayload - err error - }{ - { - name: "valid", - payload: types.DepositTicketPayload{ - DepositorAddress: depositor, - KycData: sgetypes.KycDataPayload{ - Ignore: true, - }, - }, - }, - { - name: "valid kyc", - payload: types.DepositTicketPayload{ - DepositorAddress: depositor, - KycData: sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: depositor, - }, - }, - }, - { - name: "invalid address", - payload: types.DepositTicketPayload{ - DepositorAddress: "invalid addr", - KycData: sgetypes.KycDataPayload{ - Ignore: true, - }, - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "invalid valid kyc", - payload: types.DepositTicketPayload{ - DepositorAddress: depositor, - KycData: sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: sample.AccAddress(), - }, - }, - err: types.ErrUserKycFailed, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.payload.Validate(tt.payload.DepositorAddress) - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestWithdrawTicketPayloadValidation(t *testing.T) { - depositor := sample.AccAddress() - tests := []struct { - name string - payload types.WithdrawTicketPayload - err error - }{ - { - name: "valid", - payload: types.WithdrawTicketPayload{ - DepositorAddress: depositor, - KycData: sgetypes.KycDataPayload{ - Ignore: true, - }, - }, - }, - { - name: "valid kyc", - payload: types.WithdrawTicketPayload{ - DepositorAddress: depositor, - KycData: sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: depositor, - }, - }, - }, - { - name: "invalid address", - payload: types.WithdrawTicketPayload{ - DepositorAddress: "invalid addr", - KycData: sgetypes.KycDataPayload{ - Ignore: true, - }, - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "invalid valid kyc", - payload: types.WithdrawTicketPayload{ - DepositorAddress: depositor, - KycData: sgetypes.KycDataPayload{ - Ignore: false, - Approved: true, - ID: sample.AccAddress(), - }, - }, - err: types.ErrUserKycFailed, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.payload.Validate(tt.payload.DepositorAddress) - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/house/types/withdraw_authorizaton_test.go b/x/house/types/withdraw_authorizaton_test.go deleted file mode 100644 index 08025cf0..00000000 --- a/x/house/types/withdraw_authorizaton_test.go +++ /dev/null @@ -1,57 +0,0 @@ -package types_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - authz "github.com/cosmos/cosmos-sdk/x/authz" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/house/types" -) - -func TestWithdrawGrantValidateBasic(t *testing.T) { - tests := []struct { - name string - withdrawLimit sdkmath.Int - expiration time.Time - err error - }{ - { - name: "invalid coins", - withdrawLimit: sdkmath.NewInt(10000), - expiration: time.Now().Add(5 * time.Minute), - err: sdkerrtypes.ErrInvalidCoins, - }, - { - name: "valid", - withdrawLimit: sdkmath.NewInt(100), - expiration: time.Now().Add(5 * time.Minute), - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - expTime := tt.expiration - msgGrant, err := authz.NewMsgGrant( - sdk.MustAccAddressFromBech32(sample.AccAddress()), - sdk.MustAccAddressFromBech32(sample.AccAddress()), - &types.WithdrawAuthorization{ - WithdrawLimit: tt.withdrawLimit, - }, - &expTime) - require.NoError(t, err) - - err = msgGrant.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/bet/abci.go b/x/legacy/bet/abci.go similarity index 86% rename from x/bet/abci.go rename to x/legacy/bet/abci.go index be9304f9..f95ccece 100644 --- a/x/bet/abci.go +++ b/x/legacy/bet/abci.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/bet/keeper" + "github.com/sge-network/sge/x/legacy/bet/keeper" ) // EndBlocker settles the active bets of resolved markets diff --git a/x/bet/client/cli/query.go b/x/legacy/bet/client/cli/query.go similarity index 93% rename from x/bet/client/cli/query.go rename to x/legacy/bet/client/cli/query.go index def54fa5..f5807513 100644 --- a/x/bet/client/cli/query.go +++ b/x/legacy/bet/client/cli/query.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // GetQueryCmd returns the cli query commands for this module diff --git a/x/bet/client/cli/query_bet.go b/x/legacy/bet/client/cli/query_bet.go similarity index 98% rename from x/bet/client/cli/query_bet.go rename to x/legacy/bet/client/cli/query_bet.go index 619bf0da..9641ea5c 100644 --- a/x/bet/client/cli/query_bet.go +++ b/x/legacy/bet/client/cli/query_bet.go @@ -9,7 +9,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // CmdListBet implements a command to return all bets diff --git a/x/bet/client/cli/query_params.go b/x/legacy/bet/client/cli/query_params.go similarity index 93% rename from x/bet/client/cli/query_params.go rename to x/legacy/bet/client/cli/query_params.go index 1f96c169..d8846e70 100644 --- a/x/bet/client/cli/query_params.go +++ b/x/legacy/bet/client/cli/query_params.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // CmdQueryParams returns a command object instance for module params diff --git a/x/bet/client/cli/tx.go b/x/legacy/bet/client/cli/tx.go similarity index 91% rename from x/bet/client/cli/tx.go rename to x/legacy/bet/client/cli/tx.go index 7c276c0a..974b8434 100644 --- a/x/bet/client/cli/tx.go +++ b/x/legacy/bet/client/cli/tx.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) const ( diff --git a/x/bet/client/cli/tx_bet.go b/x/legacy/bet/client/cli/tx_bet.go similarity index 96% rename from x/bet/client/cli/tx_bet.go rename to x/legacy/bet/client/cli/tx_bet.go index c73717ed..fa3489fa 100644 --- a/x/bet/client/cli/tx_bet.go +++ b/x/legacy/bet/client/cli/tx_bet.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // CmdWager implements a command to place and store a single bet diff --git a/x/bet/genesis.go b/x/legacy/bet/genesis.go similarity index 94% rename from x/bet/genesis.go rename to x/legacy/bet/genesis.go index 6892f61f..e9e6fad9 100644 --- a/x/bet/genesis.go +++ b/x/legacy/bet/genesis.go @@ -3,8 +3,8 @@ package bet import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/bet/keeper" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/keeper" + "github.com/sge-network/sge/x/legacy/bet/types" ) // InitGenesis initializes the module's state from a provided genesis diff --git a/x/bet/keeper/bet.go b/x/legacy/bet/keeper/bet.go similarity index 90% rename from x/bet/keeper/bet.go rename to x/legacy/bet/keeper/bet.go index 87b5d715..98301243 100644 --- a/x/bet/keeper/bet.go +++ b/x/legacy/bet/keeper/bet.go @@ -2,11 +2,12 @@ package keeper import ( sdkerrors "cosmossdk.io/errors" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // SetBet sets a specific bet in the store @@ -36,7 +37,7 @@ func (k Keeper) GetBet(ctx sdk.Context, creator string, id uint64) (val types.Be // GetBets returns list of bets func (k Keeper) GetBets(ctx sdk.Context) (list []types.Bet, err error) { store := k.getBetStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() @@ -74,7 +75,7 @@ func (k Keeper) GetBetID(ctx sdk.Context, uid string) (val types.UID2ID, found b // GetBetIDs returns list of uid2id func (k Keeper) GetBetIDs(ctx sdk.Context) (list []types.UID2ID, err error) { store := k.getBetIDStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() @@ -106,7 +107,7 @@ func (k Keeper) IsAnyPendingBetForMarket(ctx sdk.Context, marketUID string) (the store := prefix.NewStore(ctx.KVStore(k.storeKey), types.PendingBetListOfMarketPrefix(marketUID)) // create iterator for all existing records - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() }() @@ -120,7 +121,7 @@ func (k Keeper) IsAnyPendingBetForMarket(ctx sdk.Context, marketUID string) (the // GetPendingBets returns list of the pending bets func (k Keeper) GetPendingBets(ctx sdk.Context) (list []types.PendingBet, err error) { store := k.getPendingBetStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() @@ -156,7 +157,7 @@ func (k Keeper) SetSettledBet( // GetSettledBets returns list of the pending bets func (k Keeper) GetSettledBets(ctx sdk.Context) (list []types.SettledBet, err error) { store := k.getSettledBetStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() @@ -179,7 +180,7 @@ func (k Keeper) PrepareBetObject(ctx sdk.Context, creator string, props *types.W } payload := &types.WagerTicketPayload{} - err := k.ovmKeeper.VerifyTicketUnmarshal(sdk.WrapSDKContext(ctx), props.Ticket, &payload) + err := k.ovmKeeper.VerifyTicketUnmarshal(ctx, props.Ticket, &payload) if err != nil { return nil, nil, sdkerrors.Wrapf(types.ErrInTicketVerification, "%s", err) } diff --git a/x/orderbook/keeper/grpc_query.go b/x/legacy/bet/keeper/grpc_query.go similarity index 56% rename from x/orderbook/keeper/grpc_query.go rename to x/legacy/bet/keeper/grpc_query.go index 5a2ce19c..8ddf2766 100644 --- a/x/orderbook/keeper/grpc_query.go +++ b/x/legacy/bet/keeper/grpc_query.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) var _ types.QueryServer = Keeper{} diff --git a/x/bet/keeper/grpc_query_bet.go b/x/legacy/bet/keeper/grpc_query_bet.go similarity index 98% rename from x/bet/keeper/grpc_query_bet.go rename to x/legacy/bet/keeper/grpc_query_bet.go index 2afdc483..5ed204f3 100644 --- a/x/bet/keeper/grpc_query_bet.go +++ b/x/legacy/bet/keeper/grpc_query_bet.go @@ -9,12 +9,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) const ( diff --git a/x/orderbook/keeper/grpc_query_params.go b/x/legacy/bet/keeper/grpc_query_params.go similarity index 91% rename from x/orderbook/keeper/grpc_query_params.go rename to x/legacy/bet/keeper/grpc_query_params.go index ea51b5db..3c2ccda6 100644 --- a/x/orderbook/keeper/grpc_query_params.go +++ b/x/legacy/bet/keeper/grpc_query_params.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // Params returns the params of the module diff --git a/x/bet/keeper/keeper.go b/x/legacy/bet/keeper/keeper.go similarity index 92% rename from x/bet/keeper/keeper.go rename to x/legacy/bet/keeper/keeper.go index 7129df83..a17de46b 100644 --- a/x/bet/keeper/keeper.go +++ b/x/legacy/bet/keeper/keeper.go @@ -3,13 +3,13 @@ package keeper import ( "fmt" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // Keeper is the type for module properties diff --git a/x/market/keeper/msg_server.go b/x/legacy/bet/keeper/msg_server.go similarity index 85% rename from x/market/keeper/msg_server.go rename to x/legacy/bet/keeper/msg_server.go index 8ec0a51a..0409d809 100644 --- a/x/market/keeper/msg_server.go +++ b/x/legacy/bet/keeper/msg_server.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) type msgServer struct { diff --git a/x/bet/keeper/msg_server_bet.go b/x/legacy/bet/keeper/msg_server_bet.go similarity index 91% rename from x/bet/keeper/msg_server_bet.go rename to x/legacy/bet/keeper/msg_server_bet.go index b9d1b56c..7305e21b 100644 --- a/x/bet/keeper/msg_server_bet.go +++ b/x/legacy/bet/keeper/msg_server_bet.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) func (k msgServer) Wager( diff --git a/x/orderbook/keeper/msg_server_params.go b/x/legacy/bet/keeper/msg_server_params.go similarity index 93% rename from x/orderbook/keeper/msg_server_params.go rename to x/legacy/bet/keeper/msg_server_params.go index 6d8dc25e..d0d46323 100644 --- a/x/orderbook/keeper/msg_server_params.go +++ b/x/legacy/bet/keeper/msg_server_params.go @@ -7,7 +7,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { diff --git a/x/bet/keeper/params.go b/x/legacy/bet/keeper/params.go similarity index 92% rename from x/bet/keeper/params.go rename to x/legacy/bet/keeper/params.go index 67abf3a4..4d0da3c1 100644 --- a/x/bet/keeper/params.go +++ b/x/legacy/bet/keeper/params.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // GetParams get all parameters as types.Params diff --git a/x/bet/keeper/settle.go b/x/legacy/bet/keeper/settle.go similarity index 96% rename from x/bet/keeper/settle.go rename to x/legacy/bet/keeper/settle.go index ddd1e6e5..d4a60ea8 100644 --- a/x/bet/keeper/settle.go +++ b/x/legacy/bet/keeper/settle.go @@ -7,9 +7,10 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" + storetypes "cosmossdk.io/store/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/bet/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" ) // singlePageNum used to return single page result in pagination. @@ -178,7 +179,7 @@ func (k Keeper) batchMarketSettlement( ) (settledCount uint32, err error) { // initialize iterator for the certain number of pending bets // equal to countToBeSettled - iterator := sdk.KVStorePrefixIteratorPaginated( + iterator := storetypes.KVStorePrefixIteratorPaginated( ctx.KVStore(k.storeKey), types.PendingBetListOfMarketPrefix(marketUID), singlePageNum, diff --git a/x/bet/keeper/stats.go b/x/legacy/bet/keeper/stats.go similarity index 92% rename from x/bet/keeper/stats.go rename to x/legacy/bet/keeper/stats.go index 9bbad830..4f261024 100644 --- a/x/bet/keeper/stats.go +++ b/x/legacy/bet/keeper/stats.go @@ -4,7 +4,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // SetBetStats sets bet statistics in the store diff --git a/x/bet/keeper/view.go b/x/legacy/bet/keeper/view.go similarity index 93% rename from x/bet/keeper/view.go rename to x/legacy/bet/keeper/view.go index 97fbd6df..37841cdb 100644 --- a/x/bet/keeper/view.go +++ b/x/legacy/bet/keeper/view.go @@ -1,10 +1,10 @@ package keeper import ( - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // getBetStore returns bet store ready for iterating diff --git a/x/bet/keeper/wager.go b/x/legacy/bet/keeper/wager.go similarity index 95% rename from x/bet/keeper/wager.go rename to x/legacy/bet/keeper/wager.go index d0a1676f..739ef3d8 100644 --- a/x/bet/keeper/wager.go +++ b/x/legacy/bet/keeper/wager.go @@ -7,8 +7,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/bet/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" ) // Wager stores a new bet in KVStore diff --git a/x/bet/module.go b/x/legacy/bet/module.go similarity index 90% rename from x/bet/module.go rename to x/legacy/bet/module.go index 336d9d6f..71053d6a 100644 --- a/x/bet/module.go +++ b/x/legacy/bet/module.go @@ -18,9 +18,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/bet/client/cli" - "github.com/sge-network/sge/x/bet/keeper" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/client/cli" + "github.com/sge-network/sge/x/legacy/bet/keeper" + "github.com/sge-network/sge/x/legacy/bet/types" ) var ( @@ -118,8 +118,8 @@ func NewAppModule( marketKeeper types.MarketKeeper, orderBookKeeper types.OrderbookKeeper, ovmKeeper types.OVMKeeper, -) AppModule { - return AppModule{ +) *AppModule { + return &AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, accountKeeper: accountKeeper, @@ -130,6 +130,12 @@ func NewAppModule( } } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} + +// IsOnePerModuleType is a marker function just indicates that this is a one-per-module type. +func (am AppModule) IsOnePerModuleType() {} + // Name returns the module's name. func (am AppModule) Name() string { return am.AppModuleBasic.Name() } @@ -175,13 +181,12 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock executes all ABCI BeginBlock logic respective to the module. -func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} +func (AppModule) BeginBlock(_ sdk.Context) {} // EndBlock executes all ABCI EndBlock logic respective to the module. It // returns no validator updates. -func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { - // end blocker deprecated in favor of v2 - // EndBlocker(ctx, am.keeper) +func (am AppModule) EndBlock(ctx sdk.Context) []abci.ValidatorUpdate { + EndBlocker(ctx, am.keeper) return []abci.ValidatorUpdate{} } diff --git a/x/bet/module_simulation.go b/x/legacy/bet/module_simulation.go similarity index 84% rename from x/bet/module_simulation.go rename to x/legacy/bet/module_simulation.go index 333622ae..1bde8e8b 100644 --- a/x/bet/module_simulation.go +++ b/x/legacy/bet/module_simulation.go @@ -6,14 +6,13 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/sge-network/sge/testutil/sample" - betsimulation "github.com/sge-network/sge/x/bet/simulation" - "github.com/sge-network/sge/x/bet/types" + betsimulation "github.com/sge-network/sge/x/legacy/bet/simulation" + "github.com/sge-network/sge/x/legacy/bet/types" ) // avoid unused import issue @@ -43,7 +42,7 @@ func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedP } // RegisterStoreDecoder registers a decoder -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { sdr[types.StoreKey] = betsimulation.NewDecodeStore(am.cdc) } @@ -52,7 +51,7 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp operations := make([]simtypes.WeightedOperation, 0) var weightMsgWager int - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgWager, &weightMsgWager, nil, + simState.AppParams.GetOrGenerate(opWeightMsgWager, &weightMsgWager, nil, func(_ *rand.Rand) { weightMsgWager = defaultWeightMsgWager }, diff --git a/x/bet/simulation/bet.go b/x/legacy/bet/simulation/bet.go similarity index 85% rename from x/bet/simulation/bet.go rename to x/legacy/bet/simulation/bet.go index 9a6daf77..28bee312 100644 --- a/x/bet/simulation/bet.go +++ b/x/legacy/bet/simulation/bet.go @@ -4,15 +4,15 @@ import ( //#nosec "math/rand" - simappparams "cosmossdk.io/simapp/params" "github.com/cosmos/cosmos-sdk/baseapp" sdk "github.com/cosmos/cosmos-sdk/types" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/spf13/cast" - "github.com/sge-network/sge/x/bet/keeper" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/keeper" + "github.com/sge-network/sge/x/legacy/bet/types" ) // SimulateMsgWager returns an Operation function to run a state machine transition @@ -41,10 +41,9 @@ func SimulateMsgWager( txCtx := simulation.OperationInput{ R: r, App: app, - TxGen: simappparams.MakeTestEncodingConfig().TxConfig, + TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: simAccount, ModuleName: types.ModuleName, diff --git a/x/bet/simulation/decoder.go b/x/legacy/bet/simulation/decoder.go similarity index 97% rename from x/bet/simulation/decoder.go rename to x/legacy/bet/simulation/decoder.go index 5104dfba..ebf948ba 100644 --- a/x/bet/simulation/decoder.go +++ b/x/legacy/bet/simulation/decoder.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // NewDecodeStore returns a decoder function closure that unmarshal the KVPair's diff --git a/x/bet/simulation/errors.go b/x/legacy/bet/simulation/errors.go similarity index 100% rename from x/bet/simulation/errors.go rename to x/legacy/bet/simulation/errors.go diff --git a/x/bet/simulation/genesis.go b/x/legacy/bet/simulation/genesis.go similarity index 85% rename from x/bet/simulation/genesis.go rename to x/legacy/bet/simulation/genesis.go index 045ce93f..6c669923 100644 --- a/x/bet/simulation/genesis.go +++ b/x/legacy/bet/simulation/genesis.go @@ -12,7 +12,7 @@ import ( sdkmath "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // Simulation parameter constants @@ -47,25 +47,25 @@ func GenFee(r *rand.Rand) sdkmath.Int { func RandomizedGenState(simState *module.SimulationState) { var batchSettlementCount uint32 simState.AppParams.GetOrGenerate( - simState.Cdc, BatchSettlementCount, &batchSettlementCount, simState.Rand, + BatchSettlementCount, &batchSettlementCount, simState.Rand, func(r *rand.Rand) { batchSettlementCount = GenBatchSettlementCount(r) }, ) var maxBetByUIDQueryCount uint32 simState.AppParams.GetOrGenerate( - simState.Cdc, MaxBetByUIDQueryCount, &maxBetByUIDQueryCount, simState.Rand, + MaxBetByUIDQueryCount, &maxBetByUIDQueryCount, simState.Rand, func(r *rand.Rand) { maxBetByUIDQueryCount = GenMaxBetByUIDQueryCount(r) }, ) var minAmount sdkmath.Int simState.AppParams.GetOrGenerate( - simState.Cdc, MinAmount, &minAmount, simState.Rand, + MinAmount, &minAmount, simState.Rand, func(r *rand.Rand) { minAmount = GenMinAmount(r) }, ) var minBetFee sdkmath.Int simState.AppParams.GetOrGenerate( - simState.Cdc, BetFee, &minBetFee, simState.Rand, + BetFee, &minBetFee, simState.Rand, func(r *rand.Rand) { minBetFee = GenFee(r) }, ) diff --git a/x/bet/simulation/params.go b/x/legacy/bet/simulation/params.go similarity index 96% rename from x/bet/simulation/params.go rename to x/legacy/bet/simulation/params.go index 84990630..0899e948 100644 --- a/x/bet/simulation/params.go +++ b/x/legacy/bet/simulation/params.go @@ -10,7 +10,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) const ( diff --git a/x/bet/simulation/proposals.go b/x/legacy/bet/simulation/proposals.go similarity index 96% rename from x/bet/simulation/proposals.go rename to x/legacy/bet/simulation/proposals.go index 9e17960c..738c67b7 100644 --- a/x/bet/simulation/proposals.go +++ b/x/legacy/bet/simulation/proposals.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/spf13/cast" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // Simulation operation weights constants diff --git a/x/bet/simulation/simap.go b/x/legacy/bet/simulation/simap.go similarity index 100% rename from x/bet/simulation/simap.go rename to x/legacy/bet/simulation/simap.go diff --git a/x/bet/types/bet.go b/x/legacy/bet/types/bet.go similarity index 96% rename from x/bet/types/bet.go rename to x/legacy/bet/types/bet.go index c3d965dc..219d72f7 100644 --- a/x/bet/types/bet.go +++ b/x/legacy/bet/types/bet.go @@ -3,7 +3,7 @@ package types import ( sdkmath "cosmossdk.io/math" - markettypes "github.com/sge-network/sge/x/market/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" ) func NewPendingBet(uid, creator string) *PendingBet { diff --git a/x/bet/types/bet.pb.go b/x/legacy/bet/types/bet.pb.go similarity index 87% rename from x/bet/types/bet.pb.go rename to x/legacy/bet/types/bet.pb.go index 6649070e..97e5123c 100644 --- a/x/bet/types/bet.pb.go +++ b/x/legacy/bet/types/bet.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/bet.proto +// source: sge/legacy/bet/v1beta/bet.proto package types @@ -70,7 +70,7 @@ func (x Bet_Status) String() string { } func (Bet_Status) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{0, 0} + return fileDescriptor_53f19620418bb46a, []int{0, 0} } // Result of the bet. @@ -110,7 +110,7 @@ func (x Bet_Result) String() string { } func (Bet_Result) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{0, 1} + return fileDescriptor_53f19620418bb46a, []int{0, 1} } // Bet is the transaction order placed by a bettor on a specific event and odd @@ -130,9 +130,9 @@ type Bet struct { // fee is the betting fee user needs to pay for placing a bet Fee cosmossdk_io_math.Int `protobuf:"bytes,7,opt,name=fee,proto3,customtype=cosmossdk.io/math.Int" json:"fee"` // status is the status of the bet, such as `unspecified` or `settled`. - Status Bet_Status `protobuf:"varint,8,opt,name=status,proto3,enum=sgenetwork.sge.bet.Bet_Status" json:"status,omitempty"` + Status Bet_Status `protobuf:"varint,8,opt,name=status,proto3,enum=sge.legacy.bet.v1beta.Bet_Status" json:"status,omitempty"` // result is the result of the bet, such as `won` or `lost`. - Result Bet_Result `protobuf:"varint,9,opt,name=result,proto3,enum=sgenetwork.sge.bet.Bet_Result" json:"result,omitempty"` + Result Bet_Result `protobuf:"varint,9,opt,name=result,proto3,enum=sge.legacy.bet.v1beta.Bet_Result" json:"result,omitempty"` // creator is the bettor address. Creator string `protobuf:"bytes,10,opt,name=creator,proto3" json:"creator,omitempty"` // created_at is the bet placement timestamp. @@ -151,7 +151,7 @@ func (m *Bet) Reset() { *m = Bet{} } func (m *Bet) String() string { return proto.CompactTextString(m) } func (*Bet) ProtoMessage() {} func (*Bet) Descriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{0} + return fileDescriptor_53f19620418bb46a, []int{0} } func (m *Bet) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -269,7 +269,7 @@ func (m *UID2ID) Reset() { *m = UID2ID{} } func (m *UID2ID) String() string { return proto.CompactTextString(m) } func (*UID2ID) ProtoMessage() {} func (*UID2ID) Descriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{1} + return fileDescriptor_53f19620418bb46a, []int{1} } func (m *UID2ID) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -324,7 +324,7 @@ func (m *PendingBet) Reset() { *m = PendingBet{} } func (m *PendingBet) String() string { return proto.CompactTextString(m) } func (*PendingBet) ProtoMessage() {} func (*PendingBet) Descriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{2} + return fileDescriptor_53f19620418bb46a, []int{2} } func (m *PendingBet) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -379,7 +379,7 @@ func (m *SettledBet) Reset() { *m = SettledBet{} } func (m *SettledBet) String() string { return proto.CompactTextString(m) } func (*SettledBet) ProtoMessage() {} func (*SettledBet) Descriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{3} + return fileDescriptor_53f19620418bb46a, []int{3} } func (m *SettledBet) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -443,7 +443,7 @@ func (m *BetFulfillment) Reset() { *m = BetFulfillment{} } func (m *BetFulfillment) String() string { return proto.CompactTextString(m) } func (*BetFulfillment) ProtoMessage() {} func (*BetFulfillment) Descriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{4} + return fileDescriptor_53f19620418bb46a, []int{4} } func (m *BetFulfillment) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -489,7 +489,7 @@ func (m *BetFulfillment) GetParticipationIndex() uint64 { // metadata for bet type MetaData struct { // selected_odds_type is metadata for bet - SelectedOddsType OddsType `protobuf:"varint,1,opt,name=selected_odds_type,json=selectedOddsType,proto3,enum=sgenetwork.sge.bet.OddsType" json:"selected_odds_type,omitempty"` + SelectedOddsType OddsType `protobuf:"varint,1,opt,name=selected_odds_type,json=selectedOddsType,proto3,enum=sge.legacy.bet.v1beta.OddsType" json:"selected_odds_type,omitempty"` // selected_odds_value is metadata for bet SelectedOddsValue string `protobuf:"bytes,2,opt,name=selected_odds_value,json=selectedOddsValue,proto3" json:"selected_odds_value,omitempty"` // is_main_market will tell weather the bet placed on the main market or not @@ -500,7 +500,7 @@ func (m *MetaData) Reset() { *m = MetaData{} } func (m *MetaData) String() string { return proto.CompactTextString(m) } func (*MetaData) ProtoMessage() {} func (*MetaData) Descriptor() ([]byte, []int) { - return fileDescriptor_7e3a1b484a8c9a09, []int{5} + return fileDescriptor_53f19620418bb46a, []int{5} } func (m *MetaData) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -551,83 +551,83 @@ func (m *MetaData) GetIsMainMarket() bool { } func init() { - proto.RegisterEnum("sgenetwork.sge.bet.Bet_Status", Bet_Status_name, Bet_Status_value) - proto.RegisterEnum("sgenetwork.sge.bet.Bet_Result", Bet_Result_name, Bet_Result_value) - proto.RegisterType((*Bet)(nil), "sgenetwork.sge.bet.Bet") - proto.RegisterType((*UID2ID)(nil), "sgenetwork.sge.bet.UID2ID") - proto.RegisterType((*PendingBet)(nil), "sgenetwork.sge.bet.PendingBet") - proto.RegisterType((*SettledBet)(nil), "sgenetwork.sge.bet.SettledBet") - proto.RegisterType((*BetFulfillment)(nil), "sgenetwork.sge.bet.BetFulfillment") - proto.RegisterType((*MetaData)(nil), "sgenetwork.sge.bet.MetaData") -} - -func init() { proto.RegisterFile("sgenetwork/sge/bet/bet.proto", fileDescriptor_7e3a1b484a8c9a09) } - -var fileDescriptor_7e3a1b484a8c9a09 = []byte{ - // 997 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x55, 0xcf, 0x4e, 0x23, 0xc7, - 0x13, 0x66, 0x6c, 0xaf, 0xc1, 0x05, 0x18, 0xd3, 0xf0, 0xdb, 0xdf, 0x84, 0x65, 0x6d, 0x6b, 0x12, - 0x45, 0x48, 0xd1, 0x1a, 0xc9, 0xab, 0xdd, 0x43, 0x72, 0x48, 0x6c, 0x66, 0xc8, 0x3a, 0x31, 0x86, - 0xb4, 0xed, 0x44, 0xda, 0xcb, 0xa8, 0xed, 0x69, 0x4c, 0x87, 0xf9, 0x63, 0x4d, 0xb7, 0x13, 0x78, - 0x8b, 0x3c, 0x42, 0x1e, 0x20, 0xc7, 0x3c, 0xc4, 0x1e, 0x57, 0x39, 0x45, 0x39, 0x58, 0x89, 0xb9, - 0xe5, 0xb8, 0xb7, 0xdc, 0xa2, 0xfe, 0x03, 0x18, 0x2d, 0xd9, 0xf5, 0x01, 0xd4, 0xfd, 0xd5, 0xf7, - 0x55, 0x95, 0x6b, 0xaa, 0xab, 0x60, 0x97, 0x8f, 0x68, 0x4c, 0xc5, 0x8f, 0x49, 0x7a, 0xbe, 0xcf, - 0x47, 0x74, 0x7f, 0x40, 0x85, 0xfc, 0xab, 0x8d, 0xd3, 0x44, 0x24, 0x08, 0xdd, 0x5a, 0x6b, 0x7c, - 0x44, 0x6b, 0x03, 0x2a, 0x76, 0xb6, 0x47, 0xc9, 0x28, 0x51, 0xe6, 0x7d, 0x79, 0xd2, 0xcc, 0x9d, - 0x0f, 0x86, 0x09, 0x8f, 0x12, 0xee, 0x6b, 0x83, 0xbe, 0x18, 0x93, 0x73, 0x4f, 0x88, 0x24, 0x08, - 0xb8, 0x2f, 0x2e, 0xc7, 0x54, 0x73, 0x9c, 0x7f, 0x96, 0x21, 0xdb, 0xa4, 0x02, 0x55, 0x21, 0x3b, - 0x61, 0x81, 0x6d, 0x55, 0xad, 0xbd, 0x42, 0xb3, 0x38, 0x9b, 0x56, 0xb2, 0xfd, 0x96, 0xfb, 0xf7, - 0xb4, 0x22, 0x51, 0x2c, 0xff, 0xa1, 0xcf, 0x00, 0x22, 0x92, 0x9e, 0x53, 0xe1, 0x4b, 0x62, 0x46, - 0x11, 0x1f, 0xcd, 0xa6, 0x95, 0xc2, 0x91, 0x42, 0x35, 0x7d, 0x8e, 0x82, 0xe7, 0xce, 0xe8, 0x29, - 0xac, 0xa8, 0xc8, 0x52, 0x9a, 0x55, 0xd2, 0xff, 0xcf, 0xa6, 0x95, 0xe5, 0xe3, 0x20, 0xe0, 0x5a, - 0x78, 0x63, 0xc6, 0x37, 0x27, 0xf4, 0x18, 0x40, 0x9d, 0x7f, 0x20, 0xe1, 0x84, 0xda, 0x0f, 0xa4, - 0x0c, 0x17, 0x24, 0xf2, 0xad, 0x04, 0xd0, 0x33, 0xc8, 0x93, 0x28, 0x99, 0xc4, 0xc2, 0xce, 0x2b, - 0x8f, 0x8f, 0x5f, 0x4d, 0x2b, 0x4b, 0x7f, 0x4c, 0x2b, 0xff, 0xd3, 0x45, 0xe0, 0xc1, 0x79, 0x8d, - 0x25, 0xfb, 0x11, 0x11, 0x67, 0xb5, 0x56, 0x2c, 0xb0, 0x21, 0xa3, 0x7d, 0xc8, 0x9e, 0x52, 0x6a, - 0x2f, 0x2f, 0xa2, 0x91, 0x4c, 0xf4, 0x1c, 0xf2, 0x5c, 0x10, 0x31, 0xe1, 0xf6, 0x4a, 0xd5, 0xda, - 0x2b, 0xd6, 0xcb, 0xb5, 0xb7, 0x3f, 0x4e, 0xad, 0x49, 0x45, 0xad, 0xab, 0x58, 0xd8, 0xb0, 0xa5, - 0x2e, 0xa5, 0x7c, 0x12, 0x0a, 0xbb, 0xf0, 0x6e, 0x1d, 0x56, 0x2c, 0x6c, 0xd8, 0xa8, 0x0e, 0xcb, - 0xc3, 0x94, 0x12, 0x91, 0xa4, 0x36, 0xa8, 0x24, 0xed, 0xdf, 0x7e, 0x7d, 0xb2, 0x6d, 0xbe, 0x6c, - 0x23, 0x08, 0x52, 0xca, 0x79, 0x57, 0xa4, 0x2c, 0x1e, 0xe1, 0x6b, 0xa2, 0x2c, 0x95, 0x3a, 0xd2, - 0xc0, 0x27, 0xc2, 0x5e, 0xad, 0x5a, 0x7b, 0x59, 0x5c, 0x30, 0x48, 0x43, 0xa0, 0x4f, 0x60, 0x93, - 0x53, 0x21, 0x42, 0x1a, 0xd1, 0x58, 0xf8, 0x67, 0x94, 0x8d, 0xce, 0x84, 0xbd, 0xa6, 0x58, 0xa5, - 0x5b, 0xc3, 0x0b, 0x85, 0xa3, 0x2e, 0x6c, 0x45, 0xe4, 0xc2, 0x0f, 0x13, 0xce, 0xfd, 0x68, 0x12, - 0x0a, 0x36, 0x0e, 0x19, 0x4d, 0xed, 0x75, 0x95, 0xcb, 0x87, 0xa6, 0x60, 0x8f, 0xde, 0x2e, 0x58, - 0x9b, 0x8e, 0xc8, 0xf0, 0xd2, 0xa5, 0x43, 0xbc, 0x19, 0x91, 0x8b, 0x76, 0xc2, 0xf9, 0xd1, 0x8d, - 0x1a, 0x7d, 0x0d, 0x1b, 0x03, 0x2a, 0xfc, 0xd3, 0x49, 0x78, 0xca, 0xc2, 0x50, 0x46, 0xb3, 0x8b, - 0xd5, 0xec, 0xde, 0x6a, 0xdd, 0xf9, 0x8f, 0xaa, 0x1c, 0xde, 0x32, 0x71, 0x71, 0x70, 0xe7, 0x8e, - 0x9e, 0x43, 0x2e, 0xa2, 0x82, 0xd8, 0x1b, 0x55, 0x6b, 0x6f, 0xb5, 0xbe, 0x7b, 0x9f, 0x87, 0x23, - 0x2a, 0x88, 0x4b, 0x04, 0x69, 0xe6, 0x64, 0xc2, 0x58, 0xf1, 0x9d, 0x9f, 0x2d, 0xc8, 0xeb, 0x8f, - 0x84, 0x1e, 0x02, 0xea, 0xf6, 0x1a, 0xbd, 0x7e, 0xd7, 0xef, 0x77, 0xba, 0x27, 0xde, 0x41, 0xeb, - 0xb0, 0xe5, 0xb9, 0xa5, 0x25, 0xb4, 0x09, 0xeb, 0x06, 0x3f, 0x69, 0x37, 0x0e, 0x3c, 0xb7, 0x64, - 0xa1, 0x2d, 0xd8, 0x30, 0xd0, 0x41, 0xa3, 0x73, 0xe0, 0xb5, 0x3d, 0xb7, 0x94, 0x41, 0x08, 0x8a, - 0x06, 0x6c, 0x34, 0x8f, 0x71, 0xcf, 0x73, 0x4b, 0xd9, 0x39, 0xec, 0xc4, 0xeb, 0xb8, 0xad, 0xce, - 0x97, 0xa5, 0x1c, 0xda, 0x81, 0x87, 0x06, 0xc3, 0x5e, 0xb7, 0xdf, 0xee, 0xf9, 0xae, 0x77, 0xd0, - 0x6e, 0x60, 0xcf, 0x2d, 0x3d, 0x98, 0xe3, 0x77, 0xbd, 0x5e, 0x4f, 0xfa, 0xcd, 0x3b, 0xdf, 0x43, - 0x5e, 0xb7, 0x83, 0xcc, 0xd0, 0x48, 0xee, 0x66, 0x88, 0xa0, 0x68, 0xf0, 0xeb, 0x28, 0x16, 0x2a, - 0x02, 0x18, 0xec, 0xbb, 0xe3, 0x4e, 0x29, 0x83, 0x36, 0x60, 0xd5, 0xdc, 0xdb, 0xc7, 0xdd, 0x5e, - 0x29, 0x2b, 0x7f, 0x83, 0x01, 0xb0, 0x77, 0xd8, 0xef, 0xb8, 0x9e, 0x5b, 0xca, 0x39, 0x2f, 0x20, - 0xdf, 0x6f, 0xb9, 0xf5, 0x96, 0xbb, 0xc0, 0xeb, 0xdf, 0x85, 0x8c, 0x79, 0xf5, 0xb9, 0xe6, 0xda, - 0x6c, 0x5a, 0xc9, 0x28, 0x7b, 0x86, 0x05, 0x38, 0xc3, 0x02, 0x67, 0x00, 0x70, 0x42, 0xe3, 0x80, - 0xc5, 0xa3, 0xc5, 0x66, 0xc9, 0x5c, 0x8b, 0x67, 0x16, 0x6c, 0x71, 0x27, 0x01, 0xe8, 0xaa, 0x56, - 0x0d, 0x16, 0x8b, 0xf1, 0x39, 0xc8, 0xb6, 0x11, 0x49, 0xea, 0x13, 0xed, 0xf0, 0xbd, 0xa1, 0xd6, - 0x35, 0xdf, 0x80, 0xce, 0x5f, 0x19, 0x28, 0xde, 0x6d, 0x44, 0x74, 0x0c, 0x5b, 0x63, 0x92, 0x0a, - 0x36, 0x64, 0x63, 0x12, 0x8b, 0x1b, 0xc7, 0x3a, 0x8b, 0xf2, 0x9b, 0x69, 0x65, 0xe7, 0x92, 0x44, - 0xe1, 0xa7, 0xce, 0x3d, 0x24, 0x07, 0xa3, 0x39, 0xd4, 0xc4, 0xb8, 0xe3, 0x50, 0xb0, 0x24, 0xf6, - 0x59, 0x1c, 0xd0, 0x0b, 0x53, 0xe7, 0xfb, 0x1c, 0xde, 0x92, 0xe6, 0x1d, 0x4a, 0xb4, 0x25, 0x41, - 0xf4, 0x0d, 0x80, 0x7c, 0x67, 0x66, 0x30, 0xea, 0x51, 0x5b, 0x7f, 0xe7, 0x90, 0x7b, 0x33, 0xad, - 0x6c, 0xea, 0x20, 0xb7, 0x42, 0x07, 0x17, 0x06, 0x54, 0x34, 0xf4, 0xc0, 0x7c, 0x09, 0xeb, 0x63, - 0x72, 0x99, 0x4c, 0x84, 0xdc, 0x31, 0xa7, 0x4c, 0xd8, 0x39, 0xe5, 0xf5, 0xd9, 0xfb, 0xbc, 0x6e, - 0x5f, 0xa7, 0x3e, 0xa7, 0x75, 0xf0, 0x9a, 0xbe, 0x9f, 0xe8, 0xeb, 0x2f, 0x16, 0xac, 0x5c, 0x3f, - 0x55, 0xf4, 0x15, 0x20, 0x4e, 0x43, 0x3a, 0x94, 0x53, 0xec, 0x66, 0x4f, 0xa9, 0xe2, 0x16, 0xef, - 0x7f, 0xe4, 0x72, 0x7d, 0xf4, 0x2e, 0xc7, 0x54, 0x0e, 0x31, 0xad, 0xbb, 0x46, 0x50, 0x0d, 0xb6, - 0xee, 0xfa, 0xd2, 0x4b, 0x44, 0xb5, 0x00, 0xde, 0x9c, 0xa7, 0xeb, 0x65, 0xf2, 0x11, 0x14, 0x19, - 0xf7, 0x23, 0xc2, 0x62, 0x5f, 0xaf, 0x2d, 0x55, 0xbb, 0x15, 0xbc, 0xc6, 0xf8, 0x11, 0x61, 0xb1, - 0xde, 0x71, 0xcd, 0x2f, 0x5e, 0xcd, 0xca, 0xd6, 0xeb, 0x59, 0xd9, 0xfa, 0x73, 0x56, 0xb6, 0x7e, - 0xba, 0x2a, 0x2f, 0xbd, 0xbe, 0x2a, 0x2f, 0xfd, 0x7e, 0x55, 0x5e, 0x7a, 0xf9, 0xf1, 0x88, 0x89, - 0xb3, 0xc9, 0xa0, 0x36, 0x4c, 0x22, 0xb9, 0x6b, 0x9f, 0xcc, 0xef, 0xdd, 0x0b, 0xb5, 0x79, 0xe5, - 0x8f, 0xe1, 0x83, 0xbc, 0x5a, 0xbb, 0x4f, 0xff, 0x0d, 0x00, 0x00, 0xff, 0xff, 0xfe, 0x02, 0x23, - 0x3c, 0xff, 0x07, 0x00, 0x00, + proto.RegisterEnum("sge.legacy.bet.v1beta.Bet_Status", Bet_Status_name, Bet_Status_value) + proto.RegisterEnum("sge.legacy.bet.v1beta.Bet_Result", Bet_Result_name, Bet_Result_value) + proto.RegisterType((*Bet)(nil), "sge.legacy.bet.v1beta.Bet") + proto.RegisterType((*UID2ID)(nil), "sge.legacy.bet.v1beta.UID2ID") + proto.RegisterType((*PendingBet)(nil), "sge.legacy.bet.v1beta.PendingBet") + proto.RegisterType((*SettledBet)(nil), "sge.legacy.bet.v1beta.SettledBet") + proto.RegisterType((*BetFulfillment)(nil), "sge.legacy.bet.v1beta.BetFulfillment") + proto.RegisterType((*MetaData)(nil), "sge.legacy.bet.v1beta.MetaData") +} + +func init() { proto.RegisterFile("sge/legacy/bet/v1beta/bet.proto", fileDescriptor_53f19620418bb46a) } + +var fileDescriptor_53f19620418bb46a = []byte{ + // 1004 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x55, 0xcd, 0x6e, 0xdb, 0x46, + 0x10, 0x36, 0x25, 0x45, 0xb1, 0xc6, 0xb6, 0x2c, 0xaf, 0x9d, 0x94, 0x75, 0x1a, 0x51, 0x65, 0x1b, + 0xc0, 0x40, 0x61, 0x09, 0x55, 0x90, 0x43, 0xda, 0x43, 0x21, 0x99, 0x74, 0x22, 0x40, 0x96, 0xdd, + 0x95, 0xd4, 0x02, 0xb9, 0x10, 0x2b, 0x71, 0x2d, 0xb3, 0xe6, 0x8f, 0xc0, 0x5d, 0xa5, 0xf6, 0x03, + 0xf4, 0xde, 0x47, 0xe8, 0x1b, 0xf4, 0xd2, 0x87, 0xc8, 0x31, 0xe8, 0xa9, 0xe8, 0x41, 0x68, 0xe5, + 0x5b, 0x8f, 0x79, 0x82, 0x62, 0x7f, 0x6c, 0xcb, 0xa8, 0x5d, 0xeb, 0x42, 0xcc, 0x7e, 0xfc, 0xbe, + 0x99, 0xe1, 0x70, 0x76, 0x06, 0x2c, 0x36, 0xa2, 0xb5, 0x90, 0x8e, 0xc8, 0xf0, 0xbc, 0x36, 0xa0, + 0xbc, 0xf6, 0xf6, 0xcb, 0x01, 0xe5, 0x44, 0x98, 0xd5, 0x71, 0x9a, 0xf0, 0x04, 0x3d, 0x62, 0x23, + 0x5a, 0x55, 0x84, 0xaa, 0x40, 0x15, 0x61, 0xfb, 0xe3, 0x61, 0xc2, 0xa2, 0x84, 0x79, 0x92, 0x54, + 0x53, 0x07, 0xa5, 0xd8, 0xde, 0x1a, 0x25, 0xa3, 0x44, 0xe1, 0xc2, 0xd2, 0xe8, 0xb3, 0xdb, 0x03, + 0x25, 0xbe, 0xcf, 0x3c, 0x7e, 0x3e, 0xa6, 0x8a, 0x66, 0xff, 0xb4, 0x0c, 0xd9, 0x26, 0xe5, 0xa8, + 0x02, 0xd9, 0x49, 0xe0, 0x9b, 0x46, 0xc5, 0xd8, 0x29, 0x34, 0x8b, 0xb3, 0xa9, 0x95, 0xed, 0xb7, + 0x9c, 0x7f, 0xa6, 0x96, 0x40, 0xb1, 0x78, 0xa0, 0xaf, 0x01, 0x22, 0x92, 0x9e, 0x52, 0xee, 0x09, + 0x62, 0x46, 0x12, 0x9f, 0xcc, 0xa6, 0x56, 0xe1, 0x40, 0xa2, 0x8a, 0x3e, 0x47, 0xc1, 0x73, 0x36, + 0x7a, 0x0e, 0xcb, 0x32, 0xb2, 0x90, 0x66, 0xa5, 0xf4, 0xa3, 0xd9, 0xd4, 0x7a, 0x78, 0xe8, 0xfb, + 0x4c, 0x09, 0xaf, 0x5e, 0xe3, 0x2b, 0x0b, 0x3d, 0x05, 0x90, 0xf6, 0x5b, 0x12, 0x4e, 0xa8, 0xf9, + 0x40, 0xc8, 0x70, 0x41, 0x20, 0xdf, 0x09, 0x00, 0xbd, 0x80, 0x3c, 0x89, 0x92, 0x49, 0xcc, 0xcd, + 0xbc, 0xf4, 0xf8, 0xf4, 0xdd, 0xd4, 0x5a, 0xfa, 0x73, 0x6a, 0x3d, 0x52, 0xd5, 0x61, 0xfe, 0x69, + 0x35, 0x48, 0x6a, 0x11, 0xe1, 0x27, 0xd5, 0x56, 0xcc, 0xb1, 0x26, 0xa3, 0x1a, 0x64, 0x8f, 0x29, + 0x35, 0x1f, 0x2e, 0xa2, 0x11, 0x4c, 0xf4, 0x12, 0xf2, 0x8c, 0x13, 0x3e, 0x61, 0xe6, 0x72, 0xc5, + 0xd8, 0x29, 0xd6, 0x3f, 0xad, 0xde, 0xfa, 0x8b, 0xaa, 0x4d, 0xca, 0xab, 0x5d, 0x49, 0xc4, 0x5a, + 0x20, 0xa4, 0x29, 0x65, 0x93, 0x90, 0x9b, 0x85, 0x7b, 0xa5, 0x58, 0x12, 0xb1, 0x16, 0xa0, 0x3a, + 0x3c, 0x1c, 0xa6, 0x94, 0xf0, 0x24, 0x35, 0x41, 0xa6, 0x6a, 0xfe, 0xfe, 0xdb, 0xee, 0x96, 0xfe, + 0xf1, 0x0d, 0xdf, 0x4f, 0x29, 0x63, 0x5d, 0x9e, 0x06, 0xf1, 0x08, 0x5f, 0x12, 0x45, 0xc1, 0xa4, + 0x49, 0x7d, 0x8f, 0x70, 0x73, 0xa5, 0x62, 0xec, 0x64, 0x71, 0x41, 0x23, 0x0d, 0x8e, 0xbe, 0x80, + 0x0d, 0x46, 0x39, 0x0f, 0x69, 0x44, 0x63, 0xee, 0x9d, 0xd0, 0x60, 0x74, 0xc2, 0xcd, 0x55, 0xc9, + 0x2a, 0x5d, 0xbf, 0x78, 0x2d, 0x71, 0xd4, 0x85, 0xcd, 0x88, 0x9c, 0x79, 0x61, 0xc2, 0x98, 0x17, + 0x4d, 0x42, 0x1e, 0x8c, 0xc3, 0x80, 0xa6, 0xe6, 0x9a, 0xcc, 0xe5, 0x33, 0x5d, 0xb6, 0x27, 0xff, + 0x2d, 0x5b, 0x5b, 0x7e, 0x9c, 0x43, 0x87, 0x78, 0x23, 0x22, 0x67, 0xed, 0x84, 0xb1, 0x83, 0x2b, + 0x35, 0xea, 0xc0, 0xfa, 0x80, 0x72, 0xef, 0x78, 0x12, 0x1e, 0x07, 0x61, 0x28, 0xa2, 0x99, 0xc5, + 0x4a, 0x76, 0x67, 0xa5, 0xfe, 0xec, 0xee, 0xc2, 0xec, 0x5f, 0x93, 0x71, 0x71, 0x70, 0xe3, 0x8c, + 0x5e, 0x42, 0x2e, 0xa2, 0x9c, 0x98, 0xeb, 0x15, 0x63, 0x67, 0xa5, 0x6e, 0xdd, 0xe1, 0xe4, 0x80, + 0x72, 0xe2, 0x10, 0x4e, 0x9a, 0x39, 0x91, 0x36, 0x96, 0x12, 0xfb, 0x17, 0x03, 0xf2, 0xea, 0x6f, + 0xa1, 0xc7, 0x80, 0xba, 0xbd, 0x46, 0xaf, 0xdf, 0xf5, 0xfa, 0x9d, 0xee, 0x91, 0xbb, 0xd7, 0xda, + 0x6f, 0xb9, 0x4e, 0x69, 0x09, 0x6d, 0xc0, 0x9a, 0xc6, 0x8f, 0xda, 0x8d, 0x3d, 0xd7, 0x29, 0x19, + 0x68, 0x13, 0xd6, 0x35, 0xb4, 0xd7, 0xe8, 0xec, 0xb9, 0x6d, 0xd7, 0x29, 0x65, 0x10, 0x82, 0xa2, + 0x06, 0x1b, 0xcd, 0x43, 0xdc, 0x73, 0x9d, 0x52, 0x76, 0x0e, 0x3b, 0x72, 0x3b, 0x4e, 0xab, 0xf3, + 0xaa, 0x94, 0x43, 0xdb, 0xf0, 0x58, 0x63, 0xd8, 0xed, 0xf6, 0xdb, 0x3d, 0xcf, 0x71, 0xf7, 0xda, + 0x0d, 0xec, 0x3a, 0xa5, 0x07, 0x73, 0xfc, 0xae, 0xdb, 0xeb, 0x09, 0xbf, 0x79, 0xfb, 0x07, 0xc8, + 0xab, 0xa6, 0x10, 0x19, 0x6a, 0xc9, 0xcd, 0x0c, 0x11, 0x14, 0x35, 0x7e, 0x19, 0xc5, 0x40, 0x45, + 0x00, 0x8d, 0x7d, 0x7f, 0xd8, 0x29, 0x65, 0xd0, 0x3a, 0xac, 0xe8, 0x73, 0xfb, 0xb0, 0xdb, 0x2b, + 0x65, 0xc5, 0x37, 0x68, 0x00, 0xbb, 0xfb, 0xfd, 0x8e, 0xe3, 0x3a, 0xa5, 0x9c, 0xfd, 0x1a, 0xf2, + 0xfd, 0x96, 0x53, 0x6f, 0x39, 0x0b, 0x4c, 0x82, 0x4f, 0x20, 0xa3, 0x27, 0x40, 0xae, 0xb9, 0x3a, + 0x9b, 0x5a, 0x19, 0xf9, 0x3e, 0x13, 0xf8, 0x38, 0x13, 0xf8, 0xf6, 0x00, 0xe0, 0x88, 0xc6, 0x7e, + 0x10, 0x8f, 0x16, 0x9b, 0x2b, 0x73, 0x8d, 0x9e, 0x59, 0xb0, 0xd1, 0xed, 0x04, 0xa0, 0x2b, 0x1b, + 0xd6, 0x5f, 0x2c, 0xc6, 0x37, 0x20, 0x3a, 0x87, 0x27, 0xa9, 0x47, 0x94, 0xc3, 0x7b, 0x43, 0xad, + 0x29, 0xbe, 0x06, 0xed, 0xbf, 0x33, 0x50, 0xbc, 0xd9, 0x8b, 0xe8, 0x10, 0x36, 0xc7, 0x24, 0xe5, + 0xc1, 0x30, 0x18, 0x93, 0x98, 0x5f, 0x39, 0x56, 0x59, 0x94, 0x3f, 0x4c, 0xad, 0xed, 0x73, 0x12, + 0x85, 0x5f, 0xd9, 0xb7, 0x90, 0x6c, 0x8c, 0xe6, 0x50, 0x1d, 0xe3, 0x86, 0x43, 0x1e, 0x24, 0xb1, + 0x17, 0xc4, 0x3e, 0x3d, 0xd3, 0x75, 0xbe, 0xcd, 0xe1, 0x35, 0x69, 0xde, 0xa1, 0x40, 0x5b, 0x02, + 0x44, 0xdf, 0x02, 0x88, 0xdb, 0xa6, 0x87, 0xa4, 0x1a, 0xbb, 0xf5, 0xff, 0x1d, 0x78, 0x1f, 0xa6, + 0xd6, 0x86, 0x0a, 0x72, 0x2d, 0xb4, 0x71, 0x61, 0x40, 0x79, 0x43, 0x0d, 0xcf, 0x37, 0xb0, 0x36, + 0x26, 0xe7, 0xc9, 0x84, 0x8b, 0x45, 0x74, 0x1c, 0x70, 0x33, 0x27, 0xbd, 0xbe, 0xb8, 0xcf, 0xeb, + 0xd6, 0x65, 0xea, 0x73, 0x5a, 0x1b, 0xaf, 0xaa, 0xf3, 0x91, 0x3a, 0xfe, 0x6a, 0xc0, 0xf2, 0xe5, + 0x55, 0x45, 0x07, 0x80, 0x18, 0x0d, 0xe9, 0x50, 0xcc, 0xb2, 0xab, 0x9d, 0x25, 0x8b, 0x5b, 0xbc, + 0xf3, 0x9e, 0x8b, 0x6d, 0xd2, 0x3b, 0x1f, 0x53, 0x31, 0xcd, 0x94, 0xf4, 0x12, 0x41, 0x55, 0xd8, + 0xbc, 0xe9, 0x4e, 0xed, 0x14, 0xd9, 0x05, 0x78, 0x63, 0x9e, 0xae, 0x76, 0xcb, 0xe7, 0x50, 0x0c, + 0x98, 0x17, 0x91, 0x20, 0xf6, 0xd4, 0x16, 0x93, 0xe5, 0x5b, 0xc6, 0xab, 0x01, 0x3b, 0x20, 0x41, + 0xac, 0x56, 0x5e, 0xf3, 0xd5, 0xbb, 0x59, 0xd9, 0x78, 0x3f, 0x2b, 0x1b, 0x7f, 0xcd, 0xca, 0xc6, + 0xcf, 0x17, 0xe5, 0xa5, 0xf7, 0x17, 0xe5, 0xa5, 0x3f, 0x2e, 0xca, 0x4b, 0x6f, 0x76, 0x47, 0x01, + 0x3f, 0x99, 0x0c, 0xaa, 0xc3, 0x24, 0xaa, 0xb1, 0x11, 0xdd, 0x8d, 0x29, 0xff, 0x31, 0x49, 0x4f, + 0x85, 0x5d, 0x3b, 0x9b, 0x5f, 0xcb, 0xe2, 0xb3, 0xd8, 0x20, 0x2f, 0x97, 0xf1, 0xf3, 0x7f, 0x03, + 0x00, 0x00, 0xff, 0xff, 0xed, 0x0e, 0x26, 0xb0, 0x1e, 0x08, 0x00, 0x00, } func (m *Bet) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/bet_odds.pb.go b/x/legacy/bet/types/bet_odds.pb.go similarity index 85% rename from x/bet/types/bet_odds.pb.go rename to x/legacy/bet/types/bet_odds.pb.go index ce0a848f..e973910d 100644 --- a/x/bet/types/bet_odds.pb.go +++ b/x/legacy/bet/types/bet_odds.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/bet_odds.proto +// source: sge/legacy/bet/v1beta/bet_odds.proto package types @@ -43,7 +43,7 @@ func (m *BetOdds) Reset() { *m = BetOdds{} } func (m *BetOdds) String() string { return proto.CompactTextString(m) } func (*BetOdds) ProtoMessage() {} func (*BetOdds) Descriptor() ([]byte, []int) { - return fileDescriptor_cabb5a887005fe34, []int{0} + return fileDescriptor_90fea61887d66624, []int{0} } func (m *BetOdds) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -106,7 +106,7 @@ func (m *BetOddsCompact) Reset() { *m = BetOddsCompact{} } func (m *BetOddsCompact) String() string { return proto.CompactTextString(m) } func (*BetOddsCompact) ProtoMessage() {} func (*BetOddsCompact) Descriptor() ([]byte, []int) { - return fileDescriptor_cabb5a887005fe34, []int{1} + return fileDescriptor_90fea61887d66624, []int{1} } func (m *BetOddsCompact) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -143,36 +143,38 @@ func (m *BetOddsCompact) GetUID() string { } func init() { - proto.RegisterType((*BetOdds)(nil), "sgenetwork.sge.bet.BetOdds") - proto.RegisterType((*BetOddsCompact)(nil), "sgenetwork.sge.bet.BetOddsCompact") + proto.RegisterType((*BetOdds)(nil), "sge.legacy.bet.v1beta.BetOdds") + proto.RegisterType((*BetOddsCompact)(nil), "sge.legacy.bet.v1beta.BetOddsCompact") } -func init() { proto.RegisterFile("sgenetwork/sge/bet/bet_odds.proto", fileDescriptor_cabb5a887005fe34) } +func init() { + proto.RegisterFile("sge/legacy/bet/v1beta/bet_odds.proto", fileDescriptor_90fea61887d66624) +} -var fileDescriptor_cabb5a887005fe34 = []byte{ - // 341 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x4f, 0x4a, 0x2d, 0x01, 0xe1, - 0xf8, 0xfc, 0x94, 0x94, 0x62, 0xbd, 0x82, 0xa2, 0xfc, 0x92, 0x7c, 0x21, 0x21, 0x84, 0x12, 0xbd, - 0xe2, 0xf4, 0x54, 0xbd, 0xa4, 0xd4, 0x12, 0x29, 0x91, 0xf4, 0xfc, 0xf4, 0x7c, 0xb0, 0xb4, 0x3e, - 0x88, 0x05, 0x51, 0xa9, 0xd4, 0xc4, 0xc4, 0xc5, 0xee, 0x94, 0x5a, 0xe2, 0x9f, 0x92, 0x52, 0x2c, - 0xa4, 0xc0, 0xc5, 0x5c, 0x9a, 0x99, 0x22, 0xc1, 0xa8, 0xc0, 0xa8, 0xc1, 0xe9, 0xc4, 0xf7, 0xe8, - 0x9e, 0x3c, 0x73, 0xa8, 0xa7, 0xcb, 0xab, 0x7b, 0xf2, 0x20, 0xd1, 0x20, 0x10, 0x21, 0x64, 0xcd, - 0xc5, 0x95, 0x9b, 0x58, 0x94, 0x9d, 0x5a, 0x12, 0x0f, 0x52, 0xc8, 0x04, 0x56, 0x28, 0xfd, 0xe8, - 0x9e, 0x3c, 0xa7, 0x2f, 0x58, 0x14, 0xa2, 0x1c, 0x49, 0x49, 0x10, 0x12, 0x5b, 0x48, 0x84, 0x8b, - 0xb5, 0x2c, 0x31, 0xa7, 0x34, 0x55, 0x82, 0x19, 0xa4, 0x2f, 0x08, 0xc2, 0x11, 0x6a, 0x64, 0xe4, - 0x12, 0xce, 0x4d, 0xac, 0x88, 0xcf, 0xc9, 0x2f, 0x2e, 0x8e, 0xcf, 0x2d, 0xcd, 0x29, 0xc9, 0x2c, - 0xc8, 0xc9, 0x4c, 0x2d, 0x92, 0x60, 0x01, 0x1b, 0xee, 0x7f, 0xe2, 0x9e, 0x3c, 0xc3, 0xad, 0x7b, - 0xf2, 0xd2, 0xc9, 0xf9, 0xc5, 0xb9, 0xf9, 0xc5, 0xc5, 0x29, 0xd9, 0x7a, 0x99, 0xf9, 0xfa, 0xb9, - 0x89, 0x25, 0x19, 0x7a, 0x3e, 0xa9, 0xe9, 0x89, 0xc9, 0x95, 0x2e, 0xa9, 0xc9, 0x8f, 0xee, 0xc9, - 0x0b, 0xfa, 0x26, 0x56, 0xf8, 0xe4, 0x17, 0x17, 0xfb, 0xc2, 0xf5, 0xbf, 0xba, 0x27, 0x8f, 0xcd, - 0xd8, 0x20, 0x6c, 0x82, 0x4a, 0xdb, 0x18, 0xb9, 0xf8, 0xa0, 0x81, 0xe0, 0x9c, 0x9f, 0x5b, 0x90, - 0x98, 0x5c, 0x42, 0x44, 0x58, 0xe0, 0x72, 0x38, 0x13, 0xfd, 0x1c, 0xee, 0xe4, 0x70, 0xe2, 0x91, - 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x4e, 0x78, 0x2c, 0xc7, 0x70, 0xe1, - 0xb1, 0x1c, 0xc3, 0x8d, 0xc7, 0x72, 0x0c, 0x51, 0x6a, 0xe9, 0x99, 0x25, 0x19, 0xa5, 0x49, 0x7a, - 0xc9, 0xf9, 0xb9, 0xa0, 0x44, 0xa2, 0x8b, 0x9c, 0x60, 0x2a, 0xc0, 0x49, 0xa6, 0xa4, 0xb2, 0x20, - 0xb5, 0x38, 0x89, 0x0d, 0x9c, 0x0c, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0x49, 0xc4, 0x29, - 0xe1, 0x55, 0x02, 0x00, 0x00, +var fileDescriptor_90fea61887d66624 = []byte{ + // 349 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x92, 0xc1, 0x4a, 0xfb, 0x40, + 0x10, 0xc6, 0x93, 0xf6, 0xff, 0x57, 0xba, 0x87, 0x82, 0xb1, 0x42, 0xb1, 0x90, 0x94, 0xe2, 0xc1, + 0x4b, 0xb3, 0x88, 0x47, 0x6f, 0xb5, 0x20, 0x42, 0x4b, 0x21, 0xe0, 0xc5, 0x4b, 0xd8, 0x24, 0xc3, + 0x36, 0x34, 0xeb, 0x86, 0xec, 0xa6, 0xb6, 0x47, 0x7d, 0x02, 0x9f, 0xc6, 0x67, 0xe8, 0xb1, 0x47, + 0xf1, 0xb0, 0x48, 0x7a, 0xeb, 0x53, 0xc8, 0x26, 0x22, 0x3d, 0x54, 0xf0, 0xe4, 0x65, 0xf9, 0xf6, + 0xe3, 0x37, 0xc3, 0xcc, 0xf0, 0xa1, 0x33, 0x41, 0x01, 0x27, 0x40, 0x49, 0xb8, 0xc4, 0x01, 0x48, + 0x3c, 0xbf, 0x08, 0x40, 0x12, 0x2d, 0x7d, 0x1e, 0x45, 0xc2, 0x4d, 0x33, 0x2e, 0xb9, 0x75, 0x22, + 0x28, 0xb8, 0x15, 0xe5, 0x06, 0x20, 0xdd, 0x8a, 0x3a, 0x6d, 0x51, 0x4e, 0x79, 0x49, 0x60, 0xad, + 0x2a, 0xb8, 0xf7, 0x5c, 0x43, 0x87, 0x03, 0x90, 0x93, 0x28, 0x12, 0x56, 0x17, 0xd5, 0xf3, 0x38, + 0x6a, 0x9b, 0x5d, 0xf3, 0xbc, 0x31, 0x68, 0x16, 0xca, 0xa9, 0xdf, 0xdd, 0x0e, 0xb7, 0xca, 0xd1, + 0xae, 0xa7, 0x1f, 0xeb, 0x0a, 0x21, 0x46, 0xb2, 0x19, 0x48, 0x5f, 0x83, 0xb5, 0x12, 0xec, 0x14, + 0xca, 0x69, 0x8c, 0x4b, 0xb7, 0xc2, 0x77, 0x10, 0x6f, 0x47, 0x5b, 0x2d, 0xf4, 0x7f, 0x4e, 0x92, + 0x1c, 0xda, 0x75, 0x5d, 0xe7, 0x55, 0x1f, 0xeb, 0xc9, 0x44, 0xc7, 0x8c, 0x2c, 0xfc, 0x84, 0x0b, + 0xe1, 0xb3, 0x3c, 0x91, 0x71, 0x9a, 0xc4, 0x90, 0xb5, 0xff, 0x95, 0xcd, 0x27, 0x2b, 0xe5, 0x18, + 0xef, 0xca, 0xe9, 0x84, 0x5c, 0x30, 0x2e, 0x44, 0x34, 0x73, 0x63, 0x8e, 0x19, 0x91, 0x53, 0x77, + 0x54, 0x6e, 0x38, 0x84, 0xb0, 0x50, 0xce, 0xd1, 0x98, 0x2c, 0x46, 0x5c, 0x88, 0xf1, 0x77, 0xfd, + 0x56, 0x39, 0xfb, 0xda, 0x7a, 0xfb, 0xcc, 0xde, 0xab, 0x89, 0x9a, 0x5f, 0x47, 0xb8, 0xe6, 0x2c, + 0x25, 0xa1, 0xfc, 0xc5, 0x2d, 0x7e, 0x1a, 0xbc, 0xf6, 0x77, 0x83, 0x0f, 0x6e, 0x56, 0x85, 0x6d, + 0xae, 0x0b, 0xdb, 0xfc, 0x28, 0x6c, 0xf3, 0x65, 0x63, 0x1b, 0xeb, 0x8d, 0x6d, 0xbc, 0x6d, 0x6c, + 0xe3, 0xbe, 0x4f, 0x63, 0x39, 0xcd, 0x03, 0x37, 0xe4, 0x0c, 0x0b, 0x0a, 0xfd, 0x07, 0x90, 0x8f, + 0x3c, 0x9b, 0x69, 0x8d, 0x17, 0xbb, 0x19, 0x92, 0xcb, 0x14, 0x44, 0x70, 0x50, 0xa6, 0xe1, 0xf2, + 0x33, 0x00, 0x00, 0xff, 0xff, 0x26, 0xc5, 0x7d, 0x51, 0x62, 0x02, 0x00, 0x00, } func (m *BetOdds) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/bet_test.go b/x/legacy/bet/types/bet_test.go similarity index 94% rename from x/bet/types/bet_test.go rename to x/legacy/bet/types/bet_test.go index cd93edcc..e74ee3bb 100644 --- a/x/bet/types/bet_test.go +++ b/x/legacy/bet/types/bet_test.go @@ -5,8 +5,8 @@ import ( "github.com/stretchr/testify/require" - "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/bet/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" ) func TestCheckSettlementEligiblity(t *testing.T) { diff --git a/x/bet/types/codec.go b/x/legacy/bet/types/codec.go similarity index 100% rename from x/bet/types/codec.go rename to x/legacy/bet/types/codec.go diff --git a/x/bet/types/constraints.pb.go b/x/legacy/bet/types/constraints.pb.go similarity index 81% rename from x/bet/types/constraints.pb.go rename to x/legacy/bet/types/constraints.pb.go index b8c4a5dc..015dab88 100644 --- a/x/bet/types/constraints.pb.go +++ b/x/legacy/bet/types/constraints.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/constraints.proto +// source: sge/legacy/bet/v1beta/constraints.proto package types @@ -36,7 +36,7 @@ func (m *Constraints) Reset() { *m = Constraints{} } func (m *Constraints) String() string { return proto.CompactTextString(m) } func (*Constraints) ProtoMessage() {} func (*Constraints) Descriptor() ([]byte, []int) { - return fileDescriptor_1cb99da0ccbae1b1, []int{0} + return fileDescriptor_878eab791621a43a, []int{0} } func (m *Constraints) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -66,30 +66,30 @@ func (m *Constraints) XXX_DiscardUnknown() { var xxx_messageInfo_Constraints proto.InternalMessageInfo func init() { - proto.RegisterType((*Constraints)(nil), "sgenetwork.sge.bet.Constraints") + proto.RegisterType((*Constraints)(nil), "sge.legacy.bet.v1beta.Constraints") } func init() { - proto.RegisterFile("sgenetwork/sge/bet/constraints.proto", fileDescriptor_1cb99da0ccbae1b1) + proto.RegisterFile("sge/legacy/bet/v1beta/constraints.proto", fileDescriptor_878eab791621a43a) } -var fileDescriptor_1cb99da0ccbae1b1 = []byte{ - // 225 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x29, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x4f, 0x4a, 0x2d, 0xd1, 0x4f, - 0xce, 0xcf, 0x2b, 0x2e, 0x29, 0x4a, 0xcc, 0xcc, 0x2b, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, - 0x17, 0x12, 0x42, 0xa8, 0xd2, 0x2b, 0x4e, 0x4f, 0xd5, 0x4b, 0x4a, 0x2d, 0x91, 0x12, 0x49, 0xcf, - 0x4f, 0xcf, 0x07, 0x4b, 0xeb, 0x83, 0x58, 0x10, 0x95, 0x4a, 0x35, 0x5c, 0xdc, 0xce, 0x08, 0xed, - 0x42, 0x36, 0x5c, 0x5c, 0xb9, 0x99, 0x79, 0xf1, 0x89, 0xb9, 0xf9, 0xa5, 0x79, 0x25, 0x12, 0x8c, - 0x0a, 0x8c, 0x1a, 0x9c, 0x4e, 0xb2, 0x27, 0xee, 0xc9, 0x33, 0xdc, 0xba, 0x27, 0x2f, 0x9a, 0x9c, - 0x5f, 0x9c, 0x9b, 0x5f, 0x5c, 0x9c, 0x92, 0xad, 0x97, 0x99, 0xaf, 0x9f, 0x9b, 0x58, 0x92, 0xa1, - 0xe7, 0x99, 0x57, 0x12, 0xc4, 0x99, 0x9b, 0x99, 0xe7, 0x08, 0x56, 0x2f, 0xa4, 0xcf, 0xc5, 0x9c, - 0x96, 0x9a, 0x2a, 0xc1, 0x44, 0x8c, 0x36, 0x90, 0x4a, 0x27, 0x87, 0x13, 0x8f, 0xe4, 0x18, 0x2f, - 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, - 0x6e, 0x3c, 0x96, 0x63, 0x88, 0x52, 0x4b, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, - 0x05, 0xf9, 0x53, 0x17, 0xd9, 0xcf, 0x15, 0x60, 0x5f, 0x97, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, - 0x81, 0xbd, 0x61, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x79, 0x77, 0x20, 0x37, 0x18, 0x01, 0x00, - 0x00, +var fileDescriptor_878eab791621a43a = []byte{ + // 239 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0xd0, 0xb1, 0x4a, 0x03, 0x41, + 0x10, 0x80, 0xe1, 0x3b, 0x05, 0x21, 0x6b, 0x77, 0x18, 0x08, 0x82, 0x1b, 0xb1, 0xd1, 0x26, 0x3b, + 0x88, 0xad, 0x8d, 0xb1, 0x10, 0x5b, 0x4b, 0x1b, 0xd9, 0x3d, 0xc7, 0xcd, 0x12, 0x77, 0x27, 0xdc, + 0x4c, 0xd4, 0x80, 0x0f, 0xe1, 0x63, 0xa5, 0x4c, 0x29, 0x16, 0x41, 0xee, 0x5e, 0x44, 0xee, 0xae, + 0xd0, 0xd2, 0xee, 0x2f, 0xbe, 0x19, 0x98, 0x51, 0xa7, 0xec, 0x11, 0x9e, 0xd1, 0xdb, 0x72, 0x05, + 0x0e, 0x05, 0x5e, 0xce, 0x1d, 0x8a, 0x85, 0x92, 0x12, 0x4b, 0x65, 0x43, 0x12, 0x36, 0x8b, 0x8a, + 0x84, 0x8a, 0x21, 0x7b, 0x34, 0x3d, 0x34, 0x0e, 0xc5, 0xf4, 0xf0, 0xf0, 0xc0, 0x93, 0xa7, 0x4e, + 0x40, 0x5b, 0x3d, 0x3e, 0x79, 0x57, 0xfb, 0xd7, 0xbf, 0x1b, 0x8a, 0x4b, 0xa5, 0x62, 0x48, 0x0f, + 0x36, 0xd2, 0x32, 0xc9, 0x28, 0x3f, 0xce, 0xcf, 0x06, 0xd3, 0xa3, 0xf5, 0x76, 0x9c, 0x7d, 0x6d, + 0xc7, 0xc3, 0x92, 0x38, 0x12, 0xf3, 0xe3, 0xdc, 0x04, 0x82, 0x68, 0x65, 0x66, 0x6e, 0x93, 0xdc, + 0x0d, 0x62, 0x48, 0x57, 0x9d, 0x2f, 0x40, 0xed, 0x3e, 0x21, 0x8e, 0x76, 0xfe, 0x33, 0xd6, 0xca, + 0xe9, 0xcd, 0xba, 0xd6, 0xf9, 0xa6, 0xd6, 0xf9, 0x77, 0xad, 0xf3, 0x8f, 0x46, 0x67, 0x9b, 0x46, + 0x67, 0x9f, 0x8d, 0xce, 0xee, 0x27, 0x3e, 0xc8, 0x6c, 0xe9, 0x4c, 0x49, 0x11, 0xd8, 0xe3, 0x24, + 0xa1, 0xbc, 0x52, 0x35, 0x6f, 0x1b, 0xde, 0xfe, 0xbe, 0x41, 0x56, 0x0b, 0x64, 0xb7, 0xd7, 0x5d, + 0x73, 0xf1, 0x13, 0x00, 0x00, 0xff, 0xff, 0x65, 0xc5, 0xd2, 0xde, 0x25, 0x01, 0x00, 0x00, } func (m *Constraints) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/errors.go b/x/legacy/bet/types/errors.go similarity index 100% rename from x/bet/types/errors.go rename to x/legacy/bet/types/errors.go diff --git a/x/bet/types/events.go b/x/legacy/bet/types/events.go similarity index 100% rename from x/bet/types/events.go rename to x/legacy/bet/types/events.go diff --git a/x/bet/types/expected_keepers.go b/x/legacy/bet/types/expected_keepers.go similarity index 89% rename from x/bet/types/expected_keepers.go rename to x/legacy/bet/types/expected_keepers.go index 7feab15c..55a9a640 100644 --- a/x/bet/types/expected_keepers.go +++ b/x/legacy/bet/types/expected_keepers.go @@ -5,20 +5,19 @@ import ( sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/auth/types" - markettypes "github.com/sge-network/sge/x/market/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" ) // AccountKeeper defines the expected account keeper used for simulations (noalias) type AccountKeeper interface { - GetAccount(ctx sdk.Context, addr sdk.AccAddress) types.AccountI + GetAccount(ctx context.Context, addr sdk.AccAddress) sdk.AccountI // Methods imported from account should be defined here } // BankKeeper defines the expected interface needed to retrieve account balances. type BankKeeper interface { - SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins + SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins // Methods imported from bank should be defined here } diff --git a/x/bet/types/funder.go b/x/legacy/bet/types/funder.go similarity index 100% rename from x/bet/types/funder.go rename to x/legacy/bet/types/funder.go diff --git a/x/bet/types/genesis.go b/x/legacy/bet/types/genesis.go similarity index 100% rename from x/bet/types/genesis.go rename to x/legacy/bet/types/genesis.go diff --git a/x/bet/types/genesis.pb.go b/x/legacy/bet/types/genesis.pb.go similarity index 84% rename from x/bet/types/genesis.pb.go rename to x/legacy/bet/types/genesis.pb.go index 9296794c..f2e5653a 100644 --- a/x/bet/types/genesis.pb.go +++ b/x/legacy/bet/types/genesis.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/genesis.proto +// source: sge/legacy/bet/v1beta/genesis.proto package types @@ -43,7 +43,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_a21c537e364bf87c, []int{0} + return fileDescriptor_43f1a910e30c9f7c, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -115,35 +115,38 @@ func (m *GenesisState) GetStats() BetStats { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.bet.GenesisState") + proto.RegisterType((*GenesisState)(nil), "sge.legacy.bet.v1beta.GenesisState") } -func init() { proto.RegisterFile("sgenetwork/sge/bet/genesis.proto", fileDescriptor_a21c537e364bf87c) } +func init() { + proto.RegisterFile("sge/legacy/bet/v1beta/genesis.proto", fileDescriptor_43f1a910e30c9f7c) +} -var fileDescriptor_a21c537e364bf87c = []byte{ - // 344 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0xcd, 0x4a, 0xc3, 0x40, - 0x14, 0x85, 0x13, 0xfb, 0xa3, 0x4c, 0x45, 0x24, 0x08, 0x96, 0x50, 0xa6, 0xc5, 0x85, 0x74, 0x63, - 0x02, 0x71, 0xd3, 0xa5, 0x96, 0x82, 0x14, 0x44, 0xc4, 0xe2, 0xc6, 0x4d, 0xc9, 0x98, 0xcb, 0x38, - 0xd8, 0x36, 0xa1, 0x73, 0x8b, 0xfa, 0x16, 0xbe, 0x81, 0xaf, 0xd3, 0x65, 0x97, 0xae, 0x44, 0xda, - 0x17, 0x91, 0xcc, 0x4c, 0x9b, 0x82, 0xd3, 0xdd, 0x70, 0xef, 0x39, 0xdf, 0x5c, 0xce, 0x21, 0x2d, - 0xc9, 0x61, 0x02, 0xf8, 0x96, 0x4e, 0x5f, 0x43, 0xc9, 0x21, 0x64, 0x80, 0x61, 0x3e, 0x91, 0x42, - 0x06, 0xd9, 0x34, 0xc5, 0xd4, 0xf3, 0x0a, 0x45, 0x20, 0x39, 0x04, 0x0c, 0xd0, 0x3f, 0xe1, 0x29, - 0x4f, 0xd5, 0x3a, 0xcc, 0x5f, 0x5a, 0xe9, 0x37, 0x2d, 0xac, 0x2c, 0x9e, 0xc6, 0x63, 0x83, 0xf2, - 0x1b, 0x16, 0x01, 0x03, 0x34, 0x5b, 0x6a, 0xd9, 0x4a, 0x8c, 0xd1, 0xb8, 0xcf, 0xbe, 0x4a, 0xe4, - 0xf0, 0x46, 0x9f, 0x36, 0xc0, 0x18, 0xc1, 0xeb, 0x90, 0xaa, 0xc6, 0xd7, 0xdd, 0x96, 0xdb, 0xae, - 0x45, 0x7e, 0xf0, 0xff, 0xd4, 0xe0, 0x5e, 0x29, 0xba, 0xe5, 0xf9, 0x4f, 0xd3, 0x79, 0x30, 0x7a, - 0xaf, 0x43, 0x0e, 0x18, 0xe0, 0x70, 0x24, 0x24, 0xd6, 0xf7, 0x5a, 0xa5, 0x76, 0x2d, 0x3a, 0xb5, - 0x79, 0xbb, 0x80, 0xc6, 0xb8, 0xcf, 0x00, 0x6f, 0x85, 0x44, 0xef, 0x8e, 0x1c, 0x67, 0x30, 0x49, - 0xc4, 0x84, 0x0f, 0x37, 0x84, 0x92, 0x22, 0x50, 0xeb, 0xef, 0x5a, 0x5b, 0x80, 0x8e, 0xb2, 0xcd, - 0x64, 0xcd, 0x93, 0x80, 0x38, 0x82, 0xa4, 0xe0, 0x95, 0x77, 0xf3, 0x06, 0x5a, 0xbb, 0xc5, 0x93, - 0x9b, 0x89, 0xe2, 0x5d, 0x93, 0xda, 0x4c, 0x24, 0x91, 0x48, 0x34, 0xaa, 0xa2, 0x50, 0xd6, 0x60, - 0x1e, 0xfb, 0xbd, 0xa8, 0xdf, 0x33, 0x18, 0xa2, 0x4d, 0x0a, 0xd1, 0x21, 0x15, 0x15, 0x7b, 0xbd, - 0xaa, 0x52, 0x6d, 0xec, 0x48, 0x26, 0xef, 0x60, 0x9d, 0xab, 0x36, 0x74, 0xaf, 0xe6, 0x4b, 0xea, - 0x2e, 0x96, 0xd4, 0xfd, 0x5d, 0x52, 0xf7, 0x73, 0x45, 0x9d, 0xc5, 0x8a, 0x3a, 0xdf, 0x2b, 0xea, - 0x3c, 0x9d, 0x73, 0x81, 0x2f, 0x33, 0x16, 0x3c, 0xa7, 0xe3, 0xbc, 0xdb, 0x8b, 0xed, 0x9e, 0xdf, - 0x55, 0xd3, 0xf8, 0x91, 0x81, 0x64, 0x55, 0x55, 0xf5, 0xe5, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, - 0xad, 0xf5, 0xa2, 0xce, 0x97, 0x02, 0x00, 0x00, +var fileDescriptor_43f1a910e30c9f7c = []byte{ + // 356 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0xcb, 0x4a, 0xc3, 0x40, + 0x14, 0x86, 0x13, 0x7b, 0x51, 0xa6, 0x22, 0x12, 0x14, 0x4a, 0xc0, 0xf4, 0xe2, 0xa6, 0x9b, 0x66, + 0x30, 0x2e, 0xbb, 0x2b, 0x85, 0x52, 0x70, 0xa1, 0x16, 0x37, 0x6e, 0x4a, 0xa6, 0x39, 0x8c, 0x83, + 0x6d, 0x12, 0x3a, 0xa7, 0x6a, 0xdf, 0xc2, 0x57, 0xf1, 0x2d, 0xba, 0xec, 0xd2, 0x95, 0x48, 0xfb, + 0x22, 0x92, 0x99, 0xf4, 0xb2, 0x48, 0xdc, 0x0d, 0xc3, 0xf7, 0x7f, 0x73, 0xf8, 0xe7, 0x90, 0x6b, + 0xc9, 0x81, 0x4e, 0x80, 0xfb, 0xe3, 0x05, 0x65, 0x80, 0xf4, 0xed, 0x86, 0x01, 0xfa, 0x94, 0x43, + 0x08, 0x52, 0x48, 0x37, 0x9e, 0x45, 0x18, 0x59, 0x97, 0x92, 0x83, 0xab, 0x21, 0x97, 0x01, 0xba, + 0x1a, 0xb2, 0x2f, 0x78, 0xc4, 0x23, 0x45, 0xd0, 0xe4, 0xa4, 0x61, 0xbb, 0x96, 0x6d, 0x4c, 0x72, + 0x1a, 0x68, 0x66, 0x03, 0xb1, 0x3f, 0xf3, 0xa7, 0xe9, 0x8b, 0x76, 0x23, 0x9b, 0x91, 0xe8, 0x63, + 0x8a, 0x34, 0xbf, 0x0a, 0xe4, 0xb4, 0xaf, 0xc7, 0x1c, 0xa2, 0x8f, 0x60, 0x75, 0x48, 0x59, 0x3b, + 0xaa, 0x66, 0xdd, 0x6c, 0x55, 0xbc, 0x2b, 0x37, 0x73, 0x6c, 0xf7, 0x5e, 0x41, 0xdd, 0xe2, 0xf2, + 0xa7, 0x66, 0x3c, 0xa6, 0x11, 0xab, 0x43, 0x4e, 0x18, 0xe0, 0x68, 0x22, 0x24, 0x56, 0x8f, 0xea, + 0x85, 0x56, 0xc5, 0xb3, 0x73, 0xe2, 0x5d, 0xc0, 0x34, 0x7b, 0xcc, 0x00, 0xef, 0x84, 0x44, 0xeb, + 0x81, 0x9c, 0xc7, 0x10, 0x06, 0x22, 0xe4, 0xa3, 0x9d, 0xa4, 0xa0, 0x24, 0x8d, 0xbc, 0x19, 0x34, + 0xbe, 0x77, 0x9d, 0xc5, 0xbb, 0x9b, 0xad, 0x52, 0x02, 0xe2, 0x04, 0x82, 0xbd, 0xb2, 0xf8, 0xaf, + 0x72, 0xa8, 0xf1, 0x03, 0xa5, 0xdc, 0xdd, 0x28, 0x65, 0x8f, 0x54, 0xe6, 0x22, 0xf0, 0x44, 0xa0, + 0x6d, 0x25, 0x65, 0xcb, 0x2b, 0xe9, 0x69, 0xd0, 0xf3, 0x06, 0xbd, 0xd4, 0x44, 0x74, 0x4e, 0x59, + 0x3a, 0xa4, 0xa4, 0x7e, 0xa1, 0x5a, 0x56, 0x25, 0xd7, 0xf2, 0x5b, 0x4a, 0x7e, 0x65, 0x5b, 0xb3, + 0xce, 0x74, 0xfb, 0xcb, 0xb5, 0x63, 0xae, 0xd6, 0x8e, 0xf9, 0xbb, 0x76, 0xcc, 0xcf, 0x8d, 0x63, + 0xac, 0x36, 0x8e, 0xf1, 0xbd, 0x71, 0x8c, 0xe7, 0x36, 0x17, 0xf8, 0x32, 0x67, 0xee, 0x38, 0x9a, + 0x52, 0xc9, 0xa1, 0x1d, 0x02, 0xbe, 0x47, 0xb3, 0xd7, 0xe4, 0x4c, 0x3f, 0x0e, 0x37, 0x01, 0x17, + 0x31, 0x48, 0x56, 0x56, 0x3b, 0x70, 0xfb, 0x17, 0x00, 0x00, 0xff, 0xff, 0xd7, 0x89, 0xbd, 0x3f, + 0xbf, 0x02, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/genesis_test.go b/x/legacy/bet/types/genesis_test.go similarity index 97% rename from x/bet/types/genesis_test.go rename to x/legacy/bet/types/genesis_test.go index 7934c9ea..c483507b 100644 --- a/x/bet/types/genesis_test.go +++ b/x/legacy/bet/types/genesis_test.go @@ -6,7 +6,7 @@ import ( "github.com/google/uuid" "github.com/stretchr/testify/require" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) const ( diff --git a/x/bet/types/keys.go b/x/legacy/bet/types/keys.go similarity index 100% rename from x/bet/types/keys.go rename to x/legacy/bet/types/keys.go diff --git a/x/bet/types/messages_bet.go b/x/legacy/bet/types/messages_bet.go similarity index 100% rename from x/bet/types/messages_bet.go rename to x/legacy/bet/types/messages_bet.go diff --git a/x/bet/types/messages_bet_test.go b/x/legacy/bet/types/messages_bet_test.go similarity index 97% rename from x/bet/types/messages_bet_test.go rename to x/legacy/bet/types/messages_bet_test.go index 00c16526..af929037 100644 --- a/x/bet/types/messages_bet_test.go +++ b/x/legacy/bet/types/messages_bet_test.go @@ -8,7 +8,7 @@ import ( "github.com/stretchr/testify/require" "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) func TestMsgWagerValidateBasic(t *testing.T) { diff --git a/x/bet/types/messages_params.go b/x/legacy/bet/types/messages_params.go similarity index 100% rename from x/bet/types/messages_params.go rename to x/legacy/bet/types/messages_params.go diff --git a/x/bet/types/odds_type.go b/x/legacy/bet/types/odds_type.go similarity index 100% rename from x/bet/types/odds_type.go rename to x/legacy/bet/types/odds_type.go diff --git a/x/legacy/bet/types/odds_type.pb.go b/x/legacy/bet/types/odds_type.pb.go new file mode 100644 index 00000000..76accbc8 --- /dev/null +++ b/x/legacy/bet/types/odds_type.pb.go @@ -0,0 +1,84 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: sge/legacy/bet/v1beta/odds_type.proto + +package types + +import ( + fmt "fmt" + proto "github.com/cosmos/gogoproto/proto" + math "math" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +// OddsType is the representation of the type of the odds. +type OddsType int32 + +const ( + // invalid odds type + OddsType_ODDS_TYPE_UNSPECIFIED OddsType = 0 + // decimal odds type (european) + OddsType_ODDS_TYPE_DECIMAL OddsType = 1 + // fractional odds type (british) + OddsType_ODDS_TYPE_FRACTIONAL OddsType = 2 + // moneyline odds type (american) + OddsType_ODDS_TYPE_MONEYLINE OddsType = 3 +) + +var OddsType_name = map[int32]string{ + 0: "ODDS_TYPE_UNSPECIFIED", + 1: "ODDS_TYPE_DECIMAL", + 2: "ODDS_TYPE_FRACTIONAL", + 3: "ODDS_TYPE_MONEYLINE", +} + +var OddsType_value = map[string]int32{ + "ODDS_TYPE_UNSPECIFIED": 0, + "ODDS_TYPE_DECIMAL": 1, + "ODDS_TYPE_FRACTIONAL": 2, + "ODDS_TYPE_MONEYLINE": 3, +} + +func (x OddsType) String() string { + return proto.EnumName(OddsType_name, int32(x)) +} + +func (OddsType) EnumDescriptor() ([]byte, []int) { + return fileDescriptor_443226a4cee69b9e, []int{0} +} + +func init() { + proto.RegisterEnum("sge.legacy.bet.v1beta.OddsType", OddsType_name, OddsType_value) +} + +func init() { + proto.RegisterFile("sge/legacy/bet/v1beta/odds_type.proto", fileDescriptor_443226a4cee69b9e) +} + +var fileDescriptor_443226a4cee69b9e = []byte{ + // 233 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2d, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0x4f, 0x4a, 0x2d, 0xd1, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, + 0x49, 0xd4, 0xcf, 0x4f, 0x49, 0x29, 0x8e, 0x2f, 0xa9, 0x2c, 0x48, 0xd5, 0x2b, 0x28, 0xca, 0x2f, + 0xc9, 0x17, 0x12, 0x2d, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd3, 0x4b, 0x4a, 0x2d, 0xd1, 0x83, 0x28, + 0xd3, 0xca, 0xe7, 0xe2, 0xf0, 0x4f, 0x49, 0x29, 0x0e, 0xa9, 0x2c, 0x48, 0x15, 0x92, 0xe4, 0x12, + 0xf5, 0x77, 0x71, 0x09, 0x8e, 0x0f, 0x89, 0x0c, 0x70, 0x8d, 0x0f, 0xf5, 0x0b, 0x0e, 0x70, 0x75, + 0xf6, 0x74, 0xf3, 0x74, 0x75, 0x11, 0x60, 0x10, 0x12, 0xe5, 0x12, 0x44, 0x48, 0xb9, 0xb8, 0x3a, + 0x7b, 0xfa, 0x3a, 0xfa, 0x08, 0x30, 0x0a, 0x49, 0x70, 0x89, 0x20, 0x84, 0xdd, 0x82, 0x1c, 0x9d, + 0x43, 0x3c, 0xfd, 0xfd, 0x1c, 0x7d, 0x04, 0x98, 0x84, 0xc4, 0xb9, 0x84, 0x11, 0x32, 0xbe, 0xfe, + 0x7e, 0xae, 0x91, 0x3e, 0x9e, 0x7e, 0xae, 0x02, 0xcc, 0x4e, 0xee, 0x27, 0x1e, 0xc9, 0x31, 0x5e, + 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, + 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x9b, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, + 0xab, 0x5f, 0x9c, 0x9e, 0xaa, 0x9b, 0x97, 0x5a, 0x52, 0x9e, 0x5f, 0x94, 0x0d, 0x62, 0xeb, 0x57, + 0x20, 0xfb, 0x10, 0xe4, 0xab, 0xe2, 0x24, 0x36, 0xb0, 0xbf, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, + 0xff, 0xe4, 0xa1, 0x54, 0x23, 0x00, 0x01, 0x00, 0x00, +} diff --git a/x/bet/types/params.go b/x/legacy/bet/types/params.go similarity index 100% rename from x/bet/types/params.go rename to x/legacy/bet/types/params.go diff --git a/x/bet/types/params.pb.go b/x/legacy/bet/types/params.pb.go similarity index 78% rename from x/bet/types/params.pb.go rename to x/legacy/bet/types/params.pb.go index ac55edbf..e5be5789 100644 --- a/x/bet/types/params.pb.go +++ b/x/legacy/bet/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/params.proto +// source: sge/legacy/bet/v1beta/params.proto package types @@ -36,7 +36,7 @@ type Params struct { func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_f6bea002c4bbd0b9, []int{0} + return fileDescriptor_a4817f7b4190cb0c, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -87,32 +87,35 @@ func (m *Params) GetConstraints() Constraints { } func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.bet.Params") + proto.RegisterType((*Params)(nil), "sge.legacy.bet.v1beta.Params") } -func init() { proto.RegisterFile("sgenetwork/sge/bet/params.proto", fileDescriptor_f6bea002c4bbd0b9) } +func init() { + proto.RegisterFile("sge/legacy/bet/v1beta/params.proto", fileDescriptor_a4817f7b4190cb0c) +} -var fileDescriptor_f6bea002c4bbd0b9 = []byte{ - // 303 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2f, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x4f, 0x4a, 0x2d, 0xd1, 0x2f, - 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x42, 0x28, 0xd0, - 0x2b, 0x4e, 0x4f, 0xd5, 0x4b, 0x4a, 0x2d, 0x91, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x4b, 0xeb, - 0x83, 0x58, 0x10, 0x95, 0x52, 0x2a, 0x58, 0x8c, 0x4a, 0xce, 0xcf, 0x2b, 0x2e, 0x29, 0x4a, 0xcc, - 0xcc, 0x2b, 0x81, 0x9a, 0xa7, 0x74, 0x8f, 0x91, 0x8b, 0x2d, 0x00, 0x6c, 0x81, 0x90, 0x09, 0x97, - 0x58, 0x52, 0x62, 0x49, 0x72, 0x46, 0x7c, 0x71, 0x6a, 0x49, 0x49, 0x4e, 0x6a, 0x6e, 0x6a, 0x5e, - 0x49, 0x7c, 0x72, 0x7e, 0x69, 0x5e, 0x89, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0x6f, 0x90, 0x08, 0x58, - 0x36, 0x18, 0x2e, 0xe9, 0x0c, 0x92, 0x13, 0xb2, 0xe4, 0x92, 0xca, 0x4d, 0xac, 0x88, 0x4f, 0x4a, - 0x2d, 0x89, 0x4f, 0xaa, 0x8c, 0x2f, 0xcd, 0x4c, 0x89, 0x2f, 0x2c, 0x4d, 0x2d, 0xaa, 0x84, 0xea, - 0x64, 0x02, 0xeb, 0x14, 0xcd, 0x4d, 0xac, 0x70, 0x4a, 0x2d, 0x71, 0xaa, 0x0c, 0xcd, 0x4c, 0x09, - 0x04, 0xc9, 0x42, 0xb4, 0xc6, 0x72, 0x71, 0x23, 0x39, 0x48, 0x82, 0x59, 0x81, 0x51, 0x83, 0xdb, - 0x48, 0x5e, 0x0f, 0xd3, 0x87, 0x7a, 0xce, 0x08, 0x65, 0x4e, 0x52, 0x27, 0xee, 0xc9, 0x33, 0x7c, - 0xba, 0x27, 0x2f, 0x54, 0x99, 0x98, 0x9b, 0x63, 0xa5, 0x84, 0x64, 0x82, 0x52, 0x10, 0xb2, 0x79, - 0x56, 0x2c, 0x33, 0x16, 0xc8, 0x33, 0x38, 0x39, 0x9c, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, - 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, - 0x1c, 0x43, 0x94, 0x5a, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0x2e, 0x28, 0x80, - 0x74, 0x91, 0x03, 0xab, 0x02, 0x1c, 0x5c, 0x25, 0x95, 0x05, 0xa9, 0xc5, 0x49, 0x6c, 0xe0, 0x90, - 0x32, 0x06, 0x04, 0x00, 0x00, 0xff, 0xff, 0x5e, 0x9c, 0x75, 0x93, 0x9c, 0x01, 0x00, 0x00, +var fileDescriptor_a4817f7b4190cb0c = []byte{ + // 312 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x90, 0xbf, 0x4e, 0xc3, 0x30, + 0x10, 0xc6, 0x63, 0x40, 0x1d, 0x52, 0xb1, 0x44, 0x2d, 0xaa, 0x32, 0xa4, 0x55, 0x16, 0xba, 0xd4, + 0x16, 0x7f, 0x16, 0x3a, 0xa6, 0x03, 0x2b, 0x14, 0xb1, 0xb0, 0x04, 0x3b, 0x3d, 0xb9, 0x11, 0x4d, + 0x5c, 0xe2, 0x0b, 0xd4, 0x6f, 0xc1, 0xc8, 0xc8, 0xe3, 0x74, 0xec, 0xc8, 0x54, 0x41, 0xfb, 0x06, + 0x3c, 0x01, 0x4a, 0x52, 0x41, 0x86, 0x6e, 0x27, 0x7d, 0xbf, 0xef, 0x67, 0xdf, 0xd9, 0xbe, 0x96, + 0xc0, 0x66, 0x20, 0x79, 0x64, 0x98, 0x00, 0x64, 0x2f, 0x67, 0x02, 0x90, 0xb3, 0x39, 0xcf, 0x78, + 0xa2, 0xe9, 0x3c, 0x53, 0xa8, 0x9c, 0xb6, 0x96, 0x40, 0x2b, 0x86, 0x0a, 0x40, 0x5a, 0x31, 0x6e, + 0x4b, 0x2a, 0xa9, 0x4a, 0x82, 0x15, 0x53, 0x05, 0xbb, 0xa7, 0xfb, 0x85, 0x91, 0x4a, 0x35, 0x66, + 0x3c, 0x4e, 0x71, 0x67, 0xf5, 0xbf, 0x89, 0xdd, 0xb8, 0x29, 0x9f, 0x71, 0x2e, 0xed, 0x13, 0xc1, + 0x31, 0x9a, 0x86, 0x1a, 0x10, 0x67, 0x90, 0x40, 0x8a, 0x61, 0xa4, 0xf2, 0x14, 0x3b, 0xa4, 0x47, + 0xfa, 0xc7, 0xe3, 0x56, 0x99, 0xde, 0xfd, 0x85, 0xa3, 0x22, 0x73, 0xae, 0x6c, 0x37, 0xe1, 0x8b, + 0x50, 0x00, 0x86, 0xc2, 0x84, 0x79, 0x3c, 0x09, 0x9f, 0x73, 0xc8, 0xcc, 0xae, 0x79, 0x50, 0x36, + 0xdb, 0x09, 0x5f, 0x04, 0x80, 0x81, 0xb9, 0x8f, 0x27, 0xb7, 0x45, 0x5a, 0x55, 0x1f, 0xed, 0x66, + 0xed, 0x43, 0x9d, 0xc3, 0x1e, 0xe9, 0x37, 0xcf, 0x7d, 0xba, 0x77, 0x4f, 0x3a, 0xfa, 0x27, 0x03, + 0x77, 0xb9, 0xee, 0x5a, 0x3f, 0xeb, 0xae, 0x63, 0x78, 0x32, 0x1b, 0xfa, 0x35, 0x89, 0x3f, 0xae, + 0x2b, 0x87, 0x47, 0xef, 0x1f, 0x5d, 0x2b, 0xb8, 0x5e, 0x6e, 0x3c, 0xb2, 0xda, 0x78, 0xe4, 0x6b, + 0xe3, 0x91, 0xb7, 0xad, 0x67, 0xad, 0xb6, 0x9e, 0xf5, 0xb9, 0xf5, 0xac, 0x87, 0x81, 0x8c, 0x71, + 0x9a, 0x0b, 0x1a, 0xa9, 0x84, 0x69, 0x09, 0x83, 0x14, 0xf0, 0x55, 0x65, 0x4f, 0xc5, 0xcc, 0x16, + 0xf5, 0xfb, 0xa1, 0x99, 0x83, 0x16, 0x8d, 0xf2, 0x66, 0x17, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, + 0x3c, 0xfc, 0x8c, 0x52, 0xaf, 0x01, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/payout.go b/x/legacy/bet/types/payout.go similarity index 100% rename from x/bet/types/payout.go rename to x/legacy/bet/types/payout.go diff --git a/x/bet/types/payout_test.go b/x/legacy/bet/types/payout_test.go similarity index 97% rename from x/bet/types/payout_test.go rename to x/legacy/bet/types/payout_test.go index a3eaa7be..b3412a1b 100644 --- a/x/bet/types/payout_test.go +++ b/x/legacy/bet/types/payout_test.go @@ -7,7 +7,7 @@ import ( sdkmath "cosmossdk.io/math" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) var ecceptedTruncatedValue = sdkmath.NewInt(1) diff --git a/x/bet/types/query.pb.go b/x/legacy/bet/types/query.pb.go similarity index 90% rename from x/bet/types/query.pb.go rename to x/legacy/bet/types/query.pb.go index f4a64b1a..6b699825 100644 --- a/x/bet/types/query.pb.go +++ b/x/legacy/bet/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/query.proto +// source: sge/legacy/bet/v1beta/query.proto package types @@ -11,7 +11,7 @@ import ( _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" - types "github.com/sge-network/sge/x/market/types" + types "github.com/sge-network/sge/x/legacy/market/types" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" @@ -41,7 +41,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{0} + return fileDescriptor_6d13e7d3deb3d881, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -81,7 +81,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{1} + return fileDescriptor_6d13e7d3deb3d881, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -128,7 +128,7 @@ func (m *QueryBetRequest) Reset() { *m = QueryBetRequest{} } func (m *QueryBetRequest) String() string { return proto.CompactTextString(m) } func (*QueryBetRequest) ProtoMessage() {} func (*QueryBetRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{2} + return fileDescriptor_6d13e7d3deb3d881, []int{2} } func (m *QueryBetRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -182,7 +182,7 @@ func (m *QueryBetResponse) Reset() { *m = QueryBetResponse{} } func (m *QueryBetResponse) String() string { return proto.CompactTextString(m) } func (*QueryBetResponse) ProtoMessage() {} func (*QueryBetResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{3} + return fileDescriptor_6d13e7d3deb3d881, []int{3} } func (m *QueryBetResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -235,7 +235,7 @@ func (m *QueryBetsRequest) Reset() { *m = QueryBetsRequest{} } func (m *QueryBetsRequest) String() string { return proto.CompactTextString(m) } func (*QueryBetsRequest) ProtoMessage() {} func (*QueryBetsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{4} + return fileDescriptor_6d13e7d3deb3d881, []int{4} } func (m *QueryBetsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -282,7 +282,7 @@ func (m *QueryBetsResponse) Reset() { *m = QueryBetsResponse{} } func (m *QueryBetsResponse) String() string { return proto.CompactTextString(m) } func (*QueryBetsResponse) ProtoMessage() {} func (*QueryBetsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{5} + return fileDescriptor_6d13e7d3deb3d881, []int{5} } func (m *QueryBetsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -336,7 +336,7 @@ func (m *QueryBetsByCreatorRequest) Reset() { *m = QueryBetsByCreatorReq func (m *QueryBetsByCreatorRequest) String() string { return proto.CompactTextString(m) } func (*QueryBetsByCreatorRequest) ProtoMessage() {} func (*QueryBetsByCreatorRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{6} + return fileDescriptor_6d13e7d3deb3d881, []int{6} } func (m *QueryBetsByCreatorRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -390,7 +390,7 @@ func (m *QueryBetsByCreatorResponse) Reset() { *m = QueryBetsByCreatorRe func (m *QueryBetsByCreatorResponse) String() string { return proto.CompactTextString(m) } func (*QueryBetsByCreatorResponse) ProtoMessage() {} func (*QueryBetsByCreatorResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{7} + return fileDescriptor_6d13e7d3deb3d881, []int{7} } func (m *QueryBetsByCreatorResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -443,7 +443,7 @@ func (m *QueryBetsByUIDsRequest) Reset() { *m = QueryBetsByUIDsRequest{} func (m *QueryBetsByUIDsRequest) String() string { return proto.CompactTextString(m) } func (*QueryBetsByUIDsRequest) ProtoMessage() {} func (*QueryBetsByUIDsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{8} + return fileDescriptor_6d13e7d3deb3d881, []int{8} } func (m *QueryBetsByUIDsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -490,7 +490,7 @@ func (m *QueryBetsByUIDsResponse) Reset() { *m = QueryBetsByUIDsResponse func (m *QueryBetsByUIDsResponse) String() string { return proto.CompactTextString(m) } func (*QueryBetsByUIDsResponse) ProtoMessage() {} func (*QueryBetsByUIDsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{9} + return fileDescriptor_6d13e7d3deb3d881, []int{9} } func (m *QueryBetsByUIDsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -545,7 +545,7 @@ func (m *QueryPendingBetsRequest) Reset() { *m = QueryPendingBetsRequest func (m *QueryPendingBetsRequest) String() string { return proto.CompactTextString(m) } func (*QueryPendingBetsRequest) ProtoMessage() {} func (*QueryPendingBetsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{10} + return fileDescriptor_6d13e7d3deb3d881, []int{10} } func (m *QueryPendingBetsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -599,7 +599,7 @@ func (m *QueryPendingBetsResponse) Reset() { *m = QueryPendingBetsRespon func (m *QueryPendingBetsResponse) String() string { return proto.CompactTextString(m) } func (*QueryPendingBetsResponse) ProtoMessage() {} func (*QueryPendingBetsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{11} + return fileDescriptor_6d13e7d3deb3d881, []int{11} } func (m *QueryPendingBetsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -654,7 +654,7 @@ func (m *QuerySettledBetsOfHeightRequest) Reset() { *m = QuerySettledBet func (m *QuerySettledBetsOfHeightRequest) String() string { return proto.CompactTextString(m) } func (*QuerySettledBetsOfHeightRequest) ProtoMessage() {} func (*QuerySettledBetsOfHeightRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{12} + return fileDescriptor_6d13e7d3deb3d881, []int{12} } func (m *QuerySettledBetsOfHeightRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -708,7 +708,7 @@ func (m *QuerySettledBetsOfHeightResponse) Reset() { *m = QuerySettledBe func (m *QuerySettledBetsOfHeightResponse) String() string { return proto.CompactTextString(m) } func (*QuerySettledBetsOfHeightResponse) ProtoMessage() {} func (*QuerySettledBetsOfHeightResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5d73c4d56d215257, []int{13} + return fileDescriptor_6d13e7d3deb3d881, []int{13} } func (m *QuerySettledBetsOfHeightResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -752,84 +752,85 @@ func (m *QuerySettledBetsOfHeightResponse) GetPagination() *query.PageResponse { } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.bet.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.bet.QueryParamsResponse") - proto.RegisterType((*QueryBetRequest)(nil), "sgenetwork.sge.bet.QueryBetRequest") - proto.RegisterType((*QueryBetResponse)(nil), "sgenetwork.sge.bet.QueryBetResponse") - proto.RegisterType((*QueryBetsRequest)(nil), "sgenetwork.sge.bet.QueryBetsRequest") - proto.RegisterType((*QueryBetsResponse)(nil), "sgenetwork.sge.bet.QueryBetsResponse") - proto.RegisterType((*QueryBetsByCreatorRequest)(nil), "sgenetwork.sge.bet.QueryBetsByCreatorRequest") - proto.RegisterType((*QueryBetsByCreatorResponse)(nil), "sgenetwork.sge.bet.QueryBetsByCreatorResponse") - proto.RegisterType((*QueryBetsByUIDsRequest)(nil), "sgenetwork.sge.bet.QueryBetsByUIDsRequest") - proto.RegisterType((*QueryBetsByUIDsResponse)(nil), "sgenetwork.sge.bet.QueryBetsByUIDsResponse") - proto.RegisterType((*QueryPendingBetsRequest)(nil), "sgenetwork.sge.bet.QueryPendingBetsRequest") - proto.RegisterType((*QueryPendingBetsResponse)(nil), "sgenetwork.sge.bet.QueryPendingBetsResponse") - proto.RegisterType((*QuerySettledBetsOfHeightRequest)(nil), "sgenetwork.sge.bet.QuerySettledBetsOfHeightRequest") - proto.RegisterType((*QuerySettledBetsOfHeightResponse)(nil), "sgenetwork.sge.bet.QuerySettledBetsOfHeightResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/bet/query.proto", fileDescriptor_5d73c4d56d215257) } - -var fileDescriptor_5d73c4d56d215257 = []byte{ - // 916 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x96, 0xcf, 0x6f, 0xdc, 0x44, - 0x14, 0xc7, 0xe3, 0x6c, 0x9a, 0x28, 0x2f, 0x54, 0xa1, 0xaf, 0x81, 0x6c, 0x2c, 0xb2, 0x4e, 0x4d, - 0x9a, 0x54, 0x49, 0xd7, 0x56, 0x52, 0x0e, 0x20, 0x2e, 0x60, 0x50, 0x81, 0x03, 0x6a, 0x70, 0x95, - 0x4b, 0x2f, 0x8b, 0xbd, 0x9e, 0x3a, 0x26, 0x59, 0xcf, 0xd6, 0x33, 0x0b, 0xac, 0x56, 0x2b, 0x21, - 0xce, 0x45, 0x42, 0xa2, 0x82, 0x0b, 0x7f, 0x03, 0x27, 0xfe, 0x88, 0x1e, 0x38, 0x54, 0x70, 0xe1, - 0x14, 0xa1, 0x84, 0x53, 0xff, 0x0a, 0xe4, 0x99, 0x59, 0xdb, 0xfb, 0x2b, 0xbb, 0x48, 0xa9, 0x72, - 0x59, 0xaf, 0x67, 0xbe, 0xf3, 0xbe, 0x9f, 0xf7, 0xe6, 0x97, 0xa1, 0xc2, 0x42, 0x12, 0x13, 0xfe, - 0x0d, 0x4d, 0x8e, 0x6d, 0x16, 0x12, 0xdb, 0x27, 0xdc, 0x7e, 0xd2, 0x22, 0x49, 0xdb, 0x6a, 0x26, - 0x94, 0x53, 0xc4, 0xbc, 0xdf, 0x62, 0x21, 0xb1, 0x7c, 0xc2, 0xf5, 0x95, 0x90, 0x86, 0x54, 0x74, - 0xdb, 0xe9, 0x3f, 0xa9, 0xd4, 0xd7, 0xea, 0x94, 0x35, 0x28, 0xab, 0xc9, 0x0e, 0xf9, 0xa2, 0xba, - 0xde, 0x0a, 0x29, 0x0d, 0x4f, 0x88, 0xed, 0x35, 0x23, 0xdb, 0x8b, 0x63, 0xca, 0x3d, 0x1e, 0xd1, - 0xb8, 0xd7, 0xbb, 0x23, 0xb5, 0xb6, 0xef, 0x31, 0x22, 0xbd, 0xed, 0xaf, 0xf7, 0x7c, 0xc2, 0xbd, - 0x3d, 0xbb, 0xe9, 0x85, 0x51, 0x2c, 0xc4, 0x4a, 0x6b, 0x8c, 0xc0, 0x6d, 0x7a, 0x89, 0xd7, 0xc8, - 0xac, 0x46, 0x08, 0x7c, 0xc2, 0x55, 0xaf, 0x39, 0xd0, 0xdb, 0xf0, 0x92, 0x63, 0xc2, 0xd5, 0x43, - 0x6a, 0xcc, 0x15, 0xc0, 0x2f, 0x52, 0x88, 0x03, 0x11, 0xd6, 0x25, 0x4f, 0x5a, 0x84, 0x71, 0xf3, - 0x01, 0xdc, 0xec, 0x6b, 0x65, 0x4d, 0x1a, 0x33, 0x82, 0xef, 0xc2, 0xbc, 0xb4, 0x2f, 0x6b, 0x1b, - 0xda, 0x9d, 0xa5, 0x7d, 0xdd, 0x1a, 0xae, 0x97, 0x25, 0xc7, 0x38, 0x73, 0xcf, 0x4f, 0x8d, 0x19, - 0x57, 0xe9, 0xcd, 0x2f, 0x61, 0x59, 0x04, 0x74, 0x08, 0x57, 0x1e, 0xb8, 0x0f, 0x0b, 0xf5, 0x84, - 0x78, 0x9c, 0x26, 0x22, 0xda, 0xa2, 0x53, 0xfe, 0xf3, 0xf7, 0xea, 0x8a, 0xaa, 0xe4, 0x87, 0x41, - 0x90, 0x10, 0xc6, 0x1e, 0xf2, 0x24, 0x8a, 0x43, 0xb7, 0x27, 0xc4, 0x35, 0x28, 0xb5, 0xa2, 0xa0, - 0x3c, 0x2b, 0xf4, 0x0b, 0x2f, 0x4f, 0x8d, 0xf4, 0xd5, 0x4d, 0x7f, 0xcc, 0xef, 0x34, 0x78, 0x3d, - 0xb7, 0x50, 0xc0, 0x36, 0x94, 0x7c, 0xc2, 0x15, 0xed, 0xea, 0x28, 0x5a, 0x87, 0x70, 0x85, 0x9a, - 0x2a, 0xf1, 0x7d, 0x98, 0x97, 0xe5, 0x11, 0x1e, 0x4b, 0xfb, 0xeb, 0x83, 0x63, 0x54, 0xf1, 0x3e, - 0x17, 0x8f, 0x5e, 0x92, 0xb2, 0xd1, 0x7c, 0x94, 0x13, 0xf4, 0x2a, 0x89, 0xf7, 0x01, 0xf2, 0x69, - 0x55, 0x20, 0x5b, 0x96, 0xca, 0x32, 0x5d, 0x03, 0x96, 0x5c, 0x7f, 0x6a, 0x0d, 0x58, 0x07, 0x5e, - 0x48, 0xd4, 0x58, 0xb7, 0x30, 0xd2, 0xfc, 0x41, 0x83, 0x1b, 0x85, 0xe0, 0x83, 0xf9, 0x95, 0xa6, - 0xcc, 0xef, 0x93, 0x3e, 0x1c, 0x99, 0xe3, 0xf6, 0x44, 0x1c, 0xe9, 0xd6, 0xc7, 0xd3, 0x85, 0xb5, - 0x0c, 0xc7, 0x69, 0x7f, 0x24, 0xe7, 0xe7, 0x92, 0x93, 0xc6, 0x72, 0xbe, 0x44, 0xc4, 0x94, 0x67, - 0x0b, 0xc1, 0xfc, 0x59, 0x03, 0x7d, 0x94, 0xff, 0x95, 0xd7, 0xe5, 0x3d, 0x78, 0xb3, 0xc0, 0x75, - 0xf8, 0xd9, 0xc7, 0xd9, 0x4a, 0x30, 0xe0, 0x5a, 0xc4, 0x89, 0xd8, 0x3b, 0xa5, 0x3b, 0x8b, 0xce, - 0xe2, 0xcb, 0x53, 0x43, 0x36, 0xb8, 0xf2, 0x61, 0xb6, 0x61, 0x75, 0x68, 0xa8, 0xca, 0x67, 0x0f, - 0xe6, 0x7c, 0xc2, 0xd9, 0x74, 0x09, 0x09, 0x29, 0xee, 0x02, 0xc6, 0x94, 0xd7, 0x1e, 0xd3, 0x56, - 0x1c, 0xd4, 0x7c, 0xc2, 0x6b, 0xad, 0x28, 0x60, 0xe5, 0xd9, 0xd4, 0xdb, 0x5d, 0x8e, 0x29, 0xbf, - 0x9f, 0x76, 0x38, 0x84, 0x1f, 0x46, 0x01, 0x4b, 0x37, 0x8f, 0xf4, 0x3e, 0x20, 0x71, 0x10, 0xc5, - 0xe1, 0x2b, 0x58, 0xc1, 0xb8, 0x0e, 0x20, 0xf7, 0x49, 0x2d, 0xdb, 0xc2, 0xee, 0xa2, 0x6c, 0x39, - 0x8c, 0x02, 0xf3, 0x99, 0x06, 0xe5, 0x61, 0x84, 0x2b, 0x9f, 0xcf, 0xa7, 0x1a, 0x18, 0x02, 0xeb, - 0x21, 0xe1, 0xfc, 0x84, 0xa4, 0x15, 0x63, 0x0f, 0x1e, 0x7f, 0x4a, 0xa2, 0xf0, 0x88, 0x5f, 0x76, - 0x85, 0x6e, 0xc1, 0x6b, 0xfe, 0x09, 0xad, 0x1f, 0xd7, 0x8e, 0x44, 0x78, 0x81, 0x5d, 0x72, 0x97, - 0x44, 0x9b, 0x74, 0x34, 0x7f, 0xd5, 0x60, 0x63, 0x3c, 0xce, 0x55, 0x57, 0x6b, 0xff, 0x8f, 0x05, - 0xb8, 0x26, 0xf0, 0x30, 0x81, 0x79, 0x79, 0x11, 0xe0, 0xd6, 0x28, 0x80, 0xe1, 0x3b, 0x47, 0xdf, - 0x9e, 0xa8, 0x93, 0x86, 0xe6, 0xea, 0xf7, 0x7f, 0xfd, 0xfb, 0xd3, 0xec, 0x0d, 0x5c, 0x1e, 0xb8, - 0x13, 0x31, 0x81, 0x92, 0x43, 0x38, 0xbe, 0x3d, 0x36, 0x50, 0x7e, 0xfb, 0xe8, 0x9b, 0x17, 0x8b, - 0x94, 0xd5, 0x86, 0xb0, 0xd2, 0xb1, 0x9c, 0x59, 0x75, 0xd4, 0x09, 0xd4, 0xb5, 0x3b, 0xad, 0x28, - 0xe8, 0xe2, 0x2f, 0x1a, 0x5c, 0xef, 0x3b, 0x83, 0xb0, 0x7a, 0x51, 0xe4, 0xa1, 0xb3, 0x52, 0xb7, - 0xa6, 0x95, 0x2b, 0xa4, 0x6d, 0x81, 0x74, 0x0b, 0x8d, 0x0c, 0x49, 0x11, 0x15, 0xd0, 0xc4, 0x01, - 0xf0, 0x15, 0xcc, 0xa5, 0x11, 0xf0, 0xc2, 0x4c, 0xb3, 0xea, 0xdf, 0x9e, 0xa0, 0x52, 0xee, 0x6f, - 0x08, 0xf7, 0x65, 0xbc, 0x5e, 0xfc, 0xdc, 0x60, 0xf8, 0x4c, 0x83, 0xa5, 0xc2, 0xbe, 0xc5, 0xdd, - 0xf1, 0x73, 0x39, 0x74, 0xc0, 0xe8, 0x77, 0xa7, 0x13, 0x2b, 0x82, 0x1d, 0x41, 0xb0, 0x89, 0x66, - 0x1f, 0x81, 0xdd, 0x94, 0x52, 0xbb, 0x93, 0x9f, 0x31, 0x5d, 0xfc, 0x4d, 0x83, 0x9b, 0x23, 0x36, - 0x0a, 0xde, 0x1b, 0xeb, 0x38, 0x7e, 0x97, 0xeb, 0xef, 0xfc, 0xbf, 0x41, 0x0a, 0xf7, 0xae, 0xc0, - 0xdd, 0xc2, 0xcd, 0x7e, 0x5c, 0x26, 0x87, 0xd8, 0x9d, 0xe2, 0x86, 0xef, 0xe2, 0x53, 0x0d, 0x20, - 0x3f, 0xfe, 0x71, 0x67, 0xc2, 0xda, 0x28, 0x5c, 0x2f, 0xfa, 0xee, 0x54, 0x5a, 0x45, 0x75, 0x5b, - 0x50, 0x19, 0xb8, 0xde, 0x47, 0x55, 0xf5, 0xdb, 0xd5, 0xf4, 0x96, 0xb0, 0x3b, 0xe2, 0x42, 0xea, - 0x3a, 0x1f, 0x3c, 0x3f, 0xab, 0x68, 0x2f, 0xce, 0x2a, 0xda, 0x3f, 0x67, 0x15, 0xed, 0xc7, 0xf3, - 0xca, 0xcc, 0x8b, 0xf3, 0xca, 0xcc, 0xdf, 0xe7, 0x95, 0x99, 0x47, 0x5b, 0x61, 0xc4, 0x8f, 0x5a, - 0xbe, 0x55, 0xa7, 0x8d, 0x34, 0x44, 0xb5, 0xf8, 0x99, 0xf9, 0xad, 0x08, 0xc8, 0xdb, 0x4d, 0xc2, - 0xfc, 0x79, 0xf1, 0x95, 0x79, 0xef, 0xbf, 0x00, 0x00, 0x00, 0xff, 0xff, 0xe8, 0x7e, 0x9b, 0x1f, - 0x79, 0x0b, 0x00, 0x00, + proto.RegisterType((*QueryParamsRequest)(nil), "sge.legacy.bet.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.legacy.bet.v1beta.QueryParamsResponse") + proto.RegisterType((*QueryBetRequest)(nil), "sge.legacy.bet.v1beta.QueryBetRequest") + proto.RegisterType((*QueryBetResponse)(nil), "sge.legacy.bet.v1beta.QueryBetResponse") + proto.RegisterType((*QueryBetsRequest)(nil), "sge.legacy.bet.v1beta.QueryBetsRequest") + proto.RegisterType((*QueryBetsResponse)(nil), "sge.legacy.bet.v1beta.QueryBetsResponse") + proto.RegisterType((*QueryBetsByCreatorRequest)(nil), "sge.legacy.bet.v1beta.QueryBetsByCreatorRequest") + proto.RegisterType((*QueryBetsByCreatorResponse)(nil), "sge.legacy.bet.v1beta.QueryBetsByCreatorResponse") + proto.RegisterType((*QueryBetsByUIDsRequest)(nil), "sge.legacy.bet.v1beta.QueryBetsByUIDsRequest") + proto.RegisterType((*QueryBetsByUIDsResponse)(nil), "sge.legacy.bet.v1beta.QueryBetsByUIDsResponse") + proto.RegisterType((*QueryPendingBetsRequest)(nil), "sge.legacy.bet.v1beta.QueryPendingBetsRequest") + proto.RegisterType((*QueryPendingBetsResponse)(nil), "sge.legacy.bet.v1beta.QueryPendingBetsResponse") + proto.RegisterType((*QuerySettledBetsOfHeightRequest)(nil), "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightRequest") + proto.RegisterType((*QuerySettledBetsOfHeightResponse)(nil), "sge.legacy.bet.v1beta.QuerySettledBetsOfHeightResponse") +} + +func init() { proto.RegisterFile("sge/legacy/bet/v1beta/query.proto", fileDescriptor_6d13e7d3deb3d881) } + +var fileDescriptor_6d13e7d3deb3d881 = []byte{ + // 935 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x96, 0x41, 0x6f, 0xdc, 0x44, + 0x14, 0xc7, 0x33, 0xd9, 0x34, 0x51, 0x5e, 0xa8, 0x42, 0xa7, 0x29, 0xdd, 0x58, 0x64, 0x9d, 0x58, + 0x6d, 0x12, 0x02, 0xeb, 0x21, 0x0b, 0x02, 0x21, 0x24, 0x24, 0x0c, 0x6a, 0xe1, 0x80, 0x08, 0xae, + 0x72, 0xe9, 0x65, 0xb1, 0xd7, 0x53, 0xc7, 0x4a, 0xe2, 0x71, 0x3d, 0xb3, 0x90, 0xd5, 0xb2, 0x12, + 0xe2, 0xc0, 0x89, 0x43, 0x05, 0x07, 0x04, 0x12, 0xe2, 0x4b, 0xf4, 0x43, 0xf4, 0x58, 0xc1, 0x85, + 0x53, 0x84, 0x12, 0x4e, 0xfd, 0x00, 0x9c, 0x91, 0x67, 0x66, 0x6d, 0x2f, 0xbb, 0xc9, 0x6e, 0xa5, + 0x54, 0xca, 0xa5, 0xcd, 0x8c, 0xff, 0xef, 0xbd, 0xdf, 0x7b, 0xf3, 0x66, 0xde, 0xc2, 0x1a, 0x0f, + 0x29, 0x39, 0xa0, 0xa1, 0xd7, 0xea, 0x10, 0x9f, 0x0a, 0xf2, 0xd5, 0xb6, 0x4f, 0x85, 0x47, 0x1e, + 0xb6, 0x69, 0xda, 0xb1, 0x93, 0x94, 0x09, 0x86, 0x6f, 0xf0, 0x90, 0xda, 0x4a, 0x62, 0xfb, 0x54, + 0xd8, 0x4a, 0x62, 0x6c, 0xb5, 0x18, 0x3f, 0x64, 0x9c, 0xf8, 0x1e, 0xa7, 0x4a, 0xaf, 0x8d, 0xb7, + 0x49, 0xe2, 0x85, 0x51, 0xec, 0x89, 0x88, 0xc5, 0xca, 0x85, 0xb1, 0xac, 0xb4, 0x4d, 0xb9, 0x22, + 0x6a, 0xa1, 0x3f, 0x2d, 0x85, 0x2c, 0x64, 0x6a, 0x3f, 0xfb, 0x4b, 0xef, 0xbe, 0x1a, 0x32, 0x16, + 0x1e, 0x50, 0xe2, 0x25, 0x11, 0xf1, 0xe2, 0x98, 0x09, 0xe9, 0xad, 0x6f, 0x63, 0x8e, 0x86, 0xce, + 0xe0, 0x94, 0xc0, 0x1a, 0x2d, 0x48, 0xbc, 0xd4, 0x3b, 0xec, 0x3b, 0xb9, 0x5d, 0xd2, 0x1c, 0x7a, + 0xe9, 0x7e, 0x21, 0x53, 0x2b, 0x25, 0xb3, 0x96, 0x00, 0x7f, 0x91, 0x25, 0xb7, 0x23, 0x6d, 0x5d, + 0xfa, 0xb0, 0x4d, 0xb9, 0xb0, 0x5c, 0xb8, 0x3e, 0xb0, 0xcb, 0x13, 0x16, 0x73, 0x8a, 0xdf, 0x87, + 0x59, 0x15, 0xa3, 0x8a, 0x56, 0xd1, 0xe6, 0x42, 0x63, 0xc5, 0x1e, 0x59, 0x3b, 0x5b, 0x99, 0x39, + 0x33, 0x4f, 0x8e, 0xcd, 0x29, 0x57, 0x9b, 0x58, 0x5f, 0xc2, 0xa2, 0xf4, 0xe9, 0x50, 0xa1, 0xc3, + 0xe0, 0x06, 0xcc, 0xb5, 0x52, 0xea, 0x09, 0x96, 0x4a, 0x87, 0xf3, 0x4e, 0xf5, 0x8f, 0xc7, 0xf5, + 0x25, 0x5d, 0xbf, 0x0f, 0x83, 0x20, 0xa5, 0x9c, 0xdf, 0x13, 0x69, 0x14, 0x87, 0x6e, 0x5f, 0x88, + 0x97, 0xa1, 0xd2, 0x8e, 0x82, 0xea, 0xb4, 0xd4, 0xcf, 0x3d, 0x3b, 0x36, 0xb3, 0xa5, 0x9b, 0xfd, + 0x63, 0x7d, 0x8f, 0xe0, 0xe5, 0x22, 0x84, 0x66, 0x6e, 0x40, 0xc5, 0xa7, 0x42, 0x03, 0x1b, 0x67, + 0x00, 0x3b, 0x54, 0x68, 0xda, 0x4c, 0x8c, 0x3f, 0x80, 0x59, 0x55, 0x24, 0x19, 0x66, 0xa1, 0xb1, + 0x5a, 0x36, 0xd3, 0xe5, 0xd3, 0x96, 0x9f, 0xc9, 0x55, 0x3f, 0x55, 0xf5, 0xcd, 0xba, 0x5f, 0x70, + 0xf4, 0x4b, 0x8a, 0xef, 0x00, 0x14, 0x7d, 0xa3, 0x71, 0xd6, 0x6d, 0x9d, 0x6b, 0xd6, 0x64, 0xb6, + 0x6a, 0x4a, 0xdd, 0x64, 0xf6, 0x8e, 0x17, 0x52, 0x6d, 0xeb, 0x96, 0x2c, 0xad, 0x47, 0x08, 0xae, + 0x95, 0x9c, 0xff, 0x3f, 0xcb, 0xca, 0xe4, 0x59, 0xde, 0x1d, 0x20, 0x52, 0x99, 0x6e, 0x8c, 0x25, + 0x52, 0x01, 0x07, 0x90, 0x7a, 0xb0, 0x9c, 0x13, 0x39, 0x9d, 0x8f, 0xd4, 0x41, 0x5d, 0x70, 0xde, + 0xb8, 0x5a, 0xf4, 0x8a, 0x3c, 0xfb, 0xbc, 0x23, 0xac, 0x5f, 0x10, 0x18, 0xa3, 0xe2, 0x5f, 0x86, + 0xd2, 0xbc, 0x07, 0xaf, 0x94, 0xd0, 0x76, 0x3f, 0xfd, 0x38, 0xef, 0x07, 0x13, 0xae, 0x44, 0x82, + 0xca, 0xab, 0x54, 0xd9, 0x9c, 0x77, 0xe6, 0x9f, 0x1d, 0x9b, 0x6a, 0xc3, 0x55, 0xff, 0x59, 0xdf, + 0xc0, 0xcd, 0x21, 0x53, 0x9d, 0xd2, 0xdb, 0x30, 0xe3, 0x53, 0xc1, 0x27, 0xce, 0x49, 0xaa, 0xf1, + 0xeb, 0x80, 0x63, 0x26, 0x9a, 0x0f, 0x58, 0x3b, 0x0e, 0x9a, 0x3e, 0x15, 0xcd, 0x76, 0x14, 0xf0, + 0xea, 0x74, 0x16, 0xde, 0x5d, 0x8c, 0x99, 0xb8, 0x93, 0x7d, 0x70, 0xa8, 0xd8, 0x8d, 0x02, 0x6e, + 0x7d, 0x8b, 0x74, 0xf8, 0x1d, 0x1a, 0x07, 0x51, 0x1c, 0xbe, 0x80, 0x56, 0xc6, 0x2b, 0x00, 0xea, + 0xc2, 0x34, 0xf3, 0x1b, 0xed, 0xce, 0xab, 0x9d, 0xdd, 0x28, 0xb0, 0x7e, 0x46, 0x50, 0x1d, 0x46, + 0xb8, 0x0c, 0xa7, 0xfa, 0x03, 0x02, 0x53, 0x92, 0xdd, 0xa3, 0x42, 0x1c, 0xd0, 0xac, 0x68, 0xfc, + 0xf3, 0x07, 0x9f, 0xd0, 0x28, 0xdc, 0x13, 0x17, 0x5d, 0xa4, 0x35, 0x78, 0xc9, 0x3f, 0x60, 0xad, + 0xfd, 0xe6, 0x9e, 0x74, 0x2f, 0xb1, 0x2b, 0xee, 0x82, 0xdc, 0x53, 0x11, 0xad, 0xdf, 0x11, 0xac, + 0x9e, 0x8d, 0x73, 0x09, 0x0a, 0xd6, 0xf8, 0x77, 0x0e, 0xae, 0x48, 0x42, 0x7c, 0x04, 0xb3, 0x6a, + 0x3a, 0xe0, 0xd7, 0xce, 0x60, 0x18, 0x1e, 0x47, 0xc6, 0xd6, 0x24, 0x52, 0x15, 0xd6, 0xba, 0xf9, + 0xdd, 0x9f, 0xff, 0xfc, 0x34, 0x7d, 0x0d, 0x2f, 0x92, 0x6c, 0x00, 0x66, 0xd3, 0x51, 0xcd, 0x1f, + 0x7c, 0x04, 0x15, 0x87, 0x0a, 0xbc, 0x7e, 0x9e, 0xaf, 0x62, 0x36, 0x19, 0x1b, 0x63, 0x75, 0x3a, + 0xe0, 0xaa, 0x0c, 0x68, 0xe0, 0x6a, 0x1e, 0xb0, 0xab, 0x5f, 0xa6, 0x1e, 0xe9, 0xb6, 0xa3, 0xa0, + 0x87, 0x7f, 0x43, 0x70, 0x75, 0xe0, 0x6d, 0xc2, 0x6f, 0x8e, 0x71, 0x3e, 0xf4, 0x8c, 0x1a, 0xdb, + 0xcf, 0x61, 0xa1, 0xc1, 0x36, 0x24, 0xd8, 0x1a, 0x36, 0x73, 0x30, 0xcd, 0x55, 0x02, 0x94, 0x0f, + 0x43, 0x02, 0x33, 0x99, 0x07, 0x3c, 0x2e, 0xe5, 0xfc, 0x3c, 0x36, 0xc7, 0x0b, 0x35, 0xc3, 0x0d, + 0xc9, 0xb0, 0x88, 0xaf, 0xe6, 0x0c, 0x32, 0xe2, 0xaf, 0x08, 0x16, 0x4a, 0xb7, 0x1a, 0xdb, 0xe7, + 0x1e, 0xf0, 0xd0, 0x0b, 0x64, 0x90, 0x89, 0xf5, 0x9a, 0x63, 0x4b, 0x72, 0xdc, 0xc2, 0xd6, 0x00, + 0x07, 0x49, 0x94, 0x94, 0x74, 0x8b, 0x77, 0xa8, 0x87, 0x1f, 0x23, 0xb8, 0x3e, 0xe2, 0x26, 0xe1, + 0x77, 0xce, 0x0b, 0x7a, 0xf6, 0x4b, 0x60, 0xbc, 0xfb, 0xdc, 0x76, 0x1a, 0xfa, 0x0d, 0x09, 0xbd, + 0x8e, 0x6f, 0x0d, 0x42, 0x73, 0x65, 0x42, 0xba, 0xe5, 0x77, 0xa1, 0x87, 0x7f, 0x44, 0x00, 0xc5, + 0xac, 0xc0, 0xf5, 0xf1, 0x0d, 0x53, 0x1a, 0x47, 0x86, 0x3d, 0xa9, 0x5c, 0xb3, 0xdd, 0x96, 0x6c, + 0x26, 0x5e, 0x19, 0x60, 0xab, 0xfb, 0x9d, 0x7a, 0x36, 0x55, 0x48, 0x57, 0xce, 0xb0, 0x9e, 0x73, + 0xf7, 0xc9, 0x49, 0x0d, 0x3d, 0x3d, 0xa9, 0xa1, 0xbf, 0x4f, 0x6a, 0xe8, 0xd1, 0x69, 0x6d, 0xea, + 0xe9, 0x69, 0x6d, 0xea, 0xaf, 0xd3, 0xda, 0xd4, 0xfd, 0x7a, 0x18, 0x89, 0xbd, 0xb6, 0x6f, 0xb7, + 0xd8, 0x61, 0xe6, 0xa2, 0x1e, 0x53, 0xf1, 0x35, 0x4b, 0xf7, 0xa5, 0xbb, 0xa3, 0xf2, 0x8f, 0x5b, + 0xd1, 0x49, 0x28, 0xf7, 0x67, 0xe5, 0xcf, 0xd5, 0xb7, 0xfe, 0x0b, 0x00, 0x00, 0xff, 0xff, 0xaf, + 0x1c, 0xac, 0xa9, 0xd1, 0x0b, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -870,7 +871,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -879,7 +880,7 @@ func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts . func (c *queryClient) Bet(ctx context.Context, in *QueryBetRequest, opts ...grpc.CallOption) (*QueryBetResponse, error) { out := new(QueryBetResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Query/Bet", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Query/Bet", in, out, opts...) if err != nil { return nil, err } @@ -888,7 +889,7 @@ func (c *queryClient) Bet(ctx context.Context, in *QueryBetRequest, opts ...grpc func (c *queryClient) BetsByCreator(ctx context.Context, in *QueryBetsByCreatorRequest, opts ...grpc.CallOption) (*QueryBetsByCreatorResponse, error) { out := new(QueryBetsByCreatorResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Query/BetsByCreator", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Query/BetsByCreator", in, out, opts...) if err != nil { return nil, err } @@ -897,7 +898,7 @@ func (c *queryClient) BetsByCreator(ctx context.Context, in *QueryBetsByCreatorR func (c *queryClient) Bets(ctx context.Context, in *QueryBetsRequest, opts ...grpc.CallOption) (*QueryBetsResponse, error) { out := new(QueryBetsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Query/Bets", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Query/Bets", in, out, opts...) if err != nil { return nil, err } @@ -906,7 +907,7 @@ func (c *queryClient) Bets(ctx context.Context, in *QueryBetsRequest, opts ...gr func (c *queryClient) PendingBets(ctx context.Context, in *QueryPendingBetsRequest, opts ...grpc.CallOption) (*QueryPendingBetsResponse, error) { out := new(QueryPendingBetsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Query/PendingBets", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Query/PendingBets", in, out, opts...) if err != nil { return nil, err } @@ -915,7 +916,7 @@ func (c *queryClient) PendingBets(ctx context.Context, in *QueryPendingBetsReque func (c *queryClient) SettledBetsOfHeight(ctx context.Context, in *QuerySettledBetsOfHeightRequest, opts ...grpc.CallOption) (*QuerySettledBetsOfHeightResponse, error) { out := new(QuerySettledBetsOfHeightResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Query/SettledBetsOfHeight", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Query/SettledBetsOfHeight", in, out, opts...) if err != nil { return nil, err } @@ -924,7 +925,7 @@ func (c *queryClient) SettledBetsOfHeight(ctx context.Context, in *QuerySettledB func (c *queryClient) BetsByUIDs(ctx context.Context, in *QueryBetsByUIDsRequest, opts ...grpc.CallOption) (*QueryBetsByUIDsResponse, error) { out := new(QueryBetsByUIDsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Query/BetsByUIDs", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Query/BetsByUIDs", in, out, opts...) if err != nil { return nil, err } @@ -989,7 +990,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Query/Params", + FullMethod: "/sge.legacy.bet.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -1007,7 +1008,7 @@ func _Query_Bet_Handler(srv interface{}, ctx context.Context, dec func(interface } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Query/Bet", + FullMethod: "/sge.legacy.bet.v1beta.Query/Bet", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Bet(ctx, req.(*QueryBetRequest)) @@ -1025,7 +1026,7 @@ func _Query_BetsByCreator_Handler(srv interface{}, ctx context.Context, dec func } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Query/BetsByCreator", + FullMethod: "/sge.legacy.bet.v1beta.Query/BetsByCreator", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).BetsByCreator(ctx, req.(*QueryBetsByCreatorRequest)) @@ -1043,7 +1044,7 @@ func _Query_Bets_Handler(srv interface{}, ctx context.Context, dec func(interfac } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Query/Bets", + FullMethod: "/sge.legacy.bet.v1beta.Query/Bets", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Bets(ctx, req.(*QueryBetsRequest)) @@ -1061,7 +1062,7 @@ func _Query_PendingBets_Handler(srv interface{}, ctx context.Context, dec func(i } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Query/PendingBets", + FullMethod: "/sge.legacy.bet.v1beta.Query/PendingBets", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PendingBets(ctx, req.(*QueryPendingBetsRequest)) @@ -1079,7 +1080,7 @@ func _Query_SettledBetsOfHeight_Handler(srv interface{}, ctx context.Context, de } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Query/SettledBetsOfHeight", + FullMethod: "/sge.legacy.bet.v1beta.Query/SettledBetsOfHeight", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).SettledBetsOfHeight(ctx, req.(*QuerySettledBetsOfHeightRequest)) @@ -1097,7 +1098,7 @@ func _Query_BetsByUIDs_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Query/BetsByUIDs", + FullMethod: "/sge.legacy.bet.v1beta.Query/BetsByUIDs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).BetsByUIDs(ctx, req.(*QueryBetsByUIDsRequest)) @@ -1105,8 +1106,9 @@ func _Query_BetsByUIDs_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.bet.Query", + ServiceName: "sge.legacy.bet.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -1139,7 +1141,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/bet/query.proto", + Metadata: "sge/legacy/bet/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/query.pb.gw.go b/x/legacy/bet/types/query.pb.gw.go similarity index 99% rename from x/bet/types/query.pb.gw.go rename to x/legacy/bet/types/query.pb.gw.go index 370e2a1c..397b1ef4 100644 --- a/x/bet/types/query.pb.gw.go +++ b/x/legacy/bet/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/bet/query.proto +// source: sge/legacy/bet/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/bet/types/stats.pb.go b/x/legacy/bet/types/stats.pb.go similarity index 82% rename from x/bet/types/stats.pb.go rename to x/legacy/bet/types/stats.pb.go index e34d45ca..b974b750 100644 --- a/x/bet/types/stats.pb.go +++ b/x/legacy/bet/types/stats.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/stats.proto +// source: sge/legacy/bet/v1beta/stats.proto package types @@ -32,7 +32,7 @@ func (m *BetStats) Reset() { *m = BetStats{} } func (m *BetStats) String() string { return proto.CompactTextString(m) } func (*BetStats) ProtoMessage() {} func (*BetStats) Descriptor() ([]byte, []int) { - return fileDescriptor_d4b91f5cccbf55c0, []int{0} + return fileDescriptor_95e3802f814d1f07, []int{0} } func (m *BetStats) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -69,23 +69,24 @@ func (m *BetStats) GetCount() uint64 { } func init() { - proto.RegisterType((*BetStats)(nil), "sgenetwork.sge.bet.BetStats") + proto.RegisterType((*BetStats)(nil), "sge.legacy.bet.v1beta.BetStats") } -func init() { proto.RegisterFile("sgenetwork/sge/bet/stats.proto", fileDescriptor_d4b91f5cccbf55c0) } +func init() { proto.RegisterFile("sge/legacy/bet/v1beta/stats.proto", fileDescriptor_95e3802f814d1f07) } -var fileDescriptor_d4b91f5cccbf55c0 = []byte{ - // 154 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2b, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x4f, 0x4a, 0x2d, 0xd1, 0x2f, - 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x42, 0xc8, 0xeb, 0x15, - 0xa7, 0xa7, 0xea, 0x25, 0xa5, 0x96, 0x28, 0x29, 0x70, 0x71, 0x38, 0xa5, 0x96, 0x04, 0x83, 0x54, - 0x09, 0x89, 0x70, 0xb1, 0x26, 0xe7, 0x97, 0xe6, 0x95, 0x48, 0x30, 0x2a, 0x30, 0x6a, 0xb0, 0x04, - 0x41, 0x38, 0x4e, 0x0e, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, - 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x96, - 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0x0b, 0xb2, 0x4f, 0x17, 0xd9, 0xee, 0x0a, - 0xb0, 0xed, 0x25, 0x95, 0x05, 0xa9, 0xc5, 0x49, 0x6c, 0x60, 0xeb, 0x8d, 0x01, 0x01, 0x00, 0x00, - 0xff, 0xff, 0x99, 0x1c, 0x2c, 0x12, 0xa0, 0x00, 0x00, 0x00, +var fileDescriptor_95e3802f814d1f07 = []byte{ + // 170 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0x4f, 0x4a, 0x2d, 0xd1, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, + 0x49, 0xd4, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x2d, + 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd1, 0x4b, 0x4a, 0x2d, 0xd1, 0x83, 0x28, 0x51, 0x52, 0xe0, 0xe2, + 0x70, 0x4a, 0x2d, 0x09, 0x06, 0x29, 0x14, 0x12, 0xe1, 0x62, 0x4d, 0xce, 0x2f, 0xcd, 0x2b, 0x91, + 0x60, 0x54, 0x60, 0xd4, 0x60, 0x09, 0x82, 0x70, 0x9c, 0xdc, 0x4f, 0x3c, 0x92, 0x63, 0xbc, 0xf0, + 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, + 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x37, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, + 0xbf, 0x38, 0x3d, 0x55, 0x37, 0x2f, 0xb5, 0xa4, 0x3c, 0xbf, 0x28, 0x1b, 0xc4, 0xd6, 0xaf, 0x40, + 0x76, 0x4e, 0x49, 0x65, 0x41, 0x6a, 0x71, 0x12, 0x1b, 0xd8, 0x21, 0xc6, 0x80, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xb0, 0x0d, 0x5d, 0x90, 0xad, 0x00, 0x00, 0x00, } func (m *BetStats) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/ticket.go b/x/legacy/bet/types/ticket.go similarity index 100% rename from x/bet/types/ticket.go rename to x/legacy/bet/types/ticket.go diff --git a/x/bet/types/ticket.pb.go b/x/legacy/bet/types/ticket.pb.go similarity index 81% rename from x/bet/types/ticket.pb.go rename to x/legacy/bet/types/ticket.pb.go index 84f73cd1..319a465d 100644 --- a/x/bet/types/ticket.pb.go +++ b/x/legacy/bet/types/ticket.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/ticket.proto +// source: sge/legacy/bet/v1beta/ticket.proto package types @@ -7,7 +7,7 @@ import ( fmt "fmt" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" - types "github.com/sge-network/sge/types" + legacy "github.com/sge-network/sge/types/legacy" io "io" math "math" math_bits "math/bits" @@ -29,7 +29,7 @@ type WagerTicketPayload struct { // selected_odds is the user-selected odds to place bet. SelectedOdds *BetOdds `protobuf:"bytes,1,opt,name=selected_odds,json=selectedOdds,proto3" json:"selected_odds,omitempty"` // kyc_data contains the details of user kyc. - KycData types.KycDataPayload `protobuf:"bytes,2,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data"` + KycData legacy.KycDataPayload `protobuf:"bytes,2,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data"` // all odds for the selected market. AllOdds []*BetOddsCompact `protobuf:"bytes,4,rep,name=all_odds,json=allOdds,proto3" json:"all_odds,omitempty"` // meta is metadata for bet placement @@ -42,7 +42,7 @@ func (m *WagerTicketPayload) Reset() { *m = WagerTicketPayload{} } func (m *WagerTicketPayload) String() string { return proto.CompactTextString(m) } func (*WagerTicketPayload) ProtoMessage() {} func (*WagerTicketPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_5c3f88574fd82596, []int{0} + return fileDescriptor_e2eb910bc5b6fae8, []int{0} } func (m *WagerTicketPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -78,11 +78,11 @@ func (m *WagerTicketPayload) GetSelectedOdds() *BetOdds { return nil } -func (m *WagerTicketPayload) GetKycData() types.KycDataPayload { +func (m *WagerTicketPayload) GetKycData() legacy.KycDataPayload { if m != nil { return m.KycData } - return types.KycDataPayload{} + return legacy.KycDataPayload{} } func (m *WagerTicketPayload) GetAllOdds() []*BetOddsCompact { @@ -107,35 +107,38 @@ func (m *WagerTicketPayload) GetContext() string { } func init() { - proto.RegisterType((*WagerTicketPayload)(nil), "sgenetwork.sge.bet.WagerTicketPayload") + proto.RegisterType((*WagerTicketPayload)(nil), "sge.legacy.bet.v1beta.WagerTicketPayload") } -func init() { proto.RegisterFile("sgenetwork/sge/bet/ticket.proto", fileDescriptor_5c3f88574fd82596) } +func init() { + proto.RegisterFile("sge/legacy/bet/v1beta/ticket.proto", fileDescriptor_e2eb910bc5b6fae8) +} -var fileDescriptor_5c3f88574fd82596 = []byte{ - // 343 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0x41, 0x4b, 0x02, 0x41, - 0x18, 0x86, 0x77, 0xcd, 0xd4, 0xd6, 0xba, 0x0c, 0x1d, 0x16, 0xb3, 0xd5, 0x0c, 0xc2, 0x4b, 0xb3, - 0x60, 0xd0, 0x2d, 0x10, 0xf3, 0x16, 0x51, 0x2c, 0x41, 0xd0, 0x45, 0x66, 0x67, 0x3e, 0x26, 0xd9, - 0xd5, 0x59, 0x9c, 0x2f, 0x72, 0xff, 0x45, 0x7f, 0xa4, 0xff, 0xe1, 0xd1, 0x63, 0xa7, 0x08, 0xfd, - 0x23, 0xb1, 0xb3, 0x4a, 0x61, 0xd2, 0x6d, 0xbf, 0xfd, 0xde, 0x77, 0xde, 0x67, 0x5e, 0xc6, 0x69, - 0x68, 0x09, 0x63, 0xc0, 0x57, 0x35, 0x89, 0x7c, 0x2d, 0xc1, 0x0f, 0x01, 0x7d, 0x1c, 0xf2, 0x08, - 0x90, 0x26, 0x13, 0x85, 0x8a, 0x90, 0x1f, 0x01, 0xd5, 0x12, 0x68, 0x08, 0x58, 0x3b, 0x94, 0x4a, - 0x2a, 0xb3, 0xf6, 0xb3, 0xaf, 0x5c, 0x59, 0x3b, 0xde, 0x38, 0x0a, 0xd3, 0x04, 0xfc, 0x28, 0xe5, - 0xab, 0x75, 0x7d, 0x4b, 0x52, 0xb8, 0x8e, 0xa9, 0x9d, 0x6c, 0xdf, 0x0e, 0x94, 0x10, 0x3a, 0x97, - 0xb4, 0xde, 0x0b, 0x0e, 0x79, 0x64, 0x12, 0x26, 0x0f, 0x86, 0xef, 0x9e, 0xa5, 0xb1, 0x62, 0x82, - 0x74, 0x9d, 0x03, 0x0d, 0x31, 0x70, 0x04, 0x61, 0xd4, 0xae, 0xdd, 0xb4, 0xdb, 0xd5, 0xce, 0x11, - 0xfd, 0x0b, 0x4e, 0x7b, 0x80, 0x77, 0x42, 0xe8, 0x60, 0x7f, 0xed, 0xc8, 0x26, 0xd2, 0x77, 0x2a, - 0x51, 0xca, 0x07, 0x82, 0x21, 0x73, 0x0b, 0xc6, 0x7c, 0xba, 0x69, 0xce, 0xee, 0x42, 0x6f, 0x52, - 0xde, 0x67, 0xc8, 0x56, 0xc1, 0xbd, 0xe2, 0xec, 0xb3, 0x61, 0x05, 0xe5, 0x28, 0xff, 0x4b, 0xae, - 0x9c, 0x0a, 0x8b, 0xe3, 0x1c, 0xa1, 0xd8, 0xdc, 0x69, 0x57, 0x3b, 0xad, 0x7f, 0x10, 0xae, 0xd5, - 0x28, 0x61, 0x1c, 0x83, 0x32, 0x8b, 0x63, 0x03, 0x71, 0xe9, 0x14, 0x47, 0x80, 0xcc, 0xdd, 0x35, - 0x00, 0xf5, 0x6d, 0xd6, 0x5b, 0x40, 0x96, 0x45, 0xad, 0x92, 0x8d, 0x9e, 0xb8, 0x4e, 0x99, 0xab, - 0x31, 0xc2, 0x14, 0xdd, 0x52, 0xd3, 0x6e, 0xef, 0x05, 0xeb, 0xb1, 0xd7, 0x9d, 0x2d, 0x3c, 0x7b, - 0xbe, 0xf0, 0xec, 0xaf, 0x85, 0x67, 0xbf, 0x2d, 0x3d, 0x6b, 0xbe, 0xf4, 0xac, 0x8f, 0xa5, 0x67, - 0x3d, 0x9d, 0xc9, 0x21, 0x3e, 0xbf, 0x84, 0x94, 0xab, 0x51, 0x56, 0xf6, 0xf9, 0xef, 0xe2, 0xa7, - 0xf9, 0x13, 0x48, 0x13, 0xd0, 0x61, 0xc9, 0x14, 0x7f, 0xf1, 0x1d, 0x00, 0x00, 0xff, 0xff, 0x6b, - 0x10, 0xb1, 0xd7, 0x25, 0x02, 0x00, 0x00, +var fileDescriptor_e2eb910bc5b6fae8 = []byte{ + // 354 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x91, 0xcf, 0x4e, 0xfa, 0x40, + 0x10, 0xc7, 0x5b, 0x7e, 0xfc, 0x00, 0x8b, 0x5e, 0x1a, 0x4d, 0x1a, 0x0e, 0xa5, 0x21, 0x6a, 0xb8, + 0xd0, 0x46, 0x3c, 0x79, 0x33, 0x60, 0xc2, 0xc1, 0x18, 0x4d, 0x63, 0x62, 0xe2, 0x85, 0x4c, 0xb7, + 0x93, 0x95, 0x74, 0x61, 0x09, 0x3b, 0x2a, 0x7d, 0x0b, 0x5f, 0xc7, 0x37, 0xe0, 0xc8, 0xd1, 0x93, + 0x31, 0xf0, 0x22, 0xa6, 0x5b, 0x9a, 0x70, 0x00, 0x6f, 0x33, 0xcd, 0xe7, 0xfb, 0xa7, 0x3b, 0x56, + 0x4b, 0x71, 0x0c, 0x04, 0x72, 0x60, 0x69, 0x10, 0x21, 0x05, 0x6f, 0x17, 0x11, 0x12, 0x04, 0x34, + 0x62, 0x09, 0x92, 0x3f, 0x9d, 0x49, 0x92, 0xf6, 0x89, 0xe2, 0xe8, 0xe7, 0x8c, 0x1f, 0x21, 0xf9, + 0x39, 0xd3, 0x38, 0xe6, 0x92, 0x4b, 0x4d, 0x04, 0xd9, 0x94, 0xc3, 0x8d, 0xe6, 0x6e, 0xc3, 0xa8, + 0x70, 0x6b, 0x9c, 0xee, 0x05, 0x86, 0x32, 0x8e, 0xd5, 0x86, 0xf2, 0xb6, 0x28, 0x4a, 0xa7, 0x58, + 0x60, 0x49, 0xca, 0x72, 0xa2, 0xf5, 0x59, 0xb2, 0xec, 0x27, 0xe0, 0x38, 0x7b, 0xd4, 0x5d, 0x1f, + 0x20, 0x15, 0x12, 0x62, 0xbb, 0x6f, 0x1d, 0x29, 0x14, 0xc8, 0x08, 0x63, 0xed, 0xe7, 0x98, 0x9e, + 0xd9, 0xae, 0x77, 0x5d, 0x7f, 0xe7, 0x4f, 0xf8, 0x3d, 0xa4, 0xfb, 0x38, 0x56, 0xe1, 0x61, 0x21, + 0xca, 0x36, 0x7b, 0x60, 0xd5, 0x92, 0x94, 0x0d, 0x63, 0x20, 0x70, 0x4a, 0x5a, 0x7f, 0xbe, 0xad, + 0xcf, 0x0a, 0x15, 0x06, 0xb7, 0x29, 0xbb, 0x01, 0x82, 0x4d, 0x7c, 0xaf, 0xbc, 0xf8, 0x6e, 0x1a, + 0x61, 0x35, 0xc9, 0xbf, 0xda, 0xd7, 0x56, 0x0d, 0x84, 0xc8, 0x8b, 0x94, 0xbd, 0x7f, 0xed, 0x7a, + 0xf7, 0xec, 0xef, 0x22, 0x7d, 0x39, 0x9e, 0x02, 0xa3, 0xb0, 0x0a, 0x42, 0xe8, 0x2a, 0x57, 0x56, + 0x79, 0x8c, 0x04, 0xce, 0x7f, 0x5d, 0xa3, 0xb9, 0x47, 0x7d, 0x87, 0x04, 0x59, 0xe0, 0x26, 0x5f, + 0x4b, 0x6c, 0xc7, 0xaa, 0x32, 0x39, 0x21, 0x9c, 0x93, 0x53, 0xf1, 0xcc, 0xf6, 0x41, 0x58, 0xac, + 0xbd, 0xc1, 0x62, 0xe5, 0x9a, 0xcb, 0x95, 0x6b, 0xfe, 0xac, 0x5c, 0xf3, 0x63, 0xed, 0x1a, 0xcb, + 0xb5, 0x6b, 0x7c, 0xad, 0x5d, 0xe3, 0xb9, 0xc3, 0x47, 0xf4, 0xf2, 0x1a, 0xf9, 0x4c, 0x8e, 0x03, + 0xc5, 0xb1, 0x33, 0x41, 0x7a, 0x97, 0xb3, 0x24, 0x9b, 0x83, 0xf9, 0xf6, 0xd9, 0xb2, 0x37, 0x50, + 0x51, 0x45, 0xdf, 0xe2, 0xf2, 0x37, 0x00, 0x00, 0xff, 0xff, 0xa3, 0x61, 0x3b, 0x85, 0x47, 0x02, + 0x00, 0x00, } func (m *WagerTicketPayload) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/ticket_test.go b/x/legacy/bet/types/ticket_test.go similarity index 96% rename from x/bet/types/ticket_test.go rename to x/legacy/bet/types/ticket_test.go index 2c10c22f..33b9f2b3 100644 --- a/x/bet/types/ticket_test.go +++ b/x/legacy/bet/types/ticket_test.go @@ -7,8 +7,8 @@ import ( sdkmath "cosmossdk.io/math" - sgetypes "github.com/sge-network/sge/types" - "github.com/sge-network/sge/x/bet/types" + sgetypes "github.com/sge-network/sge/types/legacy" + "github.com/sge-network/sge/x/legacy/bet/types" ) func TestTicketFieldsValidation(t *testing.T) { diff --git a/x/bet/types/tx.pb.go b/x/legacy/bet/types/tx.pb.go similarity index 85% rename from x/bet/types/tx.pb.go rename to x/legacy/bet/types/tx.pb.go index cfce06eb..467ea452 100644 --- a/x/bet/types/tx.pb.go +++ b/x/legacy/bet/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/tx.proto +// source: sge/legacy/bet/v1beta/tx.proto package types @@ -43,7 +43,7 @@ func (m *MsgWager) Reset() { *m = MsgWager{} } func (m *MsgWager) String() string { return proto.CompactTextString(m) } func (*MsgWager) ProtoMessage() {} func (*MsgWager) Descriptor() ([]byte, []int) { - return fileDescriptor_3fc41486184bd76d, []int{0} + return fileDescriptor_523ee62c5df3b632, []int{0} } func (m *MsgWager) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -96,7 +96,7 @@ func (m *MsgWagerResponse) Reset() { *m = MsgWagerResponse{} } func (m *MsgWagerResponse) String() string { return proto.CompactTextString(m) } func (*MsgWagerResponse) ProtoMessage() {} func (*MsgWagerResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3fc41486184bd76d, []int{1} + return fileDescriptor_523ee62c5df3b632, []int{1} } func (m *MsgWagerResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -145,7 +145,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_3fc41486184bd76d, []int{2} + return fileDescriptor_523ee62c5df3b632, []int{2} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -197,7 +197,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3fc41486184bd76d, []int{3} + return fileDescriptor_523ee62c5df3b632, []int{3} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -227,45 +227,46 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgWager)(nil), "sgenetwork.sge.bet.MsgWager") - proto.RegisterType((*MsgWagerResponse)(nil), "sgenetwork.sge.bet.MsgWagerResponse") - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.bet.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.bet.MsgUpdateParamsResponse") + proto.RegisterType((*MsgWager)(nil), "sge.legacy.bet.v1beta.MsgWager") + proto.RegisterType((*MsgWagerResponse)(nil), "sge.legacy.bet.v1beta.MsgWagerResponse") + proto.RegisterType((*MsgUpdateParams)(nil), "sge.legacy.bet.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.legacy.bet.v1beta.MsgUpdateParamsResponse") } -func init() { proto.RegisterFile("sgenetwork/sge/bet/tx.proto", fileDescriptor_3fc41486184bd76d) } +func init() { proto.RegisterFile("sge/legacy/bet/v1beta/tx.proto", fileDescriptor_523ee62c5df3b632) } -var fileDescriptor_3fc41486184bd76d = []byte{ - // 462 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2e, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x4f, 0x4a, 0x2d, 0xd1, 0x2f, - 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x42, 0x48, 0xea, 0x15, 0xa7, 0xa7, 0xea, - 0x25, 0xa5, 0x96, 0x48, 0x09, 0x26, 0xe6, 0x66, 0xe6, 0xe5, 0xeb, 0x83, 0x49, 0x88, 0x32, 0x29, - 0xf1, 0xe4, 0xfc, 0xe2, 0xdc, 0xfc, 0x62, 0xfd, 0xdc, 0xe2, 0x74, 0xfd, 0x32, 0x43, 0x10, 0x05, - 0x95, 0x90, 0x84, 0x48, 0xc4, 0x83, 0x79, 0xfa, 0x10, 0x0e, 0x54, 0x4a, 0x24, 0x3d, 0x3f, 0x3d, - 0x1f, 0x22, 0x0e, 0x62, 0x41, 0x45, 0xe5, 0xb1, 0xb8, 0xa6, 0x20, 0xb1, 0x28, 0x31, 0x17, 0xa6, - 0x4d, 0x0e, 0x8b, 0x82, 0xf2, 0xc4, 0xf4, 0xd4, 0x22, 0x88, 0xbc, 0x52, 0x13, 0x23, 0x17, 0x87, - 0x6f, 0x71, 0x7a, 0x38, 0x48, 0x48, 0xc8, 0x88, 0x8b, 0x3d, 0xb9, 0x28, 0x35, 0xb1, 0x24, 0xbf, - 0x48, 0x82, 0x51, 0x81, 0x51, 0x83, 0xd3, 0x49, 0xe2, 0xd2, 0x16, 0x5d, 0x11, 0xa8, 0x33, 0x1c, - 0x53, 0x52, 0x8a, 0x52, 0x8b, 0x8b, 0x83, 0x4b, 0x8a, 0x32, 0xf3, 0xd2, 0x83, 0x60, 0x0a, 0x85, - 0x4c, 0xb8, 0x58, 0x0b, 0x8a, 0xf2, 0x0b, 0x8a, 0x25, 0x98, 0x14, 0x18, 0x35, 0xb8, 0x8d, 0xe4, - 0xf4, 0x30, 0x83, 0x40, 0x0f, 0x6c, 0x7a, 0x00, 0x48, 0x55, 0x10, 0x44, 0xb1, 0x15, 0x4f, 0xd3, - 0xf3, 0x0d, 0x5a, 0x30, 0x33, 0x94, 0x3c, 0xb8, 0x04, 0x60, 0x6e, 0x08, 0x4a, 0x2d, 0x2e, 0xc8, - 0xcf, 0x2b, 0x4e, 0x45, 0x98, 0xcb, 0x48, 0x82, 0xb9, 0x4a, 0x6b, 0x19, 0xb9, 0xf8, 0x7d, 0x8b, - 0xd3, 0x43, 0x0b, 0x52, 0x12, 0x4b, 0x52, 0x03, 0xc0, 0x01, 0x21, 0x64, 0xc6, 0xc5, 0x99, 0x58, - 0x5a, 0x92, 0x91, 0x5f, 0x94, 0x59, 0x52, 0x49, 0xd0, 0x5f, 0x08, 0xa5, 0x42, 0xb6, 0x5c, 0x6c, - 0x90, 0xa0, 0x84, 0x7a, 0x4d, 0x0a, 0x9b, 0x13, 0x20, 0x76, 0x38, 0x71, 0x9e, 0xb8, 0x27, 0xcf, - 0xb0, 0xe2, 0xf9, 0x06, 0x2d, 0xc6, 0x20, 0xa8, 0x26, 0x2b, 0xe5, 0x4b, 0x5b, 0x74, 0x05, 0x8b, - 0xd3, 0x53, 0x75, 0xa1, 0x5a, 0x14, 0x0c, 0xf5, 0xcc, 0xf5, 0x0c, 0x41, 0xfe, 0x46, 0xd8, 0xa1, - 0x64, 0xc0, 0x25, 0x8e, 0xe6, 0x5c, 0x58, 0x00, 0x58, 0x89, 0x62, 0xd5, 0x6f, 0x74, 0x99, 0x91, - 0x8b, 0xd9, 0xb7, 0x38, 0x5d, 0x28, 0x80, 0x8b, 0x15, 0x12, 0x69, 0x32, 0xd8, 0x9c, 0x05, 0x0b, - 0x4e, 0x29, 0x15, 0x7c, 0xb2, 0x30, 0xbb, 0x94, 0x98, 0x3b, 0x98, 0x18, 0x85, 0xaa, 0xb8, 0x78, - 0x50, 0xc2, 0x4d, 0x19, 0x87, 0x56, 0x64, 0x45, 0x52, 0xda, 0x44, 0x28, 0x82, 0x5b, 0x23, 0x71, - 0x0a, 0x9b, 0x97, 0x3a, 0x98, 0x18, 0x9d, 0x1c, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, - 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, - 0x8e, 0x21, 0x4a, 0x2d, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x1f, 0x49, - 0x2b, 0x38, 0x31, 0x57, 0x40, 0x72, 0x5f, 0x65, 0x41, 0x6a, 0x71, 0x12, 0x1b, 0x38, 0x3d, 0x1b, - 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0x1a, 0x1d, 0x81, 0xff, 0xa0, 0x03, 0x00, 0x00, +var fileDescriptor_523ee62c5df3b632 = []byte{ + // 473 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x92, 0xcf, 0x6b, 0xd4, 0x40, + 0x14, 0xc7, 0x33, 0x5b, 0x5a, 0xdd, 0xb1, 0xa0, 0x0d, 0x2d, 0x8d, 0x01, 0xd3, 0x6d, 0x04, 0x2d, + 0x85, 0xcc, 0x98, 0x15, 0x2c, 0xec, 0x49, 0xf7, 0xe2, 0x41, 0x16, 0x4a, 0x44, 0x05, 0x2f, 0x32, + 0xc9, 0x0e, 0xd3, 0xa0, 0xc9, 0x84, 0x99, 0xe9, 0x8f, 0xbd, 0x89, 0x20, 0xf4, 0xe8, 0x9f, 0xe1, + 0x71, 0x0f, 0xfd, 0x23, 0x8a, 0xa7, 0xd2, 0x93, 0x27, 0x59, 0x76, 0x0f, 0xfb, 0x6f, 0x48, 0x32, + 0x89, 0xbb, 0x4a, 0x96, 0xb5, 0x97, 0xdd, 0x99, 0xf7, 0x3e, 0xef, 0xbd, 0xef, 0xfb, 0x66, 0xa0, + 0x23, 0x19, 0xc5, 0x9f, 0x28, 0x23, 0xd1, 0x00, 0x87, 0x54, 0xe1, 0x13, 0x3f, 0xa4, 0x8a, 0x60, + 0x75, 0x86, 0x32, 0xc1, 0x15, 0x37, 0xb7, 0x24, 0xa3, 0x48, 0xe7, 0x51, 0x48, 0x15, 0xd2, 0x79, + 0x7b, 0x83, 0x24, 0x71, 0xca, 0x71, 0xf1, 0xab, 0x49, 0x7b, 0x3b, 0xe2, 0x32, 0xe1, 0x12, 0x27, + 0x92, 0xe1, 0x13, 0x3f, 0xff, 0x2b, 0x13, 0xf7, 0x75, 0xe2, 0x43, 0x71, 0xc3, 0xfa, 0x52, 0xa6, + 0x36, 0x19, 0x67, 0x5c, 0xc7, 0xf3, 0x53, 0x19, 0x75, 0xeb, 0x35, 0x65, 0x44, 0x90, 0xa4, 0xaa, + 0xdc, 0xad, 0x67, 0x4e, 0x09, 0xa3, 0x42, 0x23, 0xee, 0x57, 0x00, 0x6f, 0xf7, 0x24, 0x7b, 0x97, + 0x87, 0xcc, 0x36, 0xbc, 0x15, 0x09, 0x4a, 0x14, 0x17, 0x16, 0x68, 0x81, 0xbd, 0x66, 0xd7, 0xba, + 0xbe, 0xf0, 0x36, 0x4b, 0x31, 0x2f, 0xfa, 0x7d, 0x41, 0xa5, 0x7c, 0xad, 0x44, 0x9c, 0xb2, 0xa0, + 0x02, 0xcd, 0x03, 0xb8, 0x9a, 0x09, 0x9e, 0x49, 0xab, 0xd1, 0x02, 0x7b, 0x77, 0xda, 0xbb, 0xa8, + 0xd6, 0x0b, 0x54, 0x0c, 0x38, 0xcc, 0xc1, 0x40, 0xf3, 0x9d, 0xf5, 0x2f, 0xd3, 0xe1, 0x7e, 0xd5, + 0xc6, 0x7d, 0x05, 0xef, 0x55, 0x32, 0x02, 0x2a, 0x33, 0x9e, 0x4a, 0x3a, 0x6b, 0x0d, 0x6e, 0xd6, + 0xda, 0x1d, 0x02, 0x78, 0xb7, 0x27, 0xd9, 0x9b, 0xac, 0x4f, 0x14, 0x3d, 0x2c, 0x1c, 0x31, 0x9f, + 0xc1, 0x26, 0x39, 0x56, 0x47, 0x5c, 0xc4, 0x6a, 0xb0, 0x74, 0xbb, 0x19, 0x6a, 0x3e, 0x87, 0x6b, + 0xda, 0xd3, 0x72, 0xc1, 0x07, 0x0b, 0x54, 0xe8, 0x31, 0xdd, 0xe6, 0xe5, 0xaf, 0x1d, 0xe3, 0xfb, + 0x74, 0xb8, 0x0f, 0x82, 0xb2, 0xae, 0xf3, 0xf0, 0xfa, 0xc2, 0xdb, 0x90, 0x8c, 0x7a, 0x29, 0x55, + 0xa7, 0x5c, 0x7c, 0x6c, 0xf9, 0xe8, 0x00, 0xf9, 0xf9, 0xf6, 0xb3, 0x31, 0xee, 0x13, 0xb8, 0xfd, + 0x8f, 0xe2, 0xca, 0x86, 0xce, 0x56, 0x6d, 0x7d, 0x7b, 0x04, 0xe0, 0x4a, 0x4f, 0x32, 0xf3, 0x2d, + 0x5c, 0xd5, 0x5f, 0x6f, 0x67, 0x81, 0xb2, 0xca, 0x57, 0xfb, 0xf1, 0x12, 0xa0, 0x9a, 0xe8, 0xae, + 0x9c, 0x37, 0x80, 0xf9, 0x19, 0xc0, 0xf5, 0xbf, 0x1c, 0x7c, 0xb4, 0xb8, 0x7c, 0x9e, 0xb3, 0xd1, + 0xff, 0x71, 0x7f, 0xa6, 0x59, 0x3f, 0xea, 0xf6, 0x3b, 0x6f, 0x80, 0xee, 0xcb, 0xcb, 0xb1, 0x03, + 0xae, 0xc6, 0x0e, 0x18, 0x8d, 0x1d, 0xf0, 0x6d, 0xe2, 0x18, 0x57, 0x13, 0xc7, 0xf8, 0x39, 0x71, + 0x8c, 0xf7, 0x1e, 0x8b, 0xd5, 0xd1, 0x71, 0x88, 0x22, 0x9e, 0xe0, 0xb9, 0xd2, 0xfc, 0x8c, 0xcf, + 0xe6, 0x9f, 0xbc, 0x1a, 0x64, 0x54, 0x86, 0x6b, 0xc5, 0x63, 0x7f, 0xfa, 0x3b, 0x00, 0x00, 0xff, + 0xff, 0x6c, 0x51, 0x27, 0xf0, 0xc9, 0x03, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -298,7 +299,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { // Deprecated: Do not use. func (c *msgClient) Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOption) (*MsgWagerResponse, error) { out := new(MsgWagerResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Msg/Wager", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Msg/Wager", in, out, opts...) if err != nil { return nil, err } @@ -308,7 +309,7 @@ func (c *msgClient) Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOp // Deprecated: Do not use. func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.bet.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.bet.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -349,7 +350,7 @@ func _Msg_Wager_Handler(srv interface{}, ctx context.Context, dec func(interface } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Msg/Wager", + FullMethod: "/sge.legacy.bet.v1beta.Msg/Wager", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Wager(ctx, req.(*MsgWager)) @@ -367,7 +368,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.bet.Msg/UpdateParams", + FullMethod: "/sge.legacy.bet.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -375,8 +376,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.bet.Msg", + ServiceName: "sge.legacy.bet.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -389,7 +391,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/bet/tx.proto", + Metadata: "sge/legacy/bet/v1beta/tx.proto", } func (m *MsgWager) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/wager.go b/x/legacy/bet/types/wager.go similarity index 100% rename from x/bet/types/wager.go rename to x/legacy/bet/types/wager.go diff --git a/x/bet/types/wager.pb.go b/x/legacy/bet/types/wager.pb.go similarity index 82% rename from x/bet/types/wager.pb.go rename to x/legacy/bet/types/wager.pb.go index 6f8037bc..b0020760 100644 --- a/x/bet/types/wager.pb.go +++ b/x/legacy/bet/types/wager.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/bet/wager.proto +// source: sge/legacy/bet/v1beta/wager.proto package types @@ -38,7 +38,7 @@ func (m *WagerProps) Reset() { *m = WagerProps{} } func (m *WagerProps) String() string { return proto.CompactTextString(m) } func (*WagerProps) ProtoMessage() {} func (*WagerProps) Descriptor() ([]byte, []int) { - return fileDescriptor_d31f188015e12e07, []int{0} + return fileDescriptor_20d4ed1fe6804f4c, []int{0} } func (m *WagerProps) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -82,29 +82,30 @@ func (m *WagerProps) GetTicket() string { } func init() { - proto.RegisterType((*WagerProps)(nil), "sgenetwork.sge.bet.WagerProps") + proto.RegisterType((*WagerProps)(nil), "sge.legacy.bet.v1beta.WagerProps") } -func init() { proto.RegisterFile("sgenetwork/sge/bet/wager.proto", fileDescriptor_d31f188015e12e07) } +func init() { proto.RegisterFile("sge/legacy/bet/v1beta/wager.proto", fileDescriptor_20d4ed1fe6804f4c) } -var fileDescriptor_d31f188015e12e07 = []byte{ - // 245 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2b, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x4f, 0x4a, 0x2d, 0xd1, 0x2f, - 0x4f, 0x4c, 0x4f, 0x2d, 0xd2, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x42, 0xc8, 0xeb, 0x15, - 0xa7, 0xa7, 0xea, 0x25, 0xa5, 0x96, 0x48, 0x89, 0xa4, 0xe7, 0xa7, 0xe7, 0x83, 0xa5, 0xf5, 0x41, - 0x2c, 0x88, 0x4a, 0xa5, 0x5a, 0x2e, 0xae, 0x70, 0x90, 0xc6, 0x80, 0xa2, 0xfc, 0x82, 0x62, 0x21, - 0x05, 0x2e, 0xe6, 0xd2, 0xcc, 0x14, 0x09, 0x46, 0x05, 0x46, 0x0d, 0x4e, 0x27, 0xbe, 0x47, 0xf7, - 0xe4, 0x99, 0x43, 0x3d, 0x5d, 0x5e, 0xdd, 0x93, 0x07, 0x89, 0x06, 0x81, 0x08, 0x21, 0x53, 0x2e, - 0xb6, 0xc4, 0xdc, 0xfc, 0xd2, 0xbc, 0x12, 0x09, 0x26, 0xb0, 0x22, 0xd9, 0x13, 0xf7, 0xe4, 0x19, - 0x6e, 0xdd, 0x93, 0x17, 0x4d, 0xce, 0x2f, 0xce, 0xcd, 0x2f, 0x2e, 0x4e, 0xc9, 0xd6, 0xcb, 0xcc, - 0xd7, 0xcf, 0x4d, 0x2c, 0xc9, 0xd0, 0xf3, 0xcc, 0x2b, 0x09, 0x82, 0x2a, 0x16, 0x12, 0xe3, 0x62, - 0x2b, 0xc9, 0x4c, 0xce, 0x4e, 0x2d, 0x91, 0x60, 0x06, 0x69, 0x0b, 0x82, 0xf2, 0x9c, 0x1c, 0x4e, - 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, - 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x2d, 0x3d, 0xb3, 0x24, 0xa3, 0x34, - 0x49, 0x2f, 0x39, 0x3f, 0x17, 0xe4, 0x45, 0x5d, 0x64, 0xef, 0x56, 0x80, 0x3d, 0x5c, 0x52, 0x59, - 0x90, 0x5a, 0x9c, 0xc4, 0x06, 0xf6, 0x87, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, 0x1c, 0x1c, 0xf5, - 0xe1, 0x13, 0x01, 0x00, 0x00, +var fileDescriptor_20d4ed1fe6804f4c = []byte{ + // 261 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x4c, 0xd0, 0x31, 0x4b, 0xc3, 0x40, + 0x14, 0x07, 0xf0, 0xc4, 0x42, 0xc0, 0x1b, 0x1c, 0x82, 0x95, 0x20, 0x78, 0xa9, 0x4e, 0x2e, 0xbd, + 0x43, 0xc4, 0x2f, 0x50, 0x04, 0xe9, 0x26, 0x01, 0x11, 0xdc, 0xee, 0xd2, 0xc7, 0x35, 0xc4, 0xe4, + 0x85, 0xdc, 0x8b, 0xb5, 0x83, 0xdf, 0xc1, 0x8f, 0xd5, 0xb1, 0xa3, 0x38, 0x04, 0x49, 0x36, 0x3f, + 0x85, 0x5c, 0xd2, 0xc1, 0xe5, 0xf8, 0xdf, 0xe3, 0xf7, 0x1f, 0xde, 0x63, 0x97, 0xd6, 0x80, 0x7c, + 0x05, 0xa3, 0xd2, 0xad, 0xd4, 0x40, 0xf2, 0xed, 0x46, 0x03, 0x29, 0xb9, 0x51, 0x06, 0x6a, 0x51, + 0xd5, 0x48, 0x18, 0x4e, 0xad, 0x01, 0x31, 0x12, 0xa1, 0x81, 0xc4, 0x48, 0xce, 0x4f, 0x0d, 0x1a, + 0x1c, 0x84, 0x74, 0x69, 0xc4, 0x57, 0x1f, 0x8c, 0x3d, 0xbb, 0xee, 0x63, 0x8d, 0x95, 0x0d, 0x67, + 0x6c, 0xd2, 0x64, 0xab, 0xc8, 0x9f, 0xf9, 0xd7, 0xc7, 0x8b, 0x93, 0xae, 0x8d, 0x27, 0x4f, 0xcb, + 0xfb, 0xdf, 0x36, 0x76, 0xd3, 0xc4, 0x3d, 0xe1, 0x1d, 0x0b, 0x54, 0x81, 0x4d, 0x49, 0xd1, 0xd1, + 0x80, 0x2e, 0x76, 0x6d, 0xec, 0x7d, 0xb7, 0xf1, 0x34, 0x45, 0x5b, 0xa0, 0xb5, 0xab, 0x5c, 0x64, + 0x28, 0x0b, 0x45, 0x6b, 0xb1, 0x2c, 0x29, 0x39, 0xe0, 0xf0, 0x8c, 0x05, 0x94, 0xa5, 0x39, 0x50, + 0x34, 0x71, 0xb5, 0xe4, 0xf0, 0x5b, 0x3c, 0xec, 0x3a, 0xee, 0xef, 0x3b, 0xee, 0xff, 0x74, 0xdc, + 0xff, 0xec, 0xb9, 0xb7, 0xef, 0xb9, 0xf7, 0xd5, 0x73, 0xef, 0x65, 0x6e, 0x32, 0x5a, 0x37, 0x5a, + 0xa4, 0x58, 0x48, 0x6b, 0x60, 0x5e, 0x02, 0x6d, 0xb0, 0xce, 0x5d, 0x96, 0xef, 0xff, 0x2f, 0x40, + 0xdb, 0x0a, 0xac, 0x0e, 0x86, 0x75, 0x6e, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0x77, 0x09, 0xad, + 0xf3, 0x20, 0x01, 0x00, 0x00, } func (m *WagerProps) Marshal() (dAtA []byte, err error) { diff --git a/x/bet/types/wager_test.go b/x/legacy/bet/types/wager_test.go similarity index 97% rename from x/bet/types/wager_test.go rename to x/legacy/bet/types/wager_test.go index b1200a9c..caaeb1ab 100644 --- a/x/bet/types/wager_test.go +++ b/x/legacy/bet/types/wager_test.go @@ -6,7 +6,7 @@ import ( sdkmath "cosmossdk.io/math" "github.com/stretchr/testify/require" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) func TestBetFieldsValidation(t *testing.T) { diff --git a/x/house/client/cli/query.go b/x/legacy/house/client/cli/query.go similarity index 92% rename from x/house/client/cli/query.go rename to x/legacy/house/client/cli/query.go index cbf61221..5ce28e5b 100644 --- a/x/house/client/cli/query.go +++ b/x/legacy/house/client/cli/query.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // GetQueryCmd returns the cli query commands for this module diff --git a/x/house/client/cli/query_deposit.go b/x/legacy/house/client/cli/query_deposit.go similarity index 98% rename from x/house/client/cli/query_deposit.go rename to x/legacy/house/client/cli/query_deposit.go index 7cfaf600..0687b9d4 100644 --- a/x/house/client/cli/query_deposit.go +++ b/x/legacy/house/client/cli/query_deposit.go @@ -11,7 +11,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // GetCmdQueryDeposits implements the query deposits command. diff --git a/x/orderbook/client/cli/query_params.go b/x/legacy/house/client/cli/query_params.go similarity index 93% rename from x/orderbook/client/cli/query_params.go rename to x/legacy/house/client/cli/query_params.go index 5e685a77..0d0f81e6 100644 --- a/x/orderbook/client/cli/query_params.go +++ b/x/legacy/house/client/cli/query_params.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // CmdQueryParams returns a command object instance for module params diff --git a/x/house/client/cli/query_withdrawal.go b/x/legacy/house/client/cli/query_withdrawal.go similarity index 98% rename from x/house/client/cli/query_withdrawal.go rename to x/legacy/house/client/cli/query_withdrawal.go index 18f51d41..155bfb25 100644 --- a/x/house/client/cli/query_withdrawal.go +++ b/x/legacy/house/client/cli/query_withdrawal.go @@ -12,7 +12,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // GetCmdQueryWithdrawal implements the command to query the withdrawal of a diff --git a/x/house/client/cli/tx.go b/x/legacy/house/client/cli/tx.go similarity index 91% rename from x/house/client/cli/tx.go rename to x/legacy/house/client/cli/tx.go index 94df8614..2195367f 100644 --- a/x/house/client/cli/tx.go +++ b/x/legacy/house/client/cli/tx.go @@ -5,7 +5,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // NewTxCmd returns a root CLI command handler for all x/house transaction commands. diff --git a/x/house/client/cli/tx_deposit.go b/x/legacy/house/client/cli/tx_deposit.go similarity index 96% rename from x/house/client/cli/tx_deposit.go rename to x/legacy/house/client/cli/tx_deposit.go index 6a21e219..af9b8a5b 100644 --- a/x/house/client/cli/tx_deposit.go +++ b/x/legacy/house/client/cli/tx_deposit.go @@ -12,7 +12,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/tx" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) func CmdDeposit() *cobra.Command { diff --git a/x/house/client/cli/tx_withdraw.go b/x/legacy/house/client/cli/tx_withdraw.go similarity index 97% rename from x/house/client/cli/tx_withdraw.go rename to x/legacy/house/client/cli/tx_withdraw.go index 170af3f5..3db66d9d 100644 --- a/x/house/client/cli/tx_withdraw.go +++ b/x/legacy/house/client/cli/tx_withdraw.go @@ -13,7 +13,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/tx" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) func CmdWithdraw() *cobra.Command { diff --git a/x/house/genesis.go b/x/legacy/house/genesis.go similarity index 74% rename from x/house/genesis.go rename to x/legacy/house/genesis.go index 0d81e8b3..4aff2c80 100644 --- a/x/house/genesis.go +++ b/x/legacy/house/genesis.go @@ -3,12 +3,12 @@ package house import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/house/keeper" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/keeper" + "github.com/sge-network/sge/x/legacy/house/types" ) // InitGenesis sets the deposits and parameters for the provided keeper. -func InitGenesis(ctx sdk.Context, keeper keeper.Keeper, data *types.GenesisState) { +func InitGenesis(ctx sdk.Context, keeper *keeper.Keeper, data *types.GenesisState) { keeper.SetParams(ctx, data.Params) for _, deposit := range data.DepositList { @@ -22,7 +22,7 @@ func InitGenesis(ctx sdk.Context, keeper keeper.Keeper, data *types.GenesisState // ExportGenesis returns a GenesisState for a given context and keeper. The // GenesisState will contain the params and deposits found in the keeper. -func ExportGenesis(ctx sdk.Context, k keeper.Keeper) *types.GenesisState { +func ExportGenesis(ctx sdk.Context, k *keeper.Keeper) *types.GenesisState { genesis := types.DefaultGenesis() genesis.Params = k.GetParams(ctx) diff --git a/x/house/keeper/deposit.go b/x/legacy/house/keeper/deposit.go similarity index 93% rename from x/house/keeper/deposit.go rename to x/legacy/house/keeper/deposit.go index 7fbdbf27..21e14950 100644 --- a/x/house/keeper/deposit.go +++ b/x/legacy/house/keeper/deposit.go @@ -3,10 +3,11 @@ package keeper import ( sdkerrors "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // SetDeposit sets a deposit in the store @@ -38,7 +39,7 @@ func (k Keeper) GetDeposit(ctx sdk.Context, depositorAddress, // GetAllDeposits returns list of deposits. func (k Keeper) GetAllDeposits(ctx sdk.Context) (list []types.Deposit, err error) { store := k.getDepositStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/bet/keeper/export_test.go b/x/legacy/house/keeper/export_test.go similarity index 100% rename from x/bet/keeper/export_test.go rename to x/legacy/house/keeper/export_test.go diff --git a/x/bet/keeper/grpc_query.go b/x/legacy/house/keeper/grpc_query.go similarity index 55% rename from x/bet/keeper/grpc_query.go rename to x/legacy/house/keeper/grpc_query.go index b1e90230..f2e988d8 100644 --- a/x/bet/keeper/grpc_query.go +++ b/x/legacy/house/keeper/grpc_query.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/house/types" ) var _ types.QueryServer = Keeper{} diff --git a/x/house/keeper/grpc_query_deposit.go b/x/legacy/house/keeper/grpc_query_deposit.go similarity index 95% rename from x/house/keeper/grpc_query_deposit.go rename to x/legacy/house/keeper/grpc_query_deposit.go index 1d828035..d65b3686 100644 --- a/x/house/keeper/grpc_query_deposit.go +++ b/x/legacy/house/keeper/grpc_query_deposit.go @@ -6,12 +6,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // Deposits queries all deposits diff --git a/x/house/keeper/grpc_query_params.go b/x/legacy/house/keeper/grpc_query_params.go similarity index 90% rename from x/house/keeper/grpc_query_params.go rename to x/legacy/house/keeper/grpc_query_params.go index 4a436bba..dfe3d78e 100644 --- a/x/house/keeper/grpc_query_params.go +++ b/x/legacy/house/keeper/grpc_query_params.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // Params returns the params of the module diff --git a/x/house/keeper/grpc_query_withdrawal.go b/x/legacy/house/keeper/grpc_query_withdrawal.go similarity index 95% rename from x/house/keeper/grpc_query_withdrawal.go rename to x/legacy/house/keeper/grpc_query_withdrawal.go index 0e7651c5..f04b66c5 100644 --- a/x/house/keeper/grpc_query_withdrawal.go +++ b/x/legacy/house/keeper/grpc_query_withdrawal.go @@ -6,12 +6,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // WithdrawalsByAccount returns all withdrawals of a given account address diff --git a/x/house/keeper/keeper.go b/x/legacy/house/keeper/keeper.go similarity index 93% rename from x/house/keeper/keeper.go rename to x/legacy/house/keeper/keeper.go index 1609658f..ddd05699 100644 --- a/x/house/keeper/keeper.go +++ b/x/legacy/house/keeper/keeper.go @@ -1,11 +1,11 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // Keeper of the house store diff --git a/x/house/keeper/msg_server.go b/x/legacy/house/keeper/msg_server.go similarity index 63% rename from x/house/keeper/msg_server.go rename to x/legacy/house/keeper/msg_server.go index a7e3786e..698ecf77 100644 --- a/x/house/keeper/msg_server.go +++ b/x/legacy/house/keeper/msg_server.go @@ -1,15 +1,15 @@ package keeper import ( - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) type msgServer struct { - Keeper + *Keeper } // NewMsgServerImpl returns an implementation of the house MsgServer interface // for the provided Keeper. -func NewMsgServerImpl(keeper Keeper) types.MsgServer { +func NewMsgServerImpl(keeper *Keeper) types.MsgServer { return &msgServer{Keeper: keeper} } diff --git a/x/house/keeper/msg_server_deposit.go b/x/legacy/house/keeper/msg_server_deposit.go similarity index 94% rename from x/house/keeper/msg_server_deposit.go rename to x/legacy/house/keeper/msg_server_deposit.go index 4360fb3d..dcc48750 100644 --- a/x/house/keeper/msg_server_deposit.go +++ b/x/legacy/house/keeper/msg_server_deposit.go @@ -7,7 +7,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // Deposit performs deposit operation to participate as a house in a specific market/order book @@ -63,7 +63,7 @@ func (k Keeper) ParseDepositTicketAndValidate( if !authzAllowed { return "", types.ErrAuthorizationNotAllowed } - if err := utils.ValidateMsgAuthorization(k.authzKeeper, ctx, msg.Creator, payload.DepositorAddress, msg, + if err := utils.ValidateMsgAuthorization(ctx, k.authzKeeper, msg.Creator, payload.DepositorAddress, msg, types.ErrAuthorizationNotFound, types.ErrAuthorizationNotAccepted); err != nil { return "", err } diff --git a/x/house/keeper/msg_server_params.go b/x/legacy/house/keeper/msg_server_params.go similarity index 92% rename from x/house/keeper/msg_server_params.go rename to x/legacy/house/keeper/msg_server_params.go index 1890752c..d8000447 100644 --- a/x/house/keeper/msg_server_params.go +++ b/x/legacy/house/keeper/msg_server_params.go @@ -7,7 +7,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { diff --git a/x/house/keeper/msg_server_withdraw.go b/x/legacy/house/keeper/msg_server_withdraw.go similarity index 96% rename from x/house/keeper/msg_server_withdraw.go rename to x/legacy/house/keeper/msg_server_withdraw.go index 59bcf95e..cc2f9eeb 100644 --- a/x/house/keeper/msg_server_withdraw.go +++ b/x/legacy/house/keeper/msg_server_withdraw.go @@ -7,7 +7,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // Withdraw performs withdrawal of unused tokens corresponding to a deposit. @@ -94,7 +94,7 @@ func (k Keeper) CalcAndWithdraw( } if isOnBehalf { - if err := utils.ValidateMsgAuthorization(k.authzKeeper, ctx, msg.Creator, depositorAddr, msg, + if err := utils.ValidateMsgAuthorization(ctx, k.authzKeeper, msg.Creator, depositorAddr, msg, types.ErrAuthorizationNotFound, types.ErrAuthorizationNotAccepted); err != nil { return 0, err } diff --git a/x/house/keeper/params.go b/x/legacy/house/keeper/params.go similarity index 95% rename from x/house/keeper/params.go rename to x/legacy/house/keeper/params.go index d2e6293c..93d4cff0 100644 --- a/x/house/keeper/params.go +++ b/x/legacy/house/keeper/params.go @@ -4,7 +4,7 @@ import ( sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // GetParams return parameters of the module diff --git a/x/house/keeper/view.go b/x/legacy/house/keeper/view.go similarity index 85% rename from x/house/keeper/view.go rename to x/legacy/house/keeper/view.go index 93743853..87f2147f 100644 --- a/x/house/keeper/view.go +++ b/x/legacy/house/keeper/view.go @@ -1,10 +1,10 @@ package keeper import ( - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // getDepositStore gets the store containing all deposits. diff --git a/x/house/keeper/withdrawal.go b/x/legacy/house/keeper/withdrawal.go similarity index 93% rename from x/house/keeper/withdrawal.go rename to x/legacy/house/keeper/withdrawal.go index ba81b7b9..9de35341 100644 --- a/x/house/keeper/withdrawal.go +++ b/x/legacy/house/keeper/withdrawal.go @@ -3,9 +3,10 @@ package keeper import ( sdkerrors "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // SetWithdrawal sets a withdrawal. @@ -41,7 +42,7 @@ func (k Keeper) GetWithdraw(ctx sdk.Context, depositorAddress, // GetAllWithdrawals returns all withdrawals used during genesis dump. func (k Keeper) GetAllWithdrawals(ctx sdk.Context) (list []types.Withdrawal, err error) { store := k.getWithdrawalStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/house/module.go b/x/legacy/house/module.go similarity index 89% rename from x/house/module.go rename to x/legacy/house/module.go index 3c9cb386..1a690d45 100644 --- a/x/house/module.go +++ b/x/legacy/house/module.go @@ -16,9 +16,9 @@ import ( "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" - "github.com/sge-network/sge/x/house/client/cli" - "github.com/sge-network/sge/x/house/keeper" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/client/cli" + "github.com/sge-network/sge/x/legacy/house/keeper" + "github.com/sge-network/sge/x/legacy/house/types" ) // AppModuleBasic defines the basic application module used by the house module. @@ -89,17 +89,23 @@ func (AppModuleBasic) GetQueryCmd() *cobra.Command { type AppModule struct { AppModuleBasic - keeper keeper.Keeper + keeper *keeper.Keeper } // NewAppModule creates a new AppModule object -func NewAppModule(cdc codec.Codec, keeper keeper.Keeper) AppModule { - return AppModule{ +func NewAppModule(cdc codec.Codec, keeper *keeper.Keeper) *AppModule { + return &AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, } } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} + +// IsOnePerModuleType is a marker function just indicates that this is a one-per-module type. +func (am AppModule) IsOnePerModuleType() {} + // RegisterInvariants registers the house module invariants. func (AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} diff --git a/x/house/module_simulation.go b/x/legacy/house/module_simulation.go similarity index 84% rename from x/house/module_simulation.go rename to x/legacy/house/module_simulation.go index f5f3fe9c..75ca1c76 100644 --- a/x/house/module_simulation.go +++ b/x/legacy/house/module_simulation.go @@ -5,14 +5,13 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/bet/types" - housesimulation "github.com/sge-network/sge/x/house/simulation" + "github.com/sge-network/sge/x/legacy/bet/types" + housesimulation "github.com/sge-network/sge/x/legacy/house/simulation" ) // avoid unused import issue @@ -35,7 +34,7 @@ func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedP } // RegisterStoreDecoder registers a decoder -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { sdr[types.StoreKey] = housesimulation.NewDecodeStore(am.cdc) } diff --git a/x/house/simulation/decoder.go b/x/legacy/house/simulation/decoder.go similarity index 94% rename from x/house/simulation/decoder.go rename to x/legacy/house/simulation/decoder.go index 596449ad..4dfc0c25 100644 --- a/x/house/simulation/decoder.go +++ b/x/legacy/house/simulation/decoder.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // NewDecodeStore returns a decoder function closure that unmarshal the KVPair's diff --git a/x/house/simulation/errors.go b/x/legacy/house/simulation/errors.go similarity index 100% rename from x/house/simulation/errors.go rename to x/legacy/house/simulation/errors.go diff --git a/x/house/simulation/genesis.go b/x/legacy/house/simulation/genesis.go similarity index 87% rename from x/house/simulation/genesis.go rename to x/legacy/house/simulation/genesis.go index 1bdff9e8..dbe9d5b5 100644 --- a/x/house/simulation/genesis.go +++ b/x/legacy/house/simulation/genesis.go @@ -12,7 +12,7 @@ import ( sdkmath "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // Simulation parameter constants @@ -35,13 +35,13 @@ func GenMinDeposit(r *rand.Rand) sdkmath.Int { func RandomizedGenState(simState *module.SimulationState) { var houseParticipationFee sdkmath.LegacyDec simState.AppParams.GetOrGenerate( - simState.Cdc, HouseParticipationFee, &houseParticipationFee, simState.Rand, + HouseParticipationFee, &houseParticipationFee, simState.Rand, func(r *rand.Rand) { houseParticipationFee = GenHouseParticipationFee(r) }, ) var minDeposit sdkmath.Int simState.AppParams.GetOrGenerate( - simState.Cdc, MinDeposit, &minDeposit, simState.Rand, + MinDeposit, &minDeposit, simState.Rand, func(r *rand.Rand) { minDeposit = GenMinDeposit(r) }, ) diff --git a/x/house/simulation/params.go b/x/legacy/house/simulation/params.go similarity index 92% rename from x/house/simulation/params.go rename to x/legacy/house/simulation/params.go index 7f4446a2..a669dff3 100644 --- a/x/house/simulation/params.go +++ b/x/legacy/house/simulation/params.go @@ -10,7 +10,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) const ( diff --git a/x/house/simulation/proposals.go b/x/legacy/house/simulation/proposals.go similarity index 96% rename from x/house/simulation/proposals.go rename to x/legacy/house/simulation/proposals.go index 77aa3185..c0b7d92a 100644 --- a/x/house/simulation/proposals.go +++ b/x/legacy/house/simulation/proposals.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/spf13/cast" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/house/types" ) // Simulation operation weights constants diff --git a/x/house/simulation/simap.go b/x/legacy/house/simulation/simap.go similarity index 100% rename from x/house/simulation/simap.go rename to x/legacy/house/simulation/simap.go diff --git a/x/house/types/authz.pb.go b/x/legacy/house/types/authz.pb.go similarity index 83% rename from x/house/types/authz.pb.go rename to x/legacy/house/types/authz.pb.go index 7e218dba..89c231fc 100644 --- a/x/house/types/authz.pb.go +++ b/x/legacy/house/types/authz.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/authz.proto +// source: sge/legacy/house/v1beta/authz.proto package types @@ -34,7 +34,7 @@ func (m *DepositAuthorization) Reset() { *m = DepositAuthorization{} } func (m *DepositAuthorization) String() string { return proto.CompactTextString(m) } func (*DepositAuthorization) ProtoMessage() {} func (*DepositAuthorization) Descriptor() ([]byte, []int) { - return fileDescriptor_ad67f0a0dd6cd8ca, []int{0} + return fileDescriptor_c15e2ec5050da09d, []int{0} } func (m *DepositAuthorization) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -73,7 +73,7 @@ func (m *WithdrawAuthorization) Reset() { *m = WithdrawAuthorization{} } func (m *WithdrawAuthorization) String() string { return proto.CompactTextString(m) } func (*WithdrawAuthorization) ProtoMessage() {} func (*WithdrawAuthorization) Descriptor() ([]byte, []int) { - return fileDescriptor_ad67f0a0dd6cd8ca, []int{1} + return fileDescriptor_c15e2ec5050da09d, []int{1} } func (m *WithdrawAuthorization) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -103,30 +103,33 @@ func (m *WithdrawAuthorization) XXX_DiscardUnknown() { var xxx_messageInfo_WithdrawAuthorization proto.InternalMessageInfo func init() { - proto.RegisterType((*DepositAuthorization)(nil), "sgenetwork.sge.house.DepositAuthorization") - proto.RegisterType((*WithdrawAuthorization)(nil), "sgenetwork.sge.house.WithdrawAuthorization") + proto.RegisterType((*DepositAuthorization)(nil), "sge.legacy.house.v1beta.DepositAuthorization") + proto.RegisterType((*WithdrawAuthorization)(nil), "sge.legacy.house.v1beta.WithdrawAuthorization") } -func init() { proto.RegisterFile("sgenetwork/sge/house/authz.proto", fileDescriptor_ad67f0a0dd6cd8ca) } +func init() { + proto.RegisterFile("sge/legacy/house/v1beta/authz.proto", fileDescriptor_c15e2ec5050da09d) +} -var fileDescriptor_ad67f0a0dd6cd8ca = []byte{ - // 252 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x28, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0xc8, 0x2f, 0x2d, 0x4e, - 0xd5, 0x4f, 0x2c, 0x2d, 0xc9, 0xa8, 0xd2, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x41, 0xa8, - 0xd0, 0x2b, 0x4e, 0x4f, 0xd5, 0x03, 0xab, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd0, - 0x07, 0xb1, 0x20, 0x6a, 0x95, 0xc2, 0xb8, 0x44, 0x5c, 0x52, 0x0b, 0xf2, 0x8b, 0x33, 0x4b, 0x1c, - 0x4b, 0x4b, 0x32, 0xf2, 0x8b, 0x32, 0xab, 0x12, 0x4b, 0x32, 0xf3, 0xf3, 0x84, 0xec, 0xb8, 0xb8, - 0x8b, 0x0b, 0x52, 0xf3, 0x52, 0xe2, 0x73, 0x32, 0x73, 0x33, 0x4b, 0x24, 0x18, 0x15, 0x18, 0x35, - 0x38, 0x9d, 0x64, 0x4f, 0xdc, 0x93, 0x67, 0xb8, 0x75, 0x4f, 0x5e, 0x34, 0x39, 0xbf, 0x38, 0x37, - 0xbf, 0xb8, 0x38, 0x25, 0x5b, 0x2f, 0x33, 0x5f, 0x3f, 0x37, 0xb1, 0x24, 0x43, 0xcf, 0x33, 0xaf, - 0x24, 0x88, 0x0b, 0xac, 0xc3, 0x07, 0xa4, 0x41, 0x29, 0x96, 0x4b, 0x34, 0x3c, 0xb3, 0x24, 0x23, - 0xa5, 0x28, 0xb1, 0x1c, 0xd5, 0x60, 0x17, 0x2e, 0xbe, 0x72, 0xa8, 0x04, 0x29, 0x66, 0xf3, 0xc2, - 0x34, 0x81, 0x8d, 0x77, 0x72, 0x3a, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, - 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, - 0x8d, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x50, 0xf0, 0xe8, 0x22, 0x07, - 0x55, 0x05, 0x34, 0xb0, 0x4a, 0x2a, 0x0b, 0x52, 0x8b, 0x93, 0xd8, 0xc0, 0x21, 0x60, 0x0c, 0x08, - 0x00, 0x00, 0xff, 0xff, 0x4d, 0x73, 0xfa, 0x1d, 0x51, 0x01, 0x00, 0x00, +var fileDescriptor_c15e2ec5050da09d = []byte{ + // 264 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x90, 0x31, 0x4b, 0xc3, 0x40, + 0x14, 0xc7, 0x93, 0x45, 0xf0, 0x44, 0x87, 0xd2, 0xa2, 0x08, 0x5e, 0xa5, 0x2e, 0x2e, 0xde, 0x21, + 0xee, 0x82, 0xa5, 0x4b, 0xc1, 0xc9, 0x41, 0x41, 0x10, 0xb9, 0x26, 0x8f, 0xbb, 0xa3, 0x4d, 0x5e, + 0xc8, 0x7b, 0x31, 0xb6, 0x9f, 0xc2, 0x8f, 0xd5, 0xb1, 0xa3, 0x38, 0x14, 0x49, 0xbe, 0x88, 0x24, + 0xd1, 0xa1, 0xa3, 0xdb, 0x83, 0xf7, 0xfb, 0xfd, 0x86, 0xbf, 0xb8, 0x20, 0x0b, 0x7a, 0x01, 0xd6, + 0x44, 0x4b, 0xed, 0xb0, 0x20, 0xd0, 0x6f, 0xd7, 0x33, 0x60, 0xa3, 0x4d, 0xc1, 0x6e, 0xa5, 0xb2, + 0x1c, 0x19, 0x7b, 0xc7, 0x64, 0x41, 0x75, 0x90, 0x6a, 0x21, 0xd5, 0x41, 0xa7, 0x7d, 0x8b, 0x16, + 0x5b, 0x46, 0x37, 0x57, 0x87, 0x8f, 0x1e, 0x45, 0x7f, 0x02, 0x19, 0x92, 0xe7, 0xbb, 0x82, 0x1d, + 0xe6, 0x7e, 0x65, 0xd8, 0x63, 0xda, 0xbb, 0x15, 0x07, 0x94, 0x41, 0x1a, 0xbf, 0x2e, 0x7c, 0xe2, + 0xf9, 0x24, 0x3c, 0x0f, 0x2f, 0xf7, 0xc7, 0x67, 0xeb, 0xed, 0x30, 0xf8, 0xda, 0x0e, 0x07, 0x11, + 0x52, 0x82, 0x44, 0xf1, 0x5c, 0x79, 0xd4, 0x89, 0x61, 0xa7, 0xa6, 0x29, 0x3f, 0x88, 0xd6, 0xb8, + 0x6f, 0x84, 0xd1, 0x8b, 0x18, 0x3c, 0x79, 0x76, 0x71, 0x6e, 0xca, 0xdd, 0xf0, 0x44, 0x1c, 0x95, + 0xbf, 0x8f, 0xff, 0xb4, 0x0f, 0xff, 0xa4, 0x36, 0x3f, 0x9e, 0xae, 0x2b, 0x19, 0x6e, 0x2a, 0x19, + 0x7e, 0x57, 0x32, 0xfc, 0xa8, 0x65, 0xb0, 0xa9, 0x65, 0xf0, 0x59, 0xcb, 0xe0, 0x59, 0x5b, 0xcf, + 0xae, 0x98, 0xa9, 0x08, 0x13, 0x4d, 0x16, 0xae, 0x52, 0xe0, 0x12, 0xf3, 0x79, 0x73, 0xeb, 0xf7, + 0xdd, 0xf5, 0x78, 0x99, 0x01, 0xcd, 0xf6, 0xda, 0x21, 0x6e, 0x7e, 0x02, 0x00, 0x00, 0xff, 0xff, + 0x63, 0x5c, 0xf1, 0xbe, 0x5e, 0x01, 0x00, 0x00, } func (m *DepositAuthorization) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/codec.go b/x/legacy/house/types/codec.go similarity index 100% rename from x/house/types/codec.go rename to x/legacy/house/types/codec.go diff --git a/x/house/types/consts.go b/x/legacy/house/types/consts.go similarity index 100% rename from x/house/types/consts.go rename to x/legacy/house/types/consts.go diff --git a/x/house/types/deposit.go b/x/legacy/house/types/deposit.go similarity index 100% rename from x/house/types/deposit.go rename to x/legacy/house/types/deposit.go diff --git a/x/house/types/deposit.pb.go b/x/legacy/house/types/deposit.pb.go similarity index 80% rename from x/house/types/deposit.pb.go rename to x/legacy/house/types/deposit.pb.go index 2eaf00cb..070d3450 100644 --- a/x/house/types/deposit.pb.go +++ b/x/legacy/house/types/deposit.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/deposit.proto +// source: sge/legacy/house/v1beta/deposit.proto package types @@ -49,7 +49,7 @@ type Deposit struct { func (m *Deposit) Reset() { *m = Deposit{} } func (*Deposit) ProtoMessage() {} func (*Deposit) Descriptor() ([]byte, []int) { - return fileDescriptor_723fb8b8b0b44700, []int{0} + return fileDescriptor_225ff388faae132d, []int{0} } func (m *Deposit) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -79,45 +79,45 @@ func (m *Deposit) XXX_DiscardUnknown() { var xxx_messageInfo_Deposit proto.InternalMessageInfo func init() { - proto.RegisterType((*Deposit)(nil), "sgenetwork.sge.house.Deposit") + proto.RegisterType((*Deposit)(nil), "sge.legacy.house.v1beta.Deposit") } func init() { - proto.RegisterFile("sgenetwork/sge/house/deposit.proto", fileDescriptor_723fb8b8b0b44700) + proto.RegisterFile("sge/legacy/house/v1beta/deposit.proto", fileDescriptor_225ff388faae132d) } -var fileDescriptor_723fb8b8b0b44700 = []byte{ - // 465 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x92, 0x3f, 0x8f, 0xd3, 0x30, - 0x18, 0xc6, 0x13, 0x28, 0xad, 0xce, 0xe2, 0xcf, 0x61, 0x7a, 0x10, 0x8a, 0x64, 0x9f, 0x3c, 0x75, - 0xe0, 0x92, 0x01, 0xa6, 0x63, 0x40, 0x2d, 0x27, 0xa4, 0x0e, 0x08, 0x29, 0x08, 0x21, 0xb1, 0x44, - 0xbe, 0xc4, 0x4a, 0xad, 0x36, 0x71, 0x64, 0xbb, 0xea, 0xdd, 0x37, 0x60, 0x64, 0x64, 0xec, 0x87, - 0x60, 0xe2, 0x13, 0xdc, 0x78, 0x62, 0x42, 0x0c, 0x16, 0x6a, 0x17, 0xc4, 0x98, 0x4f, 0x80, 0x6a, - 0x87, 0xb6, 0x08, 0x10, 0x9b, 0xfd, 0xbc, 0xbf, 0xe7, 0xf1, 0x63, 0xe9, 0x05, 0x44, 0xe5, 0xac, - 0x64, 0x7a, 0x2e, 0xe4, 0x24, 0x52, 0x39, 0x8b, 0xc6, 0x62, 0xa6, 0x58, 0x94, 0xb1, 0x4a, 0x28, - 0xae, 0xc3, 0x4a, 0x0a, 0x2d, 0x60, 0x77, 0xcb, 0x84, 0x2a, 0x67, 0xa1, 0x65, 0x7a, 0xdd, 0x5c, - 0xe4, 0xc2, 0x02, 0xd1, 0xfa, 0xe4, 0xd8, 0xde, 0xfd, 0x54, 0xa8, 0x42, 0xa8, 0xc4, 0x0d, 0xdc, - 0xc5, 0x8d, 0xc8, 0xa7, 0x16, 0xe8, 0x9c, 0xb8, 0x60, 0xf8, 0x10, 0x74, 0x52, 0xc9, 0xa8, 0x16, - 0x32, 0xf0, 0x0f, 0xfd, 0xfe, 0xde, 0x10, 0xd6, 0x06, 0xdf, 0x3c, 0xa7, 0xc5, 0xf4, 0x98, 0x34, - 0x03, 0x12, 0xff, 0x42, 0x20, 0x05, 0xb7, 0x9b, 0x46, 0x42, 0x26, 0x34, 0xcb, 0x24, 0x53, 0x2a, - 0xb8, 0x62, 0x7d, 0x8f, 0x6b, 0x83, 0x03, 0xe7, 0xfb, 0x03, 0x21, 0x9f, 0x3f, 0x1e, 0x75, 0x9b, - 0x0a, 0x03, 0x27, 0xbd, 0xd2, 0x92, 0x97, 0x79, 0xbc, 0xbf, 0x61, 0x1b, 0x1d, 0x3e, 0x01, 0xa0, - 0xa0, 0x72, 0xc2, 0x74, 0x32, 0xe3, 0x59, 0x70, 0xd5, 0x66, 0x3f, 0x58, 0x1a, 0xbc, 0xf7, 0xc2, - 0xaa, 0xaf, 0x47, 0x27, 0x3f, 0x0c, 0xde, 0x41, 0xe2, 0x9d, 0x33, 0x7c, 0x09, 0xee, 0x54, 0x54, - 0x6a, 0x9e, 0xf2, 0x8a, 0x6a, 0x2e, 0xca, 0x84, 0x97, 0x19, 0x3b, 0x0b, 0x5a, 0x87, 0x7e, 0xbf, - 0x35, 0x44, 0xb5, 0xc1, 0x3d, 0xd7, 0xf0, 0x2f, 0x10, 0x89, 0xe1, 0x6f, 0xea, 0x68, 0x2d, 0xc2, - 0xe7, 0xa0, 0x4d, 0x0b, 0x31, 0x2b, 0x75, 0x70, 0xcd, 0x36, 0x09, 0x2f, 0x0c, 0xf6, 0xbe, 0x1a, - 0x7c, 0xe0, 0x7e, 0xa3, 0xb2, 0x49, 0xc8, 0x45, 0x54, 0x50, 0x3d, 0x0e, 0x47, 0xa5, 0xae, 0x0d, - 0xbe, 0xe1, 0x1e, 0x70, 0x26, 0x12, 0x37, 0x6e, 0x38, 0x00, 0xfb, 0x73, 0xae, 0xc7, 0x99, 0xa4, - 0x73, 0x3a, 0x4d, 0x52, 0x9b, 0xd8, 0xb6, 0xad, 0xee, 0xd6, 0x06, 0x43, 0x67, 0xda, 0x12, 0x8a, - 0xc4, 0xb7, 0xb6, 0xb7, 0x67, 0x36, 0x62, 0x0e, 0xee, 0x69, 0xa1, 0xe9, 0x34, 0xd9, 0x09, 0x6a, - 0xba, 0x75, 0x6c, 0xb7, 0xa7, 0xff, 0xeb, 0x86, 0xdc, 0x33, 0xff, 0x48, 0x21, 0xf1, 0x81, 0x9d, - 0xbc, 0xd9, 0x0c, 0x06, 0x56, 0x3f, 0xbe, 0xfe, 0x6e, 0x81, 0xbd, 0x0f, 0x0b, 0xec, 0x7d, 0x5f, - 0x60, 0x6f, 0x38, 0xbc, 0x58, 0x22, 0xff, 0x72, 0x89, 0xfc, 0x6f, 0x4b, 0xe4, 0xbf, 0x5f, 0x21, - 0xef, 0x72, 0x85, 0xbc, 0x2f, 0x2b, 0xe4, 0xbd, 0xed, 0xe7, 0x5c, 0x8f, 0x67, 0xa7, 0x61, 0x2a, - 0x8a, 0xf5, 0x06, 0x1f, 0xed, 0x6e, 0xf3, 0x59, 0xb3, 0xcf, 0xfa, 0xbc, 0x62, 0xea, 0xb4, 0x6d, - 0xf7, 0xf0, 0xd1, 0xcf, 0x00, 0x00, 0x00, 0xff, 0xff, 0xa9, 0xc1, 0x44, 0xd8, 0xf4, 0x02, 0x00, - 0x00, +var fileDescriptor_225ff388faae132d = []byte{ + // 478 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x92, 0x4f, 0x8b, 0x13, 0x31, + 0x18, 0xc6, 0x67, 0xb4, 0xb6, 0x6c, 0xf0, 0xcf, 0x1a, 0x77, 0xdd, 0xb1, 0xc2, 0x64, 0x19, 0x10, + 0xf6, 0xe0, 0x4e, 0x10, 0x3d, 0xad, 0x07, 0x69, 0x5d, 0x84, 0x1e, 0x44, 0x18, 0x11, 0xc1, 0xcb, + 0x90, 0xce, 0x84, 0x69, 0x68, 0x67, 0x32, 0x24, 0xa9, 0xdd, 0x7e, 0x03, 0x8f, 0x1e, 0x3d, 0xf6, + 0x43, 0x78, 0xf2, 0x13, 0xec, 0x71, 0xf1, 0x24, 0x1e, 0x82, 0x4c, 0x2f, 0xe2, 0x71, 0x3e, 0x81, + 0x34, 0x19, 0x77, 0x5b, 0x54, 0xf6, 0xf6, 0xe6, 0x79, 0x7f, 0xcf, 0x93, 0x27, 0x10, 0xf0, 0x40, + 0x66, 0x14, 0x4f, 0x68, 0x46, 0x92, 0x39, 0x1e, 0xf1, 0xa9, 0xa4, 0xf8, 0xfd, 0xa3, 0x21, 0x55, + 0x04, 0xa7, 0xb4, 0xe4, 0x92, 0xa9, 0xb0, 0x14, 0x5c, 0x71, 0xb8, 0x27, 0x33, 0x1a, 0x5a, 0x2c, + 0x34, 0x58, 0x68, 0xb1, 0xee, 0x4e, 0xc6, 0x33, 0x6e, 0x18, 0xbc, 0x9a, 0x2c, 0xde, 0xbd, 0x97, + 0x70, 0x99, 0x73, 0x19, 0xdb, 0x85, 0x3d, 0xd8, 0x55, 0xf0, 0xa5, 0x05, 0x3a, 0xc7, 0x36, 0x1b, + 0x3e, 0x04, 0x9d, 0x44, 0x50, 0xa2, 0xb8, 0xf0, 0xdc, 0x7d, 0xf7, 0x60, 0xab, 0x0f, 0x6b, 0x8d, + 0x6e, 0xce, 0x49, 0x3e, 0x39, 0x0a, 0x9a, 0x45, 0x10, 0xfd, 0x41, 0x20, 0x01, 0xb7, 0x9b, 0x52, + 0x5c, 0xc4, 0x24, 0x4d, 0x05, 0x95, 0xd2, 0xbb, 0x62, 0x7c, 0x4f, 0x6a, 0x8d, 0x3c, 0xeb, 0xfb, + 0x0b, 0x09, 0xbe, 0x7e, 0x3e, 0xdc, 0x69, 0x2a, 0xf4, 0xac, 0xf4, 0x5a, 0x09, 0x56, 0x64, 0xd1, + 0xf6, 0x39, 0xdb, 0xe8, 0xf0, 0x29, 0x00, 0x39, 0x11, 0x63, 0xaa, 0xe2, 0x29, 0x4b, 0xbd, 0xab, + 0x26, 0xfb, 0x7e, 0xa5, 0xd1, 0xd6, 0x4b, 0xa3, 0xbe, 0x19, 0x1c, 0xff, 0xd2, 0x68, 0x0d, 0x89, + 0xd6, 0x66, 0xf8, 0x0a, 0xdc, 0x29, 0x89, 0x50, 0x2c, 0x61, 0x25, 0x51, 0x8c, 0x17, 0x31, 0x2b, + 0x52, 0x7a, 0xe2, 0xb5, 0xf6, 0xdd, 0x83, 0x56, 0xdf, 0xaf, 0x35, 0xea, 0xda, 0x86, 0xff, 0x80, + 0x82, 0x08, 0x6e, 0xa8, 0x83, 0x95, 0x08, 0x5f, 0x80, 0x36, 0xc9, 0xf9, 0xb4, 0x50, 0xde, 0x35, + 0xd3, 0x24, 0x3c, 0xd5, 0xc8, 0xf9, 0xae, 0xd1, 0xae, 0x7d, 0x8d, 0x4c, 0xc7, 0x21, 0xe3, 0x38, + 0x27, 0x6a, 0x14, 0x0e, 0x0a, 0x55, 0x6b, 0x74, 0xc3, 0x5e, 0x60, 0x4d, 0x41, 0xd4, 0xb8, 0x61, + 0x0f, 0x6c, 0xcf, 0x98, 0x1a, 0xa5, 0x82, 0xcc, 0xc8, 0x24, 0x4e, 0x4c, 0x62, 0xdb, 0xb4, 0xba, + 0x5b, 0x6b, 0x04, 0xad, 0xe9, 0x82, 0x90, 0x41, 0x74, 0xeb, 0xe2, 0xf4, 0xdc, 0x44, 0xcc, 0xc0, + 0x9e, 0xe2, 0x8a, 0x4c, 0xe2, 0xb5, 0xa0, 0xa6, 0x5b, 0xc7, 0x74, 0x7b, 0x76, 0x59, 0x37, 0xdf, + 0x5e, 0xf3, 0x9f, 0x94, 0x20, 0xda, 0x35, 0x9b, 0xb7, 0xe7, 0x8b, 0x9e, 0xd1, 0x8f, 0xae, 0x7f, + 0x58, 0x20, 0xe7, 0xd3, 0x02, 0x39, 0x3f, 0x17, 0xc8, 0xe9, 0x0f, 0x4e, 0x2b, 0xdf, 0x3d, 0xab, + 0x7c, 0xf7, 0x47, 0xe5, 0xbb, 0x1f, 0x97, 0xbe, 0x73, 0xb6, 0xf4, 0x9d, 0x6f, 0x4b, 0xdf, 0x79, + 0x87, 0x33, 0xa6, 0x46, 0xd3, 0x61, 0x98, 0xf0, 0x1c, 0xcb, 0x8c, 0x1e, 0x16, 0x54, 0xcd, 0xb8, + 0x18, 0xaf, 0x66, 0x7c, 0xb2, 0xf9, 0xc1, 0xd5, 0xbc, 0xa4, 0x72, 0xd8, 0x36, 0xdf, 0xf1, 0xf1, + 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, 0x73, 0x6c, 0xec, 0x42, 0x01, 0x03, 0x00, 0x00, } func (m *Deposit) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/deposit_authorizaton.go b/x/legacy/house/types/deposit_authorizaton.go similarity index 93% rename from x/house/types/deposit_authorizaton.go rename to x/legacy/house/types/deposit_authorizaton.go index 5944b592..ae9939fc 100644 --- a/x/house/types/deposit_authorizaton.go +++ b/x/legacy/house/types/deposit_authorizaton.go @@ -1,6 +1,8 @@ package types import ( + context "context" + sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" @@ -22,7 +24,7 @@ func (DepositAuthorization) MsgTypeURL() string { } // Accept implements Authorization.Accept. -func (a DepositAuthorization) Accept(_ sdk.Context, msg sdk.Msg) (authz.AcceptResponse, error) { +func (a DepositAuthorization) Accept(_ context.Context, msg sdk.Msg) (authz.AcceptResponse, error) { mDeposit, ok := msg.(*MsgDeposit) if !ok { return authz.AcceptResponse{}, sdkerrtypes.ErrInvalidType.Wrap("type mismatch") diff --git a/x/house/types/errors.go b/x/legacy/house/types/errors.go similarity index 100% rename from x/house/types/errors.go rename to x/legacy/house/types/errors.go diff --git a/x/house/types/events.go b/x/legacy/house/types/events.go similarity index 100% rename from x/house/types/events.go rename to x/legacy/house/types/events.go diff --git a/x/house/types/expected_keepers.go b/x/legacy/house/types/expected_keepers.go similarity index 95% rename from x/house/types/expected_keepers.go rename to x/legacy/house/types/expected_keepers.go index 64d237ac..7eb26194 100644 --- a/x/house/types/expected_keepers.go +++ b/x/legacy/house/types/expected_keepers.go @@ -30,19 +30,19 @@ type OVMKeeper interface { // AuthzKeeper defines the expected authz keeper. type AuthzKeeper interface { GetAuthorization( - ctx sdk.Context, + ctx context.Context, grantee sdk.AccAddress, granter sdk.AccAddress, msgType string, ) (authz.Authorization, *time.Time) SaveGrant( - ctx sdk.Context, + ctx context.Context, grantee, granter sdk.AccAddress, authorization authz.Authorization, expiration *time.Time, ) error DeleteGrant( - ctx sdk.Context, + ctx context.Context, grantee, granter sdk.AccAddress, msgType string, ) error diff --git a/x/house/types/funder.go b/x/legacy/house/types/funder.go similarity index 100% rename from x/house/types/funder.go rename to x/legacy/house/types/funder.go diff --git a/x/house/types/genesis.go b/x/legacy/house/types/genesis.go similarity index 100% rename from x/house/types/genesis.go rename to x/legacy/house/types/genesis.go diff --git a/x/house/types/genesis.pb.go b/x/legacy/house/types/genesis.pb.go similarity index 81% rename from x/house/types/genesis.pb.go rename to x/legacy/house/types/genesis.pb.go index bc365ff4..284ab125 100644 --- a/x/house/types/genesis.pb.go +++ b/x/legacy/house/types/genesis.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/genesis.proto +// source: sge/legacy/house/v1beta/genesis.proto package types @@ -37,7 +37,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_02191d749ca2ced3, []int{0} + return fileDescriptor_c9ba204137b667ff, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -88,33 +88,34 @@ func (m *GenesisState) GetWithdrawalList() []Withdrawal { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.house.GenesisState") + proto.RegisterType((*GenesisState)(nil), "sge.legacy.house.v1beta.GenesisState") } func init() { - proto.RegisterFile("sgenetwork/sge/house/genesis.proto", fileDescriptor_02191d749ca2ced3) + proto.RegisterFile("sge/legacy/house/v1beta/genesis.proto", fileDescriptor_c9ba204137b667ff) } -var fileDescriptor_02191d749ca2ced3 = []byte{ - // 282 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x90, 0x31, 0x4b, 0xc3, 0x40, - 0x18, 0x86, 0x73, 0x56, 0x3a, 0x24, 0x45, 0x21, 0x74, 0x28, 0x45, 0xcf, 0x58, 0x97, 0x2c, 0x5e, - 0xa0, 0x6e, 0x8e, 0x41, 0x74, 0x11, 0x14, 0x1d, 0x04, 0x17, 0xb9, 0xda, 0xe3, 0x72, 0xd8, 0x7a, - 0x21, 0xdf, 0x57, 0xa2, 0xff, 0xc2, 0x9f, 0xd5, 0xb1, 0xa3, 0x93, 0x48, 0xf2, 0x47, 0x24, 0x77, - 0xa7, 0x75, 0xb8, 0xed, 0x38, 0x9e, 0xf7, 0xe1, 0xfd, 0xde, 0x70, 0x02, 0x52, 0xbc, 0x0a, 0xac, - 0x75, 0xf5, 0x92, 0x81, 0x14, 0x59, 0xa1, 0x57, 0x20, 0xb2, 0xee, 0x0f, 0x14, 0xb0, 0xb2, 0xd2, - 0xa8, 0xe3, 0xe1, 0x96, 0x61, 0x20, 0x05, 0x33, 0xcc, 0x78, 0x28, 0xb5, 0xd4, 0x06, 0xc8, 0xba, - 0x97, 0x65, 0xc7, 0x7e, 0xdf, 0x5c, 0x94, 0x1a, 0x14, 0x3a, 0xe6, 0xc4, 0xcb, 0xd4, 0x0a, 0x8b, - 0x79, 0xc5, 0x6b, 0x07, 0x1d, 0x7b, 0xa1, 0x92, 0x57, 0x7c, 0xe9, 0x7a, 0x4d, 0x5a, 0x12, 0x0e, - 0xae, 0x6c, 0xd3, 0x7b, 0xe4, 0x28, 0xe2, 0xf3, 0xb0, 0x6f, 0x81, 0x11, 0x49, 0x48, 0x1a, 0x4d, - 0x0f, 0x98, 0xaf, 0x39, 0xbb, 0x35, 0x4c, 0xbe, 0xbb, 0xfe, 0x3a, 0x0a, 0xee, 0x5c, 0x22, 0xbe, - 0x0c, 0x07, 0xae, 0xe5, 0xd3, 0x42, 0x01, 0x8e, 0x76, 0x92, 0x5e, 0x1a, 0x4d, 0x0f, 0xfd, 0x86, - 0x0b, 0x4b, 0x3a, 0x45, 0xe4, 0x82, 0xd7, 0x0a, 0x30, 0xbe, 0x09, 0xf7, 0x7f, 0x2f, 0xe1, 0x0b, - 0xab, 0xea, 0x19, 0x55, 0xe2, 0x57, 0x3d, 0xfc, 0xc1, 0xce, 0xb6, 0xb7, 0x8d, 0x77, 0xc2, 0x3c, - 0x5f, 0x37, 0x94, 0x6c, 0x1a, 0x4a, 0xbe, 0x1b, 0x4a, 0x3e, 0x5a, 0x1a, 0x6c, 0x5a, 0x1a, 0x7c, - 0xb6, 0x34, 0x78, 0x4c, 0xa5, 0xc2, 0x62, 0x35, 0x63, 0xcf, 0x7a, 0xd9, 0x4d, 0x74, 0xfa, 0x7f, - 0xae, 0x37, 0x37, 0x18, 0xbe, 0x97, 0x02, 0x66, 0x7d, 0x33, 0xd8, 0xd9, 0x4f, 0x00, 0x00, 0x00, - 0xff, 0xff, 0xbc, 0x0a, 0x1b, 0xf6, 0xee, 0x01, 0x00, 0x00, +var fileDescriptor_c9ba204137b667ff = []byte{ + // 297 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0xd0, 0xbf, 0x4b, 0xc3, 0x40, + 0x14, 0xc0, 0xf1, 0x9c, 0x95, 0x0e, 0x49, 0x51, 0x08, 0x82, 0x25, 0xc3, 0x35, 0xf8, 0x8b, 0x2e, + 0xde, 0x61, 0x9d, 0x5d, 0x8a, 0x20, 0x05, 0x07, 0xa9, 0x83, 0xe0, 0x22, 0x97, 0xf6, 0x71, 0x39, + 0x4c, 0x7b, 0x21, 0x77, 0x35, 0xf6, 0xbf, 0xf0, 0xcf, 0xea, 0xd8, 0xd1, 0x49, 0x24, 0x59, 0xfd, + 0x23, 0x24, 0xb9, 0x53, 0x71, 0xb8, 0xed, 0x86, 0xcf, 0xfb, 0xe6, 0xe5, 0xf9, 0xa7, 0x8a, 0x03, + 0xcd, 0x80, 0xb3, 0xd9, 0x9a, 0xa6, 0x72, 0xa5, 0x80, 0xbe, 0x5c, 0x24, 0xa0, 0x19, 0xe5, 0xb0, + 0x04, 0x25, 0x14, 0xc9, 0x0b, 0xa9, 0x65, 0x78, 0xa8, 0x38, 0x10, 0xc3, 0x48, 0xcb, 0x88, 0x61, + 0xd1, 0x01, 0x97, 0x5c, 0xb6, 0x86, 0x36, 0x2f, 0xc3, 0x23, 0x67, 0x75, 0x0e, 0xb9, 0x54, 0x42, + 0x5b, 0x76, 0xe2, 0x62, 0x39, 0x2b, 0xd8, 0xc2, 0x7e, 0x3b, 0x3a, 0x73, 0xa9, 0x52, 0xe8, 0x74, + 0x5e, 0xb0, 0xd2, 0xb8, 0xa3, 0x2f, 0xe4, 0xf7, 0x6e, 0xcc, 0xd6, 0xf7, 0x9a, 0x69, 0x08, 0xaf, + 0xfc, 0xae, 0x09, 0xf5, 0x51, 0x8c, 0x86, 0xc1, 0x68, 0x40, 0x1c, 0x7f, 0x41, 0xee, 0x5a, 0x36, + 0xde, 0xdd, 0x7c, 0x0c, 0xbc, 0xa9, 0x1d, 0x0a, 0x27, 0x7e, 0xcf, 0xae, 0xfb, 0x94, 0x09, 0xa5, + 0xfb, 0x3b, 0x71, 0x67, 0x18, 0x8c, 0x62, 0x67, 0xe4, 0xda, 0x60, 0x5b, 0x09, 0xec, 0xec, 0xad, + 0x50, 0x3a, 0x9c, 0xfa, 0xfb, 0x3f, 0xcb, 0xb2, 0xcc, 0xd4, 0x3a, 0x6d, 0xed, 0xd8, 0x59, 0x7b, + 0xf8, 0xf5, 0x36, 0xb8, 0xf7, 0x57, 0x68, 0x9a, 0xe3, 0xc9, 0xa6, 0xc2, 0x68, 0x5b, 0x61, 0xf4, + 0x59, 0x61, 0xf4, 0x56, 0x63, 0x6f, 0x5b, 0x63, 0xef, 0xbd, 0xc6, 0xde, 0x23, 0xe5, 0x42, 0xa7, + 0xab, 0x84, 0xcc, 0xe4, 0x82, 0x2a, 0x0e, 0xe7, 0x4b, 0xd0, 0xa5, 0x2c, 0x9e, 0x9b, 0x37, 0x7d, + 0xfd, 0x7f, 0x49, 0xbd, 0xce, 0x41, 0x25, 0xdd, 0xf6, 0x80, 0x97, 0xdf, 0x01, 0x00, 0x00, 0xff, + 0xff, 0x76, 0xf9, 0x6f, 0x38, 0x0d, 0x02, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/keys.go b/x/legacy/house/types/keys.go similarity index 100% rename from x/house/types/keys.go rename to x/legacy/house/types/keys.go diff --git a/x/house/types/message_deposit.go b/x/legacy/house/types/message_deposit.go similarity index 100% rename from x/house/types/message_deposit.go rename to x/legacy/house/types/message_deposit.go diff --git a/x/house/types/message_withdraw.go b/x/legacy/house/types/message_withdraw.go similarity index 100% rename from x/house/types/message_withdraw.go rename to x/legacy/house/types/message_withdraw.go diff --git a/x/house/types/messages_params.go b/x/legacy/house/types/messages_params.go similarity index 100% rename from x/house/types/messages_params.go rename to x/legacy/house/types/messages_params.go diff --git a/x/house/types/params.go b/x/legacy/house/types/params.go similarity index 100% rename from x/house/types/params.go rename to x/legacy/house/types/params.go diff --git a/x/house/types/params.pb.go b/x/legacy/house/types/params.pb.go similarity index 79% rename from x/house/types/params.pb.go rename to x/legacy/house/types/params.pb.go index 377eb13d..5d1e3090 100644 --- a/x/house/types/params.pb.go +++ b/x/legacy/house/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/params.proto +// source: sge/legacy/house/v1beta/params.proto package types @@ -39,7 +39,7 @@ type Params struct { func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_a973c755b8200942, []int{0} + return fileDescriptor_00a11f824878d3c8, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -76,34 +76,37 @@ func (m *Params) GetMaxWithdrawalCount() uint64 { } func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.house.Params") + proto.RegisterType((*Params)(nil), "sge.legacy.house.v1beta.Params") } -func init() { proto.RegisterFile("sgenetwork/sge/house/params.proto", fileDescriptor_a973c755b8200942) } +func init() { + proto.RegisterFile("sge/legacy/house/v1beta/params.proto", fileDescriptor_00a11f824878d3c8) +} -var fileDescriptor_a973c755b8200942 = []byte{ - // 331 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x91, 0x41, 0x4b, 0x02, 0x41, - 0x14, 0xc7, 0x77, 0x4d, 0x84, 0xb6, 0xdb, 0xa2, 0x24, 0x09, 0xbb, 0xb6, 0x5d, 0xbc, 0xb4, 0x7b, - 0xf0, 0xe6, 0x71, 0x93, 0x20, 0xe8, 0x60, 0x12, 0x04, 0x75, 0x58, 0xc6, 0xf5, 0x35, 0x3b, 0xe8, - 0xcc, 0x1b, 0x76, 0x46, 0xd4, 0x6f, 0xd1, 0xa1, 0x43, 0xc7, 0x3e, 0x8e, 0x47, 0x8f, 0xd1, 0x61, - 0x09, 0xfd, 0x06, 0x7e, 0x82, 0x70, 0x94, 0x12, 0xea, 0x36, 0xf3, 0xf8, 0xbd, 0xf7, 0x7b, 0xbc, - 0xbf, 0x73, 0xae, 0x28, 0x08, 0xd0, 0x53, 0xcc, 0x47, 0x91, 0xa2, 0x10, 0x65, 0x38, 0x51, 0x10, - 0x49, 0x92, 0x13, 0xae, 0x42, 0x99, 0xa3, 0x46, 0xb7, 0xfa, 0x8b, 0x84, 0x8a, 0x42, 0x68, 0x90, - 0xb3, 0x2a, 0x45, 0x8a, 0x06, 0x88, 0xb6, 0xaf, 0x1d, 0x1b, 0xbc, 0x96, 0x9c, 0x4a, 0xcf, 0x34, - 0xbb, 0xf7, 0xce, 0x09, 0x67, 0x22, 0x19, 0x82, 0x44, 0xc5, 0x74, 0xdd, 0x6e, 0xda, 0xad, 0xe3, - 0xb8, 0xbd, 0x28, 0x7c, 0xeb, 0xb3, 0xf0, 0x6b, 0x29, 0x2a, 0x8e, 0x4a, 0x0d, 0x47, 0x21, 0xc3, - 0x88, 0x13, 0x9d, 0x85, 0x37, 0x42, 0x6f, 0x0a, 0xdf, 0x9d, 0x13, 0x3e, 0xee, 0x04, 0x07, 0x9d, - 0x41, 0xdf, 0xe1, 0x4c, 0x74, 0x77, 0x1f, 0xf7, 0xc9, 0x39, 0x35, 0xfe, 0x44, 0x92, 0x5c, 0xb3, - 0x94, 0x49, 0xa2, 0x19, 0x8a, 0xe4, 0x19, 0xa0, 0x5e, 0x32, 0x86, 0x8b, 0xbd, 0xa1, 0xf1, 0xd7, - 0x70, 0x0b, 0x94, 0xa4, 0xf3, 0x2e, 0xa4, 0xfd, 0x9a, 0x99, 0xd1, 0x3b, 0x1c, 0x71, 0x0d, 0xe0, - 0xde, 0x39, 0x55, 0x4e, 0x66, 0xc9, 0x94, 0xe9, 0x6c, 0x98, 0x93, 0x29, 0x19, 0x27, 0x29, 0x4e, - 0x84, 0xae, 0x1f, 0x35, 0xed, 0x56, 0x39, 0xf6, 0x37, 0x85, 0xdf, 0xd8, 0xaf, 0xf7, 0x0f, 0x15, - 0xf4, 0x5d, 0x4e, 0x66, 0x0f, 0x3f, 0xd5, 0xab, 0x6d, 0xb1, 0x53, 0x7e, 0x7b, 0xf7, 0xad, 0x38, - 0x5e, 0xac, 0x3c, 0x7b, 0xb9, 0xf2, 0xec, 0xaf, 0x95, 0x67, 0xbf, 0xac, 0x3d, 0x6b, 0xb9, 0xf6, - 0xac, 0x8f, 0xb5, 0x67, 0x3d, 0xb6, 0x28, 0xd3, 0xd9, 0x64, 0x10, 0xa6, 0xc8, 0xb7, 0xf7, 0xbf, - 0x3c, 0xcc, 0x62, 0xb6, 0x4f, 0x43, 0xcf, 0x25, 0xa8, 0x41, 0xc5, 0x5c, 0xb8, 0xfd, 0x1d, 0x00, - 0x00, 0xff, 0xff, 0x38, 0xab, 0xc1, 0xbc, 0xb2, 0x01, 0x00, 0x00, +var fileDescriptor_00a11f824878d3c8 = []byte{ + // 341 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x91, 0x4d, 0x4b, 0x02, 0x41, + 0x18, 0xc7, 0x77, 0x4d, 0x84, 0xb6, 0xdb, 0xa2, 0x28, 0x09, 0xbb, 0xb2, 0x75, 0xf0, 0xd2, 0x0e, + 0xe1, 0xcd, 0xa3, 0x49, 0x20, 0x74, 0x30, 0x09, 0x82, 0x3a, 0x2c, 0xe3, 0xfa, 0x34, 0x3b, 0xe8, + 0xec, 0xb3, 0xec, 0x8c, 0xa9, 0xdf, 0xa2, 0x43, 0x87, 0x8e, 0x7d, 0x1c, 0x8f, 0x1e, 0xa3, 0xc3, + 0x12, 0xfa, 0x0d, 0xfc, 0x04, 0xe1, 0xac, 0x84, 0x51, 0xb7, 0x67, 0x1e, 0x7e, 0xff, 0x97, 0x99, + 0xb1, 0xce, 0x25, 0x03, 0x32, 0x01, 0x46, 0xc3, 0x05, 0x89, 0x70, 0x2a, 0x81, 0x3c, 0x5f, 0x0e, + 0x41, 0x51, 0x92, 0xd0, 0x94, 0x0a, 0xe9, 0x27, 0x29, 0x2a, 0xb4, 0xab, 0x92, 0x81, 0x9f, 0x53, + 0xbe, 0xa6, 0xfc, 0x9c, 0x3a, 0x2d, 0x33, 0x64, 0xa8, 0x19, 0xb2, 0x9b, 0x72, 0xdc, 0x7b, 0x2d, + 0x58, 0xa5, 0xbe, 0xd6, 0xdb, 0x77, 0xd6, 0x89, 0xe0, 0x71, 0x30, 0x82, 0x04, 0x25, 0x57, 0x35, + 0xb3, 0x61, 0x36, 0x8f, 0x3b, 0xad, 0x65, 0xe6, 0x1a, 0x9f, 0x99, 0x5b, 0x09, 0x51, 0x0a, 0x94, + 0x72, 0x34, 0xf6, 0x39, 0x12, 0x41, 0x55, 0xe4, 0xf7, 0x62, 0xb5, 0xcd, 0x5c, 0x7b, 0x41, 0xc5, + 0xa4, 0xed, 0x1d, 0x28, 0xbd, 0x81, 0x25, 0x78, 0xdc, 0xcd, 0x0f, 0xf6, 0xa3, 0x55, 0xd5, 0x35, + 0x82, 0x84, 0xa6, 0x8a, 0x87, 0x3c, 0xa1, 0x8a, 0x63, 0x1c, 0x3c, 0x01, 0xd4, 0x0a, 0x3a, 0xe1, + 0x6c, 0x9f, 0x50, 0xff, 0x9b, 0x70, 0xa3, 0xaf, 0xd1, 0x85, 0x70, 0x50, 0xd1, 0x1e, 0xfd, 0x43, + 0x8b, 0x6b, 0x00, 0xfb, 0xd6, 0x2a, 0x0b, 0x3a, 0x0f, 0x66, 0x5c, 0x45, 0xa3, 0x94, 0xce, 0xe8, + 0x24, 0x08, 0x71, 0x1a, 0xab, 0xda, 0x51, 0xc3, 0x6c, 0x16, 0x3b, 0xee, 0x36, 0x73, 0xeb, 0xfb, + 0x7a, 0xff, 0x50, 0xde, 0xc0, 0x16, 0x74, 0x7e, 0xff, 0xb3, 0xbd, 0xda, 0x2d, 0xdb, 0xc5, 0xb7, + 0x77, 0xd7, 0xe8, 0xf4, 0x96, 0x6b, 0xc7, 0x5c, 0xad, 0x1d, 0xf3, 0x6b, 0xed, 0x98, 0x2f, 0x1b, + 0xc7, 0x58, 0x6d, 0x1c, 0xe3, 0x63, 0xe3, 0x18, 0x0f, 0x84, 0x71, 0x15, 0x4d, 0x87, 0x7e, 0x88, + 0x82, 0x48, 0x06, 0x17, 0x31, 0xa8, 0x19, 0xa6, 0xe3, 0xdd, 0x4c, 0xe6, 0xbf, 0xbf, 0x47, 0x2d, + 0x12, 0x90, 0xc3, 0x92, 0x7e, 0xe8, 0xd6, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0xc0, 0x42, 0xbb, + 0xb7, 0xbf, 0x01, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/query.pb.go b/x/legacy/house/types/query.pb.go similarity index 89% rename from x/house/types/query.pb.go rename to x/legacy/house/types/query.pb.go index 021def20..5c7aba85 100644 --- a/x/house/types/query.pb.go +++ b/x/legacy/house/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/query.proto +// source: sge/legacy/house/v1beta/query.proto package types @@ -40,7 +40,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{0} + return fileDescriptor_2890fb86d65c6b59, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -80,7 +80,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{1} + return fileDescriptor_2890fb86d65c6b59, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -126,7 +126,7 @@ func (m *QueryDepositsRequest) Reset() { *m = QueryDepositsRequest{} } func (m *QueryDepositsRequest) String() string { return proto.CompactTextString(m) } func (*QueryDepositsRequest) ProtoMessage() {} func (*QueryDepositsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{2} + return fileDescriptor_2890fb86d65c6b59, []int{2} } func (m *QueryDepositsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -174,7 +174,7 @@ func (m *QueryDepositsResponse) Reset() { *m = QueryDepositsResponse{} } func (m *QueryDepositsResponse) String() string { return proto.CompactTextString(m) } func (*QueryDepositsResponse) ProtoMessage() {} func (*QueryDepositsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{3} + return fileDescriptor_2890fb86d65c6b59, []int{3} } func (m *QueryDepositsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -231,7 +231,7 @@ func (m *QueryDepositsByAccountRequest) Reset() { *m = QueryDepositsByAc func (m *QueryDepositsByAccountRequest) String() string { return proto.CompactTextString(m) } func (*QueryDepositsByAccountRequest) ProtoMessage() {} func (*QueryDepositsByAccountRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{4} + return fileDescriptor_2890fb86d65c6b59, []int{4} } func (m *QueryDepositsByAccountRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -287,7 +287,7 @@ func (m *QueryDepositsByAccountResponse) Reset() { *m = QueryDepositsByA func (m *QueryDepositsByAccountResponse) String() string { return proto.CompactTextString(m) } func (*QueryDepositsByAccountResponse) ProtoMessage() {} func (*QueryDepositsByAccountResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{5} + return fileDescriptor_2890fb86d65c6b59, []int{5} } func (m *QueryDepositsByAccountResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -344,7 +344,7 @@ func (m *QueryWithdrawalsByAccountRequest) Reset() { *m = QueryWithdrawa func (m *QueryWithdrawalsByAccountRequest) String() string { return proto.CompactTextString(m) } func (*QueryWithdrawalsByAccountRequest) ProtoMessage() {} func (*QueryWithdrawalsByAccountRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{6} + return fileDescriptor_2890fb86d65c6b59, []int{6} } func (m *QueryWithdrawalsByAccountRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -400,7 +400,7 @@ func (m *QueryWithdrawalsByAccountResponse) Reset() { *m = QueryWithdraw func (m *QueryWithdrawalsByAccountResponse) String() string { return proto.CompactTextString(m) } func (*QueryWithdrawalsByAccountResponse) ProtoMessage() {} func (*QueryWithdrawalsByAccountResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{7} + return fileDescriptor_2890fb86d65c6b59, []int{7} } func (m *QueryWithdrawalsByAccountResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -459,7 +459,7 @@ func (m *QueryWithdrawalRequest) Reset() { *m = QueryWithdrawalRequest{} func (m *QueryWithdrawalRequest) String() string { return proto.CompactTextString(m) } func (*QueryWithdrawalRequest) ProtoMessage() {} func (*QueryWithdrawalRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{8} + return fileDescriptor_2890fb86d65c6b59, []int{8} } func (m *QueryWithdrawalRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -527,7 +527,7 @@ func (m *QueryWithdrawalResponse) Reset() { *m = QueryWithdrawalResponse func (m *QueryWithdrawalResponse) String() string { return proto.CompactTextString(m) } func (*QueryWithdrawalResponse) ProtoMessage() {} func (*QueryWithdrawalResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_5ca530dfff23b318, []int{9} + return fileDescriptor_2890fb86d65c6b59, []int{9} } func (m *QueryWithdrawalResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -564,71 +564,74 @@ func (m *QueryWithdrawalResponse) GetWithdrawal() Withdrawal { } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.house.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.house.QueryParamsResponse") - proto.RegisterType((*QueryDepositsRequest)(nil), "sgenetwork.sge.house.QueryDepositsRequest") - proto.RegisterType((*QueryDepositsResponse)(nil), "sgenetwork.sge.house.QueryDepositsResponse") - proto.RegisterType((*QueryDepositsByAccountRequest)(nil), "sgenetwork.sge.house.QueryDepositsByAccountRequest") - proto.RegisterType((*QueryDepositsByAccountResponse)(nil), "sgenetwork.sge.house.QueryDepositsByAccountResponse") - proto.RegisterType((*QueryWithdrawalsByAccountRequest)(nil), "sgenetwork.sge.house.QueryWithdrawalsByAccountRequest") - proto.RegisterType((*QueryWithdrawalsByAccountResponse)(nil), "sgenetwork.sge.house.QueryWithdrawalsByAccountResponse") - proto.RegisterType((*QueryWithdrawalRequest)(nil), "sgenetwork.sge.house.QueryWithdrawalRequest") - proto.RegisterType((*QueryWithdrawalResponse)(nil), "sgenetwork.sge.house.QueryWithdrawalResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/house/query.proto", fileDescriptor_5ca530dfff23b318) } - -var fileDescriptor_5ca530dfff23b318 = []byte{ - // 781 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x96, 0x4d, 0x6f, 0xd3, 0x48, - 0x18, 0x80, 0x33, 0x69, 0x37, 0xdb, 0xbe, 0x95, 0x56, 0xdb, 0x49, 0xba, 0x9b, 0x66, 0x9b, 0x34, - 0xf5, 0x6a, 0x77, 0xb3, 0xdd, 0xad, 0xad, 0xa6, 0x08, 0x24, 0x2e, 0xa8, 0x11, 0x14, 0x10, 0x42, - 0x6a, 0x53, 0x21, 0x24, 0x0e, 0x44, 0x93, 0x78, 0xe4, 0x8e, 0xda, 0x78, 0x5c, 0xdb, 0x21, 0xad, - 0xa2, 0x48, 0xc0, 0x2f, 0x40, 0xe2, 0x8e, 0xd4, 0x03, 0x17, 0x6e, 0x48, 0x88, 0x23, 0x5c, 0x7b, - 0xac, 0xe0, 0xc2, 0x09, 0xa1, 0x96, 0x1f, 0x82, 0x32, 0x33, 0xae, 0xf3, 0x61, 0x42, 0x8a, 0x7a, - 0xe0, 0x96, 0xcc, 0xfb, 0xf5, 0xf8, 0xb1, 0x67, 0x6c, 0xc8, 0x7b, 0x16, 0xb5, 0xa9, 0xdf, 0xe4, - 0xee, 0xb6, 0xe1, 0x59, 0xd4, 0xd8, 0xe2, 0x0d, 0x8f, 0x1a, 0xbb, 0x0d, 0xea, 0xee, 0xeb, 0x8e, - 0xcb, 0x7d, 0x8e, 0x53, 0x61, 0x86, 0xee, 0x59, 0x54, 0x17, 0x19, 0x99, 0xc5, 0x1a, 0xf7, 0xea, - 0xdc, 0x33, 0xaa, 0x24, 0x48, 0x37, 0x1e, 0x2c, 0x57, 0xa9, 0x4f, 0x96, 0x0d, 0x87, 0x58, 0xcc, - 0x26, 0x3e, 0xe3, 0xb6, 0xec, 0x90, 0x49, 0x59, 0xdc, 0xe2, 0xe2, 0xa7, 0xd1, 0xf9, 0xa5, 0x56, - 0x67, 0x65, 0x87, 0x8a, 0x0c, 0xc8, 0x3f, 0x2a, 0x34, 0x67, 0x71, 0x6e, 0xed, 0x50, 0x83, 0x38, - 0xcc, 0x20, 0xb6, 0xcd, 0x7d, 0xd1, 0x2d, 0x88, 0x2e, 0x44, 0x22, 0x3b, 0xc4, 0x25, 0xf5, 0x20, - 0x45, 0x8b, 0x4c, 0x31, 0xa9, 0xc3, 0x3d, 0xe6, 0xab, 0x9c, 0x3f, 0x23, 0x73, 0x9a, 0xcc, 0xdf, - 0x32, 0x5d, 0xd2, 0x94, 0x49, 0x5a, 0x0a, 0xf0, 0x46, 0xe7, 0xe2, 0xd6, 0x45, 0xf7, 0x32, 0xdd, - 0x6d, 0x50, 0xcf, 0xd7, 0x36, 0x20, 0xd9, 0xb3, 0xea, 0x39, 0xdc, 0xf6, 0x28, 0xbe, 0x0c, 0x09, - 0x49, 0x91, 0x46, 0x79, 0x54, 0x98, 0x2a, 0xce, 0xe9, 0x51, 0xea, 0x74, 0x59, 0x55, 0x1a, 0x3f, - 0xfc, 0x38, 0x1f, 0x2b, 0xab, 0x0a, 0xed, 0x3e, 0xa4, 0x44, 0xcb, 0xab, 0x92, 0x31, 0x18, 0x85, - 0xd7, 0x00, 0x42, 0x9f, 0xaa, 0xef, 0xdf, 0xba, 0xb2, 0xd5, 0x91, 0xaf, 0xcb, 0x7b, 0xa5, 0xe4, - 0xeb, 0xeb, 0xc4, 0xa2, 0xaa, 0xb6, 0xdc, 0x55, 0xa9, 0x1d, 0x20, 0x98, 0xe9, 0x1b, 0xa0, 0xa8, - 0xaf, 0xc0, 0x84, 0x12, 0xd3, 0xe1, 0x1e, 0x2b, 0x4c, 0x15, 0xb3, 0xd1, 0xdc, 0xaa, 0x52, 0x81, - 0x9f, 0x16, 0xe1, 0xeb, 0x3d, 0x88, 0x71, 0x81, 0xf8, 0xcf, 0x37, 0x11, 0xe5, 0xf4, 0x1e, 0xc6, - 0x47, 0x08, 0xb2, 0x3d, 0x8c, 0xa5, 0xfd, 0xd5, 0x5a, 0x8d, 0x37, 0x6c, 0x3f, 0xb0, 0x91, 0x86, - 0x9f, 0x89, 0x69, 0xba, 0xd4, 0x93, 0x8a, 0x27, 0xcb, 0xc1, 0xdf, 0x3e, 0x4f, 0xf1, 0xef, 0xf6, - 0xf4, 0x02, 0x41, 0xee, 0x6b, 0x0c, 0x3f, 0x9c, 0xb0, 0x67, 0x08, 0xf2, 0x02, 0xf6, 0xae, 0x7a, - 0x6a, 0xc9, 0xce, 0xa0, 0xb3, 0x62, 0x9f, 0xb3, 0x52, 0xfa, 0xdd, 0xab, 0xa5, 0x94, 0x9a, 0xb6, - 0x2a, 0x23, 0x9b, 0xbe, 0xcb, 0x6c, 0xeb, 0xfc, 0x6d, 0xbe, 0x46, 0xb0, 0x30, 0x04, 0x50, 0x09, - 0xbd, 0x01, 0x53, 0xcd, 0x30, 0xae, 0x9c, 0xe6, 0xa3, 0x9d, 0x86, 0x8d, 0x94, 0xd6, 0xee, 0xd2, - 0xf3, 0x33, 0xfb, 0x16, 0xc1, 0x6f, 0x7d, 0xe0, 0x81, 0xcf, 0x6b, 0x30, 0xad, 0xee, 0x24, 0x77, - 0x2b, 0xa3, 0x9a, 0xfd, 0xf5, 0xb4, 0x44, 0xad, 0xe3, 0x2c, 0x40, 0x9d, 0xb8, 0xdb, 0xd4, 0xaf, - 0x34, 0x98, 0x29, 0x50, 0x27, 0xcb, 0x93, 0x72, 0xe5, 0x0e, 0x33, 0xb1, 0x01, 0x49, 0x87, 0xb8, - 0x3e, 0xab, 0x31, 0x47, 0x10, 0x55, 0x98, 0x6d, 0xd2, 0xbd, 0xf4, 0x58, 0x1e, 0x15, 0xc6, 0xcb, - 0xb8, 0x27, 0x74, 0xb3, 0x13, 0xc1, 0xbf, 0x40, 0x9c, 0x99, 0xe9, 0x71, 0x11, 0x8f, 0x33, 0x53, - 0x23, 0xf0, 0xfb, 0xc0, 0x05, 0x28, 0xdf, 0x6b, 0x00, 0xa1, 0x34, 0x75, 0xa6, 0x8c, 0xaa, 0xbb, - 0xab, 0xb2, 0x78, 0x90, 0x80, 0x9f, 0xc4, 0x0c, 0xbc, 0x07, 0x09, 0x79, 0xaa, 0xe1, 0x42, 0x74, - 0x9f, 0xc1, 0x43, 0x34, 0xf3, 0xef, 0x08, 0x99, 0x12, 0x58, 0x9b, 0x7d, 0xfc, 0xfe, 0xf3, 0xd3, - 0x78, 0x12, 0x4f, 0x0f, 0x9c, 0xf7, 0xf8, 0x21, 0x82, 0x89, 0x60, 0xab, 0xe2, 0xc5, 0x21, 0x2d, - 0xfb, 0x0e, 0xd6, 0xcc, 0x7f, 0x23, 0xe5, 0x2a, 0x80, 0x3f, 0x04, 0xc0, 0x0c, 0x4e, 0x0e, 0xbe, - 0x4d, 0x3c, 0xfc, 0x1c, 0xc1, 0xf4, 0xc0, 0x69, 0x81, 0x57, 0x46, 0xe8, 0xdf, 0xbf, 0x57, 0x33, - 0x17, 0xce, 0x56, 0xa4, 0xe8, 0xfe, 0x12, 0x74, 0xf3, 0x38, 0x1b, 0x41, 0x67, 0xb4, 0xd4, 0x23, - 0xda, 0xc6, 0x2f, 0x11, 0xa4, 0xa2, 0xf6, 0x21, 0xbe, 0x38, 0x64, 0xea, 0x90, 0x93, 0x25, 0x73, - 0xe9, 0xcc, 0x75, 0x0a, 0xb8, 0x20, 0x80, 0x35, 0x9c, 0x8f, 0x78, 0xf1, 0x92, 0x9d, 0x6e, 0xe6, - 0x37, 0x08, 0x20, 0x6c, 0x85, 0xff, 0x1f, 0x69, 0x62, 0xc0, 0xb7, 0x34, 0x62, 0xb6, 0xa2, 0xda, - 0x14, 0x54, 0xb7, 0xf1, 0x2d, 0x41, 0x15, 0xf2, 0x18, 0xad, 0x81, 0xfd, 0xde, 0x36, 0x5a, 0xe1, - 0xe6, 0x6d, 0x1b, 0xad, 0x88, 0xad, 0xda, 0x36, 0x5a, 0xcc, 0x6c, 0x97, 0x4a, 0x87, 0xc7, 0x39, - 0x74, 0x74, 0x9c, 0x43, 0x9f, 0x8e, 0x73, 0xe8, 0xc9, 0x49, 0x2e, 0x76, 0x74, 0x92, 0x8b, 0x7d, - 0x38, 0xc9, 0xc5, 0xee, 0x15, 0x2c, 0xe6, 0x6f, 0x35, 0xaa, 0x7a, 0x8d, 0xd7, 0x3b, 0x03, 0x97, - 0xba, 0xbf, 0x45, 0xf6, 0x94, 0x14, 0x7f, 0xdf, 0xa1, 0x5e, 0x35, 0x21, 0xbe, 0x45, 0x56, 0xbe, - 0x04, 0x00, 0x00, 0xff, 0xff, 0xe8, 0x3c, 0xb0, 0x73, 0xac, 0x09, 0x00, 0x00, + proto.RegisterType((*QueryParamsRequest)(nil), "sge.legacy.house.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.legacy.house.v1beta.QueryParamsResponse") + proto.RegisterType((*QueryDepositsRequest)(nil), "sge.legacy.house.v1beta.QueryDepositsRequest") + proto.RegisterType((*QueryDepositsResponse)(nil), "sge.legacy.house.v1beta.QueryDepositsResponse") + proto.RegisterType((*QueryDepositsByAccountRequest)(nil), "sge.legacy.house.v1beta.QueryDepositsByAccountRequest") + proto.RegisterType((*QueryDepositsByAccountResponse)(nil), "sge.legacy.house.v1beta.QueryDepositsByAccountResponse") + proto.RegisterType((*QueryWithdrawalsByAccountRequest)(nil), "sge.legacy.house.v1beta.QueryWithdrawalsByAccountRequest") + proto.RegisterType((*QueryWithdrawalsByAccountResponse)(nil), "sge.legacy.house.v1beta.QueryWithdrawalsByAccountResponse") + proto.RegisterType((*QueryWithdrawalRequest)(nil), "sge.legacy.house.v1beta.QueryWithdrawalRequest") + proto.RegisterType((*QueryWithdrawalResponse)(nil), "sge.legacy.house.v1beta.QueryWithdrawalResponse") +} + +func init() { + proto.RegisterFile("sge/legacy/house/v1beta/query.proto", fileDescriptor_2890fb86d65c6b59) +} + +var fileDescriptor_2890fb86d65c6b59 = []byte{ + // 797 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x96, 0xcf, 0x6b, 0x13, 0x5b, + 0x14, 0xc7, 0x73, 0xd3, 0xbe, 0xbc, 0xf6, 0x14, 0x1e, 0xaf, 0x37, 0xe9, 0x6b, 0x9a, 0x67, 0xd3, + 0x98, 0xda, 0x1a, 0xd4, 0xce, 0xb5, 0x11, 0x14, 0x05, 0x17, 0x0d, 0xfe, 0xa0, 0x14, 0xa1, 0xa6, + 0x8a, 0xe0, 0xc2, 0x30, 0xc9, 0x5c, 0xa6, 0x97, 0x36, 0x73, 0xa7, 0x33, 0x13, 0xd3, 0x10, 0x22, + 0xe8, 0xc2, 0xb5, 0xe0, 0xde, 0x95, 0x3b, 0x71, 0x27, 0x88, 0xab, 0x6e, 0x5c, 0x74, 0x59, 0x74, + 0xe3, 0x4a, 0xa4, 0xf5, 0x0f, 0x91, 0xdc, 0x7b, 0xa7, 0xf9, 0xd5, 0x89, 0x69, 0xe9, 0xc2, 0x5d, + 0xe6, 0x9e, 0xf3, 0x3d, 0xe7, 0x33, 0xdf, 0x9b, 0x73, 0x18, 0x98, 0x75, 0x4d, 0x4a, 0x36, 0xa9, + 0xa9, 0x97, 0x6a, 0x64, 0x9d, 0x57, 0x5c, 0x4a, 0x9e, 0x2e, 0x16, 0xa9, 0xa7, 0x93, 0xad, 0x0a, + 0x75, 0x6a, 0x9a, 0xed, 0x70, 0x8f, 0xe3, 0x49, 0xd7, 0xa4, 0x9a, 0x4c, 0xd2, 0x44, 0x92, 0x26, + 0x93, 0x12, 0x17, 0x4a, 0xdc, 0x2d, 0x73, 0x97, 0x14, 0x75, 0x97, 0x4a, 0x85, 0x92, 0x2f, 0x12, + 0x5b, 0x37, 0x99, 0xa5, 0x7b, 0x8c, 0x5b, 0xb2, 0x48, 0x62, 0x4a, 0xe6, 0x16, 0xc4, 0x13, 0x91, + 0x0f, 0x2a, 0x14, 0x33, 0xb9, 0xc9, 0xe5, 0x79, 0xf3, 0x97, 0x3a, 0x3d, 0x63, 0x72, 0x6e, 0x6e, + 0x52, 0xa2, 0xdb, 0x8c, 0xe8, 0x96, 0xc5, 0x3d, 0x51, 0xcd, 0xd7, 0xcc, 0x05, 0x81, 0x1b, 0xd4, + 0xe6, 0x2e, 0xf3, 0x54, 0xda, 0xb9, 0xa0, 0x34, 0x5b, 0x77, 0xf4, 0xb2, 0x5f, 0x6c, 0x3e, 0x28, + 0xab, 0xca, 0xbc, 0x75, 0xc3, 0xd1, 0xab, 0x32, 0x2f, 0x1d, 0x03, 0x7c, 0xbf, 0xf9, 0x96, 0xab, + 0x42, 0x9c, 0xa7, 0x5b, 0x15, 0xea, 0x7a, 0xe9, 0x07, 0x10, 0xed, 0x38, 0x75, 0x6d, 0x6e, 0xb9, + 0x14, 0xdf, 0x84, 0x88, 0x6c, 0x12, 0x47, 0x29, 0x94, 0x19, 0xcb, 0xce, 0x68, 0x01, 0x36, 0x6a, + 0x52, 0x98, 0x1b, 0xde, 0xfd, 0x3e, 0x13, 0xca, 0x2b, 0x51, 0xfa, 0x09, 0xc4, 0x44, 0xd5, 0x5b, + 0xf2, 0x7d, 0xfc, 0x6e, 0xf8, 0x0e, 0x40, 0xcb, 0x5b, 0x55, 0x7a, 0x5e, 0x53, 0x7e, 0x36, 0x2f, + 0x42, 0x93, 0x57, 0xa7, 0x2e, 0x42, 0x5b, 0xd5, 0x4d, 0xaa, 0xb4, 0xf9, 0x36, 0x65, 0xfa, 0x2d, + 0x82, 0x89, 0xae, 0x06, 0x0a, 0x3c, 0x07, 0x23, 0xca, 0xc4, 0x26, 0xfa, 0x50, 0x66, 0x2c, 0x9b, + 0x0a, 0x44, 0x57, 0x62, 0xc5, 0x7e, 0xa8, 0xc3, 0x77, 0x3b, 0x28, 0xc3, 0x82, 0xf2, 0xfc, 0x6f, + 0x29, 0x25, 0x40, 0x07, 0xe6, 0x73, 0x04, 0xd3, 0x1d, 0x98, 0xb9, 0xda, 0x52, 0xa9, 0xc4, 0x2b, + 0x96, 0xe7, 0x1b, 0x12, 0x87, 0xbf, 0x75, 0xc3, 0x70, 0xa8, 0x2b, 0x8d, 0x1e, 0xcd, 0xfb, 0x8f, + 0x5d, 0x56, 0x85, 0x4f, 0x6c, 0xd5, 0x7b, 0x04, 0xc9, 0x20, 0x86, 0x3f, 0xd1, 0xb3, 0x37, 0x08, + 0x52, 0x82, 0xf7, 0x91, 0xfa, 0xfb, 0xea, 0x9b, 0xbd, 0xb6, 0x65, 0xbb, 0x6c, 0xcb, 0xc5, 0xbf, + 0x7c, 0x58, 0x88, 0xa9, 0x6e, 0x4b, 0x32, 0xb2, 0xe6, 0x39, 0xcc, 0x32, 0x4f, 0xdf, 0xd0, 0x4f, + 0x08, 0xce, 0xf6, 0x01, 0x54, 0x9e, 0xae, 0xc0, 0x58, 0xb5, 0x15, 0x57, 0xb6, 0xce, 0x06, 0xda, + 0xda, 0xaa, 0xa5, 0x9c, 0x6d, 0x57, 0x9f, 0x9e, 0xb9, 0x3b, 0x08, 0xfe, 0xeb, 0x62, 0xf7, 0x2d, + 0xbd, 0x0d, 0xe3, 0xea, 0x32, 0xb9, 0x53, 0x18, 0xd4, 0xdc, 0x7f, 0x0f, 0x25, 0xea, 0x1c, 0x4f, + 0x03, 0x94, 0x75, 0x67, 0x83, 0x7a, 0x85, 0x0a, 0x33, 0x04, 0xea, 0x68, 0x7e, 0x54, 0x9e, 0x3c, + 0x64, 0x06, 0x26, 0x10, 0xb5, 0x75, 0xc7, 0x63, 0x25, 0x66, 0x0b, 0xa2, 0x02, 0xb3, 0x0c, 0xba, + 0x1d, 0x1f, 0x4a, 0xa1, 0xcc, 0x70, 0x1e, 0x77, 0x84, 0x96, 0x9b, 0x11, 0xfc, 0x0f, 0x84, 0x99, + 0x11, 0x1f, 0x16, 0xf1, 0x30, 0x33, 0xd2, 0x06, 0x4c, 0xf6, 0xbc, 0x80, 0xb2, 0x7c, 0x19, 0xa0, + 0x65, 0x9a, 0x5a, 0x2e, 0xc7, 0x70, 0xbc, 0x4d, 0x9c, 0xdd, 0x89, 0xc0, 0x5f, 0xa2, 0x0d, 0x7e, + 0x06, 0x11, 0xb9, 0xe1, 0xf0, 0xc5, 0xc0, 0x52, 0xbd, 0x6b, 0x35, 0x71, 0x69, 0xb0, 0x64, 0x49, + 0x9e, 0x9e, 0x7a, 0xf1, 0xf5, 0xe7, 0xeb, 0x70, 0x14, 0x8f, 0x93, 0xe6, 0x2e, 0x97, 0x4b, 0x5c, + 0x6e, 0x52, 0xfc, 0x12, 0xc1, 0x88, 0x3f, 0xb9, 0x78, 0xa1, 0x7f, 0xd5, 0xae, 0x6d, 0x9b, 0xd0, + 0x06, 0x4d, 0x57, 0x18, 0xff, 0x0b, 0x8c, 0x09, 0x1c, 0x6d, 0xc3, 0x38, 0x1c, 0xf0, 0x77, 0x08, + 0xc6, 0x7b, 0x56, 0x08, 0xbe, 0x3a, 0x58, 0x8b, 0xee, 0x01, 0x4e, 0x5c, 0x3b, 0xb6, 0x4e, 0x31, + 0xce, 0x09, 0xc6, 0x19, 0x3c, 0x7d, 0x04, 0x23, 0xa9, 0xab, 0xff, 0x6d, 0x03, 0x7f, 0x44, 0x10, + 0x3b, 0x6a, 0x3e, 0xf1, 0xf5, 0xfe, 0x8d, 0xfb, 0x2c, 0x9d, 0xc4, 0x8d, 0x93, 0x48, 0x15, 0x76, + 0x46, 0x60, 0xa7, 0x71, 0xaa, 0x0d, 0xbb, 0x6d, 0xc2, 0xdb, 0xc8, 0x3f, 0x23, 0x80, 0x56, 0x29, + 0x4c, 0x06, 0x6d, 0xea, 0x53, 0x5e, 0x1e, 0x5c, 0xa0, 0xd8, 0xd6, 0x04, 0xdb, 0x3d, 0xbc, 0x22, + 0xd8, 0x5a, 0x54, 0xa4, 0xde, 0xb3, 0x10, 0x1a, 0xa4, 0xde, 0x9a, 0xee, 0x06, 0xa9, 0x1f, 0x31, + 0xcb, 0x0d, 0x52, 0x67, 0x46, 0x23, 0xb7, 0xbc, 0xbb, 0x9f, 0x44, 0x7b, 0xfb, 0x49, 0xf4, 0x63, + 0x3f, 0x89, 0x5e, 0x1d, 0x24, 0x43, 0x7b, 0x07, 0xc9, 0xd0, 0xb7, 0x83, 0x64, 0xe8, 0x31, 0x31, + 0x99, 0xb7, 0x5e, 0x29, 0x6a, 0x25, 0x5e, 0x6e, 0x36, 0x5c, 0xb0, 0xa8, 0x57, 0xe5, 0xce, 0x86, + 0x68, 0xbe, 0xdd, 0xf9, 0x21, 0xe3, 0xd5, 0x6c, 0xea, 0x16, 0x23, 0xe2, 0xfb, 0xe5, 0xca, 0xaf, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xce, 0xec, 0xee, 0xbc, 0xef, 0x09, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -665,7 +668,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -674,7 +677,7 @@ func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts . func (c *queryClient) Deposits(ctx context.Context, in *QueryDepositsRequest, opts ...grpc.CallOption) (*QueryDepositsResponse, error) { out := new(QueryDepositsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Query/Deposits", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Query/Deposits", in, out, opts...) if err != nil { return nil, err } @@ -683,7 +686,7 @@ func (c *queryClient) Deposits(ctx context.Context, in *QueryDepositsRequest, op func (c *queryClient) DepositsByAccount(ctx context.Context, in *QueryDepositsByAccountRequest, opts ...grpc.CallOption) (*QueryDepositsByAccountResponse, error) { out := new(QueryDepositsByAccountResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Query/DepositsByAccount", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Query/DepositsByAccount", in, out, opts...) if err != nil { return nil, err } @@ -692,7 +695,7 @@ func (c *queryClient) DepositsByAccount(ctx context.Context, in *QueryDepositsBy func (c *queryClient) WithdrawalsByAccount(ctx context.Context, in *QueryWithdrawalsByAccountRequest, opts ...grpc.CallOption) (*QueryWithdrawalsByAccountResponse, error) { out := new(QueryWithdrawalsByAccountResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Query/WithdrawalsByAccount", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Query/WithdrawalsByAccount", in, out, opts...) if err != nil { return nil, err } @@ -701,7 +704,7 @@ func (c *queryClient) WithdrawalsByAccount(ctx context.Context, in *QueryWithdra func (c *queryClient) Withdrawal(ctx context.Context, in *QueryWithdrawalRequest, opts ...grpc.CallOption) (*QueryWithdrawalResponse, error) { out := new(QueryWithdrawalResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Query/Withdrawal", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Query/Withdrawal", in, out, opts...) if err != nil { return nil, err } @@ -756,7 +759,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Query/Params", + FullMethod: "/sge.legacy.house.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -774,7 +777,7 @@ func _Query_Deposits_Handler(srv interface{}, ctx context.Context, dec func(inte } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Query/Deposits", + FullMethod: "/sge.legacy.house.v1beta.Query/Deposits", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Deposits(ctx, req.(*QueryDepositsRequest)) @@ -792,7 +795,7 @@ func _Query_DepositsByAccount_Handler(srv interface{}, ctx context.Context, dec } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Query/DepositsByAccount", + FullMethod: "/sge.legacy.house.v1beta.Query/DepositsByAccount", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).DepositsByAccount(ctx, req.(*QueryDepositsByAccountRequest)) @@ -810,7 +813,7 @@ func _Query_WithdrawalsByAccount_Handler(srv interface{}, ctx context.Context, d } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Query/WithdrawalsByAccount", + FullMethod: "/sge.legacy.house.v1beta.Query/WithdrawalsByAccount", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).WithdrawalsByAccount(ctx, req.(*QueryWithdrawalsByAccountRequest)) @@ -828,7 +831,7 @@ func _Query_Withdrawal_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Query/Withdrawal", + FullMethod: "/sge.legacy.house.v1beta.Query/Withdrawal", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Withdrawal(ctx, req.(*QueryWithdrawalRequest)) @@ -836,8 +839,9 @@ func _Query_Withdrawal_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.house.Query", + ServiceName: "sge.legacy.house.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -862,7 +866,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/house/query.proto", + Metadata: "sge/legacy/house/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/query.pb.gw.go b/x/legacy/house/types/query.pb.gw.go similarity index 99% rename from x/house/types/query.pb.gw.go rename to x/legacy/house/types/query.pb.gw.go index c17d43cd..a755c32d 100644 --- a/x/house/types/query.pb.gw.go +++ b/x/legacy/house/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/house/query.proto +// source: sge/legacy/house/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/house/types/ticket.go b/x/legacy/house/types/ticket.go similarity index 100% rename from x/house/types/ticket.go rename to x/legacy/house/types/ticket.go diff --git a/x/house/types/ticket.pb.go b/x/legacy/house/types/ticket.pb.go similarity index 81% rename from x/house/types/ticket.pb.go rename to x/legacy/house/types/ticket.pb.go index b8181a4f..01d4f7c2 100644 --- a/x/house/types/ticket.pb.go +++ b/x/legacy/house/types/ticket.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/ticket.proto +// source: sge/legacy/house/v1beta/ticket.proto package types @@ -8,7 +8,7 @@ import ( _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" - types "github.com/sge-network/sge/types" + legacy "github.com/sge-network/sge/types/legacy" io "io" math "math" math_bits "math/bits" @@ -28,7 +28,7 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // DepositTicketPayload indicates data of the deposit ticket. type DepositTicketPayload struct { // kyc_data contains the details of user kyc. - KycData types.KycDataPayload `protobuf:"bytes,1,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data"` + KycData legacy.KycDataPayload `protobuf:"bytes,1,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data"` // depositor_address is the account who makes a deposit DepositorAddress string `protobuf:"bytes,2,opt,name=depositor_address,json=depositorAddress,proto3" json:"depositor_address,omitempty" yaml:"depositor_address"` } @@ -37,7 +37,7 @@ func (m *DepositTicketPayload) Reset() { *m = DepositTicketPayload{} } func (m *DepositTicketPayload) String() string { return proto.CompactTextString(m) } func (*DepositTicketPayload) ProtoMessage() {} func (*DepositTicketPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_240713aaceffb197, []int{0} + return fileDescriptor_943082e152f22a00, []int{0} } func (m *DepositTicketPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -66,11 +66,11 @@ func (m *DepositTicketPayload) XXX_DiscardUnknown() { var xxx_messageInfo_DepositTicketPayload proto.InternalMessageInfo -func (m *DepositTicketPayload) GetKycData() types.KycDataPayload { +func (m *DepositTicketPayload) GetKycData() legacy.KycDataPayload { if m != nil { return m.KycData } - return types.KycDataPayload{} + return legacy.KycDataPayload{} } func (m *DepositTicketPayload) GetDepositorAddress() string { @@ -83,7 +83,7 @@ func (m *DepositTicketPayload) GetDepositorAddress() string { // WithdrawTicketPayload indicates data of the withdrawal ticket. type WithdrawTicketPayload struct { // kyc_data contains the details of user kyc. - KycData types.KycDataPayload `protobuf:"bytes,1,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data"` + KycData legacy.KycDataPayload `protobuf:"bytes,1,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data"` // depositor_address is the account who makes a deposit DepositorAddress string `protobuf:"bytes,2,opt,name=depositor_address,json=depositorAddress,proto3" json:"depositor_address,omitempty" yaml:"depositor_address"` } @@ -92,7 +92,7 @@ func (m *WithdrawTicketPayload) Reset() { *m = WithdrawTicketPayload{} } func (m *WithdrawTicketPayload) String() string { return proto.CompactTextString(m) } func (*WithdrawTicketPayload) ProtoMessage() {} func (*WithdrawTicketPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_240713aaceffb197, []int{1} + return fileDescriptor_943082e152f22a00, []int{1} } func (m *WithdrawTicketPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -121,11 +121,11 @@ func (m *WithdrawTicketPayload) XXX_DiscardUnknown() { var xxx_messageInfo_WithdrawTicketPayload proto.InternalMessageInfo -func (m *WithdrawTicketPayload) GetKycData() types.KycDataPayload { +func (m *WithdrawTicketPayload) GetKycData() legacy.KycDataPayload { if m != nil { return m.KycData } - return types.KycDataPayload{} + return legacy.KycDataPayload{} } func (m *WithdrawTicketPayload) GetDepositorAddress() string { @@ -136,34 +136,37 @@ func (m *WithdrawTicketPayload) GetDepositorAddress() string { } func init() { - proto.RegisterType((*DepositTicketPayload)(nil), "sgenetwork.sge.house.DepositTicketPayload") - proto.RegisterType((*WithdrawTicketPayload)(nil), "sgenetwork.sge.house.WithdrawTicketPayload") + proto.RegisterType((*DepositTicketPayload)(nil), "sge.legacy.house.v1beta.DepositTicketPayload") + proto.RegisterType((*WithdrawTicketPayload)(nil), "sge.legacy.house.v1beta.WithdrawTicketPayload") } -func init() { proto.RegisterFile("sgenetwork/sge/house/ticket.proto", fileDescriptor_240713aaceffb197) } +func init() { + proto.RegisterFile("sge/legacy/house/v1beta/ticket.proto", fileDescriptor_943082e152f22a00) +} -var fileDescriptor_240713aaceffb197 = []byte{ - // 313 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0xc8, 0x2f, 0x2d, 0x4e, - 0xd5, 0x2f, 0xc9, 0x4c, 0xce, 0x4e, 0x2d, 0xd1, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x41, - 0x28, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0x03, 0x2b, 0x91, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, - 0xd0, 0x07, 0xb1, 0x20, 0x6a, 0xa5, 0x24, 0x93, 0xf3, 0x8b, 0x73, 0xf3, 0x8b, 0xe3, 0x21, 0x12, - 0x10, 0x0e, 0x54, 0x4a, 0x16, 0xcd, 0xa6, 0x92, 0xca, 0x82, 0x54, 0xfd, 0xec, 0xca, 0x64, 0x88, - 0xb4, 0xd2, 0x7e, 0x46, 0x2e, 0x11, 0x97, 0xd4, 0x82, 0xfc, 0xe2, 0xcc, 0x92, 0x10, 0xb0, 0xed, - 0x01, 0x89, 0x95, 0x39, 0xf9, 0x89, 0x29, 0x42, 0x2e, 0x5c, 0x1c, 0xd9, 0x95, 0xc9, 0xf1, 0x29, - 0x89, 0x25, 0x89, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0xdc, 0x46, 0xca, 0x7a, 0x68, 0x2e, 0x02, 0x19, - 0xa5, 0xe7, 0x5d, 0x99, 0xec, 0x92, 0x58, 0x92, 0x08, 0xd5, 0xe6, 0xc4, 0x72, 0xe2, 0x9e, 0x3c, - 0x43, 0x10, 0x7b, 0x36, 0x44, 0x54, 0x28, 0x91, 0x4b, 0x30, 0x05, 0x62, 0x7a, 0x7e, 0x51, 0x7c, - 0x62, 0x4a, 0x4a, 0x51, 0x6a, 0x71, 0xb1, 0x04, 0x93, 0x02, 0xa3, 0x06, 0xa7, 0x93, 0xc9, 0xa7, - 0x7b, 0xf2, 0x12, 0x95, 0x89, 0xb9, 0x39, 0x56, 0x4a, 0x18, 0x4a, 0x94, 0x2e, 0x6d, 0xd1, 0x15, - 0x81, 0x7a, 0xc3, 0x11, 0x22, 0x14, 0x5c, 0x52, 0x94, 0x99, 0x97, 0x1e, 0x24, 0x00, 0x57, 0x0b, - 0x15, 0x57, 0x3a, 0xc0, 0xc8, 0x25, 0x1a, 0x9e, 0x59, 0x92, 0x91, 0x52, 0x94, 0x58, 0x3e, 0x34, - 0xbd, 0xe0, 0xe4, 0x74, 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, - 0x4e, 0x78, 0x2c, 0xc7, 0x70, 0xe1, 0xb1, 0x1c, 0xc3, 0x8d, 0xc7, 0x72, 0x0c, 0x51, 0x1a, 0xe9, - 0x99, 0x25, 0x19, 0xa5, 0x49, 0x7a, 0xc9, 0xf9, 0xb9, 0xa0, 0xd8, 0xd3, 0x45, 0x8e, 0xc9, 0x0a, - 0x58, 0xaa, 0xa9, 0x2c, 0x48, 0x2d, 0x4e, 0x62, 0x03, 0xc7, 0xa7, 0x31, 0x20, 0x00, 0x00, 0xff, - 0xff, 0x8d, 0x8c, 0xb3, 0x00, 0x5a, 0x02, 0x00, 0x00, +var fileDescriptor_943082e152f22a00 = []byte{ + // 330 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x29, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0xc8, 0x2f, 0x2d, 0x4e, 0xd5, 0x2f, 0x33, 0x4c, + 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0xc9, 0x4c, 0xce, 0x4e, 0x2d, 0xd1, 0x2b, 0x28, 0xca, 0x2f, 0xc9, + 0x17, 0x12, 0x2f, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0xd2, 0x03, 0xab, 0xd2, 0x83, 0xa8, 0x92, 0x92, + 0x4c, 0xce, 0x2f, 0xce, 0xcd, 0x2f, 0x8e, 0x07, 0x2b, 0xd3, 0x87, 0x70, 0x20, 0x7a, 0xa4, 0x44, + 0xd2, 0xf3, 0xd3, 0xf3, 0x21, 0xe2, 0x20, 0x16, 0x54, 0x54, 0x01, 0xc9, 0xbe, 0x92, 0xca, 0x02, + 0xb8, 0x75, 0xd9, 0x95, 0xc9, 0x10, 0x15, 0x4a, 0x87, 0x18, 0xb9, 0x44, 0x5c, 0x52, 0x0b, 0xf2, + 0x8b, 0x33, 0x4b, 0x42, 0xc0, 0x6e, 0x08, 0x48, 0xac, 0xcc, 0xc9, 0x4f, 0x4c, 0x11, 0x72, 0xe7, + 0xe2, 0xc8, 0xae, 0x4c, 0x8e, 0x4f, 0x49, 0x2c, 0x49, 0x94, 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x36, + 0x52, 0xd3, 0x43, 0x72, 0x17, 0xc8, 0x34, 0xa8, 0xb3, 0xf4, 0xbc, 0x2b, 0x93, 0x5d, 0x12, 0x4b, + 0x12, 0xa1, 0x3a, 0x9d, 0x58, 0x4e, 0xdc, 0x93, 0x67, 0x08, 0x62, 0xcf, 0x86, 0x88, 0x0a, 0x25, + 0x72, 0x09, 0xa6, 0x40, 0x2c, 0xc8, 0x2f, 0x8a, 0x4f, 0x4c, 0x49, 0x29, 0x4a, 0x2d, 0x2e, 0x96, + 0x60, 0x52, 0x60, 0xd4, 0xe0, 0x74, 0x32, 0xf9, 0x74, 0x4f, 0x5e, 0xa2, 0x32, 0x31, 0x37, 0xc7, + 0x4a, 0x09, 0x43, 0x89, 0xd2, 0xa5, 0x2d, 0xba, 0x22, 0x50, 0x2f, 0x3a, 0x42, 0x84, 0x82, 0x4b, + 0x8a, 0x32, 0xf3, 0xd2, 0x83, 0x04, 0xe0, 0x6a, 0xa1, 0xe2, 0x4a, 0x87, 0x19, 0xb9, 0x44, 0xc3, + 0x33, 0x4b, 0x32, 0x52, 0x8a, 0x12, 0xcb, 0x87, 0xac, 0x2f, 0x9c, 0x3c, 0x4f, 0x3c, 0x92, 0x63, + 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, + 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x3f, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, + 0x3f, 0x57, 0xbf, 0x38, 0x3d, 0x55, 0x37, 0x2f, 0xb5, 0xa4, 0x3c, 0xbf, 0x28, 0x1b, 0xc4, 0xd6, + 0xaf, 0x40, 0x4d, 0x4f, 0x20, 0x1f, 0x15, 0x27, 0xb1, 0x81, 0x23, 0xd7, 0x18, 0x10, 0x00, 0x00, + 0xff, 0xff, 0x25, 0xf2, 0xbf, 0x7c, 0x70, 0x02, 0x00, 0x00, } func (m *DepositTicketPayload) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/tx.pb.go b/x/legacy/house/types/tx.pb.go similarity index 87% rename from x/house/types/tx.pb.go rename to x/legacy/house/types/tx.pb.go index ef9e5a07..0e1690ec 100644 --- a/x/house/types/tx.pb.go +++ b/x/legacy/house/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/tx.proto +// source: sge/legacy/house/v1beta/tx.proto package types @@ -50,7 +50,7 @@ func (m *MsgDeposit) Reset() { *m = MsgDeposit{} } func (m *MsgDeposit) String() string { return proto.CompactTextString(m) } func (*MsgDeposit) ProtoMessage() {} func (*MsgDeposit) Descriptor() ([]byte, []int) { - return fileDescriptor_0764ff859f434eaf, []int{0} + return fileDescriptor_e44ed1387eb042eb, []int{0} } func (m *MsgDeposit) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -93,7 +93,7 @@ func (m *MsgDepositResponse) Reset() { *m = MsgDepositResponse{} } func (m *MsgDepositResponse) String() string { return proto.CompactTextString(m) } func (*MsgDepositResponse) ProtoMessage() {} func (*MsgDepositResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0764ff859f434eaf, []int{1} + return fileDescriptor_e44ed1387eb042eb, []int{1} } func (m *MsgDepositResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -145,7 +145,7 @@ type MsgWithdraw struct { // participation ParticipationIndex uint64 `protobuf:"varint,3,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty" yaml:"participation_index"` // mode is the withdrawal mode. It can be full or partial withdraw - Mode WithdrawalMode `protobuf:"varint,4,opt,name=mode,proto3,enum=sgenetwork.sge.house.WithdrawalMode" json:"mode,omitempty" yaml:"mode"` + Mode WithdrawalMode `protobuf:"varint,4,opt,name=mode,proto3,enum=sge.legacy.house.v1beta.WithdrawalMode" json:"mode,omitempty" yaml:"mode"` // amount is the requested withdrawal amount Amount cosmossdk_io_math.Int `protobuf:"bytes,5,opt,name=amount,proto3,customtype=cosmossdk.io/math.Int" json:"amount"` // ticket is the jwt ticket data. @@ -156,7 +156,7 @@ func (m *MsgWithdraw) Reset() { *m = MsgWithdraw{} } func (m *MsgWithdraw) String() string { return proto.CompactTextString(m) } func (*MsgWithdraw) ProtoMessage() {} func (*MsgWithdraw) Descriptor() ([]byte, []int) { - return fileDescriptor_0764ff859f434eaf, []int{2} + return fileDescriptor_e44ed1387eb042eb, []int{2} } func (m *MsgWithdraw) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -200,7 +200,7 @@ func (m *MsgWithdrawResponse) Reset() { *m = MsgWithdrawResponse{} } func (m *MsgWithdrawResponse) String() string { return proto.CompactTextString(m) } func (*MsgWithdrawResponse) ProtoMessage() {} func (*MsgWithdrawResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0764ff859f434eaf, []int{3} + return fileDescriptor_e44ed1387eb042eb, []int{3} } func (m *MsgWithdrawResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -263,7 +263,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_0764ff859f434eaf, []int{4} + return fileDescriptor_e44ed1387eb042eb, []int{4} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -315,7 +315,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0764ff859f434eaf, []int{5} + return fileDescriptor_e44ed1387eb042eb, []int{5} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -345,64 +345,64 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgDeposit)(nil), "sgenetwork.sge.house.MsgDeposit") - proto.RegisterType((*MsgDepositResponse)(nil), "sgenetwork.sge.house.MsgDepositResponse") - proto.RegisterType((*MsgWithdraw)(nil), "sgenetwork.sge.house.MsgWithdraw") - proto.RegisterType((*MsgWithdrawResponse)(nil), "sgenetwork.sge.house.MsgWithdrawResponse") - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.house.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.house.MsgUpdateParamsResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/house/tx.proto", fileDescriptor_0764ff859f434eaf) } - -var fileDescriptor_0764ff859f434eaf = []byte{ - // 725 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x55, 0x41, 0x4f, 0x13, 0x41, - 0x14, 0xee, 0x6e, 0x6b, 0xb1, 0x83, 0x81, 0x30, 0x14, 0x29, 0x55, 0xba, 0xb0, 0x68, 0x02, 0xc4, - 0xee, 0x0a, 0x46, 0x4d, 0xea, 0xc1, 0xd8, 0x70, 0xe9, 0xa1, 0xd1, 0xac, 0x21, 0x26, 0x24, 0x86, - 0x0c, 0xdd, 0xc9, 0x76, 0x52, 0x76, 0x67, 0xb3, 0x33, 0x15, 0xb8, 0x78, 0xf0, 0xc4, 0x51, 0xff, - 0x01, 0xf1, 0xe4, 0x4d, 0x0e, 0xfc, 0x00, 0x8f, 0xc4, 0x83, 0x21, 0x9c, 0x8c, 0x31, 0x1b, 0x53, - 0x0e, 0x18, 0x8f, 0xfd, 0x05, 0xa6, 0xb3, 0xbb, 0xb4, 0xe0, 0x36, 0x20, 0xf1, 0xe0, 0xa5, 0xdd, - 0x79, 0xef, 0xfb, 0xf6, 0xbd, 0x37, 0xdf, 0xb7, 0x33, 0x60, 0x92, 0x59, 0xd8, 0xc1, 0x7c, 0x83, - 0x7a, 0x0d, 0x9d, 0x59, 0x58, 0xaf, 0xd3, 0x26, 0xc3, 0x3a, 0xdf, 0xd4, 0x5c, 0x8f, 0x72, 0x0a, - 0xb3, 0xdd, 0xb4, 0xc6, 0x2c, 0xac, 0x89, 0x74, 0x7e, 0x04, 0xd9, 0xc4, 0xa1, 0xba, 0xf8, 0x0d, - 0x80, 0xf9, 0xf1, 0x1a, 0x65, 0x36, 0x65, 0xba, 0xcd, 0x2c, 0xfd, 0xd5, 0x42, 0xe7, 0x2f, 0x4c, - 0x4c, 0x04, 0x89, 0x55, 0xb1, 0xd2, 0x83, 0x45, 0x98, 0xca, 0x5a, 0xd4, 0xa2, 0x41, 0xbc, 0xf3, - 0x14, 0x46, 0xa7, 0x63, 0x3b, 0x72, 0x91, 0x87, 0xec, 0x88, 0x38, 0x13, 0x0b, 0xd9, 0x20, 0xbc, - 0x6e, 0x7a, 0x68, 0x23, 0x00, 0xa9, 0xdf, 0x25, 0x00, 0xaa, 0xcc, 0x5a, 0xc2, 0x2e, 0x65, 0x84, - 0xc3, 0x3b, 0x60, 0xa0, 0xe6, 0x61, 0xc4, 0xa9, 0x97, 0x93, 0xa6, 0xa4, 0xd9, 0x4c, 0x19, 0xb6, - 0x7d, 0x65, 0x68, 0x0b, 0xd9, 0xeb, 0x25, 0x35, 0x4c, 0xa8, 0x46, 0x04, 0x81, 0x8f, 0x00, 0xb0, - 0x91, 0xd7, 0xc0, 0x7c, 0xb5, 0x49, 0xcc, 0x9c, 0x2c, 0x08, 0x37, 0x5a, 0xbe, 0x92, 0xa9, 0x8a, - 0xe8, 0x72, 0x65, 0xe9, 0x97, 0xaf, 0xf4, 0x40, 0x8c, 0x9e, 0x67, 0x78, 0x1f, 0xa4, 0x91, 0x4d, - 0x9b, 0x0e, 0xcf, 0x25, 0x05, 0x71, 0x72, 0xdf, 0x57, 0x12, 0xdf, 0x7c, 0x65, 0x2c, 0x98, 0x9e, - 0x99, 0x0d, 0x8d, 0x50, 0xdd, 0x46, 0xbc, 0xae, 0x55, 0x1c, 0x6e, 0x84, 0x60, 0x78, 0x1d, 0xa4, - 0x39, 0xa9, 0x35, 0x30, 0xcf, 0xa5, 0x3a, 0x34, 0x23, 0x5c, 0x95, 0xb2, 0xdb, 0x3b, 0x4a, 0xe2, - 0xe7, 0x8e, 0x92, 0x78, 0x73, 0xbc, 0x3b, 0x1f, 0x75, 0xa8, 0xbe, 0x97, 0x00, 0xec, 0x8e, 0x67, - 0x60, 0xe6, 0x52, 0x87, 0xe1, 0x33, 0x8d, 0x4b, 0x7f, 0xd7, 0xf8, 0x53, 0x30, 0xea, 0x22, 0x8f, - 0x93, 0x1a, 0x71, 0x11, 0x27, 0xd4, 0x59, 0x25, 0x8e, 0x89, 0x37, 0xc5, 0xf8, 0xa9, 0x72, 0xa1, - 0xed, 0x2b, 0xf9, 0x60, 0xbf, 0x62, 0x40, 0xaa, 0x01, 0x4f, 0x45, 0x2b, 0x22, 0xf8, 0x2e, 0x09, - 0x06, 0xab, 0xcc, 0x7a, 0x11, 0x2a, 0x03, 0x97, 0xce, 0x8a, 0x30, 0xff, 0xa7, 0x08, 0x87, 0x7b, - 0xc5, 0x6c, 0x68, 0x93, 0x27, 0xa6, 0xe9, 0x61, 0xc6, 0x9e, 0x73, 0x8f, 0x38, 0xd6, 0x3f, 0x12, - 0xa7, 0xcf, 0x8c, 0xc9, 0xcb, 0xce, 0x08, 0x2b, 0x20, 0x65, 0x53, 0x13, 0x0b, 0xd1, 0x86, 0x16, - 0x6f, 0x69, 0x71, 0x5f, 0x8c, 0x16, 0xed, 0x00, 0x5a, 0xaf, 0x52, 0x13, 0x97, 0x87, 0xdb, 0xbe, - 0x32, 0x18, 0xd4, 0xe9, 0x70, 0x55, 0x43, 0xbc, 0xa2, 0xc7, 0x38, 0x57, 0x2e, 0x67, 0x9c, 0xf4, - 0x05, 0x8c, 0xf3, 0x45, 0x02, 0xa3, 0x3d, 0x9a, 0x9c, 0x38, 0x67, 0x0e, 0xc8, 0xa1, 0x63, 0x52, - 0xe5, 0x89, 0x96, 0xaf, 0xc8, 0x62, 0x1b, 0x65, 0x62, 0xb6, 0x7d, 0x25, 0x13, 0xf4, 0x4a, 0x4c, - 0xd5, 0x90, 0x89, 0xf9, 0x7f, 0x09, 0xa0, 0x7e, 0x94, 0xc0, 0x70, 0x95, 0x59, 0xcb, 0xae, 0x89, - 0x38, 0x7e, 0x26, 0xce, 0x09, 0xf8, 0x00, 0x64, 0x50, 0x93, 0xd7, 0xa9, 0x47, 0xf8, 0x56, 0x68, - 0xb5, 0x5c, 0x5f, 0x63, 0x75, 0xa1, 0xf0, 0x31, 0x48, 0x07, 0x27, 0x8d, 0x98, 0x6a, 0x70, 0xf1, - 0x66, 0xbc, 0x9c, 0x41, 0x95, 0x72, 0xa6, 0xa3, 0xcf, 0x87, 0xe3, 0xdd, 0x79, 0xc9, 0x08, 0x69, - 0xa5, 0x99, 0xc3, 0xbd, 0xe2, 0x08, 0xb3, 0x70, 0x31, 0x24, 0x4d, 0x2d, 0x68, 0x0f, 0xb5, 0x85, - 0x8e, 0x00, 0xdd, 0x2a, 0xea, 0x5d, 0x30, 0x7e, 0xa6, 0xe1, 0x48, 0x85, 0xd2, 0x58, 0x2c, 0x7f, - 0xf1, 0x93, 0x0c, 0x92, 0x55, 0x66, 0xc1, 0x15, 0x30, 0x10, 0x1d, 0x68, 0x53, 0xf1, 0xad, 0x75, - 0xcf, 0x84, 0xfc, 0xec, 0x79, 0x88, 0xa8, 0xaa, 0x9a, 0xdc, 0x96, 0x25, 0xf8, 0x12, 0x5c, 0x3d, - 0xf9, 0x50, 0xa7, 0xfb, 0x52, 0x23, 0x48, 0x7e, 0xee, 0x5c, 0xc8, 0xe9, 0xd7, 0xbf, 0x06, 0xd7, - 0x4e, 0x49, 0x74, 0xbb, 0x2f, 0xbf, 0x17, 0x96, 0x2f, 0x5e, 0x08, 0x76, 0x52, 0x2a, 0xf7, 0x39, - 0x6e, 0xff, 0xb6, 0x65, 0xa9, 0x5c, 0xde, 0x6f, 0x15, 0xa4, 0x83, 0x56, 0x41, 0xfa, 0xd1, 0x2a, - 0x48, 0x6f, 0x8f, 0x0a, 0x89, 0x83, 0xa3, 0x42, 0xe2, 0xeb, 0x51, 0x21, 0xb1, 0x32, 0x6b, 0x11, - 0x5e, 0x6f, 0xae, 0x69, 0x35, 0x6a, 0xeb, 0x3d, 0x54, 0x71, 0xb5, 0x6c, 0x46, 0x37, 0xe2, 0x96, - 0x8b, 0xd9, 0x5a, 0x5a, 0x5c, 0x2d, 0xf7, 0x7e, 0x07, 0x00, 0x00, 0xff, 0xff, 0x63, 0xd4, 0xbd, - 0x7e, 0x36, 0x07, 0x00, 0x00, + proto.RegisterType((*MsgDeposit)(nil), "sge.legacy.house.v1beta.MsgDeposit") + proto.RegisterType((*MsgDepositResponse)(nil), "sge.legacy.house.v1beta.MsgDepositResponse") + proto.RegisterType((*MsgWithdraw)(nil), "sge.legacy.house.v1beta.MsgWithdraw") + proto.RegisterType((*MsgWithdrawResponse)(nil), "sge.legacy.house.v1beta.MsgWithdrawResponse") + proto.RegisterType((*MsgUpdateParams)(nil), "sge.legacy.house.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.legacy.house.v1beta.MsgUpdateParamsResponse") +} + +func init() { proto.RegisterFile("sge/legacy/house/v1beta/tx.proto", fileDescriptor_e44ed1387eb042eb) } + +var fileDescriptor_e44ed1387eb042eb = []byte{ + // 736 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x55, 0x4f, 0x4f, 0x13, 0x4d, + 0x1c, 0xee, 0x6e, 0xfb, 0x96, 0xb7, 0xc3, 0x1b, 0x08, 0x03, 0xbc, 0x94, 0x1a, 0xbb, 0x64, 0x21, + 0x8a, 0x08, 0xbb, 0x14, 0xa3, 0x26, 0xf5, 0x64, 0xc3, 0xa5, 0x89, 0x8d, 0x66, 0x0d, 0x31, 0xf1, + 0x82, 0x43, 0x77, 0xb2, 0x9d, 0x94, 0xdd, 0xd9, 0xec, 0x4c, 0x81, 0x5e, 0x8d, 0x07, 0x8e, 0x1e, + 0xfc, 0x00, 0xc4, 0x93, 0x47, 0x62, 0xf8, 0x10, 0xc4, 0x83, 0x21, 0x78, 0x31, 0xc6, 0x6c, 0x4c, + 0x39, 0x60, 0x3c, 0xf6, 0x13, 0x98, 0xce, 0xee, 0xd2, 0x16, 0x59, 0x52, 0x89, 0x07, 0x2f, 0xed, + 0xcc, 0x6f, 0x9e, 0x67, 0x7f, 0x7f, 0x9e, 0x67, 0x67, 0xc1, 0x0c, 0xb3, 0xb0, 0xbe, 0x89, 0x2d, + 0x54, 0x6d, 0xea, 0x35, 0xda, 0x60, 0x58, 0xdf, 0x2a, 0x6c, 0x60, 0x8e, 0x74, 0xbe, 0xa3, 0xb9, + 0x1e, 0xe5, 0x14, 0x4e, 0x31, 0x0b, 0x6b, 0x01, 0x42, 0x13, 0x08, 0x2d, 0x40, 0xe4, 0xc6, 0x90, + 0x4d, 0x1c, 0xaa, 0x8b, 0xdf, 0x00, 0x9b, 0x9b, 0xaa, 0x52, 0x66, 0x53, 0xa6, 0xdb, 0xcc, 0xd2, + 0xb7, 0x0a, 0x9d, 0xbf, 0xf0, 0x60, 0x3a, 0x38, 0x58, 0x17, 0x3b, 0x3d, 0xd8, 0x84, 0x47, 0x13, + 0x16, 0xb5, 0x68, 0x10, 0xef, 0xac, 0xc2, 0xe8, 0x5c, 0x5c, 0x5d, 0x2e, 0xf2, 0x90, 0x1d, 0x71, + 0x6f, 0xc4, 0xa1, 0xb6, 0x09, 0xaf, 0x99, 0x1e, 0xda, 0x0e, 0x70, 0xea, 0x57, 0x09, 0x80, 0x0a, + 0xb3, 0x56, 0xb1, 0x4b, 0x19, 0xe1, 0x70, 0x11, 0x0c, 0x55, 0x3d, 0x8c, 0x38, 0xf5, 0xb2, 0xd2, + 0x8c, 0x34, 0x9f, 0x29, 0xc1, 0xb6, 0xaf, 0x8c, 0x34, 0x91, 0xbd, 0x59, 0x54, 0xc3, 0x03, 0xd5, + 0x88, 0x20, 0xf0, 0x01, 0x00, 0x36, 0xf2, 0xea, 0x98, 0xaf, 0x37, 0x88, 0x99, 0x95, 0x05, 0xe1, + 0x5a, 0xcb, 0x57, 0x32, 0x15, 0x11, 0x5d, 0x2b, 0xaf, 0xfe, 0xf0, 0x95, 0x1e, 0x88, 0xd1, 0xb3, + 0x86, 0x77, 0x41, 0x1a, 0xd9, 0xb4, 0xe1, 0xf0, 0x6c, 0x52, 0x10, 0xaf, 0x1f, 0xfa, 0x4a, 0xe2, + 0x8b, 0xaf, 0x4c, 0x06, 0x33, 0x60, 0x66, 0x5d, 0x23, 0x54, 0xb7, 0x11, 0xaf, 0x69, 0x65, 0x87, + 0x1b, 0x21, 0x18, 0xfe, 0x0f, 0xd2, 0x9c, 0x54, 0xeb, 0x98, 0x67, 0x53, 0x1d, 0x9a, 0x11, 0xee, + 0x8a, 0x13, 0xbb, 0x7b, 0x4a, 0xe2, 0xfb, 0x9e, 0x92, 0x78, 0x79, 0xba, 0xbf, 0x10, 0x55, 0xa8, + 0xbe, 0x95, 0x00, 0xec, 0xb6, 0x67, 0x60, 0xe6, 0x52, 0x87, 0xe1, 0x73, 0x85, 0x4b, 0xbf, 0x57, + 0xf8, 0x63, 0x30, 0xee, 0x22, 0x8f, 0x93, 0x2a, 0x71, 0x11, 0x27, 0xd4, 0x59, 0x27, 0x8e, 0x89, + 0x77, 0x44, 0xfb, 0xa9, 0x52, 0xbe, 0xed, 0x2b, 0xb9, 0x60, 0x5e, 0x17, 0x80, 0x54, 0x03, 0xf6, + 0x45, 0xcb, 0x22, 0xf8, 0x26, 0x09, 0x86, 0x2b, 0xcc, 0x7a, 0x16, 0x2a, 0x03, 0x57, 0xcf, 0x8b, + 0xb0, 0xf0, 0xab, 0x08, 0xc7, 0x07, 0x4b, 0x13, 0xa1, 0x59, 0x1e, 0x9a, 0xa6, 0x87, 0x19, 0x7b, + 0xca, 0x3d, 0xe2, 0x58, 0x7f, 0x48, 0x9c, 0x98, 0x1e, 0x93, 0x57, 0xed, 0x11, 0x3e, 0x02, 0x29, + 0x9b, 0x9a, 0x58, 0x88, 0x36, 0xb2, 0x72, 0x53, 0x8b, 0x79, 0x75, 0xb4, 0x68, 0x08, 0x68, 0xb3, + 0x42, 0x4d, 0x5c, 0x1a, 0x6d, 0xfb, 0xca, 0x70, 0x90, 0xaa, 0x43, 0x57, 0x0d, 0xf1, 0x94, 0x1e, + 0xef, 0xfc, 0x73, 0x35, 0xef, 0xa4, 0x07, 0xf0, 0xce, 0x47, 0x09, 0x8c, 0xf7, 0xc8, 0x72, 0x66, + 0x9e, 0x5b, 0x40, 0x0e, 0x4d, 0x93, 0x2a, 0x4d, 0xb7, 0x7c, 0x45, 0x16, 0x93, 0x94, 0x89, 0xd9, + 0xf6, 0x95, 0x4c, 0x50, 0x2b, 0x31, 0x55, 0x43, 0x26, 0xe6, 0xdf, 0xa5, 0x81, 0xfa, 0x5e, 0x02, + 0xa3, 0x15, 0x66, 0xad, 0xb9, 0x26, 0xe2, 0xf8, 0x89, 0xb8, 0x2d, 0xe0, 0x3d, 0x90, 0x41, 0x0d, + 0x5e, 0xa3, 0x1e, 0xe1, 0xcd, 0xd0, 0x6d, 0xd9, 0x58, 0x6f, 0x75, 0xa1, 0xb0, 0x04, 0xd2, 0xc1, + 0x7d, 0x23, 0xba, 0x1a, 0x5e, 0x51, 0x62, 0x15, 0x0d, 0x12, 0x95, 0x32, 0x1d, 0x89, 0xde, 0x9d, + 0xee, 0x2f, 0x48, 0x46, 0xc8, 0x2c, 0xce, 0x1e, 0x1f, 0x2c, 0x8d, 0x31, 0x0b, 0x2f, 0x39, 0x98, + 0x6f, 0x53, 0xaf, 0x3e, 0x53, 0xd0, 0xee, 0x6b, 0x85, 0x8e, 0x06, 0xdd, 0x44, 0xea, 0x32, 0x98, + 0x3a, 0x57, 0x73, 0x24, 0x44, 0x71, 0xf2, 0x42, 0xfe, 0xca, 0x27, 0x19, 0x24, 0x2b, 0xcc, 0x82, + 0x2f, 0xc0, 0x50, 0x74, 0xad, 0xcd, 0xc6, 0x56, 0xd7, 0xbd, 0x1c, 0x72, 0xb7, 0x07, 0x00, 0x45, + 0xb9, 0xd5, 0xe4, 0xae, 0x2c, 0xc1, 0x2a, 0xf8, 0xf7, 0xec, 0xa5, 0x9d, 0xbb, 0x8c, 0x1d, 0xa1, + 0x72, 0x8b, 0x83, 0xa0, 0xfa, 0x93, 0xbc, 0x92, 0xc0, 0x7f, 0x7d, 0x92, 0xcd, 0x5f, 0xf6, 0x8c, + 0x5e, 0x64, 0x6e, 0x79, 0x50, 0xe4, 0x59, 0xc6, 0xec, 0x87, 0x8b, 0x46, 0xba, 0x2b, 0x4b, 0xa5, + 0xf2, 0x61, 0x2b, 0x2f, 0x1d, 0xb5, 0xf2, 0xd2, 0xb7, 0x56, 0x5e, 0x7a, 0x7d, 0x92, 0x4f, 0x1c, + 0x9d, 0xe4, 0x13, 0x9f, 0x4f, 0xf2, 0x89, 0xe7, 0xba, 0x45, 0x78, 0xad, 0xb1, 0xa1, 0x55, 0xa9, + 0xad, 0xf7, 0x50, 0x3b, 0x6b, 0x7d, 0xa7, 0xff, 0x1b, 0xc4, 0x9b, 0x2e, 0x66, 0x1b, 0x69, 0xf1, + 0xe9, 0xb9, 0xf3, 0x33, 0x00, 0x00, 0xff, 0xff, 0xbd, 0xf0, 0x6f, 0x4c, 0x62, 0x07, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -440,7 +440,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { // Deprecated: Do not use. func (c *msgClient) Deposit(ctx context.Context, in *MsgDeposit, opts ...grpc.CallOption) (*MsgDepositResponse, error) { out := new(MsgDepositResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Msg/Deposit", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Msg/Deposit", in, out, opts...) if err != nil { return nil, err } @@ -450,7 +450,7 @@ func (c *msgClient) Deposit(ctx context.Context, in *MsgDeposit, opts ...grpc.Ca // Deprecated: Do not use. func (c *msgClient) Withdraw(ctx context.Context, in *MsgWithdraw, opts ...grpc.CallOption) (*MsgWithdrawResponse, error) { out := new(MsgWithdrawResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Msg/Withdraw", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Msg/Withdraw", in, out, opts...) if err != nil { return nil, err } @@ -460,7 +460,7 @@ func (c *msgClient) Withdraw(ctx context.Context, in *MsgWithdraw, opts ...grpc. // Deprecated: Do not use. func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.house.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.house.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -509,7 +509,7 @@ func _Msg_Deposit_Handler(srv interface{}, ctx context.Context, dec func(interfa } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Msg/Deposit", + FullMethod: "/sge.legacy.house.v1beta.Msg/Deposit", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Deposit(ctx, req.(*MsgDeposit)) @@ -527,7 +527,7 @@ func _Msg_Withdraw_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Msg/Withdraw", + FullMethod: "/sge.legacy.house.v1beta.Msg/Withdraw", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Withdraw(ctx, req.(*MsgWithdraw)) @@ -545,7 +545,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.house.Msg/UpdateParams", + FullMethod: "/sge.legacy.house.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -553,8 +553,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.house.Msg", + ServiceName: "sge.legacy.house.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -571,7 +572,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/house/tx.proto", + Metadata: "sge/legacy/house/v1beta/tx.proto", } func (m *MsgDeposit) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/withdraw.pb.go b/x/legacy/house/types/withdraw.pb.go similarity index 77% rename from x/house/types/withdraw.pb.go rename to x/legacy/house/types/withdraw.pb.go index c5a2c707..6ea4ae41 100644 --- a/x/house/types/withdraw.pb.go +++ b/x/legacy/house/types/withdraw.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/house/withdraw.proto +// source: sge/legacy/house/v1beta/withdraw.proto package types @@ -54,7 +54,7 @@ func (x WithdrawalMode) String() string { } func (WithdrawalMode) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_bc9c262f4256300e, []int{0} + return fileDescriptor_bde70a5bf22ba89e, []int{0} } // Withdrawal represents the withdrawal against a deposit. @@ -71,7 +71,7 @@ type Withdrawal struct { // participation_index is the id corresponding to the book participation ParticipationIndex uint64 `protobuf:"varint,5,opt,name=participation_index,json=participationIndex,proto3" json:"participation_index,omitempty" yaml:"participation_index"` // mode is the withdrawal mode enum value - Mode WithdrawalMode `protobuf:"varint,6,opt,name=mode,proto3,enum=sgenetwork.sge.house.WithdrawalMode" json:"mode,omitempty" yaml:"mode"` + Mode WithdrawalMode `protobuf:"varint,6,opt,name=mode,proto3,enum=sge.legacy.house.v1beta.WithdrawalMode" json:"mode,omitempty" yaml:"mode"` // amount is the amount being withdrawn. Amount cosmossdk_io_math.Int `protobuf:"bytes,7,opt,name=amount,proto3,customtype=cosmossdk.io/math.Int" json:"amount" yaml:"amount"` } @@ -79,7 +79,7 @@ type Withdrawal struct { func (m *Withdrawal) Reset() { *m = Withdrawal{} } func (*Withdrawal) ProtoMessage() {} func (*Withdrawal) Descriptor() ([]byte, []int) { - return fileDescriptor_bc9c262f4256300e, []int{0} + return fileDescriptor_bde70a5bf22ba89e, []int{0} } func (m *Withdrawal) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -109,49 +109,49 @@ func (m *Withdrawal) XXX_DiscardUnknown() { var xxx_messageInfo_Withdrawal proto.InternalMessageInfo func init() { - proto.RegisterEnum("sgenetwork.sge.house.WithdrawalMode", WithdrawalMode_name, WithdrawalMode_value) - proto.RegisterType((*Withdrawal)(nil), "sgenetwork.sge.house.Withdrawal") + proto.RegisterEnum("sge.legacy.house.v1beta.WithdrawalMode", WithdrawalMode_name, WithdrawalMode_value) + proto.RegisterType((*Withdrawal)(nil), "sge.legacy.house.v1beta.Withdrawal") } func init() { - proto.RegisterFile("sgenetwork/sge/house/withdraw.proto", fileDescriptor_bc9c262f4256300e) + proto.RegisterFile("sge/legacy/house/v1beta/withdraw.proto", fileDescriptor_bde70a5bf22ba89e) } -var fileDescriptor_bc9c262f4256300e = []byte{ - // 517 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0x41, 0x6f, 0xda, 0x3e, - 0x18, 0xc6, 0x93, 0x94, 0x3f, 0x15, 0xfe, 0x6f, 0x0c, 0x79, 0x4c, 0x4b, 0x41, 0x8a, 0x51, 0xb6, - 0x03, 0xab, 0xd4, 0x20, 0x6d, 0xb7, 0xee, 0x04, 0x03, 0xb4, 0x48, 0xb0, 0x56, 0x69, 0x11, 0xd2, - 0x2e, 0x28, 0xc5, 0x56, 0xb0, 0x68, 0x62, 0x14, 0x1b, 0xd1, 0x7e, 0x83, 0x1d, 0x77, 0xdc, 0x91, - 0x0f, 0xb1, 0x0f, 0xd1, 0x63, 0xb5, 0xd3, 0xb4, 0x83, 0x35, 0xc1, 0x65, 0xda, 0x31, 0x9f, 0x60, - 0xc2, 0xc9, 0x54, 0x8a, 0xaa, 0xdd, 0x9c, 0xf7, 0xf9, 0xbd, 0xcf, 0xe3, 0xbc, 0x7e, 0xc1, 0x0b, - 0x1e, 0x90, 0x88, 0x88, 0x05, 0x8b, 0xa7, 0x0d, 0x1e, 0x90, 0xc6, 0x84, 0xcd, 0x39, 0x69, 0x2c, - 0xa8, 0x98, 0xe0, 0xd8, 0x5f, 0x38, 0xb3, 0x98, 0x09, 0x06, 0xcb, 0x77, 0x90, 0xc3, 0x03, 0xe2, - 0x28, 0xa8, 0x52, 0x0e, 0x58, 0xc0, 0x14, 0xd0, 0xd8, 0x9c, 0x52, 0xb6, 0x72, 0x30, 0x66, 0x3c, - 0x64, 0x7c, 0x94, 0x0a, 0xe9, 0x47, 0x2a, 0xd9, 0xc9, 0x1e, 0x00, 0xc3, 0xcc, 0xd9, 0xbf, 0x84, - 0x6d, 0xb0, 0x3f, 0x8e, 0x89, 0x2f, 0x58, 0x6c, 0xea, 0x35, 0xbd, 0x5e, 0x68, 0x1d, 0x26, 0x12, - 0x15, 0xaf, 0xfd, 0xf0, 0xf2, 0xd8, 0xce, 0x04, 0xfb, 0xdb, 0xd7, 0xa3, 0x72, 0xe6, 0xd1, 0xc4, - 0x38, 0x26, 0x9c, 0x9f, 0x89, 0x98, 0x46, 0x81, 0xf7, 0xb7, 0x15, 0xbe, 0x02, 0x06, 0xc5, 0xa6, - 0x51, 0xd3, 0xeb, 0xb9, 0xd6, 0xc1, 0x4a, 0x22, 0xc3, 0x6d, 0xff, 0x96, 0xc8, 0xa0, 0x38, 0x91, - 0xa8, 0x90, 0x9a, 0x51, 0x6c, 0x7b, 0x06, 0xc5, 0x9b, 0x40, 0x3f, 0x35, 0x31, 0xf7, 0x76, 0x03, - 0x33, 0xe1, 0x1f, 0x81, 0x19, 0x01, 0xdf, 0x02, 0x10, 0xfa, 0xf1, 0x94, 0x88, 0xd1, 0x9c, 0x62, - 0x33, 0xa7, 0x8c, 0xaa, 0x2b, 0x89, 0x0a, 0x7d, 0x55, 0x1d, 0xa8, 0xfc, 0x2d, 0xc4, 0xdb, 0x3a, - 0xc3, 0x13, 0xf0, 0x74, 0xe6, 0xc7, 0x82, 0x8e, 0xe9, 0xcc, 0x17, 0x94, 0x45, 0x23, 0x1a, 0x61, - 0x72, 0x65, 0xfe, 0xa7, 0xae, 0x6f, 0x25, 0x12, 0x55, 0xd2, 0xeb, 0x3c, 0x00, 0xd9, 0x1e, 0xbc, - 0x57, 0x75, 0x37, 0x45, 0xe8, 0x82, 0x5c, 0xc8, 0x30, 0x31, 0xf3, 0x35, 0xbd, 0x5e, 0x7c, 0xfd, - 0xd2, 0x79, 0xe8, 0xa5, 0x9c, 0xbb, 0xa1, 0xf7, 0x19, 0x26, 0xad, 0x27, 0x89, 0x44, 0xff, 0xa7, - 0x39, 0x9b, 0x5e, 0xdb, 0x53, 0x16, 0xb0, 0x0b, 0xf2, 0x7e, 0xc8, 0xe6, 0x91, 0x30, 0xf7, 0xd5, - 0x4f, 0x39, 0x37, 0x12, 0x69, 0x3f, 0x24, 0x7a, 0x96, 0xce, 0x83, 0xe3, 0xa9, 0x43, 0x59, 0x23, - 0xf4, 0xc5, 0xc4, 0x71, 0x23, 0x91, 0x48, 0xf4, 0x38, 0x1b, 0x9d, 0x6a, 0xb2, 0xbd, 0xac, 0xfb, - 0xf8, 0xd1, 0xa7, 0x25, 0xd2, 0xbe, 0x2c, 0x91, 0xf6, 0x6b, 0x89, 0xb4, 0xc3, 0x09, 0x28, 0xde, - 0x8f, 0x87, 0x08, 0x54, 0x87, 0xee, 0xf9, 0xfb, 0xb6, 0xd7, 0x1c, 0x36, 0x7b, 0xa3, 0xfe, 0x49, - 0xbb, 0x33, 0x1a, 0x7c, 0x38, 0x3b, 0xed, 0xbc, 0x73, 0xbb, 0x6e, 0xa7, 0x5d, 0xd2, 0xa0, 0x09, - 0xca, 0xbb, 0x40, 0x77, 0xd0, 0xeb, 0x95, 0x74, 0x58, 0x05, 0xcf, 0x77, 0x95, 0xd3, 0xa6, 0x77, - 0xee, 0x36, 0x7b, 0x25, 0xa3, 0xd5, 0xba, 0x59, 0x59, 0xfa, 0xed, 0xca, 0xd2, 0x7f, 0xae, 0x2c, - 0xfd, 0xf3, 0xda, 0xd2, 0x6e, 0xd7, 0x96, 0xf6, 0x7d, 0x6d, 0x69, 0x1f, 0xeb, 0x01, 0x15, 0x93, - 0xf9, 0x85, 0x33, 0x66, 0xe1, 0x66, 0xc9, 0x8f, 0xb6, 0x17, 0xfe, 0x2a, 0x5b, 0x79, 0x71, 0x3d, - 0x23, 0xfc, 0x22, 0xaf, 0x36, 0xf5, 0xcd, 0x9f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xa3, 0xef, 0xfe, - 0x94, 0x17, 0x03, 0x00, 0x00, +var fileDescriptor_bde70a5bf22ba89e = []byte{ + // 527 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x93, 0x41, 0x8f, 0xd2, 0x40, + 0x14, 0xc7, 0xdb, 0xee, 0xca, 0x86, 0x51, 0x91, 0x8c, 0x98, 0xed, 0x42, 0xd2, 0x21, 0x3d, 0x28, + 0x6e, 0xb2, 0x6d, 0xd4, 0xdb, 0x7a, 0x02, 0x81, 0xd8, 0x04, 0xdc, 0x4d, 0x77, 0x09, 0x89, 0x17, + 0x32, 0x30, 0x93, 0x32, 0x81, 0x76, 0x48, 0x3b, 0xc8, 0xf2, 0x0d, 0x3c, 0x7a, 0xf4, 0xc8, 0x87, + 0xf0, 0x43, 0xec, 0x71, 0xe3, 0xc9, 0x78, 0x68, 0x0c, 0x5c, 0x8c, 0x47, 0x12, 0xef, 0x86, 0x4e, + 0x8d, 0x0b, 0x51, 0x6f, 0xaf, 0xef, 0xff, 0x7b, 0xff, 0xff, 0xf4, 0xb5, 0x03, 0x1e, 0x47, 0x1e, + 0xb5, 0xc7, 0xd4, 0xc3, 0x83, 0xb9, 0x3d, 0xe4, 0xd3, 0x88, 0xda, 0xef, 0x9e, 0xf5, 0xa9, 0xc0, + 0xf6, 0x8c, 0x89, 0x21, 0x09, 0xf1, 0xcc, 0x9a, 0x84, 0x5c, 0x70, 0x78, 0x18, 0x79, 0xd4, 0x92, + 0x9c, 0x95, 0x70, 0x96, 0xe4, 0x8a, 0x05, 0x8f, 0x7b, 0x3c, 0x61, 0xec, 0x4d, 0x25, 0xf1, 0xe2, + 0xd1, 0x80, 0x47, 0x3e, 0x8f, 0x7a, 0x52, 0x90, 0x0f, 0x52, 0x32, 0x7f, 0xee, 0x01, 0xd0, 0x4d, + 0xcd, 0xf1, 0x18, 0xd6, 0xc1, 0xc1, 0x20, 0xa4, 0x58, 0xf0, 0x50, 0x57, 0xcb, 0x6a, 0x25, 0x5b, + 0x3b, 0x5e, 0xc7, 0x28, 0x37, 0xc7, 0xfe, 0xf8, 0xd4, 0x4c, 0x05, 0xf3, 0xf3, 0xa7, 0x93, 0x42, + 0xea, 0x51, 0x25, 0x24, 0xa4, 0x51, 0x74, 0x21, 0x42, 0x16, 0x78, 0xee, 0xef, 0x51, 0xf8, 0x14, + 0x68, 0x8c, 0xe8, 0x5a, 0x59, 0xad, 0xec, 0xd7, 0x8e, 0x96, 0x31, 0xd2, 0x9c, 0xfa, 0x8f, 0x18, + 0x69, 0x8c, 0xac, 0x63, 0x94, 0x95, 0x66, 0x8c, 0x98, 0xae, 0xc6, 0xc8, 0x26, 0x10, 0x4b, 0x13, + 0x7d, 0x6f, 0x37, 0x30, 0x15, 0xfe, 0x13, 0x98, 0x12, 0xf0, 0x25, 0x00, 0x3e, 0x0e, 0x47, 0x54, + 0xf4, 0xa6, 0x8c, 0xe8, 0xfb, 0x89, 0x51, 0x69, 0x19, 0xa3, 0x6c, 0x3b, 0xe9, 0x76, 0x92, 0xfc, + 0x5b, 0x88, 0x7b, 0xab, 0x86, 0x67, 0xe0, 0xe1, 0x04, 0x87, 0x82, 0x0d, 0xd8, 0x04, 0x0b, 0xc6, + 0x83, 0x1e, 0x0b, 0x08, 0xbd, 0xd2, 0xef, 0x24, 0xc7, 0x37, 0xd6, 0x31, 0x2a, 0xca, 0xe3, 0xfc, + 0x05, 0x32, 0x5d, 0xb8, 0xd5, 0x75, 0x36, 0x4d, 0xd8, 0x02, 0xfb, 0x3e, 0x27, 0x54, 0xcf, 0x94, + 0xd5, 0x4a, 0xee, 0xf9, 0x13, 0xeb, 0x1f, 0x1f, 0xcb, 0xfa, 0xb3, 0xf7, 0x36, 0x27, 0xb4, 0xf6, + 0x60, 0x1d, 0xa3, 0xbb, 0x32, 0x6a, 0x33, 0x6e, 0xba, 0x89, 0x0b, 0x6c, 0x82, 0x0c, 0xf6, 0xf9, + 0x34, 0x10, 0xfa, 0x41, 0xf2, 0x5e, 0xd6, 0x75, 0x8c, 0x94, 0xaf, 0x31, 0x7a, 0x24, 0x57, 0x12, + 0x91, 0x91, 0xc5, 0xb8, 0xed, 0x63, 0x31, 0xb4, 0x9c, 0x40, 0xac, 0x63, 0x74, 0x3f, 0xdd, 0x5e, + 0x32, 0x64, 0xba, 0xe9, 0xf4, 0xe9, 0xbd, 0xf7, 0x0b, 0xa4, 0x7c, 0x5c, 0x20, 0xe5, 0xfb, 0x02, + 0x29, 0xc7, 0x43, 0x90, 0xdb, 0x8e, 0x87, 0x08, 0x94, 0xba, 0xce, 0xe5, 0xeb, 0xba, 0x5b, 0xed, + 0x56, 0x5b, 0xbd, 0xf6, 0x59, 0xbd, 0xd1, 0xeb, 0xbc, 0xb9, 0x38, 0x6f, 0xbc, 0x72, 0x9a, 0x4e, + 0xa3, 0x9e, 0x57, 0xa0, 0x0e, 0x0a, 0xbb, 0x40, 0xb3, 0xd3, 0x6a, 0xe5, 0x55, 0x58, 0x02, 0x87, + 0xbb, 0xca, 0x79, 0xd5, 0xbd, 0x74, 0xaa, 0xad, 0xbc, 0x56, 0x73, 0xae, 0x97, 0x86, 0x7a, 0xb3, + 0x34, 0xd4, 0x6f, 0x4b, 0x43, 0xfd, 0xb0, 0x32, 0x94, 0x9b, 0x95, 0xa1, 0x7c, 0x59, 0x19, 0xca, + 0x5b, 0xdb, 0x63, 0x62, 0x38, 0xed, 0x5b, 0x03, 0xee, 0xdb, 0x91, 0x47, 0x4f, 0x02, 0x2a, 0x66, + 0x3c, 0x1c, 0x6d, 0x6a, 0xfb, 0x6a, 0xfb, 0x1a, 0x88, 0xf9, 0x84, 0x46, 0xfd, 0x4c, 0xf2, 0xcf, + 0xbe, 0xf8, 0x15, 0x00, 0x00, 0xff, 0xff, 0xc9, 0x1e, 0xc1, 0xb6, 0x27, 0x03, 0x00, 0x00, } func (m *Withdrawal) Marshal() (dAtA []byte, err error) { diff --git a/x/house/types/withdraw_authorizaton.go b/x/legacy/house/types/withdraw_authorizaton.go similarity index 93% rename from x/house/types/withdraw_authorizaton.go rename to x/legacy/house/types/withdraw_authorizaton.go index 2cfc7f67..d24352bb 100644 --- a/x/house/types/withdraw_authorizaton.go +++ b/x/legacy/house/types/withdraw_authorizaton.go @@ -1,6 +1,8 @@ package types import ( + context "context" + sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" @@ -22,7 +24,7 @@ func (WithdrawAuthorization) MsgTypeURL() string { } // Accept implements Authorization.Accept. -func (a WithdrawAuthorization) Accept(_ sdk.Context, msg sdk.Msg) (authz.AcceptResponse, error) { +func (a WithdrawAuthorization) Accept(_ context.Context, msg sdk.Msg) (authz.AcceptResponse, error) { mWithdraw, ok := msg.(*MsgWithdraw) if !ok { return authz.AcceptResponse{}, sdkerrtypes.ErrInvalidType.Wrap("type mismatch") diff --git a/x/house/types/withdrawal.go b/x/legacy/house/types/withdrawal.go similarity index 100% rename from x/house/types/withdrawal.go rename to x/legacy/house/types/withdrawal.go diff --git a/x/market/client/cli/query.go b/x/legacy/market/client/cli/query.go similarity index 92% rename from x/market/client/cli/query.go rename to x/legacy/market/client/cli/query.go index edf31911..1fd869f9 100644 --- a/x/market/client/cli/query.go +++ b/x/legacy/market/client/cli/query.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // GetQueryCmd returns the cli query commands for this module diff --git a/x/market/client/cli/query_market.go b/x/legacy/market/client/cli/query_market.go similarity index 97% rename from x/market/client/cli/query_market.go rename to x/legacy/market/client/cli/query_market.go index 8c4dea97..0c6a1a89 100644 --- a/x/market/client/cli/query_market.go +++ b/x/legacy/market/client/cli/query_market.go @@ -9,7 +9,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // CmdListMarkets implements a command to return all markets diff --git a/x/market/client/cli/query_params.go b/x/legacy/market/client/cli/query_params.go similarity index 93% rename from x/market/client/cli/query_params.go rename to x/legacy/market/client/cli/query_params.go index d7fd4833..7ea8f978 100644 --- a/x/market/client/cli/query_params.go +++ b/x/legacy/market/client/cli/query_params.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // CmdQueryParams returns the cmd function of params diff --git a/x/market/client/cli/tx.go b/x/legacy/market/client/cli/tx.go similarity index 91% rename from x/market/client/cli/tx.go rename to x/legacy/market/client/cli/tx.go index 2fbc06c6..0bb38e4c 100644 --- a/x/market/client/cli/tx.go +++ b/x/legacy/market/client/cli/tx.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) const listSeparator = "," diff --git a/x/market/client/cli/tx_market.go b/x/legacy/market/client/cli/tx_market.go similarity index 96% rename from x/market/client/cli/tx_market.go rename to x/legacy/market/client/cli/tx_market.go index da3d909e..02f037c1 100644 --- a/x/market/client/cli/tx_market.go +++ b/x/legacy/market/client/cli/tx_market.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // CmdAddMarket CLI registration for add market command diff --git a/x/market/client/cli/tx_resolve_market.go b/x/legacy/market/client/cli/tx_resolve_market.go similarity index 94% rename from x/market/client/cli/tx_resolve_market.go rename to x/legacy/market/client/cli/tx_resolve_market.go index c163589b..4081f3cb 100644 --- a/x/market/client/cli/tx_resolve_market.go +++ b/x/legacy/market/client/cli/tx_resolve_market.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // CmdResolveMarket registers the resolve market command diff --git a/x/market/genesis.go b/x/legacy/market/genesis.go similarity index 86% rename from x/market/genesis.go rename to x/legacy/market/genesis.go index fa4ee40b..5bd1586a 100644 --- a/x/market/genesis.go +++ b/x/legacy/market/genesis.go @@ -3,8 +3,8 @@ package market import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/market/keeper" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/keeper" + "github.com/sge-network/sge/x/legacy/market/types" ) // InitGenesis initializes the module's state from a provided genesis diff --git a/x/house/keeper/export_test.go b/x/legacy/market/keeper/export_test.go similarity index 100% rename from x/house/keeper/export_test.go rename to x/legacy/market/keeper/export_test.go diff --git a/x/house/keeper/grpc_query.go b/x/legacy/market/keeper/grpc_query.go similarity index 54% rename from x/house/keeper/grpc_query.go rename to x/legacy/market/keeper/grpc_query.go index 403cd919..52ddea21 100644 --- a/x/house/keeper/grpc_query.go +++ b/x/legacy/market/keeper/grpc_query.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/market/types" ) var _ types.QueryServer = Keeper{} diff --git a/x/market/keeper/grpc_query_market.go b/x/legacy/market/keeper/grpc_query_market.go similarity index 97% rename from x/market/keeper/grpc_query_market.go rename to x/legacy/market/keeper/grpc_query_market.go index 1dd3881b..1a9c3515 100644 --- a/x/market/keeper/grpc_query_market.go +++ b/x/legacy/market/keeper/grpc_query_market.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // Markets returns all the markets diff --git a/x/market/keeper/grpc_query_params.go b/x/legacy/market/keeper/grpc_query_params.go similarity index 91% rename from x/market/keeper/grpc_query_params.go rename to x/legacy/market/keeper/grpc_query_params.go index 840ca7b1..d5a10874 100644 --- a/x/market/keeper/grpc_query_params.go +++ b/x/legacy/market/keeper/grpc_query_params.go @@ -9,7 +9,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // Params returns the params of the module diff --git a/x/market/keeper/keeper.go b/x/legacy/market/keeper/keeper.go similarity index 92% rename from x/market/keeper/keeper.go rename to x/legacy/market/keeper/keeper.go index 65b8597f..653f7397 100644 --- a/x/market/keeper/keeper.go +++ b/x/legacy/market/keeper/keeper.go @@ -3,15 +3,14 @@ package keeper import ( "fmt" - storetypes "github.com/cosmos/cosmos-sdk/store/types" - - "github.com/cometbft/cometbft/libs/log" + storetypes "cosmossdk.io/store/types" + "cosmossdk.io/log" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // Keeper is the type for module properties diff --git a/x/market/keeper/market.go b/x/legacy/market/keeper/market.go similarity index 93% rename from x/market/keeper/market.go rename to x/legacy/market/keeper/market.go index a945e408..22247586 100644 --- a/x/market/keeper/market.go +++ b/x/legacy/market/keeper/market.go @@ -1,10 +1,11 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // SetMarket sets a specific market in the store @@ -36,7 +37,7 @@ func (k Keeper) MarketExists(ctx sdk.Context, marketUID string) bool { // GetMarkets returns all markets func (k Keeper) GetMarkets(ctx sdk.Context) (list []types.Market, err error) { store := k.getMarketsStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/orderbook/keeper/msg_server.go b/x/legacy/market/keeper/msg_server.go similarity index 84% rename from x/orderbook/keeper/msg_server.go rename to x/legacy/market/keeper/msg_server.go index ab6771dc..58acc2a7 100644 --- a/x/orderbook/keeper/msg_server.go +++ b/x/legacy/market/keeper/msg_server.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/market/types" ) type msgServer struct { diff --git a/x/market/keeper/msg_server_market.go b/x/legacy/market/keeper/msg_server_market.go similarity index 98% rename from x/market/keeper/msg_server_market.go rename to x/legacy/market/keeper/msg_server_market.go index d2412e77..976b6092 100644 --- a/x/market/keeper/msg_server_market.go +++ b/x/legacy/market/keeper/msg_server_market.go @@ -6,7 +6,7 @@ import ( sdkerrors "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // Add accepts ticket containing creation market and return response after processing diff --git a/x/market/keeper/msg_server_market_resolve.go b/x/legacy/market/keeper/msg_server_market_resolve.go similarity index 96% rename from x/market/keeper/msg_server_market_resolve.go rename to x/legacy/market/keeper/msg_server_market_resolve.go index d8401242..5ef6bef1 100644 --- a/x/market/keeper/msg_server_market_resolve.go +++ b/x/legacy/market/keeper/msg_server_market_resolve.go @@ -6,7 +6,7 @@ import ( sdkerrors "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // Resolve accepts ticket containing resolution markets and return response after processing diff --git a/x/market/keeper/msg_server_params.go b/x/legacy/market/keeper/msg_server_params.go similarity index 92% rename from x/market/keeper/msg_server_params.go rename to x/legacy/market/keeper/msg_server_params.go index 31fa96e4..6a292c29 100644 --- a/x/market/keeper/msg_server_params.go +++ b/x/legacy/market/keeper/msg_server_params.go @@ -7,7 +7,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { diff --git a/x/ovm/keeper/params.go b/x/legacy/market/keeper/params.go similarity index 87% rename from x/ovm/keeper/params.go rename to x/legacy/market/keeper/params.go index 823a458c..24564ff7 100644 --- a/x/ovm/keeper/params.go +++ b/x/legacy/market/keeper/params.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // GetParams get all parameters as types.Params diff --git a/x/market/keeper/stats.go b/x/legacy/market/keeper/stats.go similarity index 97% rename from x/market/keeper/stats.go rename to x/legacy/market/keeper/stats.go index 0c15cf05..6911e407 100644 --- a/x/market/keeper/stats.go +++ b/x/legacy/market/keeper/stats.go @@ -4,7 +4,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // SetMarketStats sets market statistics in the store diff --git a/x/market/keeper/view.go b/x/legacy/market/keeper/view.go similarity index 85% rename from x/market/keeper/view.go rename to x/legacy/market/keeper/view.go index d14e6350..f5f39866 100644 --- a/x/market/keeper/view.go +++ b/x/legacy/market/keeper/view.go @@ -1,10 +1,10 @@ package keeper import ( - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // getMarketsStore gets the store containing all markets. diff --git a/x/market/module.go b/x/legacy/market/module.go similarity index 90% rename from x/market/module.go rename to x/legacy/market/module.go index 4ab32aa7..8cef959e 100644 --- a/x/market/module.go +++ b/x/legacy/market/module.go @@ -18,9 +18,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/market/client/cli" - "github.com/sge-network/sge/x/market/keeper" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/client/cli" + "github.com/sge-network/sge/x/legacy/market/keeper" + "github.com/sge-network/sge/x/legacy/market/types" ) var ( @@ -121,8 +121,8 @@ func NewAppModule( accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, ovmKeeper types.OVMKeeper, -) AppModule { - return AppModule{ +) *AppModule { + return &AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, accountKeeper: accountKeeper, @@ -131,6 +131,12 @@ func NewAppModule( } } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} + +// IsOnePerModuleType is a marker function just indicates that this is a one-per-module type. +func (am AppModule) IsOnePerModuleType() {} + // Name returns the module's name. func (am AppModule) Name() string { return am.AppModuleBasic.Name() @@ -178,10 +184,10 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock executes all ABCI BeginBlock logic respective to the module. -func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} +func (AppModule) BeginBlock(_ sdk.Context) {} // EndBlock executes all ABCI EndBlock logic respective to the module. It // returns no validator updates. -func (AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { +func (AppModule) EndBlock(_ sdk.Context) []abci.ValidatorUpdate { return []abci.ValidatorUpdate{} } diff --git a/x/market/module_simulation.go b/x/legacy/market/module_simulation.go similarity index 85% rename from x/market/module_simulation.go rename to x/legacy/market/module_simulation.go index 55416425..e12d52fb 100644 --- a/x/market/module_simulation.go +++ b/x/legacy/market/module_simulation.go @@ -6,14 +6,13 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/sge-network/sge/testutil/sample" - marketsimulation "github.com/sge-network/sge/x/market/simulation" - "github.com/sge-network/sge/x/market/types" + marketsimulation "github.com/sge-network/sge/x/legacy/market/simulation" + "github.com/sge-network/sge/x/legacy/market/types" ) // avoid unused import issue @@ -50,7 +49,7 @@ func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedP } // RegisterStoreDecoder registers a decoder -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { sdr[types.StoreKey] = marketsimulation.NewDecodeStore(am.cdc) } @@ -59,7 +58,7 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp operations := make([]simtypes.WeightedOperation, 0) var weightMsgAdd int - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgAdd, &weightMsgAdd, nil, + simState.AppParams.GetOrGenerate(opWeightMsgAdd, &weightMsgAdd, nil, func(_ *rand.Rand) { weightMsgAdd = defaultWeightMsgAdd }, @@ -71,7 +70,6 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp var weightMsgResolve int simState.AppParams.GetOrGenerate( - simState.Cdc, opWeightMsgResolve, &weightMsgResolve, nil, @@ -85,7 +83,7 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp )) var weightMsgUpdate int - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgUpdate, &weightMsgUpdate, nil, + simState.AppParams.GetOrGenerate(opWeightMsgUpdate, &weightMsgUpdate, nil, func(_ *rand.Rand) { weightMsgUpdate = defaultWeightMsgUpdate }, diff --git a/x/market/simulation/decoder.go b/x/legacy/market/simulation/decoder.go similarity index 94% rename from x/market/simulation/decoder.go rename to x/legacy/market/simulation/decoder.go index cedde969..dcd62a45 100644 --- a/x/market/simulation/decoder.go +++ b/x/legacy/market/simulation/decoder.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // NewDecodeStore returns a decoder function closure that unmarshal the KVPair's diff --git a/x/market/simulation/errors.go b/x/legacy/market/simulation/errors.go similarity index 100% rename from x/market/simulation/errors.go rename to x/legacy/market/simulation/errors.go diff --git a/x/market/simulation/genesis.go b/x/legacy/market/simulation/genesis.go similarity index 89% rename from x/market/simulation/genesis.go rename to x/legacy/market/simulation/genesis.go index 9b8d6ac9..4bd21bdc 100644 --- a/x/market/simulation/genesis.go +++ b/x/legacy/market/simulation/genesis.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // RandomizedGenState generates a random GenesisState for market diff --git a/x/market/simulation/market.go b/x/legacy/market/simulation/market.go similarity index 93% rename from x/market/simulation/market.go rename to x/legacy/market/simulation/market.go index e5bd2e06..2ef503c9 100644 --- a/x/market/simulation/market.go +++ b/x/legacy/market/simulation/market.go @@ -8,8 +8,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/market/keeper" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/keeper" + "github.com/sge-network/sge/x/legacy/market/types" ) // SimulateMsgAdd simulates the add market flow diff --git a/x/market/simulation/market_update.go b/x/legacy/market/simulation/market_update.go similarity index 88% rename from x/market/simulation/market_update.go rename to x/legacy/market/simulation/market_update.go index 1dc4eb44..6b0ec83e 100644 --- a/x/market/simulation/market_update.go +++ b/x/legacy/market/simulation/market_update.go @@ -8,8 +8,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/market/keeper" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/keeper" + "github.com/sge-network/sge/x/legacy/market/types" ) // SimulateMsgUpdate simulates update market message diff --git a/x/market/simulation/params.go b/x/legacy/market/simulation/params.go similarity index 100% rename from x/market/simulation/params.go rename to x/legacy/market/simulation/params.go diff --git a/x/market/simulation/proposals.go b/x/legacy/market/simulation/proposals.go similarity index 95% rename from x/market/simulation/proposals.go rename to x/legacy/market/simulation/proposals.go index 2be67a41..b6643420 100644 --- a/x/market/simulation/proposals.go +++ b/x/legacy/market/simulation/proposals.go @@ -8,7 +8,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) // Simulation operation weights constants diff --git a/x/market/simulation/simap.go b/x/legacy/market/simulation/simap.go similarity index 100% rename from x/market/simulation/simap.go rename to x/legacy/market/simulation/simap.go diff --git a/x/market/types/codec.go b/x/legacy/market/types/codec.go similarity index 100% rename from x/market/types/codec.go rename to x/legacy/market/types/codec.go diff --git a/x/market/types/consts.go b/x/legacy/market/types/consts.go similarity index 100% rename from x/market/types/consts.go rename to x/legacy/market/types/consts.go diff --git a/x/market/types/errors.go b/x/legacy/market/types/errors.go similarity index 100% rename from x/market/types/errors.go rename to x/legacy/market/types/errors.go diff --git a/x/market/types/events.go b/x/legacy/market/types/events.go similarity index 100% rename from x/market/types/events.go rename to x/legacy/market/types/events.go diff --git a/x/market/types/expected_keepers.go b/x/legacy/market/types/expected_keepers.go similarity index 82% rename from x/market/types/expected_keepers.go rename to x/legacy/market/types/expected_keepers.go index fc5eda18..11ee981a 100644 --- a/x/market/types/expected_keepers.go +++ b/x/legacy/market/types/expected_keepers.go @@ -4,18 +4,17 @@ import ( "context" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/auth/types" ) // AccountKeeper defines the expected account keeper used for simulations (noalias) type AccountKeeper interface { - GetAccount(ctx sdk.Context, addr sdk.AccAddress) types.AccountI + GetAccount(ctx context.Context, addr sdk.AccAddress) sdk.AccountI // Methods imported from account should be defined here } // BankKeeper defines the expected interface needed to retrieve account balances. type BankKeeper interface { - SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins + SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins // Methods imported from bank should be defined here } diff --git a/x/market/types/genesis.go b/x/legacy/market/types/genesis.go similarity index 100% rename from x/market/types/genesis.go rename to x/legacy/market/types/genesis.go diff --git a/x/market/types/genesis.pb.go b/x/legacy/market/types/genesis.pb.go similarity index 82% rename from x/market/types/genesis.pb.go rename to x/legacy/market/types/genesis.pb.go index 96234406..1f4eadc9 100644 --- a/x/market/types/genesis.pb.go +++ b/x/legacy/market/types/genesis.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/genesis.proto +// source: sge/legacy/market/v1beta/genesis.proto package types @@ -38,7 +38,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_eb5c3fab001b4377, []int{0} + return fileDescriptor_7a22a1093163c4cf, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -89,32 +89,33 @@ func (m *GenesisState) GetStats() MarketStats { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.market.GenesisState") + proto.RegisterType((*GenesisState)(nil), "sge.legacy.market.v1beta.GenesisState") } func init() { - proto.RegisterFile("sgenetwork/sge/market/genesis.proto", fileDescriptor_eb5c3fab001b4377) + proto.RegisterFile("sge/legacy/market/v1beta/genesis.proto", fileDescriptor_7a22a1093163c4cf) } -var fileDescriptor_eb5c3fab001b4377 = []byte{ - // 261 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2e, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, - 0x2d, 0xd1, 0x07, 0x09, 0x16, 0x67, 0x16, 0xeb, 0x15, 0x14, 0xe5, 0x97, 0xe4, 0x0b, 0x89, 0x22, - 0x14, 0xe9, 0x15, 0xa7, 0xa7, 0xea, 0x41, 0x14, 0x49, 0x89, 0xa4, 0xe7, 0xa7, 0xe7, 0x83, 0x55, - 0xe8, 0x83, 0x58, 0x10, 0xc5, 0x52, 0x4a, 0xd8, 0x4d, 0x2c, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xc6, - 0xaf, 0x06, 0x42, 0x41, 0xd5, 0x28, 0x62, 0x57, 0x53, 0x5c, 0x92, 0x58, 0x02, 0x35, 0x46, 0xe9, - 0x22, 0x23, 0x17, 0x8f, 0x3b, 0xc4, 0xa5, 0xc1, 0x25, 0x89, 0x25, 0xa9, 0x42, 0xd6, 0x5c, 0x6c, - 0x10, 0x7b, 0x24, 0x18, 0x15, 0x18, 0x35, 0xb8, 0x8d, 0x64, 0xf5, 0xb0, 0xba, 0x5c, 0x2f, 0x00, - 0xac, 0xc8, 0x89, 0xe5, 0xc4, 0x3d, 0x79, 0x86, 0x20, 0xa8, 0x16, 0x21, 0x17, 0x2e, 0x6e, 0x88, - 0x74, 0x7c, 0x4e, 0x66, 0x71, 0x89, 0x04, 0x93, 0x02, 0x33, 0x1e, 0x13, 0x7c, 0xc1, 0x14, 0xd4, - 0x04, 0x2e, 0x88, 0xa0, 0x4f, 0x66, 0x71, 0x89, 0x90, 0x1d, 0x17, 0x2b, 0xd8, 0x89, 0x12, 0xcc, - 0x60, 0x17, 0x28, 0xe1, 0xd5, 0x0f, 0x72, 0x35, 0xcc, 0x19, 0x10, 0x6d, 0x4e, 0xce, 0x27, 0x1e, - 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, - 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x99, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, - 0x97, 0x9c, 0x9f, 0x0b, 0x0a, 0x10, 0x5d, 0xe4, 0xc0, 0xa9, 0x80, 0x05, 0x4f, 0x49, 0x65, 0x41, - 0x6a, 0x71, 0x12, 0x1b, 0x38, 0x7c, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0x85, 0xde, 0x12, - 0x51, 0xde, 0x01, 0x00, 0x00, +var fileDescriptor_7a22a1093163c4cf = []byte{ + // 279 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2b, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, 0x2d, 0xd1, 0x2f, 0x33, + 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, + 0x2f, 0xc9, 0x17, 0x92, 0x28, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0xd3, 0x83, 0xa8, 0xd3, 0x83, 0xa8, + 0x93, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd2, 0x07, 0xb1, 0x20, 0xea, 0xa5, 0x54, 0x71, + 0x9a, 0x0b, 0xd5, 0x4d, 0x48, 0x59, 0x41, 0x62, 0x51, 0x62, 0x2e, 0xd4, 0x76, 0x29, 0x15, 0x9c, + 0xca, 0x8a, 0x4b, 0x12, 0x4b, 0xa0, 0xaa, 0x94, 0x6e, 0x31, 0x72, 0xf1, 0xb8, 0x43, 0x5c, 0x1d, + 0x5c, 0x92, 0x58, 0x92, 0x2a, 0x64, 0xc7, 0xc5, 0x06, 0x31, 0x46, 0x82, 0x51, 0x81, 0x51, 0x83, + 0xdb, 0x48, 0x41, 0x0f, 0x97, 0x2f, 0xf4, 0x02, 0xc0, 0xea, 0x9c, 0x58, 0x4e, 0xdc, 0x93, 0x67, + 0x08, 0x82, 0xea, 0x12, 0x72, 0xe7, 0xe2, 0x86, 0xa8, 0x8a, 0xcf, 0xc9, 0x2c, 0x2e, 0x91, 0x60, + 0x52, 0x60, 0xc6, 0x6f, 0x88, 0x2f, 0x98, 0x07, 0x35, 0x84, 0x0b, 0x22, 0xe7, 0x93, 0x59, 0x5c, + 0x22, 0xe4, 0xc8, 0xc5, 0x0a, 0x76, 0xa8, 0x04, 0x33, 0xd8, 0x1d, 0xaa, 0x84, 0x8c, 0x00, 0x39, + 0x1f, 0xe6, 0x18, 0x88, 0x4e, 0x27, 0xaf, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, + 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, + 0x88, 0x32, 0x48, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x2f, 0x4e, 0x4f, + 0xd5, 0xcd, 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0x06, 0xb1, 0xf5, 0x2b, 0xd0, 0x42, 0xad, 0xa4, + 0xb2, 0x20, 0xb5, 0x38, 0x89, 0x0d, 0x1c, 0x5e, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x6f, + 0x49, 0x58, 0x4b, 0xfd, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/market/types/genesis_test.go b/x/legacy/market/types/genesis_test.go similarity index 94% rename from x/market/types/genesis_test.go rename to x/legacy/market/types/genesis_test.go index 933f00ee..54d68c25 100644 --- a/x/market/types/genesis_test.go +++ b/x/legacy/market/types/genesis_test.go @@ -5,7 +5,7 @@ import ( "github.com/stretchr/testify/require" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/market/types" ) func TestGenesisState_Validate(t *testing.T) { diff --git a/x/market/types/keys.go b/x/legacy/market/types/keys.go similarity index 100% rename from x/market/types/keys.go rename to x/legacy/market/types/keys.go diff --git a/x/market/types/market.go b/x/legacy/market/types/market.go similarity index 100% rename from x/market/types/market.go rename to x/legacy/market/types/market.go diff --git a/x/market/types/market.pb.go b/x/legacy/market/types/market.pb.go similarity index 81% rename from x/market/types/market.pb.go rename to x/legacy/market/types/market.pb.go index 4c6e02e5..e99ba02b 100644 --- a/x/market/types/market.pb.go +++ b/x/legacy/market/types/market.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/market.proto +// source: sge/legacy/market/v1beta/market.proto package types @@ -65,7 +65,7 @@ func (x MarketStatus) String() string { } func (MarketStatus) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_14e36a254c493254, []int{0} + return fileDescriptor_ee4ef6f925a4d489, []int{0} } // Market is the representation of the market to be stored in @@ -82,7 +82,7 @@ type Market struct { // winner_odds_uids is the list of winner odds universal unique identifiers. WinnerOddsUIDs []string `protobuf:"bytes,5,rep,name=winner_odds_uids,proto3" json:"winner_odds_uids"` // status is the current status of the market. - Status MarketStatus `protobuf:"varint,6,opt,name=status,proto3,enum=sgenetwork.sge.market.MarketStatus" json:"status,omitempty"` + Status MarketStatus `protobuf:"varint,6,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` // resolution_ts is the timestamp of the resolution of market. ResolutionTS uint64 `protobuf:"varint,7,opt,name=resolution_ts,proto3" json:"resolution_ts"` // creator is the address of the creator of market. @@ -97,7 +97,7 @@ func (m *Market) Reset() { *m = Market{} } func (m *Market) String() string { return proto.CompactTextString(m) } func (*Market) ProtoMessage() {} func (*Market) Descriptor() ([]byte, []int) { - return fileDescriptor_14e36a254c493254, []int{0} + return fileDescriptor_ee4ef6f925a4d489, []int{0} } func (m *Market) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -197,51 +197,52 @@ func (m *Market) GetBookUID() string { } func init() { - proto.RegisterEnum("sgenetwork.sge.market.MarketStatus", MarketStatus_name, MarketStatus_value) - proto.RegisterType((*Market)(nil), "sgenetwork.sge.market.Market") + proto.RegisterEnum("sge.legacy.market.v1beta.MarketStatus", MarketStatus_name, MarketStatus_value) + proto.RegisterType((*Market)(nil), "sge.legacy.market.v1beta.Market") } func init() { - proto.RegisterFile("sgenetwork/sge/market/market.proto", fileDescriptor_14e36a254c493254) -} - -var fileDescriptor_14e36a254c493254 = []byte{ - // 560 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x93, 0xcd, 0x6e, 0xd3, 0x4c, - 0x14, 0x86, 0xe3, 0xda, 0x4d, 0xdb, 0xf9, 0xfa, 0x55, 0xd6, 0xd0, 0x82, 0x5b, 0x54, 0xdb, 0x2d, - 0x12, 0x0a, 0xa0, 0x3a, 0x52, 0xbb, 0x64, 0xe5, 0x3f, 0x90, 0x45, 0x7f, 0xd0, 0xd8, 0x01, 0x89, - 0x8d, 0x95, 0xc4, 0x23, 0x63, 0x85, 0x78, 0x2a, 0xcf, 0x44, 0x85, 0xbb, 0x60, 0xc1, 0xa5, 0xb0, - 0x65, 0xcf, 0xb2, 0x62, 0xc5, 0xca, 0x42, 0xce, 0x2e, 0x57, 0x81, 0x66, 0xec, 0x86, 0x86, 0x94, - 0x8d, 0xe7, 0xcc, 0x79, 0xde, 0x33, 0x9e, 0x33, 0xaf, 0x0e, 0x38, 0xa4, 0x29, 0xce, 0x31, 0xbb, - 0x22, 0xc5, 0xa8, 0x4b, 0x53, 0xdc, 0x1d, 0xf7, 0x8b, 0x11, 0x66, 0xcd, 0x62, 0x5d, 0x16, 0x84, - 0x11, 0xb8, 0xf3, 0x47, 0x63, 0xd1, 0x14, 0x5b, 0x35, 0xdc, 0xdb, 0x4e, 0x49, 0x4a, 0x84, 0xa2, - 0xcb, 0xa3, 0x5a, 0xbc, 0xb7, 0x3b, 0x24, 0x74, 0x4c, 0x68, 0x5c, 0x83, 0x7a, 0xd3, 0x20, 0xf3, - 0xee, 0x7f, 0x91, 0x24, 0x69, 0x14, 0x87, 0x5f, 0x14, 0xd0, 0x3e, 0x13, 0x59, 0x68, 0x02, 0x79, - 0x92, 0x25, 0x9a, 0x64, 0x4a, 0x9d, 0x0d, 0x67, 0xab, 0x2a, 0x0d, 0xb9, 0x17, 0x78, 0xb3, 0xd2, - 0xe0, 0x59, 0xc4, 0x3f, 0xf0, 0x04, 0xac, 0x53, 0xd6, 0x2f, 0x58, 0xcc, 0xa8, 0xb6, 0x62, 0x4a, - 0x1d, 0xc5, 0x79, 0x50, 0x95, 0xc6, 0x5a, 0xc8, 0x73, 0x51, 0x38, 0x2b, 0x8d, 0x39, 0x46, 0xf3, - 0x08, 0x3e, 0x03, 0x6d, 0x9c, 0x27, 0xbc, 0x44, 0x16, 0x25, 0xf7, 0xaa, 0xd2, 0x58, 0xf5, 0xf3, - 0x44, 0x14, 0x34, 0x08, 0x35, 0x2b, 0xec, 0x02, 0x85, 0x5f, 0x4e, 0x53, 0x4c, 0xb9, 0xf3, 0xdf, - 0xf1, 0x43, 0xeb, 0xce, 0x77, 0xb0, 0x2e, 0x92, 0x84, 0x22, 0x21, 0x84, 0x08, 0xa8, 0x57, 0x59, - 0x9e, 0xe3, 0x22, 0xe6, 0xdb, 0x78, 0x92, 0x25, 0x54, 0x5b, 0x35, 0xe5, 0xce, 0x86, 0xf3, 0xb8, - 0x2a, 0x8d, 0xad, 0xb7, 0x82, 0x71, 0x7d, 0x2f, 0xf0, 0xe8, 0xac, 0x34, 0x96, 0xd4, 0x68, 0x29, - 0x03, 0x9f, 0x83, 0x36, 0x65, 0x7d, 0x36, 0xa1, 0x5a, 0xdb, 0x94, 0x3a, 0x5b, 0xc7, 0x8f, 0xfe, - 0x71, 0x8d, 0xfa, 0xdd, 0x42, 0x21, 0x45, 0x4d, 0x09, 0x7c, 0x09, 0xfe, 0x2f, 0x30, 0x25, 0x1f, - 0x26, 0x2c, 0x23, 0x39, 0xef, 0x7a, 0x4d, 0x74, 0x7d, 0x50, 0x95, 0xc6, 0x26, 0x9a, 0x03, 0xd1, - 0xfc, 0xa2, 0x10, 0x2d, 0x6e, 0xe1, 0x31, 0x58, 0x1b, 0x16, 0xb8, 0xcf, 0x48, 0xa1, 0xad, 0x0b, - 0x4b, 0xb4, 0x1f, 0x5f, 0x8f, 0xb6, 0x1b, 0x7b, 0xed, 0x24, 0x29, 0x30, 0xa5, 0x21, 0x2b, 0xb2, - 0x3c, 0x45, 0x37, 0x42, 0x08, 0x81, 0x32, 0xc6, 0xac, 0xaf, 0x6d, 0xf0, 0x02, 0x24, 0x62, 0x6e, - 0xda, 0x80, 0x90, 0x11, 0x6f, 0x4d, 0x03, 0xe2, 0x20, 0x61, 0x9a, 0x43, 0xc8, 0xa8, 0xf6, 0x77, - 0x8e, 0xd1, 0x3c, 0x7a, 0xfa, 0x4d, 0x02, 0x9b, 0xb7, 0xdb, 0x83, 0xfb, 0x60, 0xf7, 0xcc, 0x46, - 0xaf, 0xfc, 0x28, 0x0e, 0x23, 0x3b, 0xea, 0x85, 0x71, 0xef, 0x3c, 0x7c, 0xed, 0xbb, 0xc1, 0x8b, - 0xc0, 0xf7, 0xd4, 0x16, 0xd4, 0xc0, 0xf6, 0x22, 0xb6, 0xdd, 0x28, 0x78, 0xe3, 0xab, 0x12, 0xdc, - 0x03, 0xf7, 0x17, 0x49, 0x70, 0xde, 0xb0, 0x95, 0x65, 0xe6, 0xda, 0xe7, 0xae, 0x7f, 0xea, 0x7b, - 0xaa, 0x0c, 0x77, 0xc1, 0xce, 0x5f, 0x27, 0x3a, 0x17, 0x28, 0xf2, 0x3d, 0x55, 0x81, 0x07, 0x60, - 0x7f, 0x11, 0x21, 0x3f, 0xec, 0x9d, 0x46, 0xb1, 0xe7, 0xbb, 0xa7, 0x36, 0xf2, 0x3d, 0x75, 0xd5, - 0x71, 0xbf, 0x57, 0xba, 0x74, 0x5d, 0xe9, 0xd2, 0xaf, 0x4a, 0x97, 0x3e, 0x4f, 0xf5, 0xd6, 0xf5, - 0x54, 0x6f, 0xfd, 0x9c, 0xea, 0xad, 0x77, 0x4f, 0xd2, 0x8c, 0xbd, 0x9f, 0x0c, 0xac, 0x21, 0x19, - 0xf3, 0x91, 0x38, 0xba, 0x3d, 0x1e, 0x1f, 0x6f, 0x06, 0x84, 0x7d, 0xba, 0xc4, 0x74, 0xd0, 0x16, - 0x23, 0x72, 0xf2, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x1b, 0x8a, 0x2c, 0x9f, 0xb2, 0x03, 0x00, 0x00, + proto.RegisterFile("sge/legacy/market/v1beta/market.proto", fileDescriptor_ee4ef6f925a4d489) +} + +var fileDescriptor_ee4ef6f925a4d489 = []byte{ + // 570 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x93, 0xcf, 0x6e, 0xd3, 0x40, + 0x10, 0xc6, 0xe3, 0xc6, 0x4d, 0xdb, 0xa5, 0x54, 0xd6, 0x52, 0xc0, 0xad, 0x54, 0xdb, 0x05, 0x51, + 0x45, 0xa0, 0xda, 0x90, 0xde, 0x91, 0xec, 0xd8, 0x20, 0x43, 0xff, 0xa0, 0xb5, 0x03, 0x12, 0x17, + 0xcb, 0x89, 0x57, 0xc6, 0x4a, 0xe3, 0xad, 0xbc, 0x1b, 0x4a, 0xdf, 0x82, 0x33, 0xcf, 0xc1, 0x95, + 0x3b, 0xc7, 0x8a, 0x13, 0x27, 0x0b, 0xb9, 0xb7, 0x3e, 0x05, 0xda, 0xb5, 0x89, 0x48, 0xab, 0x5c, + 0x92, 0x99, 0xf9, 0x7d, 0xdf, 0x7a, 0x67, 0x46, 0x0b, 0x9e, 0xd0, 0x14, 0x5b, 0xa7, 0x38, 0x8d, + 0x47, 0x17, 0xd6, 0x24, 0x2e, 0xc6, 0x98, 0x59, 0x9f, 0x5f, 0x0c, 0x31, 0x8b, 0x9b, 0xcc, 0x3c, + 0x2b, 0x08, 0x23, 0x50, 0xa5, 0x29, 0x36, 0x6b, 0x99, 0xd9, 0x80, 0x5a, 0xb6, 0xbd, 0x35, 0x22, + 0x74, 0x42, 0x68, 0x24, 0x74, 0x56, 0x9d, 0xd4, 0xa6, 0xed, 0xcd, 0x94, 0xa4, 0xa4, 0xae, 0xf3, + 0xa8, 0xa9, 0x3e, 0x5e, 0xf8, 0x45, 0x92, 0x24, 0x8d, 0xf5, 0xd1, 0x37, 0x19, 0x74, 0x8e, 0x04, + 0x84, 0x06, 0x68, 0x4f, 0xb3, 0x44, 0x95, 0x0c, 0xa9, 0xbb, 0xe6, 0x6c, 0x54, 0xa5, 0xde, 0x1e, + 0xf8, 0xee, 0x75, 0xa9, 0xf3, 0x2a, 0xe2, 0x3f, 0xf0, 0x00, 0xac, 0x52, 0x16, 0x17, 0x2c, 0x62, + 0x54, 0x5d, 0x32, 0xa4, 0xae, 0xec, 0x3c, 0xac, 0x4a, 0x7d, 0x25, 0xe0, 0xb5, 0x30, 0xb8, 0x2e, + 0xf5, 0x19, 0x46, 0xb3, 0x08, 0x3e, 0x03, 0x1d, 0x9c, 0x27, 0xdc, 0xd2, 0x16, 0x96, 0x7b, 0x55, + 0xa9, 0x2f, 0x7b, 0x79, 0x22, 0x0c, 0x0d, 0x42, 0xcd, 0x3f, 0xec, 0x01, 0x99, 0x5f, 0x4e, 0x95, + 0x8d, 0x76, 0xf7, 0x4e, 0x4f, 0x33, 0x17, 0x4d, 0xc3, 0x3c, 0x49, 0x12, 0x8a, 0x84, 0x16, 0x22, + 0xa0, 0x9c, 0x67, 0x79, 0x8e, 0x8b, 0x88, 0xa7, 0xd1, 0x34, 0x4b, 0xa8, 0xba, 0x6c, 0xb4, 0xbb, + 0x6b, 0xce, 0x5e, 0x55, 0xea, 0x1b, 0x1f, 0x04, 0xe3, 0xfa, 0x81, 0xef, 0xd2, 0xeb, 0x52, 0xbf, + 0xa5, 0x46, 0xb7, 0x2a, 0xf0, 0x25, 0xe8, 0x50, 0x16, 0xb3, 0x29, 0x55, 0x3b, 0x86, 0xd4, 0xdd, + 0xe8, 0xed, 0x2d, 0xbe, 0x49, 0x3d, 0xbd, 0x40, 0xa8, 0x51, 0xe3, 0x82, 0xaf, 0xc1, 0xdd, 0x02, + 0x53, 0x72, 0x3a, 0x65, 0x19, 0xc9, 0x79, 0xef, 0x2b, 0xa2, 0xf7, 0xdd, 0xaa, 0xd4, 0xd7, 0xd1, + 0x0c, 0x88, 0x11, 0xcc, 0x0b, 0xd1, 0x7c, 0x0a, 0x7b, 0x60, 0x65, 0x54, 0xe0, 0x98, 0x91, 0x42, + 0x5d, 0x15, 0x8b, 0x51, 0x7f, 0x7d, 0xdf, 0xdf, 0x6c, 0xb6, 0x6f, 0x27, 0x49, 0x81, 0x29, 0x0d, + 0x58, 0x91, 0xe5, 0x29, 0xfa, 0x27, 0x84, 0x10, 0xc8, 0x13, 0xcc, 0x62, 0x75, 0x8d, 0x1b, 0x90, + 0x88, 0xf9, 0xea, 0x86, 0x84, 0x8c, 0x79, 0x77, 0x2a, 0x10, 0x07, 0x89, 0xd5, 0x39, 0x84, 0x8c, + 0xeb, 0x2d, 0xcf, 0x30, 0x9a, 0x45, 0x4f, 0x7f, 0x48, 0x60, 0xfd, 0xff, 0xf6, 0xe0, 0x0e, 0xd8, + 0x3a, 0xb2, 0xd1, 0x5b, 0x2f, 0x8c, 0x82, 0xd0, 0x0e, 0x07, 0x41, 0x34, 0x38, 0x0e, 0xde, 0x79, + 0x7d, 0xff, 0x95, 0xef, 0xb9, 0x4a, 0x0b, 0xaa, 0x60, 0x73, 0x1e, 0xdb, 0xfd, 0xd0, 0x7f, 0xef, + 0x29, 0x12, 0xdc, 0x06, 0x0f, 0xe6, 0x89, 0x7f, 0xdc, 0xb0, 0xa5, 0xdb, 0xac, 0x6f, 0x1f, 0xf7, + 0xbd, 0x43, 0xcf, 0x55, 0xda, 0x70, 0x0b, 0xdc, 0xbf, 0x71, 0xa2, 0x73, 0x82, 0x42, 0xcf, 0x55, + 0x64, 0xb8, 0x0b, 0x76, 0xe6, 0x11, 0xf2, 0x82, 0xc1, 0x61, 0x18, 0xb9, 0x5e, 0xff, 0xd0, 0x46, + 0x9e, 0xab, 0x2c, 0x3b, 0x6f, 0x7e, 0x56, 0x9a, 0x74, 0x59, 0x69, 0xd2, 0x9f, 0x4a, 0x93, 0xbe, + 0x5e, 0x69, 0xad, 0xcb, 0x2b, 0xad, 0xf5, 0xfb, 0x4a, 0x6b, 0x7d, 0x7c, 0x9e, 0x66, 0xec, 0xd3, + 0x74, 0x68, 0x8e, 0xc8, 0xc4, 0xa2, 0x29, 0xde, 0xcf, 0x31, 0x3b, 0x27, 0xc5, 0x98, 0xc7, 0xd6, + 0x97, 0x1b, 0x8f, 0x86, 0x5d, 0x9c, 0x61, 0x3a, 0xec, 0x88, 0xf7, 0x72, 0xf0, 0x37, 0x00, 0x00, + 0xff, 0xff, 0xd2, 0x57, 0x3f, 0xed, 0xc8, 0x03, 0x00, 0x00, } func (m *Market) Marshal() (dAtA []byte, err error) { diff --git a/x/market/types/message_market.go b/x/legacy/market/types/message_market.go similarity index 100% rename from x/market/types/message_market.go rename to x/legacy/market/types/message_market.go diff --git a/x/market/types/message_market_resolve.go b/x/legacy/market/types/message_market_resolve.go similarity index 100% rename from x/market/types/message_market_resolve.go rename to x/legacy/market/types/message_market_resolve.go diff --git a/x/market/types/messages_params.go b/x/legacy/market/types/messages_params.go similarity index 100% rename from x/market/types/messages_params.go rename to x/legacy/market/types/messages_params.go diff --git a/x/market/types/odds.pb.go b/x/legacy/market/types/odds.pb.go similarity index 82% rename from x/market/types/odds.pb.go rename to x/legacy/market/types/odds.pb.go index abddb199..f84724c7 100644 --- a/x/market/types/odds.pb.go +++ b/x/legacy/market/types/odds.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/odds.proto +// source: sge/legacy/market/v1beta/odds.proto package types @@ -35,7 +35,7 @@ func (m *Odds) Reset() { *m = Odds{} } func (m *Odds) String() string { return proto.CompactTextString(m) } func (*Odds) ProtoMessage() {} func (*Odds) Descriptor() ([]byte, []int) { - return fileDescriptor_3606fe4744ae3444, []int{0} + return fileDescriptor_30a0f242322c9777, []int{0} } func (m *Odds) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -79,26 +79,28 @@ func (m *Odds) GetMeta() string { } func init() { - proto.RegisterType((*Odds)(nil), "sgenetwork.sge.market.Odds") + proto.RegisterType((*Odds)(nil), "sge.legacy.market.v1beta.Odds") } -func init() { proto.RegisterFile("sgenetwork/sge/market/odds.proto", fileDescriptor_3606fe4744ae3444) } +func init() { + proto.RegisterFile("sge/legacy/market/v1beta/odds.proto", fileDescriptor_30a0f242322c9777) +} -var fileDescriptor_3606fe4744ae3444 = []byte{ - // 193 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x28, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, - 0x2d, 0xd1, 0xcf, 0x4f, 0x49, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x45, 0xa8, - 0xd0, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xab, 0xd0, - 0x07, 0xb1, 0x20, 0x8a, 0x95, 0x6c, 0xb8, 0x58, 0xfc, 0x53, 0x52, 0x8a, 0x85, 0x14, 0xb8, 0x98, - 0x4b, 0x33, 0x53, 0x24, 0x18, 0x15, 0x18, 0x35, 0x38, 0x9d, 0xf8, 0x1e, 0xdd, 0x93, 0x67, 0x0e, - 0xf5, 0x74, 0x79, 0x75, 0x4f, 0x1e, 0x24, 0x1a, 0x04, 0x22, 0x84, 0x84, 0xb8, 0x58, 0x72, 0x53, - 0x4b, 0x12, 0x25, 0x98, 0x40, 0x4a, 0x82, 0xc0, 0x6c, 0x27, 0xe7, 0x13, 0x8f, 0xe4, 0x18, 0x2f, - 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, - 0x6e, 0x3c, 0x96, 0x63, 0x88, 0xd2, 0x4c, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, - 0x05, 0x39, 0x53, 0x17, 0xd9, 0xc9, 0x15, 0x30, 0x47, 0x97, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, - 0x81, 0x5d, 0x62, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x7a, 0xc3, 0x95, 0x51, 0xda, 0x00, 0x00, - 0x00, +var fileDescriptor_30a0f242322c9777 = []byte{ + // 208 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2e, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, 0x2d, 0xd1, 0x2f, 0x33, + 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0xcf, 0x4f, 0x49, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, + 0x92, 0x28, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd2, 0x83, 0x28, 0xd2, 0x83, 0x28, 0x92, 0x12, 0x49, + 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd2, 0x07, 0xb1, 0x20, 0xea, 0x95, 0x6c, 0xb8, 0x58, 0xfc, 0x53, + 0x52, 0x8a, 0x85, 0x14, 0xb8, 0x98, 0x4b, 0x33, 0x53, 0x24, 0x18, 0x15, 0x18, 0x35, 0x38, 0x9d, + 0xf8, 0x1e, 0xdd, 0x93, 0x67, 0x0e, 0xf5, 0x74, 0x79, 0x75, 0x4f, 0x1e, 0x24, 0x1a, 0x04, 0x22, + 0x84, 0x84, 0xb8, 0x58, 0x72, 0x53, 0x4b, 0x12, 0x25, 0x98, 0x40, 0x4a, 0x82, 0xc0, 0x6c, 0x27, + 0xaf, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, + 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0x32, 0x48, 0xcf, 0x2c, 0xc9, + 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x2f, 0x4e, 0x4f, 0xd5, 0xcd, 0x4b, 0x2d, 0x29, 0xcf, + 0x2f, 0xca, 0x06, 0xb1, 0xf5, 0x2b, 0xd0, 0x7c, 0x51, 0x52, 0x59, 0x90, 0x5a, 0x9c, 0xc4, 0x06, + 0x76, 0x90, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, 0xeb, 0xd5, 0x5f, 0x0b, 0xe7, 0x00, 0x00, 0x00, } func (m *Odds) Marshal() (dAtA []byte, err error) { diff --git a/x/market/types/params.go b/x/legacy/market/types/params.go similarity index 100% rename from x/market/types/params.go rename to x/legacy/market/types/params.go diff --git a/x/ovm/types/params.pb.go b/x/legacy/market/types/params.pb.go similarity index 79% rename from x/ovm/types/params.pb.go rename to x/legacy/market/types/params.pb.go index 91b5d56d..c5dbe4b8 100644 --- a/x/ovm/types/params.pb.go +++ b/x/legacy/market/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/params.proto +// source: sge/legacy/market/v1beta/params.proto package types @@ -24,13 +24,14 @@ var _ = math.Inf const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // Params defines the parameters for the module. +// It contains bet constraints associated to a market. type Params struct { } func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_169f97f56fec979a, []int{0} + return fileDescriptor_e04963feb9441a5a, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -60,23 +61,26 @@ func (m *Params) XXX_DiscardUnknown() { var xxx_messageInfo_Params proto.InternalMessageInfo func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.ovm.Params") + proto.RegisterType((*Params)(nil), "sge.legacy.market.v1beta.Params") } -func init() { proto.RegisterFile("sgenetwork/sge/ovm/params.proto", fileDescriptor_169f97f56fec979a) } +func init() { + proto.RegisterFile("sge/legacy/market/v1beta/params.proto", fileDescriptor_e04963feb9441a5a) +} -var fileDescriptor_169f97f56fec979a = []byte{ - // 153 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2f, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0xcb, 0xd5, 0x2f, - 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x42, 0x28, 0xd0, - 0x2b, 0x4e, 0x4f, 0xd5, 0xcb, 0x2f, 0xcb, 0x95, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x4b, 0xeb, - 0x83, 0x58, 0x10, 0x95, 0x4a, 0x7c, 0x5c, 0x6c, 0x01, 0x60, 0x9d, 0x56, 0x2c, 0x33, 0x16, 0xc8, - 0x33, 0x38, 0x39, 0x9c, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, - 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x5a, 0x7a, - 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0x2e, 0xc8, 0x52, 0x5d, 0x64, 0x07, 0x54, 0x80, - 0x9d, 0x50, 0x52, 0x59, 0x90, 0x5a, 0x9c, 0xc4, 0x06, 0x36, 0xd8, 0x18, 0x10, 0x00, 0x00, 0xff, - 0xff, 0x0a, 0x76, 0x8b, 0x3f, 0xa5, 0x00, 0x00, 0x00, +var fileDescriptor_e04963feb9441a5a = []byte{ + // 171 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2d, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, 0x2d, 0xd1, 0x2f, 0x33, + 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, + 0xc9, 0x17, 0x92, 0x28, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd3, 0x83, 0x28, 0xd3, 0x83, 0x28, 0x93, + 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd2, 0x07, 0xb1, 0x20, 0xea, 0x95, 0xf8, 0xb8, 0xd8, + 0x02, 0xc0, 0xfa, 0xad, 0x58, 0x66, 0x2c, 0x90, 0x67, 0x70, 0xf2, 0x3a, 0xf1, 0x48, 0x8e, 0xf1, + 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, + 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0x83, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, + 0x5c, 0xfd, 0xe2, 0xf4, 0x54, 0xdd, 0xbc, 0xd4, 0x92, 0xf2, 0xfc, 0xa2, 0x6c, 0x10, 0x5b, 0xbf, + 0x02, 0xcd, 0x65, 0x25, 0x95, 0x05, 0xa9, 0xc5, 0x49, 0x6c, 0x60, 0x2b, 0x8c, 0x01, 0x01, 0x00, + 0x00, 0xff, 0xff, 0x9c, 0x32, 0x1f, 0x96, 0xbb, 0x00, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/market/types/query.pb.go b/x/legacy/market/types/query.pb.go similarity index 88% rename from x/market/types/query.pb.go rename to x/legacy/market/types/query.pb.go index fbc6e11b..5c61e56b 100644 --- a/x/market/types/query.pb.go +++ b/x/legacy/market/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/query.proto +// source: sge/legacy/market/v1beta/query.proto package types @@ -39,7 +39,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{0} + return fileDescriptor_b0c3fd583c8e7772, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -79,7 +79,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{1} + return fileDescriptor_b0c3fd583c8e7772, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -125,7 +125,7 @@ func (m *QueryMarketRequest) Reset() { *m = QueryMarketRequest{} } func (m *QueryMarketRequest) String() string { return proto.CompactTextString(m) } func (*QueryMarketRequest) ProtoMessage() {} func (*QueryMarketRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{2} + return fileDescriptor_b0c3fd583c8e7772, []int{2} } func (m *QueryMarketRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -171,7 +171,7 @@ func (m *QueryMarketResponse) Reset() { *m = QueryMarketResponse{} } func (m *QueryMarketResponse) String() string { return proto.CompactTextString(m) } func (*QueryMarketResponse) ProtoMessage() {} func (*QueryMarketResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{3} + return fileDescriptor_b0c3fd583c8e7772, []int{3} } func (m *QueryMarketResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -218,7 +218,7 @@ func (m *QueryMarketsRequest) Reset() { *m = QueryMarketsRequest{} } func (m *QueryMarketsRequest) String() string { return proto.CompactTextString(m) } func (*QueryMarketsRequest) ProtoMessage() {} func (*QueryMarketsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{4} + return fileDescriptor_b0c3fd583c8e7772, []int{4} } func (m *QueryMarketsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -266,7 +266,7 @@ func (m *QueryMarketsResponse) Reset() { *m = QueryMarketsResponse{} } func (m *QueryMarketsResponse) String() string { return proto.CompactTextString(m) } func (*QueryMarketsResponse) ProtoMessage() {} func (*QueryMarketsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{5} + return fileDescriptor_b0c3fd583c8e7772, []int{5} } func (m *QueryMarketsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -319,7 +319,7 @@ func (m *QueryMarketsByUIDsRequest) Reset() { *m = QueryMarketsByUIDsReq func (m *QueryMarketsByUIDsRequest) String() string { return proto.CompactTextString(m) } func (*QueryMarketsByUIDsRequest) ProtoMessage() {} func (*QueryMarketsByUIDsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{6} + return fileDescriptor_b0c3fd583c8e7772, []int{6} } func (m *QueryMarketsByUIDsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -366,7 +366,7 @@ func (m *QueryMarketsByUIDsResponse) Reset() { *m = QueryMarketsByUIDsRe func (m *QueryMarketsByUIDsResponse) String() string { return proto.CompactTextString(m) } func (*QueryMarketsByUIDsResponse) ProtoMessage() {} func (*QueryMarketsByUIDsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_bfd151c101859bd3, []int{7} + return fileDescriptor_b0c3fd583c8e7772, []int{7} } func (m *QueryMarketsByUIDsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -410,57 +410,60 @@ func (m *QueryMarketsByUIDsResponse) GetFailedMarkets() []string { } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.market.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.market.QueryParamsResponse") - proto.RegisterType((*QueryMarketRequest)(nil), "sgenetwork.sge.market.QueryMarketRequest") - proto.RegisterType((*QueryMarketResponse)(nil), "sgenetwork.sge.market.QueryMarketResponse") - proto.RegisterType((*QueryMarketsRequest)(nil), "sgenetwork.sge.market.QueryMarketsRequest") - proto.RegisterType((*QueryMarketsResponse)(nil), "sgenetwork.sge.market.QueryMarketsResponse") - proto.RegisterType((*QueryMarketsByUIDsRequest)(nil), "sgenetwork.sge.market.QueryMarketsByUIDsRequest") - proto.RegisterType((*QueryMarketsByUIDsResponse)(nil), "sgenetwork.sge.market.QueryMarketsByUIDsResponse") + proto.RegisterType((*QueryParamsRequest)(nil), "sge.legacy.market.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.legacy.market.v1beta.QueryParamsResponse") + proto.RegisterType((*QueryMarketRequest)(nil), "sge.legacy.market.v1beta.QueryMarketRequest") + proto.RegisterType((*QueryMarketResponse)(nil), "sge.legacy.market.v1beta.QueryMarketResponse") + proto.RegisterType((*QueryMarketsRequest)(nil), "sge.legacy.market.v1beta.QueryMarketsRequest") + proto.RegisterType((*QueryMarketsResponse)(nil), "sge.legacy.market.v1beta.QueryMarketsResponse") + proto.RegisterType((*QueryMarketsByUIDsRequest)(nil), "sge.legacy.market.v1beta.QueryMarketsByUIDsRequest") + proto.RegisterType((*QueryMarketsByUIDsResponse)(nil), "sge.legacy.market.v1beta.QueryMarketsByUIDsResponse") } -func init() { proto.RegisterFile("sgenetwork/sge/market/query.proto", fileDescriptor_bfd151c101859bd3) } +func init() { + proto.RegisterFile("sge/legacy/market/v1beta/query.proto", fileDescriptor_b0c3fd583c8e7772) +} -var fileDescriptor_bfd151c101859bd3 = []byte{ - // 580 bytes of a gzipped FileDescriptorProto +var fileDescriptor_b0c3fd583c8e7772 = []byte{ + // 594 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x94, 0x41, 0x6b, 0x13, 0x4f, - 0x18, 0xc6, 0xb3, 0x69, 0xfe, 0xe9, 0xbf, 0x23, 0x15, 0x7d, 0x93, 0x82, 0x5d, 0xeb, 0x56, 0x07, - 0xad, 0x36, 0xe2, 0xac, 0xa9, 0x27, 0x11, 0x2f, 0x51, 0x14, 0x0f, 0x42, 0x5d, 0xf0, 0x22, 0x48, - 0x98, 0x34, 0xe3, 0xb8, 0xb4, 0xd9, 0xd9, 0x66, 0x76, 0xd5, 0x58, 0x8a, 0xd0, 0x4f, 0x20, 0x78, - 0xf5, 0xe0, 0xc1, 0x0f, 0xd3, 0x63, 0xc1, 0x8b, 0xa7, 0x22, 0x89, 0x27, 0x3f, 0x85, 0xec, 0xcc, - 0x6c, 0x92, 0x25, 0x6b, 0x9a, 0x5c, 0x92, 0xcd, 0xe4, 0x79, 0x9f, 0xdf, 0xf3, 0xce, 0xbc, 0x3b, - 0xe8, 0x9a, 0xe4, 0x2c, 0x60, 0xd1, 0x7b, 0xd1, 0xdd, 0x75, 0x25, 0x67, 0x6e, 0x87, 0x76, 0x77, - 0x59, 0xe4, 0xee, 0xc7, 0xac, 0xdb, 0x23, 0x61, 0x57, 0x44, 0x02, 0x56, 0x46, 0x12, 0x22, 0x39, - 0x23, 0x5a, 0x62, 0x57, 0xb9, 0xe0, 0x42, 0x29, 0xdc, 0xe4, 0x49, 0x8b, 0xed, 0x35, 0x2e, 0x04, - 0xdf, 0x63, 0x2e, 0x0d, 0x7d, 0x97, 0x06, 0x81, 0x88, 0x68, 0xe4, 0x8b, 0x40, 0x9a, 0x7f, 0x6b, - 0x3b, 0x42, 0x76, 0x84, 0x74, 0x5b, 0x54, 0x32, 0xcd, 0x70, 0xdf, 0xd5, 0x5b, 0x2c, 0xa2, 0x75, - 0x37, 0xa4, 0xdc, 0x0f, 0x94, 0xd8, 0x68, 0x71, 0x7e, 0xb2, 0x90, 0x76, 0x69, 0x47, 0x4e, 0xd7, - 0xe8, 0x2f, 0xad, 0xc1, 0x55, 0x04, 0x2f, 0x12, 0xd2, 0xb6, 0x2a, 0xf4, 0xd8, 0x7e, 0xcc, 0x64, - 0x84, 0x3d, 0x54, 0xc9, 0xac, 0xca, 0x50, 0x04, 0x92, 0xc1, 0x03, 0x54, 0xd6, 0x80, 0x4b, 0xd6, - 0x55, 0xeb, 0xd6, 0xb9, 0xad, 0x2b, 0x24, 0xb7, 0x79, 0xa2, 0xcb, 0x1a, 0xa5, 0xe3, 0xd3, 0xf5, - 0x82, 0x67, 0x4a, 0xf0, 0x86, 0x21, 0x3d, 0x57, 0x1a, 0x43, 0x82, 0x0b, 0x68, 0x21, 0xf6, 0xdb, - 0xca, 0x6f, 0xc9, 0x4b, 0x1e, 0x87, 0xec, 0x54, 0x37, 0x62, 0x6b, 0xf7, 0x33, 0xd8, 0xba, 0x2c, - 0x65, 0xeb, 0x45, 0xfc, 0x3a, 0xe3, 0x99, 0xb6, 0x09, 0x4f, 0x10, 0x1a, 0x6d, 0xac, 0xf1, 0xdd, - 0x20, 0xfa, 0x14, 0x48, 0x72, 0x0a, 0x44, 0x9f, 0xb4, 0x39, 0x05, 0xb2, 0x4d, 0x39, 0x33, 0xb5, - 0xde, 0x58, 0x25, 0xfe, 0x6a, 0xa1, 0x6a, 0xd6, 0x3f, 0x27, 0xf4, 0xc2, 0x9c, 0xa1, 0xe1, 0x69, - 0x26, 0x5d, 0x51, 0xa5, 0xbb, 0x79, 0x66, 0x3a, 0x4d, 0xce, 0xc4, 0xbb, 0x8f, 0x56, 0xc7, 0xd3, - 0x35, 0x7a, 0x2f, 0x9f, 0x3d, 0x1e, 0xee, 0xc1, 0x1a, 0x2a, 0xc5, 0x7e, 0x5b, 0xaa, 0x80, 0x4b, - 0x8d, 0xff, 0xff, 0x9c, 0xae, 0xab, 0xdf, 0x9e, 0xfa, 0xc4, 0x47, 0x16, 0xb2, 0xf3, 0x6a, 0x4d, - 0x7f, 0x0f, 0xd1, 0xa2, 0x0e, 0x2b, 0xe7, 0x69, 0x30, 0xad, 0x81, 0x1b, 0xe8, 0xfc, 0x1b, 0xea, - 0xef, 0xb1, 0x76, 0x33, 0x75, 0x29, 0x26, 0x29, 0xbc, 0x65, 0xbd, 0x6a, 0x98, 0x5b, 0xdf, 0x4b, - 0xe8, 0x3f, 0x15, 0x02, 0x0e, 0x50, 0x59, 0xcf, 0x16, 0x6c, 0xfe, 0x03, 0x34, 0x39, 0xcc, 0x76, - 0x6d, 0x16, 0xa9, 0x6e, 0x08, 0xdb, 0x47, 0x3f, 0x7e, 0x7f, 0x29, 0x56, 0x01, 0x26, 0x5f, 0x2a, - 0xf8, 0x88, 0xca, 0x3a, 0xd1, 0x74, 0x78, 0x66, 0xbe, 0xa7, 0xc3, 0xb3, 0x23, 0x8e, 0x57, 0x15, - 0xbc, 0x02, 0x17, 0xc7, 0xe1, 0x07, 0xb1, 0xdf, 0x3e, 0x84, 0x4f, 0x68, 0xd1, 0xec, 0x06, 0xcc, - 0xe0, 0x38, 0x6c, 0xfd, 0xf6, 0x4c, 0x5a, 0x83, 0xbf, 0xac, 0xf0, 0x2b, 0x50, 0x99, 0xbc, 0x2c, - 0x24, 0x7c, 0xb3, 0xd0, 0x72, 0x66, 0x06, 0xe0, 0xee, 0x0c, 0xde, 0x99, 0x51, 0xb3, 0xeb, 0x73, - 0x54, 0x98, 0x4c, 0x35, 0x95, 0xe9, 0x3a, 0xe0, 0x9c, 0x4c, 0xcd, 0x56, 0xaf, 0x99, 0x0c, 0xa9, - 0xda, 0x22, 0x79, 0xd8, 0x78, 0x74, 0xdc, 0x77, 0xac, 0x93, 0xbe, 0x63, 0xfd, 0xea, 0x3b, 0xd6, - 0xe7, 0x81, 0x53, 0x38, 0x19, 0x38, 0x85, 0x9f, 0x03, 0xa7, 0xf0, 0x6a, 0x93, 0xfb, 0xd1, 0xdb, - 0xb8, 0x45, 0x76, 0x44, 0x27, 0xf1, 0xb9, 0x33, 0x7e, 0x29, 0x7e, 0x48, 0x5d, 0xa3, 0x5e, 0xc8, - 0x64, 0xab, 0xac, 0xae, 0xc5, 0x7b, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0xb3, 0x69, 0x41, 0xfc, - 0xfa, 0x05, 0x00, 0x00, + 0x18, 0xc6, 0x33, 0x69, 0xfe, 0xe9, 0xbf, 0x23, 0x15, 0x9d, 0x44, 0x68, 0xd7, 0xb2, 0x2d, 0x4b, + 0x5b, 0xa5, 0xd8, 0x19, 0xdb, 0x7a, 0xf1, 0x22, 0x12, 0x44, 0x51, 0x10, 0xea, 0x42, 0x2f, 0x82, + 0x84, 0x49, 0x32, 0x8e, 0x4b, 0x93, 0x9d, 0xed, 0xce, 0xae, 0xba, 0x48, 0x41, 0x85, 0xde, 0x05, + 0x3f, 0x80, 0x37, 0xbf, 0x86, 0xd7, 0x1e, 0x0b, 0x5e, 0x3c, 0x15, 0x49, 0x3c, 0xf9, 0x29, 0x64, + 0x67, 0x66, 0xd3, 0xac, 0x26, 0x6c, 0x72, 0x09, 0x93, 0xd9, 0xf7, 0x79, 0x9e, 0xdf, 0xcc, 0xfb, + 0xee, 0xc2, 0x75, 0xc9, 0x19, 0xe9, 0x32, 0x4e, 0xdb, 0x09, 0xe9, 0xd1, 0xf0, 0x90, 0x45, 0xe4, + 0xf5, 0x4e, 0x8b, 0x45, 0x94, 0x1c, 0xc5, 0x2c, 0x4c, 0x70, 0x10, 0x8a, 0x48, 0xa0, 0x25, 0xc9, + 0x19, 0xd6, 0x55, 0x58, 0x57, 0x61, 0x5d, 0x65, 0x6d, 0xb5, 0x85, 0xec, 0x09, 0x49, 0x5a, 0x54, + 0x32, 0x2d, 0x31, 0xfa, 0x1d, 0x12, 0x50, 0xee, 0xf9, 0x34, 0xf2, 0x84, 0xaf, 0x5d, 0xac, 0x3a, + 0x17, 0x5c, 0xa8, 0x25, 0x49, 0x57, 0x66, 0x77, 0x85, 0x0b, 0xc1, 0xbb, 0x8c, 0xd0, 0xc0, 0x23, + 0xd4, 0xf7, 0x45, 0xa4, 0x24, 0xd2, 0x3c, 0xdd, 0x98, 0xc8, 0x67, 0x38, 0x8a, 0xca, 0x02, 0x1a, + 0xd2, 0x9e, 0x71, 0x73, 0xea, 0x10, 0x3d, 0x4b, 0x19, 0xf7, 0xd5, 0xa6, 0xcb, 0x8e, 0x62, 0x26, + 0x23, 0xe7, 0x00, 0xd6, 0x72, 0xbb, 0x32, 0x10, 0xbe, 0x64, 0xe8, 0x1e, 0xac, 0x6a, 0xf1, 0x12, + 0x58, 0x03, 0x37, 0x2f, 0xed, 0xae, 0xe1, 0x49, 0xb7, 0x80, 0xb5, 0xb2, 0x51, 0x39, 0x3d, 0x5f, + 0x2d, 0xb9, 0x46, 0xe5, 0x6c, 0x9a, 0xb0, 0xa7, 0xaa, 0xd4, 0x84, 0xa1, 0x2b, 0x70, 0x2e, 0xf6, + 0x3a, 0xca, 0x72, 0xc1, 0x4d, 0x97, 0xc3, 0xf8, 0xac, 0xee, 0x22, 0x5e, 0x87, 0x14, 0xc7, 0x6b, + 0x65, 0x16, 0xaf, 0x9f, 0x39, 0x2f, 0x72, 0xb6, 0xd9, 0x61, 0xd1, 0x43, 0x08, 0x2f, 0x1a, 0x63, + 0xac, 0x37, 0xb1, 0xee, 0x22, 0x4e, 0xbb, 0x88, 0x75, 0xe3, 0x4d, 0x17, 0xf1, 0x3e, 0xe5, 0xcc, + 0x68, 0xdd, 0x11, 0xa5, 0xf3, 0x05, 0xc0, 0x7a, 0xde, 0x7f, 0x0c, 0xf7, 0xdc, 0xec, 0xdc, 0xe8, + 0x51, 0x0e, 0xb0, 0xac, 0x00, 0x6f, 0x14, 0x02, 0xea, 0xf0, 0x1c, 0xe1, 0x5d, 0xb8, 0x3c, 0x0a, + 0xd8, 0x48, 0x0e, 0x1e, 0x3f, 0x18, 0x5e, 0xc3, 0x0a, 0xac, 0xc4, 0x5e, 0x47, 0x2a, 0xc6, 0x85, + 0xc6, 0xff, 0xbf, 0xcf, 0x57, 0xd5, 0x7f, 0x57, 0xfd, 0x3a, 0x27, 0x00, 0x5a, 0xe3, 0xb4, 0xe6, + 0x88, 0xf7, 0xe1, 0xbc, 0x86, 0x95, 0x33, 0x9e, 0x31, 0x93, 0xa1, 0x0d, 0x78, 0xf9, 0x25, 0xf5, + 0xba, 0xac, 0xd3, 0xcc, 0x8c, 0xca, 0x29, 0x88, 0xbb, 0xa8, 0x77, 0x4d, 0xec, 0xee, 0xb7, 0x0a, + 0xfc, 0x4f, 0x71, 0xa0, 0x0f, 0x00, 0x56, 0xf5, 0x94, 0xa1, 0x5b, 0x93, 0xc3, 0xfe, 0x1d, 0x6e, + 0x6b, 0x7b, 0xca, 0x6a, 0x7d, 0x34, 0xc7, 0xfa, 0xf8, 0xfd, 0xd7, 0xe7, 0x72, 0x1d, 0x21, 0x92, + 0xbe, 0x51, 0xe6, 0x55, 0xd2, 0x03, 0x8d, 0xde, 0x03, 0x58, 0xd5, 0x64, 0x85, 0x0c, 0xb9, 0x99, + 0x2f, 0x64, 0xc8, 0x4f, 0xbe, 0xb3, 0xac, 0x18, 0x6a, 0xe8, 0xea, 0x28, 0xc3, 0xbb, 0xd8, 0xeb, + 0x1c, 0xa3, 0x13, 0x00, 0xe7, 0xcd, 0xe5, 0xa0, 0xe9, 0x5c, 0x87, 0x17, 0x81, 0xa7, 0x2d, 0x37, + 0x14, 0xd7, 0x15, 0xc5, 0x35, 0x54, 0x1b, 0xa5, 0xc8, 0xfa, 0xf7, 0x15, 0xc0, 0xc5, 0xdc, 0x6c, + 0xa0, 0xbd, 0xe9, 0xec, 0x73, 0x53, 0x68, 0xdd, 0x99, 0x4d, 0x64, 0xc8, 0xb6, 0x14, 0xd9, 0x3a, + 0x72, 0xc6, 0x90, 0x35, 0x5b, 0x49, 0x33, 0x1d, 0x61, 0x75, 0x5f, 0xf2, 0xb8, 0xf1, 0xe4, 0xb4, + 0x6f, 0x83, 0xb3, 0xbe, 0x0d, 0x7e, 0xf6, 0x6d, 0xf0, 0x69, 0x60, 0x97, 0xce, 0x06, 0x76, 0xe9, + 0xc7, 0xc0, 0x2e, 0x3d, 0xbf, 0xcd, 0xbd, 0xe8, 0x55, 0xdc, 0xc2, 0x6d, 0xd1, 0x4b, 0x7d, 0xb6, + 0x7d, 0x16, 0xbd, 0x11, 0xe1, 0xa1, 0xf2, 0x7c, 0xfb, 0xd7, 0xb7, 0x34, 0x4a, 0x02, 0x26, 0x5b, + 0x55, 0xf5, 0x11, 0xdd, 0xfb, 0x13, 0x00, 0x00, 0xff, 0xff, 0x75, 0xa7, 0xfb, 0x16, 0x34, 0x06, + 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -495,7 +498,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -504,7 +507,7 @@ func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts . func (c *queryClient) Market(ctx context.Context, in *QueryMarketRequest, opts ...grpc.CallOption) (*QueryMarketResponse, error) { out := new(QueryMarketResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Query/Market", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Query/Market", in, out, opts...) if err != nil { return nil, err } @@ -513,7 +516,7 @@ func (c *queryClient) Market(ctx context.Context, in *QueryMarketRequest, opts . func (c *queryClient) Markets(ctx context.Context, in *QueryMarketsRequest, opts ...grpc.CallOption) (*QueryMarketsResponse, error) { out := new(QueryMarketsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Query/Markets", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Query/Markets", in, out, opts...) if err != nil { return nil, err } @@ -522,7 +525,7 @@ func (c *queryClient) Markets(ctx context.Context, in *QueryMarketsRequest, opts func (c *queryClient) MarketsByUIDs(ctx context.Context, in *QueryMarketsByUIDsRequest, opts ...grpc.CallOption) (*QueryMarketsByUIDsResponse, error) { out := new(QueryMarketsByUIDsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Query/MarketsByUIDs", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Query/MarketsByUIDs", in, out, opts...) if err != nil { return nil, err } @@ -572,7 +575,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Query/Params", + FullMethod: "/sge.legacy.market.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -590,7 +593,7 @@ func _Query_Market_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Query/Market", + FullMethod: "/sge.legacy.market.v1beta.Query/Market", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Market(ctx, req.(*QueryMarketRequest)) @@ -608,7 +611,7 @@ func _Query_Markets_Handler(srv interface{}, ctx context.Context, dec func(inter } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Query/Markets", + FullMethod: "/sge.legacy.market.v1beta.Query/Markets", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Markets(ctx, req.(*QueryMarketsRequest)) @@ -626,7 +629,7 @@ func _Query_MarketsByUIDs_Handler(srv interface{}, ctx context.Context, dec func } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Query/MarketsByUIDs", + FullMethod: "/sge.legacy.market.v1beta.Query/MarketsByUIDs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).MarketsByUIDs(ctx, req.(*QueryMarketsByUIDsRequest)) @@ -634,8 +637,9 @@ func _Query_MarketsByUIDs_Handler(srv interface{}, ctx context.Context, dec func return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.market.Query", + ServiceName: "sge.legacy.market.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -656,7 +660,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/market/query.proto", + Metadata: "sge/legacy/market/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/market/types/query.pb.gw.go b/x/legacy/market/types/query.pb.gw.go similarity index 99% rename from x/market/types/query.pb.gw.go rename to x/legacy/market/types/query.pb.gw.go index c64b2270..ef5a430a 100644 --- a/x/market/types/query.pb.gw.go +++ b/x/legacy/market/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/market/query.proto +// source: sge/legacy/market/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/market/types/stats.pb.go b/x/legacy/market/types/stats.pb.go similarity index 82% rename from x/market/types/stats.pb.go rename to x/legacy/market/types/stats.pb.go index ef9b35f2..abbf034d 100644 --- a/x/market/types/stats.pb.go +++ b/x/legacy/market/types/stats.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/stats.proto +// source: sge/legacy/market/v1beta/stats.proto package types @@ -33,7 +33,7 @@ func (m *MarketStats) Reset() { *m = MarketStats{} } func (m *MarketStats) String() string { return proto.CompactTextString(m) } func (*MarketStats) ProtoMessage() {} func (*MarketStats) Descriptor() ([]byte, []int) { - return fileDescriptor_b89d96b591dbbbbd, []int{0} + return fileDescriptor_81eab7bced6fc837, []int{0} } func (m *MarketStats) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -70,24 +70,27 @@ func (m *MarketStats) GetResolvedUnsettled() []string { } func init() { - proto.RegisterType((*MarketStats)(nil), "sgenetwork.sge.market.MarketStats") + proto.RegisterType((*MarketStats)(nil), "sge.legacy.market.v1beta.MarketStats") } -func init() { proto.RegisterFile("sgenetwork/sge/market/stats.proto", fileDescriptor_b89d96b591dbbbbd) } +func init() { + proto.RegisterFile("sge/legacy/market/v1beta/stats.proto", fileDescriptor_81eab7bced6fc837) +} -var fileDescriptor_b89d96b591dbbbbd = []byte{ - // 173 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, - 0x2d, 0xd1, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x45, - 0x28, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0x51, 0xb2, 0xe1, 0xe2, 0xf6, 0x05, 0xb3, 0x82, - 0x41, 0x6a, 0x85, 0x74, 0xb9, 0x84, 0x8a, 0x52, 0x8b, 0xf3, 0x73, 0xca, 0x52, 0x53, 0xe2, 0x4b, - 0xf3, 0x8a, 0x53, 0x4b, 0x4a, 0x72, 0x52, 0x53, 0x24, 0x18, 0x15, 0x98, 0x35, 0x38, 0x83, 0x04, - 0x61, 0x32, 0xa1, 0x30, 0x09, 0x27, 0xe7, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, - 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, - 0x88, 0xd2, 0x4c, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0x05, 0xb9, 0x48, 0x17, - 0xd9, 0x75, 0x15, 0x30, 0xf7, 0x95, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, 0x81, 0x1d, 0x68, 0x0c, - 0x08, 0x00, 0x00, 0xff, 0xff, 0xa8, 0x0d, 0x49, 0x10, 0xc5, 0x00, 0x00, 0x00, +var fileDescriptor_81eab7bced6fc837 = []byte{ + // 189 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x29, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, 0x2d, 0xd1, 0x2f, 0x33, + 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, + 0x17, 0x92, 0x28, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0xd2, 0x83, 0xa8, 0xd2, 0x83, 0xa8, 0x52, 0xb2, + 0xe1, 0xe2, 0xf6, 0x05, 0x0b, 0x04, 0x83, 0x94, 0x0b, 0xe9, 0x72, 0x09, 0x15, 0xa5, 0x16, 0xe7, + 0xe7, 0x94, 0xa5, 0xa6, 0xc4, 0x97, 0xe6, 0x15, 0xa7, 0x96, 0x94, 0xe4, 0xa4, 0xa6, 0x48, 0x30, + 0x2a, 0x30, 0x6b, 0x70, 0x06, 0x09, 0xc2, 0x64, 0x42, 0x61, 0x12, 0x4e, 0x5e, 0x27, 0x1e, 0xc9, + 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, + 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0x65, 0x90, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, + 0x9c, 0x9f, 0xab, 0x5f, 0x9c, 0x9e, 0xaa, 0x9b, 0x97, 0x5a, 0x52, 0x9e, 0x5f, 0x94, 0x0d, 0x62, + 0xeb, 0x57, 0xa0, 0x39, 0xb8, 0xa4, 0xb2, 0x20, 0xb5, 0x38, 0x89, 0x0d, 0xec, 0x54, 0x63, 0x40, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xde, 0x8f, 0xa4, 0x8a, 0xd2, 0x00, 0x00, 0x00, } func (m *MarketStats) Marshal() (dAtA []byte, err error) { diff --git a/x/market/types/ticket.go b/x/legacy/market/types/ticket.go similarity index 100% rename from x/market/types/ticket.go rename to x/legacy/market/types/ticket.go diff --git a/x/market/types/ticket.pb.go b/x/legacy/market/types/ticket.pb.go similarity index 87% rename from x/market/types/ticket.pb.go rename to x/legacy/market/types/ticket.pb.go index 7e1b1ccf..b0301fbb 100644 --- a/x/market/types/ticket.pb.go +++ b/x/legacy/market/types/ticket.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/ticket.proto +// source: sge/legacy/market/v1beta/ticket.proto package types @@ -34,7 +34,7 @@ type MarketAddTicketPayload struct { // odds is the list of odds of the market. Odds []*Odds `protobuf:"bytes,4,rep,name=odds,proto3" json:"odds,omitempty"` // status is the current status of the market. - Status MarketStatus `protobuf:"varint,5,opt,name=status,proto3,enum=sgenetwork.sge.market.MarketStatus" json:"status,omitempty"` + Status MarketStatus `protobuf:"varint,5,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` // meta contains human-readable metadata of the market. Meta string `protobuf:"bytes,6,opt,name=meta,proto3" json:"meta,omitempty"` } @@ -43,7 +43,7 @@ func (m *MarketAddTicketPayload) Reset() { *m = MarketAddTicketPayload{} func (m *MarketAddTicketPayload) String() string { return proto.CompactTextString(m) } func (*MarketAddTicketPayload) ProtoMessage() {} func (*MarketAddTicketPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_a35459e041976d97, []int{0} + return fileDescriptor_3578f687d4a13206, []int{0} } func (m *MarketAddTicketPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -123,14 +123,14 @@ type MarketUpdateTicketPayload struct { // end_ts is the end timestamp of the market EndTS uint64 `protobuf:"varint,3,opt,name=end_ts,proto3" json:"end_ts"` // status is the status of the resolution. - Status MarketStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sgenetwork.sge.market.MarketStatus" json:"status,omitempty"` + Status MarketStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` } func (m *MarketUpdateTicketPayload) Reset() { *m = MarketUpdateTicketPayload{} } func (m *MarketUpdateTicketPayload) String() string { return proto.CompactTextString(m) } func (*MarketUpdateTicketPayload) ProtoMessage() {} func (*MarketUpdateTicketPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_a35459e041976d97, []int{1} + return fileDescriptor_3578f687d4a13206, []int{1} } func (m *MarketUpdateTicketPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -198,14 +198,14 @@ type MarketResolutionTicketPayload struct { // odds. WinnerOddsUIDs []string `protobuf:"bytes,3,rep,name=winner_odds_uids,proto3" json:"winner_odds_uids"` // status is the status of the resolution. - Status MarketStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sgenetwork.sge.market.MarketStatus" json:"status,omitempty"` + Status MarketStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sge.legacy.market.v1beta.MarketStatus" json:"status,omitempty"` } func (m *MarketResolutionTicketPayload) Reset() { *m = MarketResolutionTicketPayload{} } func (m *MarketResolutionTicketPayload) String() string { return proto.CompactTextString(m) } func (*MarketResolutionTicketPayload) ProtoMessage() {} func (*MarketResolutionTicketPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_a35459e041976d97, []int{2} + return fileDescriptor_3578f687d4a13206, []int{2} } func (m *MarketResolutionTicketPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -263,46 +263,46 @@ func (m *MarketResolutionTicketPayload) GetStatus() MarketStatus { } func init() { - proto.RegisterType((*MarketAddTicketPayload)(nil), "sgenetwork.sge.market.MarketAddTicketPayload") - proto.RegisterType((*MarketUpdateTicketPayload)(nil), "sgenetwork.sge.market.MarketUpdateTicketPayload") - proto.RegisterType((*MarketResolutionTicketPayload)(nil), "sgenetwork.sge.market.MarketResolutionTicketPayload") + proto.RegisterType((*MarketAddTicketPayload)(nil), "sge.legacy.market.v1beta.MarketAddTicketPayload") + proto.RegisterType((*MarketUpdateTicketPayload)(nil), "sge.legacy.market.v1beta.MarketUpdateTicketPayload") + proto.RegisterType((*MarketResolutionTicketPayload)(nil), "sge.legacy.market.v1beta.MarketResolutionTicketPayload") } func init() { - proto.RegisterFile("sgenetwork/sge/market/ticket.proto", fileDescriptor_a35459e041976d97) + proto.RegisterFile("sge/legacy/market/v1beta/ticket.proto", fileDescriptor_3578f687d4a13206) } -var fileDescriptor_a35459e041976d97 = []byte{ - // 449 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x93, 0xcf, 0x6b, 0xd4, 0x40, - 0x14, 0xc7, 0x77, 0x36, 0xe9, 0x6a, 0x47, 0x5d, 0x64, 0xfc, 0x15, 0x2b, 0x66, 0x62, 0x04, 0x89, - 0x88, 0x09, 0xb4, 0x47, 0x4f, 0xc6, 0x8a, 0xf4, 0x20, 0xca, 0x6c, 0x17, 0xc1, 0xcb, 0x92, 0x76, - 0x86, 0x18, 0xb6, 0x9b, 0x59, 0x32, 0x13, 0x6a, 0xff, 0x0b, 0xef, 0x82, 0x7f, 0x8f, 0xc7, 0x1e, - 0x3d, 0xc8, 0x20, 0xb3, 0xb7, 0xfd, 0x2b, 0x64, 0x26, 0x21, 0xdb, 0xd2, 0xf6, 0xb0, 0x78, 0xf1, - 0x92, 0x79, 0x79, 0xef, 0xf3, 0x1d, 0xe6, 0xfb, 0x1e, 0x0f, 0x86, 0x22, 0x67, 0x25, 0x93, 0xc7, - 0xbc, 0x9a, 0x26, 0x22, 0x67, 0xc9, 0x2c, 0xab, 0xa6, 0x4c, 0x26, 0xb2, 0x38, 0x9c, 0x32, 0x19, - 0xcf, 0x2b, 0x2e, 0x39, 0xba, 0xb7, 0x62, 0x62, 0x91, 0xb3, 0xb8, 0x61, 0xb6, 0xae, 0x90, 0x36, - 0x47, 0x23, 0xdd, 0x0a, 0x2e, 0x67, 0x38, 0xa5, 0xa2, 0x25, 0xee, 0xe6, 0x3c, 0xe7, 0x36, 0x4c, - 0x4c, 0xd4, 0x64, 0xc3, 0x1f, 0x7d, 0x78, 0xff, 0xbd, 0x65, 0x5f, 0x53, 0xba, 0x6f, 0x1f, 0xf3, - 0x31, 0x3b, 0x39, 0xe2, 0x19, 0x45, 0x01, 0x74, 0xea, 0x82, 0x7a, 0x20, 0x00, 0xd1, 0x66, 0x3a, - 0xd4, 0x0a, 0x3b, 0xe3, 0xbd, 0xdd, 0xa5, 0xc2, 0x26, 0x4b, 0xcc, 0x07, 0xed, 0xc0, 0xeb, 0x42, - 0x66, 0x95, 0x9c, 0x48, 0xe1, 0xf5, 0x03, 0x10, 0xb9, 0xe9, 0x03, 0xad, 0xf0, 0xb5, 0x91, 0xc9, - 0xed, 0x8f, 0x96, 0x0a, 0x77, 0x65, 0xd2, 0x45, 0xe8, 0x05, 0x1c, 0xb0, 0x92, 0x1a, 0x89, 0x63, - 0x25, 0x77, 0xb4, 0xc2, 0x1b, 0x6f, 0x4b, 0x6a, 0x05, 0x6d, 0x89, 0xb4, 0x27, 0x4a, 0xa0, 0x6b, - 0x2c, 0x78, 0x6e, 0xe0, 0x44, 0x37, 0xb6, 0x1f, 0xc5, 0x97, 0x36, 0x28, 0xfe, 0x40, 0xa9, 0x20, - 0x16, 0x44, 0xaf, 0xe0, 0x40, 0xc8, 0x4c, 0xd6, 0xc2, 0xdb, 0x08, 0x40, 0x34, 0xdc, 0x7e, 0x7a, - 0x85, 0xa4, 0xf1, 0x3c, 0xb2, 0x28, 0x69, 0x25, 0x08, 0x41, 0x77, 0xc6, 0x64, 0xe6, 0x0d, 0x8c, - 0x65, 0x62, 0xe3, 0xf0, 0x37, 0x80, 0x0f, 0x1b, 0x78, 0x3c, 0xa7, 0x99, 0x64, 0xff, 0x5f, 0x8f, - 0x56, 0x96, 0xdd, 0xb5, 0x2d, 0x87, 0xdf, 0xfb, 0xf0, 0x71, 0x53, 0x20, 0x4c, 0xf0, 0xa3, 0x5a, - 0x16, 0xbc, 0x5c, 0xd7, 0xe2, 0x3b, 0x78, 0xab, 0xea, 0xc4, 0x2b, 0x9f, 0x4f, 0xb4, 0xc2, 0x37, - 0xcf, 0xdc, 0x6a, 0xde, 0x7e, 0x1e, 0x24, 0xe7, 0x7f, 0x11, 0x81, 0xb7, 0x8f, 0x8b, 0xb2, 0x64, - 0xd5, 0xc4, 0xcc, 0x72, 0x52, 0x17, 0xd4, 0x34, 0xc0, 0x89, 0x36, 0xd3, 0x67, 0x5a, 0xe1, 0xe1, - 0x27, 0x5b, 0x33, 0xc3, 0x1e, 0xef, 0xed, 0x8a, 0xa5, 0xc2, 0x17, 0x68, 0x72, 0x21, 0xf3, 0x4f, - 0xdd, 0x49, 0xdf, 0xfc, 0xd4, 0x3e, 0x38, 0xd5, 0x3e, 0xf8, 0xa3, 0x7d, 0xf0, 0x6d, 0xe1, 0xf7, - 0x4e, 0x17, 0x7e, 0xef, 0xd7, 0xc2, 0xef, 0x7d, 0x7e, 0x9e, 0x17, 0xf2, 0x4b, 0x7d, 0x10, 0x1f, - 0xf2, 0x99, 0xd9, 0xb7, 0x97, 0x67, 0x77, 0xef, 0x6b, 0xb7, 0xdc, 0x27, 0x73, 0x26, 0x0e, 0x06, - 0x76, 0xd3, 0x76, 0xfe, 0x06, 0x00, 0x00, 0xff, 0xff, 0xd7, 0xcf, 0xf7, 0x80, 0x02, 0x04, 0x00, - 0x00, +var fileDescriptor_3578f687d4a13206 = []byte{ + // 460 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x93, 0x41, 0x8b, 0xd3, 0x40, + 0x14, 0xc7, 0x9b, 0x26, 0x5b, 0xdd, 0x51, 0x8b, 0x8c, 0xa2, 0x71, 0xc1, 0x24, 0x56, 0x5c, 0x02, + 0x62, 0xa2, 0xdd, 0xbb, 0x60, 0x59, 0x91, 0x15, 0x44, 0x99, 0x6e, 0x11, 0xbc, 0x94, 0x69, 0x67, + 0x88, 0xa1, 0x6d, 0xa6, 0x64, 0x5e, 0x5c, 0xfb, 0x2d, 0xfc, 0x04, 0x9e, 0xfc, 0x30, 0x1e, 0xf7, + 0xe8, 0x29, 0xca, 0xf4, 0xd6, 0x4f, 0x21, 0x33, 0x53, 0xba, 0xae, 0x4b, 0x0f, 0xea, 0xc5, 0x4b, + 0xfb, 0xf2, 0xfe, 0xbf, 0xff, 0xf0, 0xfe, 0x6f, 0x18, 0xf4, 0x40, 0x66, 0x3c, 0x9d, 0xf2, 0x8c, + 0x8e, 0x17, 0xe9, 0x8c, 0x96, 0x13, 0x0e, 0xe9, 0x87, 0x27, 0x23, 0x0e, 0x34, 0x85, 0x7c, 0x3c, + 0xe1, 0x90, 0xcc, 0x4b, 0x01, 0x02, 0xfb, 0x32, 0xe3, 0x89, 0xc5, 0x12, 0x8b, 0x25, 0x16, 0xdb, + 0xbb, 0x99, 0x89, 0x4c, 0x18, 0x28, 0xd5, 0x95, 0xe5, 0xf7, 0xb6, 0x1f, 0xbb, 0x76, 0x5b, 0xec, + 0xfe, 0x56, 0x4c, 0x30, 0x26, 0x2d, 0xd4, 0xf9, 0xd2, 0x44, 0xb7, 0x5e, 0x19, 0xf1, 0x19, 0x63, + 0xc7, 0x66, 0xaa, 0x37, 0x74, 0x31, 0x15, 0x94, 0xe1, 0x08, 0xb9, 0x55, 0xce, 0x7c, 0x27, 0x72, + 0xe2, 0xdd, 0x5e, 0x5b, 0xd5, 0xa1, 0x3b, 0x38, 0x3a, 0x5c, 0xd5, 0xa1, 0xee, 0x12, 0xfd, 0x83, + 0x0f, 0xd0, 0x65, 0x09, 0xb4, 0x84, 0x21, 0x48, 0xbf, 0x19, 0x39, 0xb1, 0xd7, 0xbb, 0xad, 0xea, + 0xf0, 0x52, 0x5f, 0xf7, 0x8e, 0xfb, 0xab, 0x3a, 0xdc, 0xc8, 0x64, 0x53, 0xe1, 0x87, 0xa8, 0xc5, + 0x0b, 0xa6, 0x2d, 0xae, 0xb1, 0xdc, 0x50, 0x75, 0xb8, 0xf3, 0xbc, 0x60, 0xc6, 0xb0, 0x96, 0xc8, + 0xfa, 0x1f, 0x77, 0x91, 0xa7, 0x87, 0xf5, 0xbd, 0xc8, 0x8d, 0xaf, 0x74, 0x83, 0x64, 0xdb, 0xa6, + 0x92, 0xd7, 0x8c, 0x49, 0x62, 0x58, 0xfc, 0x14, 0xb5, 0x24, 0x50, 0xa8, 0xa4, 0xbf, 0x13, 0x39, + 0x71, 0xbb, 0xbb, 0xbf, 0xdd, 0x65, 0x93, 0xf7, 0x0d, 0x4d, 0xd6, 0x2e, 0x8c, 0x91, 0x37, 0xe3, + 0x40, 0xfd, 0x96, 0x0e, 0x4e, 0x4c, 0xdd, 0xf9, 0xee, 0xa0, 0x3b, 0x16, 0x1e, 0xcc, 0x19, 0x05, + 0xfe, 0xff, 0x6d, 0xea, 0x2c, 0xb5, 0xf7, 0x37, 0xa9, 0x3b, 0x9f, 0x9b, 0xe8, 0xae, 0x15, 0x08, + 0x97, 0x62, 0x5a, 0x41, 0x2e, 0x8a, 0x3f, 0x4d, 0xf9, 0x02, 0x5d, 0x2b, 0x37, 0xe6, 0xb3, 0xa8, + 0xf7, 0x54, 0x1d, 0x5e, 0xfd, 0xe5, 0x54, 0x3d, 0xfe, 0x79, 0x90, 0x9c, 0xff, 0xc4, 0x04, 0x5d, + 0x3f, 0xc9, 0x8b, 0x82, 0x97, 0x43, 0x7d, 0xa3, 0xc3, 0x2a, 0x67, 0x7a, 0x07, 0x6e, 0xbc, 0xdb, + 0xdb, 0x57, 0x75, 0xd8, 0x7e, 0x6b, 0x34, 0x7d, 0xe5, 0x83, 0xa3, 0x43, 0xb9, 0xaa, 0xc3, 0x0b, + 0x34, 0xb9, 0xd0, 0xf9, 0xd7, 0x05, 0xf5, 0x5e, 0x7e, 0x55, 0x81, 0x73, 0xaa, 0x02, 0xe7, 0x87, + 0x0a, 0x9c, 0x4f, 0xcb, 0xa0, 0x71, 0xba, 0x0c, 0x1a, 0xdf, 0x96, 0x41, 0xe3, 0xdd, 0xe3, 0x2c, + 0x87, 0xf7, 0xd5, 0x28, 0x19, 0x8b, 0x59, 0x2a, 0x33, 0xfe, 0xa8, 0xe0, 0x70, 0x22, 0xca, 0x89, + 0xae, 0xd3, 0x8f, 0xbf, 0xbd, 0x40, 0x58, 0xcc, 0xb9, 0x1c, 0xb5, 0xcc, 0xe3, 0x3b, 0xf8, 0x19, + 0x00, 0x00, 0xff, 0xff, 0x7e, 0x4b, 0x99, 0x27, 0x21, 0x04, 0x00, 0x00, } func (m *MarketAddTicketPayload) Marshal() (dAtA []byte, err error) { diff --git a/x/market/types/tx.pb.go b/x/legacy/market/types/tx.pb.go similarity index 90% rename from x/market/types/tx.pb.go rename to x/legacy/market/types/tx.pb.go index 25a76e6c..7efb4a1c 100644 --- a/x/market/types/tx.pb.go +++ b/x/legacy/market/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/tx.proto +// source: sge/legacy/market/v1beta/tx.proto package types @@ -44,7 +44,7 @@ func (m *MsgAdd) Reset() { *m = MsgAdd{} } func (m *MsgAdd) String() string { return proto.CompactTextString(m) } func (*MsgAdd) ProtoMessage() {} func (*MsgAdd) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{0} + return fileDescriptor_7946da5d3f27fadd, []int{0} } func (m *MsgAdd) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -99,7 +99,7 @@ func (m *MsgAddResponse) Reset() { *m = MsgAddResponse{} } func (m *MsgAddResponse) String() string { return proto.CompactTextString(m) } func (*MsgAddResponse) ProtoMessage() {} func (*MsgAddResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{1} + return fileDescriptor_7946da5d3f27fadd, []int{1} } func (m *MsgAddResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -154,7 +154,7 @@ func (m *MsgResolve) Reset() { *m = MsgResolve{} } func (m *MsgResolve) String() string { return proto.CompactTextString(m) } func (*MsgResolve) ProtoMessage() {} func (*MsgResolve) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{2} + return fileDescriptor_7946da5d3f27fadd, []int{2} } func (m *MsgResolve) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -209,7 +209,7 @@ func (m *MsgResolveResponse) Reset() { *m = MsgResolveResponse{} } func (m *MsgResolveResponse) String() string { return proto.CompactTextString(m) } func (*MsgResolveResponse) ProtoMessage() {} func (*MsgResolveResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{3} + return fileDescriptor_7946da5d3f27fadd, []int{3} } func (m *MsgResolveResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -265,7 +265,7 @@ func (m *MsgUpdate) Reset() { *m = MsgUpdate{} } func (m *MsgUpdate) String() string { return proto.CompactTextString(m) } func (*MsgUpdate) ProtoMessage() {} func (*MsgUpdate) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{4} + return fileDescriptor_7946da5d3f27fadd, []int{4} } func (m *MsgUpdate) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -320,7 +320,7 @@ func (m *MsgUpdateResponse) Reset() { *m = MsgUpdateResponse{} } func (m *MsgUpdateResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateResponse) ProtoMessage() {} func (*MsgUpdateResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{5} + return fileDescriptor_7946da5d3f27fadd, []int{5} } func (m *MsgUpdateResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -376,7 +376,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{6} + return fileDescriptor_7946da5d3f27fadd, []int{6} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -428,7 +428,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_cb37002f2abdafc2, []int{7} + return fileDescriptor_7946da5d3f27fadd, []int{7} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -458,54 +458,55 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgAdd)(nil), "sgenetwork.sge.market.MsgAdd") - proto.RegisterType((*MsgAddResponse)(nil), "sgenetwork.sge.market.MsgAddResponse") - proto.RegisterType((*MsgResolve)(nil), "sgenetwork.sge.market.MsgResolve") - proto.RegisterType((*MsgResolveResponse)(nil), "sgenetwork.sge.market.MsgResolveResponse") - proto.RegisterType((*MsgUpdate)(nil), "sgenetwork.sge.market.MsgUpdate") - proto.RegisterType((*MsgUpdateResponse)(nil), "sgenetwork.sge.market.MsgUpdateResponse") - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.market.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.market.MsgUpdateParamsResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/market/tx.proto", fileDescriptor_cb37002f2abdafc2) } - -var fileDescriptor_cb37002f2abdafc2 = []byte{ - // 541 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x54, 0x41, 0x6b, 0x13, 0x4f, - 0x14, 0xcf, 0x24, 0xfd, 0xa7, 0xe4, 0xfd, 0x8b, 0x92, 0xa1, 0xb5, 0x71, 0xc1, 0x6d, 0x5c, 0x51, - 0xda, 0x42, 0x76, 0x4d, 0x04, 0x0b, 0x39, 0xd9, 0x78, 0x0e, 0x94, 0x15, 0x0f, 0x8a, 0x20, 0x9b, - 0xec, 0x38, 0x59, 0xe2, 0x66, 0xc2, 0xcc, 0xb4, 0xb6, 0x37, 0xf1, 0xd4, 0xa3, 0xe0, 0x97, 0xf0, - 0x98, 0x43, 0x3f, 0x44, 0xf0, 0x54, 0x7a, 0xf2, 0x54, 0x24, 0x39, 0xf4, 0x6b, 0xc8, 0xee, 0xcc, - 0x6e, 0x8c, 0x24, 0x5d, 0x2f, 0xb9, 0xec, 0xec, 0xcc, 0xfb, 0xfd, 0xde, 0xef, 0xbd, 0x37, 0x6f, - 0x1e, 0x98, 0x82, 0x92, 0x01, 0x91, 0x9f, 0x18, 0xef, 0x3b, 0x82, 0x12, 0x27, 0xf4, 0x78, 0x9f, - 0x48, 0x47, 0x9e, 0xda, 0x43, 0xce, 0x24, 0xc3, 0x5b, 0x33, 0xbb, 0x2d, 0x28, 0xb1, 0x95, 0xdd, - 0x28, 0x7b, 0x61, 0x30, 0x60, 0x4e, 0xfc, 0x55, 0x48, 0x63, 0xbb, 0xcb, 0x44, 0xc8, 0x84, 0x13, - 0x0a, 0xea, 0x9c, 0xd4, 0xa3, 0x45, 0x1b, 0xee, 0x2b, 0xc3, 0xfb, 0x78, 0xe7, 0xa8, 0x8d, 0x36, - 0x6d, 0x52, 0x46, 0x99, 0x3a, 0x8f, 0xfe, 0xf4, 0xa9, 0xb5, 0x38, 0x26, 0xb5, 0xdc, 0x8e, 0x19, - 0x7a, 0xdc, 0x0b, 0xb5, 0x77, 0xab, 0x03, 0xc5, 0xb6, 0xa0, 0x87, 0xbe, 0x8f, 0x1b, 0xb0, 0xde, - 0xe5, 0xc4, 0x93, 0x8c, 0x57, 0x50, 0x15, 0xed, 0x96, 0x5a, 0x95, 0xab, 0x8b, 0xda, 0xa6, 0x0e, - 0xe5, 0xd0, 0xf7, 0x39, 0x11, 0xe2, 0x95, 0xe4, 0xc1, 0x80, 0xba, 0x09, 0x10, 0xdf, 0x83, 0xa2, - 0x0c, 0xba, 0x7d, 0x22, 0x2b, 0xf9, 0x88, 0xe2, 0xea, 0x5d, 0x73, 0xe3, 0xcb, 0xcd, 0x68, 0x3f, - 0x41, 0x59, 0x04, 0xee, 0x28, 0x0d, 0x97, 0x88, 0x21, 0x1b, 0x08, 0x82, 0x0d, 0xf8, 0x8f, 0x70, - 0x9e, 0x2a, 0xad, 0x8d, 0xaf, 0x77, 0x90, 0xab, 0x8e, 0xf0, 0x01, 0xac, 0xf9, 0x9e, 0xf4, 0x62, - 0x8f, 0xff, 0x37, 0x1e, 0xd8, 0x0b, 0x8b, 0x6b, 0xb7, 0xe3, 0x45, 0x33, 0x63, 0x82, 0xf5, 0x01, - 0xa0, 0x2d, 0xa8, 0x4b, 0x04, 0xfb, 0x78, 0x42, 0x56, 0x98, 0x4e, 0x00, 0x78, 0xa6, 0xb3, 0xda, - 0x94, 0x08, 0x94, 0xda, 0x82, 0xbe, 0x1e, 0xfa, 0x9e, 0x5c, 0x65, 0x46, 0x3d, 0x28, 0xa7, 0x32, - 0xab, 0x4d, 0x68, 0x84, 0xe0, 0x6e, 0x2a, 0x75, 0x14, 0x37, 0x22, 0x7e, 0x0e, 0x25, 0xef, 0x58, - 0xf6, 0x18, 0x0f, 0xe4, 0x59, 0x66, 0x66, 0x33, 0x28, 0x7e, 0x01, 0x45, 0xd5, 0xca, 0x19, 0x61, - 0x28, 0x99, 0x56, 0x69, 0x7c, 0xbd, 0x93, 0xfb, 0x7e, 0x33, 0xda, 0x47, 0xae, 0xe6, 0x35, 0x1f, - 0x5d, 0x5d, 0xd4, 0xca, 0x82, 0x92, 0x9a, 0x66, 0x55, 0xeb, 0xf6, 0x81, 0x5d, 0x8f, 0x4a, 0x33, - 0x93, 0xb1, 0x9e, 0xc2, 0xf6, 0x5f, 0x11, 0x27, 0x25, 0x6a, 0x6e, 0x2d, 0xe4, 0x37, 0xbe, 0x15, - 0xa0, 0xd0, 0x16, 0x14, 0x1f, 0x41, 0x21, 0x7a, 0x58, 0x4b, 0xcb, 0x13, 0xbf, 0x09, 0xe3, 0xf1, - 0xad, 0xe6, 0x44, 0xcb, 0x2a, 0x9c, 0xe7, 0x11, 0x7e, 0x07, 0xeb, 0x49, 0x7f, 0x3f, 0x5c, 0x4e, - 0xd3, 0x10, 0x63, 0x2f, 0x13, 0x32, 0xef, 0xfd, 0x0d, 0x14, 0x75, 0xab, 0x55, 0x97, 0x33, 0x15, - 0xc2, 0xd8, 0xcd, 0x42, 0xcc, 0xbb, 0xfe, 0x8c, 0x60, 0x63, 0xee, 0xd2, 0x9f, 0x64, 0xf1, 0x15, - 0xce, 0xb0, 0xff, 0x0d, 0x97, 0xaa, 0x55, 0x7e, 0x2c, 0xba, 0x92, 0xf3, 0x3c, 0x6a, 0xbd, 0x1c, - 0x4f, 0x4c, 0x74, 0x39, 0x31, 0xd1, 0xaf, 0x89, 0x89, 0xbe, 0x4e, 0xcd, 0xdc, 0xe5, 0xd4, 0xcc, - 0xfd, 0x9c, 0x9a, 0xb9, 0xb7, 0x7b, 0x34, 0x90, 0xbd, 0xe3, 0x8e, 0xdd, 0x65, 0xa1, 0xf3, 0x07, - 0x35, 0x9e, 0x99, 0xa7, 0xe9, 0xb4, 0x3f, 0x1b, 0x12, 0xd1, 0x29, 0xc6, 0x53, 0xf3, 0xd9, 0xef, - 0x00, 0x00, 0x00, 0xff, 0xff, 0x40, 0x40, 0x35, 0x34, 0x13, 0x06, 0x00, 0x00, + proto.RegisterType((*MsgAdd)(nil), "sge.legacy.market.v1beta.MsgAdd") + proto.RegisterType((*MsgAddResponse)(nil), "sge.legacy.market.v1beta.MsgAddResponse") + proto.RegisterType((*MsgResolve)(nil), "sge.legacy.market.v1beta.MsgResolve") + proto.RegisterType((*MsgResolveResponse)(nil), "sge.legacy.market.v1beta.MsgResolveResponse") + proto.RegisterType((*MsgUpdate)(nil), "sge.legacy.market.v1beta.MsgUpdate") + proto.RegisterType((*MsgUpdateResponse)(nil), "sge.legacy.market.v1beta.MsgUpdateResponse") + proto.RegisterType((*MsgUpdateParams)(nil), "sge.legacy.market.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.legacy.market.v1beta.MsgUpdateParamsResponse") +} + +func init() { proto.RegisterFile("sge/legacy/market/v1beta/tx.proto", fileDescriptor_7946da5d3f27fadd) } + +var fileDescriptor_7946da5d3f27fadd = []byte{ + // 550 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x94, 0x41, 0x6f, 0x12, 0x41, + 0x14, 0xc7, 0x19, 0xa8, 0x34, 0x3c, 0x1b, 0x0d, 0x9b, 0x6a, 0x71, 0x0f, 0x5b, 0xa4, 0x9a, 0xd4, + 0x2a, 0x3b, 0x05, 0x13, 0x4d, 0xb8, 0x15, 0x6f, 0x26, 0x24, 0x66, 0x8d, 0x1e, 0xbc, 0x34, 0x03, + 0x3b, 0x0e, 0x04, 0x96, 0x21, 0x33, 0x53, 0x2c, 0x57, 0x0f, 0xa6, 0x47, 0x3f, 0x86, 0x89, 0x97, + 0x26, 0xf6, 0x43, 0x10, 0x4f, 0x4d, 0x4f, 0x9e, 0x1a, 0x03, 0x87, 0x7e, 0x0d, 0xb3, 0x3b, 0xb3, + 0x20, 0x4d, 0x0b, 0x5c, 0xb8, 0xc0, 0xbe, 0x99, 0xdf, 0x7f, 0xff, 0xef, 0xbd, 0x7d, 0x33, 0xf0, + 0x58, 0x32, 0x8a, 0x3b, 0x94, 0x91, 0xc6, 0x00, 0x07, 0x44, 0xb4, 0xa9, 0xc2, 0xfd, 0x52, 0x9d, + 0x2a, 0x82, 0xd5, 0xb1, 0xdb, 0x13, 0x5c, 0x71, 0x2b, 0x27, 0x19, 0x75, 0x35, 0xe2, 0x6a, 0xc4, + 0xd5, 0x88, 0x9d, 0x25, 0x41, 0xab, 0xcb, 0x71, 0xf4, 0xab, 0x61, 0x7b, 0xab, 0xc1, 0x65, 0xc0, + 0x25, 0x0e, 0x24, 0xc3, 0xfd, 0x52, 0xf8, 0x67, 0x36, 0x1e, 0xe9, 0x8d, 0xc3, 0x28, 0xc2, 0x3a, + 0x30, 0x5b, 0x9b, 0x8c, 0x33, 0xae, 0xd7, 0xc3, 0x27, 0xb3, 0xfa, 0xf4, 0xd6, 0xcc, 0x4c, 0x12, + 0x8b, 0xb0, 0x1e, 0x11, 0x24, 0x30, 0x1e, 0x85, 0x3a, 0xa4, 0x6b, 0x92, 0x1d, 0xf8, 0xbe, 0x55, + 0x86, 0xf5, 0x86, 0xa0, 0x44, 0x71, 0x91, 0x43, 0x79, 0xb4, 0x9b, 0xa9, 0xe6, 0x2e, 0xce, 0x8a, + 0x9b, 0x26, 0xa1, 0x03, 0xdf, 0x17, 0x54, 0xca, 0xf7, 0x4a, 0xb4, 0xba, 0xcc, 0x8b, 0x41, 0xeb, + 0x21, 0xa4, 0x55, 0xab, 0xd1, 0xa6, 0x2a, 0x97, 0x0c, 0x25, 0x9e, 0x89, 0x2a, 0x1b, 0x5f, 0xaf, + 0x4e, 0xf7, 0x62, 0xaa, 0xd0, 0x84, 0x7b, 0xda, 0xc3, 0xa3, 0xb2, 0xc7, 0xbb, 0x92, 0x5a, 0x36, + 0xdc, 0xa1, 0x42, 0x4c, 0x9c, 0xd6, 0x86, 0x97, 0xdb, 0xc8, 0xd3, 0x4b, 0x56, 0x05, 0xd6, 0x7c, + 0xa2, 0x48, 0xf4, 0xc6, 0xbb, 0xe5, 0xbc, 0x7b, 0x5b, 0x97, 0xdd, 0x5a, 0x14, 0x19, 0x71, 0xa4, + 0x29, 0x7c, 0x06, 0xa8, 0x49, 0xe6, 0x51, 0xc9, 0x3b, 0x7d, 0xba, 0xc2, 0x8a, 0x3a, 0x60, 0x4d, + 0x7d, 0x56, 0x5e, 0x15, 0x85, 0x4c, 0x4d, 0xb2, 0x0f, 0x3d, 0x9f, 0xa8, 0x55, 0x16, 0xd5, 0x86, + 0xec, 0xc4, 0x66, 0xe5, 0x35, 0xfd, 0x42, 0x70, 0x7f, 0xe2, 0xf6, 0x2e, 0x9a, 0x48, 0xeb, 0x15, + 0x64, 0xc8, 0x91, 0x6a, 0x72, 0xd1, 0x52, 0x83, 0x85, 0xc5, 0x4d, 0x51, 0xeb, 0x0d, 0xa4, 0xf5, + 0x4c, 0x2f, 0xce, 0x44, 0x3b, 0x55, 0x33, 0xc3, 0xcb, 0xed, 0xc4, 0x8f, 0xab, 0xd3, 0x3d, 0xe4, + 0x19, 0x69, 0x65, 0xe7, 0xe2, 0xac, 0x98, 0x95, 0x8c, 0x16, 0xbb, 0x54, 0x7d, 0xe1, 0xa2, 0x9d, + 0x2f, 0xb9, 0xaf, 0xdd, 0x52, 0xd8, 0xa0, 0xa9, 0x53, 0x61, 0x1f, 0xb6, 0xae, 0x25, 0x1d, 0x37, + 0xaa, 0xf2, 0xe0, 0x46, 0x7d, 0xf9, 0x67, 0x0a, 0x52, 0x35, 0xc9, 0xac, 0x8f, 0x90, 0x0a, 0x0f, + 0xd9, 0xbc, 0x26, 0x45, 0x47, 0xc4, 0xde, 0x5d, 0x44, 0xc4, 0x8e, 0x85, 0xd4, 0x49, 0x12, 0x59, + 0x75, 0x58, 0x8f, 0xc7, 0xfd, 0xc9, 0x5c, 0xa5, 0xa1, 0xec, 0x17, 0xcb, 0x50, 0xb3, 0x1e, 0x87, + 0x90, 0x36, 0xc3, 0xb7, 0x33, 0x57, 0xac, 0x21, 0xfb, 0xf9, 0x12, 0xd0, 0xac, 0xc1, 0x37, 0x04, + 0x1b, 0x33, 0x93, 0xf0, 0x6c, 0x89, 0x57, 0x68, 0xd4, 0x2e, 0x2d, 0x8d, 0x4e, 0x3c, 0x73, 0xbf, + 0x6f, 0xfa, 0x54, 0x27, 0x49, 0x54, 0x7d, 0x3b, 0x1c, 0x39, 0xe8, 0x7c, 0xe4, 0xa0, 0xbf, 0x23, + 0x07, 0x7d, 0x1f, 0x3b, 0x89, 0xf3, 0xb1, 0x93, 0xf8, 0x33, 0x76, 0x12, 0x9f, 0xf6, 0x59, 0x4b, + 0x35, 0x8f, 0xea, 0x6e, 0x83, 0x07, 0xf8, 0x3f, 0x69, 0xf8, 0x8c, 0x8f, 0xaf, 0xdd, 0xb3, 0x6a, + 0xd0, 0xa3, 0xb2, 0x9e, 0x8e, 0x2e, 0xd8, 0x97, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0xca, 0x24, + 0x66, 0x97, 0x4a, 0x06, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -542,7 +543,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { // Deprecated: Do not use. func (c *msgClient) Add(ctx context.Context, in *MsgAdd, opts ...grpc.CallOption) (*MsgAddResponse, error) { out := new(MsgAddResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Msg/Add", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Msg/Add", in, out, opts...) if err != nil { return nil, err } @@ -552,7 +553,7 @@ func (c *msgClient) Add(ctx context.Context, in *MsgAdd, opts ...grpc.CallOption // Deprecated: Do not use. func (c *msgClient) Resolve(ctx context.Context, in *MsgResolve, opts ...grpc.CallOption) (*MsgResolveResponse, error) { out := new(MsgResolveResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Msg/Resolve", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Msg/Resolve", in, out, opts...) if err != nil { return nil, err } @@ -562,7 +563,7 @@ func (c *msgClient) Resolve(ctx context.Context, in *MsgResolve, opts ...grpc.Ca // Deprecated: Do not use. func (c *msgClient) Update(ctx context.Context, in *MsgUpdate, opts ...grpc.CallOption) (*MsgUpdateResponse, error) { out := new(MsgUpdateResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Msg/Update", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Msg/Update", in, out, opts...) if err != nil { return nil, err } @@ -572,7 +573,7 @@ func (c *msgClient) Update(ctx context.Context, in *MsgUpdate, opts ...grpc.Call // Deprecated: Do not use. func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.market.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.market.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -623,7 +624,7 @@ func _Msg_Add_Handler(srv interface{}, ctx context.Context, dec func(interface{} } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Msg/Add", + FullMethod: "/sge.legacy.market.v1beta.Msg/Add", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Add(ctx, req.(*MsgAdd)) @@ -641,7 +642,7 @@ func _Msg_Resolve_Handler(srv interface{}, ctx context.Context, dec func(interfa } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Msg/Resolve", + FullMethod: "/sge.legacy.market.v1beta.Msg/Resolve", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Resolve(ctx, req.(*MsgResolve)) @@ -659,7 +660,7 @@ func _Msg_Update_Handler(srv interface{}, ctx context.Context, dec func(interfac } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Msg/Update", + FullMethod: "/sge.legacy.market.v1beta.Msg/Update", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Update(ctx, req.(*MsgUpdate)) @@ -677,7 +678,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.market.Msg/UpdateParams", + FullMethod: "/sge.legacy.market.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -685,8 +686,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.market.Msg", + ServiceName: "sge.legacy.market.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -707,7 +709,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/market/tx.proto", + Metadata: "sge/legacy/market/v1beta/tx.proto", } func (m *MsgAdd) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/abci.go b/x/legacy/orderbook/abci.go similarity index 86% rename from x/orderbook/abci.go rename to x/legacy/orderbook/abci.go index b4a9700d..707307e1 100644 --- a/x/orderbook/abci.go +++ b/x/legacy/orderbook/abci.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/keeper" + "github.com/sge-network/sge/x/legacy/orderbook/keeper" ) // EndBlocker settles the active deposits of resolved order books diff --git a/x/orderbook/client/cli/query.go b/x/legacy/orderbook/client/cli/query.go similarity index 94% rename from x/orderbook/client/cli/query.go rename to x/legacy/orderbook/client/cli/query.go index bd521d51..26800952 100644 --- a/x/orderbook/client/cli/query.go +++ b/x/legacy/orderbook/client/cli/query.go @@ -5,7 +5,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // GetQueryCmd returns the cli query commands for this module diff --git a/x/orderbook/client/cli/query_bet.go b/x/legacy/orderbook/client/cli/query_bet.go similarity index 97% rename from x/orderbook/client/cli/query_bet.go rename to x/legacy/orderbook/client/cli/query_bet.go index cc5d1e33..038c6ea2 100644 --- a/x/orderbook/client/cli/query_bet.go +++ b/x/legacy/orderbook/client/cli/query_bet.go @@ -11,7 +11,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // GetCmdQueryParticipationBets implements the command to query all the participation fulfilled bets to a specific orderbook. diff --git a/x/orderbook/client/cli/query_exposure_odds.go b/x/legacy/orderbook/client/cli/query_exposure_odds.go similarity index 97% rename from x/orderbook/client/cli/query_exposure_odds.go rename to x/legacy/orderbook/client/cli/query_exposure_odds.go index 506897e0..e5378c32 100644 --- a/x/orderbook/client/cli/query_exposure_odds.go +++ b/x/legacy/orderbook/client/cli/query_exposure_odds.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // GetCmdQueryOrderBookExposure implements the book-exposure query command. diff --git a/x/orderbook/client/cli/query_exposure_participation.go b/x/legacy/orderbook/client/cli/query_exposure_participation.go similarity index 98% rename from x/orderbook/client/cli/query_exposure_participation.go rename to x/legacy/orderbook/client/cli/query_exposure_participation.go index 8e51f151..0805be38 100644 --- a/x/orderbook/client/cli/query_exposure_participation.go +++ b/x/legacy/orderbook/client/cli/query_exposure_participation.go @@ -11,7 +11,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // GetCmdQueryOrderBookParticipationExposures implements the command to query all the participation exposures to a specific orderbook. diff --git a/x/orderbook/client/cli/query_orderbook.go b/x/legacy/orderbook/client/cli/query_orderbook.go similarity index 97% rename from x/orderbook/client/cli/query_orderbook.go rename to x/legacy/orderbook/client/cli/query_orderbook.go index 048bf073..a3412645 100644 --- a/x/orderbook/client/cli/query_orderbook.go +++ b/x/legacy/orderbook/client/cli/query_orderbook.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // GetCmdQueryOrderBooks implements the query all order books command. diff --git a/x/ovm/client/cli/query_params.go b/x/legacy/orderbook/client/cli/query_params.go similarity index 93% rename from x/ovm/client/cli/query_params.go rename to x/legacy/orderbook/client/cli/query_params.go index 5effe47d..0e62e555 100644 --- a/x/ovm/client/cli/query_params.go +++ b/x/legacy/orderbook/client/cli/query_params.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // CmdQueryParams returns a command object instance for module params diff --git a/x/orderbook/client/cli/query_participation.go b/x/legacy/orderbook/client/cli/query_participation.go similarity index 98% rename from x/orderbook/client/cli/query_participation.go rename to x/legacy/orderbook/client/cli/query_participation.go index 291b05be..5d59db89 100644 --- a/x/orderbook/client/cli/query_participation.go +++ b/x/legacy/orderbook/client/cli/query_participation.go @@ -11,7 +11,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // GetCmdQueryOrderBookParticipations implements the command to query all the participations to a specific orderbook. diff --git a/x/orderbook/genesis.go b/x/legacy/orderbook/genesis.go similarity index 95% rename from x/orderbook/genesis.go rename to x/legacy/orderbook/genesis.go index 700ba57d..db876f71 100644 --- a/x/orderbook/genesis.go +++ b/x/legacy/orderbook/genesis.go @@ -3,8 +3,8 @@ package orderbook import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/keeper" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // InitGenesis sets the parameters for the provided keeper. diff --git a/x/orderbook/keeper/bet_settle.go b/x/legacy/orderbook/keeper/bet_settle.go similarity index 96% rename from x/orderbook/keeper/bet_settle.go rename to x/legacy/orderbook/keeper/bet_settle.go index 8da14671..412e48d1 100644 --- a/x/orderbook/keeper/bet_settle.go +++ b/x/legacy/orderbook/keeper/bet_settle.go @@ -5,8 +5,8 @@ import ( sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" - bettypes "github.com/sge-network/sge/x/bet/types" - "github.com/sge-network/sge/x/orderbook/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // RefundBettor process bets in case market gets cancelled or aborted, diff --git a/x/orderbook/keeper/bet_wager.go b/x/legacy/orderbook/keeper/bet_wager.go similarity index 99% rename from x/orderbook/keeper/bet_wager.go rename to x/legacy/orderbook/keeper/bet_wager.go index 728af91c..0ae133c5 100644 --- a/x/orderbook/keeper/bet_wager.go +++ b/x/legacy/orderbook/keeper/bet_wager.go @@ -6,8 +6,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cast" - bettypes "github.com/sge-network/sge/x/bet/types" - "github.com/sge-network/sge/x/orderbook/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // ProcessWager processes bet placement diff --git a/x/orderbook/keeper/export_test.go b/x/legacy/orderbook/keeper/export_test.go similarity index 100% rename from x/orderbook/keeper/export_test.go rename to x/legacy/orderbook/keeper/export_test.go diff --git a/x/orderbook/keeper/exposure_odds.go b/x/legacy/orderbook/keeper/exposure_odds.go similarity index 92% rename from x/orderbook/keeper/exposure_odds.go rename to x/legacy/orderbook/keeper/exposure_odds.go index afa2c48b..f113c5a2 100644 --- a/x/orderbook/keeper/exposure_odds.go +++ b/x/legacy/orderbook/keeper/exposure_odds.go @@ -2,9 +2,10 @@ package keeper import ( sdkmath "cosmossdk.io/math" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // SetOrderBookOddsExposure sets a book odds exposure. @@ -39,7 +40,7 @@ func (k Keeper) GetOddsExposuresByOrderBook( orderBookUID string, ) (list []types.OrderBookOddsExposure, err error) { store := k.getOrderBookOddsExposureStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, types.GetOrderBookOddsExposuresKey(orderBookUID)) + iterator := storetypes.KVStorePrefixIterator(store, types.GetOrderBookOddsExposuresKey(orderBookUID)) defer func() { err = iterator.Close() @@ -59,7 +60,7 @@ func (k Keeper) GetAllOrderBookExposures( ctx sdk.Context, ) (list []types.OrderBookOddsExposure, err error) { store := k.getOrderBookOddsExposureStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/orderbook/keeper/exposure_participation.go b/x/legacy/orderbook/keeper/exposure_participation.go similarity index 91% rename from x/orderbook/keeper/exposure_participation.go rename to x/legacy/orderbook/keeper/exposure_participation.go index 9e9938e8..a1a871b6 100644 --- a/x/orderbook/keeper/exposure_participation.go +++ b/x/legacy/orderbook/keeper/exposure_participation.go @@ -1,9 +1,10 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // SetParticipationExposure sets a participation exposure. @@ -29,7 +30,7 @@ func (k Keeper) GetExposureByOrderBookAndOdds( bookUID, oddsUID string, ) (list []types.ParticipationExposure, err error) { store := k.getParticipationExposureStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, types.GetParticipationExposuresKey(bookUID, oddsUID)) + iterator := storetypes.KVStorePrefixIterator(store, types.GetParticipationExposuresKey(bookUID, oddsUID)) defer func() { err = iterator.Close() @@ -51,7 +52,7 @@ func (k Keeper) GetExposureByOrderBook( ) (peMap map[uint64]map[string]*types.ParticipationExposure, err error) { peMap = make(map[uint64]map[string]*types.ParticipationExposure) store := k.getParticipationExposureStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, types.GetParticipationExposuresByOrderBookKey(bookUID)) + iterator := storetypes.KVStorePrefixIterator(store, types.GetParticipationExposuresByOrderBookKey(bookUID)) defer func() { err = iterator.Close() @@ -75,7 +76,7 @@ func (k Keeper) GetAllParticipationExposures( ctx sdk.Context, ) (list []types.ParticipationExposure, err error) { store := k.getParticipationExposureStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() @@ -110,7 +111,7 @@ func (k Keeper) GetExposureByOrderBookAndParticipationIndex( participationIndex uint64, ) (list []types.ParticipationExposure, err error) { store := k.getParticipationExposureByIndexStore(ctx) - iterator := sdk.KVStorePrefixIterator( + iterator := storetypes.KVStorePrefixIterator( store, types.GetParticipationByIndexKey(bookUID, participationIndex), ) @@ -155,7 +156,7 @@ func (k Keeper) GetAllHistoricalParticipationExposures( ctx sdk.Context, ) (list []types.ParticipationExposure, err error) { store := k.getHistoricalParticipationExposureStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/orderbook/keeper/fund.go b/x/legacy/orderbook/keeper/fund.go similarity index 97% rename from x/orderbook/keeper/fund.go rename to x/legacy/orderbook/keeper/fund.go index 6fd518ab..e3f5a567 100644 --- a/x/orderbook/keeper/fund.go +++ b/x/legacy/orderbook/keeper/fund.go @@ -6,7 +6,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) type iModuleFunder interface { diff --git a/x/legacy/orderbook/keeper/grpc_query.go b/x/legacy/orderbook/keeper/grpc_query.go new file mode 100644 index 00000000..1085e5d7 --- /dev/null +++ b/x/legacy/orderbook/keeper/grpc_query.go @@ -0,0 +1,7 @@ +package keeper + +import ( + "github.com/sge-network/sge/x/legacy/orderbook/types" +) + +var _ types.QueryServer = Keeper{} diff --git a/x/orderbook/keeper/grpc_query_exposure_odds.go b/x/legacy/orderbook/keeper/grpc_query_exposure_odds.go similarity index 96% rename from x/orderbook/keeper/grpc_query_exposure_odds.go rename to x/legacy/orderbook/keeper/grpc_query_exposure_odds.go index ed5bdbd8..19459a78 100644 --- a/x/orderbook/keeper/grpc_query_exposure_odds.go +++ b/x/legacy/orderbook/keeper/grpc_query_exposure_odds.go @@ -6,12 +6,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // OrderBookExposure queries book exposure info for given order book id and odds id diff --git a/x/orderbook/keeper/grpc_query_exposure_participation.go b/x/legacy/orderbook/keeper/grpc_query_exposure_participation.go similarity index 98% rename from x/orderbook/keeper/grpc_query_exposure_participation.go rename to x/legacy/orderbook/keeper/grpc_query_exposure_participation.go index 44ff1018..48a70b7f 100644 --- a/x/orderbook/keeper/grpc_query_exposure_participation.go +++ b/x/legacy/orderbook/keeper/grpc_query_exposure_participation.go @@ -6,12 +6,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // OrderBookParticipationExposures queries participation exposures info for a given orderbook diff --git a/x/orderbook/keeper/grpc_query_orderbook.go b/x/legacy/orderbook/keeper/grpc_query_orderbook.go similarity index 96% rename from x/orderbook/keeper/grpc_query_orderbook.go rename to x/legacy/orderbook/keeper/grpc_query_orderbook.go index e0b9a035..a0005c97 100644 --- a/x/orderbook/keeper/grpc_query_orderbook.go +++ b/x/legacy/orderbook/keeper/grpc_query_orderbook.go @@ -7,12 +7,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // OrderBook queries orderbook info for given order book id diff --git a/x/bet/keeper/grpc_query_params.go b/x/legacy/orderbook/keeper/grpc_query_params.go similarity index 90% rename from x/bet/keeper/grpc_query_params.go rename to x/legacy/orderbook/keeper/grpc_query_params.go index 57ecd7be..7de219f4 100644 --- a/x/bet/keeper/grpc_query_params.go +++ b/x/legacy/orderbook/keeper/grpc_query_params.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // Params returns the params of the module diff --git a/x/orderbook/keeper/grpc_query_participation.go b/x/legacy/orderbook/keeper/grpc_query_participation.go similarity index 97% rename from x/orderbook/keeper/grpc_query_participation.go rename to x/legacy/orderbook/keeper/grpc_query_participation.go index d815b91b..12e2b611 100644 --- a/x/orderbook/keeper/grpc_query_participation.go +++ b/x/legacy/orderbook/keeper/grpc_query_participation.go @@ -6,12 +6,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // OrderBookParticipation queries book participation info for given order book id and participation index diff --git a/x/orderbook/keeper/grpc_query_participation_bet.go b/x/legacy/orderbook/keeper/grpc_query_participation_bet.go similarity index 95% rename from x/orderbook/keeper/grpc_query_participation_bet.go rename to x/legacy/orderbook/keeper/grpc_query_participation_bet.go index 05001339..ac327af4 100644 --- a/x/orderbook/keeper/grpc_query_participation_bet.go +++ b/x/legacy/orderbook/keeper/grpc_query_participation_bet.go @@ -6,12 +6,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // ParticipationFulfilledBets queries participation fulfilled bets info for given order book id and participation index diff --git a/x/orderbook/keeper/keeper.go b/x/legacy/orderbook/keeper/keeper.go similarity index 94% rename from x/orderbook/keeper/keeper.go rename to x/legacy/orderbook/keeper/keeper.go index cf7312f4..f0d1e363 100644 --- a/x/orderbook/keeper/keeper.go +++ b/x/legacy/orderbook/keeper/keeper.go @@ -3,13 +3,13 @@ package keeper import ( "fmt" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // Keeper of the orderbook store diff --git a/x/orderbook/keeper/market.go b/x/legacy/orderbook/keeper/market.go similarity index 85% rename from x/orderbook/keeper/market.go rename to x/legacy/orderbook/keeper/market.go index 2fb2adee..65ddc1c2 100644 --- a/x/orderbook/keeper/market.go +++ b/x/legacy/orderbook/keeper/market.go @@ -4,7 +4,7 @@ import ( sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" - bettypes "github.com/sge-network/sge/x/bet/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" ) func (k Keeper) WithdrawBetFee(ctx sdk.Context, marketCreator sdk.AccAddress, betFee sdkmath.Int) error { diff --git a/x/legacy/orderbook/keeper/msg_server.go b/x/legacy/orderbook/keeper/msg_server.go new file mode 100644 index 00000000..484fe1a9 --- /dev/null +++ b/x/legacy/orderbook/keeper/msg_server.go @@ -0,0 +1,17 @@ +package keeper + +import ( + "github.com/sge-network/sge/x/legacy/orderbook/types" +) + +type msgServer struct { + Keeper +} + +// NewMsgServerImpl returns an implementation of the MsgServer interface +// for the provided Keeper. +func NewMsgServerImpl(keeper Keeper) types.MsgServer { + return &msgServer{Keeper: keeper} +} + +var _ types.MsgServer = msgServer{} diff --git a/x/legacy/orderbook/keeper/msg_server_params.go b/x/legacy/orderbook/keeper/msg_server_params.go new file mode 100644 index 00000000..f1b2d611 --- /dev/null +++ b/x/legacy/orderbook/keeper/msg_server_params.go @@ -0,0 +1,27 @@ +package keeper + +import ( + "context" + + sdkerrors "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + + "github.com/sge-network/sge/x/legacy/orderbook/types" +) + +func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { + ctx := sdk.UnwrapSDKContext(goCtx) + + if k.GetAuthority() != req.Authority { + return nil, sdkerrors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.GetAuthority(), req.Authority) + } + + if err := req.Params.Validate(); err != nil { + return nil, err + } + + k.SetParams(ctx, req.Params) + + return &types.MsgUpdateParamsResponse{}, nil +} diff --git a/x/orderbook/keeper/orderbook.go b/x/legacy/orderbook/keeper/orderbook.go similarity index 92% rename from x/orderbook/keeper/orderbook.go rename to x/legacy/orderbook/keeper/orderbook.go index 68a2218f..dfb1ca60 100644 --- a/x/orderbook/keeper/orderbook.go +++ b/x/legacy/orderbook/keeper/orderbook.go @@ -2,9 +2,10 @@ package keeper import ( sdkerrors "cosmossdk.io/errors" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // SetOrderBook sets an order book. @@ -33,7 +34,7 @@ func (k Keeper) GetOrderBook(ctx sdk.Context, orderBookUID string) (val types.Or // GetAllOrderBooks returns all order books used during genesis dump. func (k Keeper) GetAllOrderBooks(ctx sdk.Context) (list []types.OrderBook, err error) { store := k.getOrderBookStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/orderbook/keeper/orderbook_settle.go b/x/legacy/orderbook/keeper/orderbook_settle.go similarity index 97% rename from x/orderbook/keeper/orderbook_settle.go rename to x/legacy/orderbook/keeper/orderbook_settle.go index c3ef927b..5494ac97 100644 --- a/x/orderbook/keeper/orderbook_settle.go +++ b/x/legacy/orderbook/keeper/orderbook_settle.go @@ -9,9 +9,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - housetypes "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" - "github.com/sge-network/sge/x/orderbook/types" + housetypes "github.com/sge-network/sge/x/legacy/house/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // BatchOrderBookSettlements settles order books diff --git a/x/orderbook/keeper/params.go b/x/legacy/orderbook/keeper/params.go similarity index 94% rename from x/orderbook/keeper/params.go rename to x/legacy/orderbook/keeper/params.go index 66f46636..2b2c918c 100644 --- a/x/orderbook/keeper/params.go +++ b/x/legacy/orderbook/keeper/params.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // GetParams Get all parameters as types.Params diff --git a/x/orderbook/keeper/participation.go b/x/legacy/orderbook/keeper/participation.go similarity index 94% rename from x/orderbook/keeper/participation.go rename to x/legacy/orderbook/keeper/participation.go index 94278b98..65861871 100644 --- a/x/orderbook/keeper/participation.go +++ b/x/legacy/orderbook/keeper/participation.go @@ -3,11 +3,12 @@ package keeper import ( sdkerrors "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - housetypes "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" - "github.com/sge-network/sge/x/orderbook/types" + housetypes "github.com/sge-network/sge/x/legacy/house/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // SetOrderBookParticipation sets a book participation. @@ -46,7 +47,7 @@ func (k Keeper) GetParticipationsOfOrderBook( bookUID string, ) (list []types.OrderBookParticipation, err error) { store := k.getParticipationStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, types.GetOrderBookParticipationsKey(bookUID)) + iterator := storetypes.KVStorePrefixIterator(store, types.GetOrderBookParticipationsKey(bookUID)) defer func() { err = iterator.Close() @@ -66,7 +67,7 @@ func (k Keeper) GetAllOrderBookParticipations( ctx sdk.Context, ) (list []types.OrderBookParticipation, err error) { store := k.getParticipationStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/orderbook/keeper/participation_bet.go b/x/legacy/orderbook/keeper/participation_bet.go similarity index 84% rename from x/orderbook/keeper/participation_bet.go rename to x/legacy/orderbook/keeper/participation_bet.go index 5943ad76..93efbc67 100644 --- a/x/orderbook/keeper/participation_bet.go +++ b/x/legacy/orderbook/keeper/participation_bet.go @@ -1,9 +1,10 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // SetParticipationBetPair sets a participation bet pair. @@ -20,7 +21,7 @@ func (k Keeper) GetAllParticipationBetPair( ctx sdk.Context, ) (list []types.ParticipationBetPair, err error) { store := k.getParticipationBetPairStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/orderbook/keeper/stats.go b/x/legacy/orderbook/keeper/stats.go similarity index 97% rename from x/orderbook/keeper/stats.go rename to x/legacy/orderbook/keeper/stats.go index 1ac5f3ec..e424e0da 100644 --- a/x/orderbook/keeper/stats.go +++ b/x/legacy/orderbook/keeper/stats.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // SetOrderBookStats sets bet statistics in the store diff --git a/x/orderbook/keeper/view.go b/x/legacy/orderbook/keeper/view.go similarity index 95% rename from x/orderbook/keeper/view.go rename to x/legacy/orderbook/keeper/view.go index 95c6ae82..ad4a21ec 100644 --- a/x/orderbook/keeper/view.go +++ b/x/legacy/orderbook/keeper/view.go @@ -1,10 +1,10 @@ package keeper import ( - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // getOrderBookStore gets the store containing all order books. diff --git a/x/orderbook/module.go b/x/legacy/orderbook/module.go similarity index 87% rename from x/orderbook/module.go rename to x/legacy/orderbook/module.go index a0d48cd0..776b4891 100644 --- a/x/orderbook/module.go +++ b/x/legacy/orderbook/module.go @@ -16,9 +16,9 @@ import ( "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" - "github.com/sge-network/sge/x/orderbook/client/cli" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/client/cli" + "github.com/sge-network/sge/x/legacy/orderbook/keeper" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // ---------------------------------------------------------------------------- @@ -92,13 +92,19 @@ type AppModule struct { } // NewAppModule creates a new AppModule object -func NewAppModule(cdc codec.Codec, keeper keeper.Keeper) AppModule { - return AppModule{ +func NewAppModule(cdc codec.Codec, keeper keeper.Keeper) *AppModule { + return &AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, } } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} + +// IsOnePerModuleType is a marker function just indicates that this is a one-per-module type. +func (am AppModule) IsOnePerModuleType() {} + // RegisterInvariants registers the orderbook module invariants. func (AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} @@ -138,13 +144,12 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock executes all ABCI BeginBlock logic respective to the module. -func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} +func (AppModule) BeginBlock(_ sdk.Context) {} // EndBlock executes all ABCI EndBlock logic respective to the module. It // returns no validator updates. -func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { - // end blocker deprecated in favor of v2 - // EndBlocker(ctx, am.keeper) +func (am AppModule) EndBlock(ctx sdk.Context) []abci.ValidatorUpdate { + EndBlocker(ctx, am.keeper) return []abci.ValidatorUpdate{} } diff --git a/x/orderbook/module_simulation.go b/x/legacy/orderbook/module_simulation.go similarity index 82% rename from x/orderbook/module_simulation.go rename to x/legacy/orderbook/module_simulation.go index 0089e5ee..61d49fa9 100644 --- a/x/orderbook/module_simulation.go +++ b/x/legacy/orderbook/module_simulation.go @@ -6,14 +6,13 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/sge-network/sge/testutil/sample" - orderbooksimulation "github.com/sge-network/sge/x/orderbook/simulation" - "github.com/sge-network/sge/x/orderbook/types" + orderbooksimulation "github.com/sge-network/sge/x/legacy/orderbook/simulation" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // avoid unused import issue @@ -42,7 +41,7 @@ func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedP } // RegisterStoreDecoder registers a decoder -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { sdr[types.StoreKey] = orderbooksimulation.NewDecodeStore(am.cdc) } @@ -51,7 +50,7 @@ func (AppModule) WeightedOperations(simState module.SimulationState) []simtypes. operations := make([]simtypes.WeightedOperation, 0) var weightMsgAdd int - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgAdd, &weightMsgAdd, nil, + simState.AppParams.GetOrGenerate(opWeightMsgAdd, &weightMsgAdd, nil, func(_ *rand.Rand) { weightMsgAdd = defaultWeightMsgAdd }, diff --git a/x/orderbook/simulation/decoder.go b/x/legacy/orderbook/simulation/decoder.go similarity index 97% rename from x/orderbook/simulation/decoder.go rename to x/legacy/orderbook/simulation/decoder.go index b17332b7..c28dea90 100644 --- a/x/orderbook/simulation/decoder.go +++ b/x/legacy/orderbook/simulation/decoder.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // NewDecodeStore returns a decoder function closure that unmarshal the KVPair's diff --git a/x/orderbook/simulation/errors.go b/x/legacy/orderbook/simulation/errors.go similarity index 100% rename from x/orderbook/simulation/errors.go rename to x/legacy/orderbook/simulation/errors.go diff --git a/x/orderbook/simulation/genesis.go b/x/legacy/orderbook/simulation/genesis.go similarity index 84% rename from x/orderbook/simulation/genesis.go rename to x/legacy/orderbook/simulation/genesis.go index 7dc6a0b3..af99a4a8 100644 --- a/x/orderbook/simulation/genesis.go +++ b/x/legacy/orderbook/simulation/genesis.go @@ -11,7 +11,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // Simulation parameter constants @@ -40,19 +40,19 @@ func GenRequeueThreshold(r *rand.Rand) uint64 { func RandomizedGenState(simState *module.SimulationState) { var batchSettlementCount uint64 simState.AppParams.GetOrGenerate( - simState.Cdc, BatchSettlementCount, &batchSettlementCount, simState.Rand, + BatchSettlementCount, &batchSettlementCount, simState.Rand, func(r *rand.Rand) { batchSettlementCount = GenBatchSettlementCount(r) }, ) var maxOrderBookParticipations uint64 simState.AppParams.GetOrGenerate( - simState.Cdc, MaxOrderBookParticipations, &maxOrderBookParticipations, simState.Rand, + MaxOrderBookParticipations, &maxOrderBookParticipations, simState.Rand, func(r *rand.Rand) { maxOrderBookParticipations = GenMaxOrderBookParticipations(r) }, ) var requeueThreshold uint64 simState.AppParams.GetOrGenerate( - simState.Cdc, RequeueThreshold, &requeueThreshold, simState.Rand, + RequeueThreshold, &requeueThreshold, simState.Rand, func(r *rand.Rand) { requeueThreshold = GenRequeueThreshold(r) }, ) diff --git a/x/orderbook/simulation/params.go b/x/legacy/orderbook/simulation/params.go similarity index 95% rename from x/orderbook/simulation/params.go rename to x/legacy/orderbook/simulation/params.go index 3b4fa5ff..37f09ea2 100644 --- a/x/orderbook/simulation/params.go +++ b/x/legacy/orderbook/simulation/params.go @@ -10,7 +10,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) const ( diff --git a/x/orderbook/simulation/proposals.go b/x/legacy/orderbook/simulation/proposals.go similarity index 95% rename from x/orderbook/simulation/proposals.go rename to x/legacy/orderbook/simulation/proposals.go index c3ab31d6..3cca4974 100644 --- a/x/orderbook/simulation/proposals.go +++ b/x/legacy/orderbook/simulation/proposals.go @@ -9,7 +9,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/spf13/cast" - "github.com/sge-network/sge/x/orderbook/types" + "github.com/sge-network/sge/x/legacy/orderbook/types" ) // Simulation operation weights constants diff --git a/x/mint/simulation/simap.go b/x/legacy/orderbook/simulation/simap.go similarity index 100% rename from x/mint/simulation/simap.go rename to x/legacy/orderbook/simulation/simap.go diff --git a/x/orderbook/types/codec.go b/x/legacy/orderbook/types/codec.go similarity index 100% rename from x/orderbook/types/codec.go rename to x/legacy/orderbook/types/codec.go diff --git a/x/orderbook/types/consts.go b/x/legacy/orderbook/types/consts.go similarity index 100% rename from x/orderbook/types/consts.go rename to x/legacy/orderbook/types/consts.go diff --git a/x/orderbook/types/errors.go b/x/legacy/orderbook/types/errors.go similarity index 100% rename from x/orderbook/types/errors.go rename to x/legacy/orderbook/types/errors.go diff --git a/x/orderbook/types/events.go b/x/legacy/orderbook/types/events.go similarity index 100% rename from x/orderbook/types/events.go rename to x/legacy/orderbook/types/events.go diff --git a/x/orderbook/types/expected_keepers.go b/x/legacy/orderbook/types/expected_keepers.go similarity index 79% rename from x/orderbook/types/expected_keepers.go rename to x/legacy/orderbook/types/expected_keepers.go index 0def41cf..ed0a9ca6 100644 --- a/x/orderbook/types/expected_keepers.go +++ b/x/legacy/orderbook/types/expected_keepers.go @@ -4,12 +4,12 @@ import ( context "context" sdkmath "cosmossdk.io/math" + sdkfeegrant "cosmossdk.io/x/feegrant" sdk "github.com/cosmos/cosmos-sdk/types" - sdkfeegrant "github.com/cosmos/cosmos-sdk/x/feegrant" - bettypes "github.com/sge-network/sge/x/bet/types" - housetypes "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" + housetypes "github.com/sge-network/sge/x/legacy/house/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" ) // AccountKeeper defines the expected account keeper methods. @@ -19,21 +19,21 @@ type AccountKeeper interface { // BankKeeper defines the expected bank keeper methods. type BankKeeper interface { - SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins + SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins SendCoinsFromAccountToModule( - ctx sdk.Context, + ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins, ) error - GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin + GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin SendCoinsFromModuleToModule( - ctx sdk.Context, + ctx context.Context, senderModule, recipientModule string, amt sdk.Coins, ) error SendCoinsFromModuleToAccount( - ctx sdk.Context, + ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins, @@ -67,11 +67,11 @@ type OVMKeeper interface { // FeeGrantKeeper defines the expected interface needed for the fee grant. type FeeGrantKeeper interface { GrantAllowance( - ctx sdk.Context, + ctx context.Context, granter, grantee sdk.AccAddress, feeAllowance sdkfeegrant.FeeAllowanceI, ) error - GetAllowance(ctx sdk.Context, granter, grantee sdk.AccAddress) (sdkfeegrant.FeeAllowanceI, error) + GetAllowance(ctx context.Context, granter, grantee sdk.AccAddress) (sdkfeegrant.FeeAllowanceI, error) } // Event Hooks diff --git a/x/orderbook/types/exposure.go b/x/legacy/orderbook/types/exposure.go similarity index 100% rename from x/orderbook/types/exposure.go rename to x/legacy/orderbook/types/exposure.go diff --git a/x/orderbook/types/exposure.pb.go b/x/legacy/orderbook/types/exposure.pb.go similarity index 85% rename from x/orderbook/types/exposure.pb.go rename to x/legacy/orderbook/types/exposure.pb.go index 938e8b4a..4fdcb690 100644 --- a/x/orderbook/types/exposure.pb.go +++ b/x/legacy/orderbook/types/exposure.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/exposure.proto +// source: sge/legacy/orderbook/v1beta/exposure.proto package types @@ -39,7 +39,7 @@ type OrderBookOddsExposure struct { func (m *OrderBookOddsExposure) Reset() { *m = OrderBookOddsExposure{} } func (*OrderBookOddsExposure) ProtoMessage() {} func (*OrderBookOddsExposure) Descriptor() ([]byte, []int) { - return fileDescriptor_59a6191091f0874f, []int{0} + return fileDescriptor_87d0a6eb50df3146, []int{0} } func (m *OrderBookOddsExposure) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -92,7 +92,7 @@ type ParticipationExposure struct { func (m *ParticipationExposure) Reset() { *m = ParticipationExposure{} } func (*ParticipationExposure) ProtoMessage() {} func (*ParticipationExposure) Descriptor() ([]byte, []int) { - return fileDescriptor_59a6191091f0874f, []int{1} + return fileDescriptor_87d0a6eb50df3146, []int{1} } func (m *ParticipationExposure) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -122,47 +122,48 @@ func (m *ParticipationExposure) XXX_DiscardUnknown() { var xxx_messageInfo_ParticipationExposure proto.InternalMessageInfo func init() { - proto.RegisterType((*OrderBookOddsExposure)(nil), "sgenetwork.sge.orderbook.OrderBookOddsExposure") - proto.RegisterType((*ParticipationExposure)(nil), "sgenetwork.sge.orderbook.ParticipationExposure") + proto.RegisterType((*OrderBookOddsExposure)(nil), "sge.legacy.orderbook.v1beta.OrderBookOddsExposure") + proto.RegisterType((*ParticipationExposure)(nil), "sge.legacy.orderbook.v1beta.ParticipationExposure") } func init() { - proto.RegisterFile("sgenetwork/sge/orderbook/exposure.proto", fileDescriptor_59a6191091f0874f) + proto.RegisterFile("sge/legacy/orderbook/v1beta/exposure.proto", fileDescriptor_87d0a6eb50df3146) } -var fileDescriptor_59a6191091f0874f = []byte{ - // 491 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x93, 0xb1, 0x6f, 0xd3, 0x40, - 0x14, 0xc6, 0x6d, 0x92, 0xb6, 0xe9, 0x11, 0x41, 0xeb, 0x12, 0xd5, 0xaa, 0x90, 0x2f, 0xba, 0x01, - 0x32, 0x80, 0x83, 0xe8, 0x96, 0x0d, 0x0b, 0x2a, 0x05, 0x21, 0x85, 0x5a, 0x62, 0x61, 0xb1, 0xec, - 0xdc, 0xd5, 0x3d, 0x25, 0xf6, 0x19, 0xdf, 0x59, 0xa4, 0xff, 0x01, 0x23, 0x23, 0x63, 0xfe, 0x9c, - 0x8e, 0x1d, 0x11, 0xc3, 0x09, 0x39, 0x0b, 0x62, 0xc3, 0x33, 0x03, 0xf2, 0xb9, 0x71, 0xdd, 0x82, - 0xc4, 0xda, 0xed, 0xdd, 0xf7, 0xbe, 0xef, 0x77, 0x77, 0x3e, 0x3f, 0xf0, 0x98, 0x87, 0x24, 0x26, - 0xe2, 0x23, 0x4b, 0x67, 0x43, 0x1e, 0x92, 0x21, 0x4b, 0x31, 0x49, 0x03, 0xc6, 0x66, 0x43, 0xb2, - 0x48, 0x18, 0xcf, 0x52, 0x62, 0x27, 0x29, 0x13, 0xcc, 0x30, 0xaf, 0x8c, 0x36, 0x0f, 0x89, 0x5d, - 0x1b, 0x0f, 0x1e, 0x84, 0x2c, 0x64, 0xca, 0x34, 0x2c, 0xab, 0xca, 0x8f, 0x7e, 0xe9, 0xa0, 0x37, - 0x29, 0x3d, 0x0e, 0x63, 0xb3, 0x09, 0xc6, 0xfc, 0xd5, 0x25, 0xcf, 0x78, 0x0d, 0xee, 0xa9, 0xb0, - 0x57, 0xa6, 0xbd, 0x8c, 0x62, 0x53, 0xef, 0xeb, 0x83, 0x6d, 0x07, 0xe5, 0x12, 0x76, 0xeb, 0xc8, - 0xbb, 0xf1, 0xcb, 0x9f, 0x12, 0xde, 0x70, 0xba, 0x37, 0xd6, 0xc6, 0x21, 0xe8, 0x30, 0x8c, 0xb9, - 0xa2, 0xdc, 0x51, 0x94, 0xfd, 0x5c, 0xc2, 0xad, 0x72, 0xbf, 0x0a, 0x50, 0xb7, 0xdd, 0xba, 0x32, - 0xc6, 0x60, 0xf7, 0x24, 0x9b, 0x9f, 0xd0, 0xf9, 0x3c, 0x22, 0xb1, 0xf0, 0x3e, 0x64, 0x24, 0x23, - 0x66, 0xab, 0xdf, 0x1a, 0xb4, 0x9d, 0x87, 0x85, 0x84, 0xe6, 0x99, 0x1f, 0xcd, 0x47, 0xe8, 0x2f, - 0x0b, 0x72, 0x77, 0x1a, 0xda, 0x71, 0x29, 0x8d, 0xba, 0x9f, 0x96, 0x50, 0xfb, 0xb2, 0x84, 0xda, - 0x8f, 0x25, 0xd4, 0xd0, 0xef, 0x16, 0xe8, 0xbd, 0xf5, 0x53, 0x41, 0xa7, 0x34, 0xf1, 0x05, 0x65, - 0xf1, 0xed, 0xb9, 0xf3, 0x04, 0xec, 0x25, 0xcd, 0x93, 0x79, 0x34, 0xc6, 0x64, 0x61, 0xb6, 0xfa, - 0xfa, 0xa0, 0xed, 0x58, 0x85, 0x84, 0x07, 0xd5, 0xad, 0xff, 0x61, 0x42, 0xae, 0x71, 0x4d, 0x1d, - 0x97, 0xa2, 0xf1, 0x06, 0x74, 0xd6, 0x7f, 0x88, 0xd9, 0x56, 0xa7, 0x78, 0x76, 0x2e, 0xa1, 0xf6, - 0x4d, 0xc2, 0xde, 0x94, 0xf1, 0x88, 0x71, 0x8e, 0x67, 0x36, 0x65, 0xc3, 0xc8, 0x17, 0xa7, 0xf6, - 0x38, 0x16, 0x85, 0x84, 0xf7, 0xab, 0x2d, 0xd6, 0x31, 0xe4, 0xd6, 0x04, 0xe3, 0x18, 0x80, 0x80, - 0x08, 0xcf, 0x8f, 0x58, 0x16, 0x0b, 0x73, 0x43, 0xf1, 0x9e, 0xff, 0x8f, 0xb7, 0x5b, 0xf1, 0xae, - 0x82, 0xc8, 0xdd, 0x0e, 0x88, 0x78, 0xa1, 0x6a, 0x63, 0x04, 0xba, 0x94, 0x7b, 0x97, 0x2f, 0x46, - 0xb0, 0xb9, 0xd9, 0xd7, 0x07, 0x1d, 0x67, 0xbf, 0x90, 0x70, 0xaf, 0xca, 0x35, 0xbb, 0xc8, 0xbd, - 0x4b, 0xf9, 0xd1, 0x7a, 0x65, 0x3c, 0x02, 0x1b, 0x29, 0xcb, 0x62, 0x6c, 0x6e, 0xa9, 0xef, 0xb3, - 0x53, 0x48, 0xd8, 0xad, 0x42, 0x4a, 0x46, 0x6e, 0xd5, 0xbe, 0xfe, 0xfc, 0xce, 0xd1, 0x79, 0x6e, - 0xe9, 0x17, 0xb9, 0xa5, 0x7f, 0xcf, 0x2d, 0xfd, 0xf3, 0xca, 0xd2, 0x2e, 0x56, 0x96, 0xf6, 0x75, - 0x65, 0x69, 0xef, 0x9f, 0x84, 0x54, 0x9c, 0x66, 0x81, 0x3d, 0x65, 0x51, 0x39, 0x65, 0x4f, 0x9b, - 0x13, 0xb7, 0x68, 0xcc, 0x9c, 0x38, 0x4b, 0x08, 0x0f, 0x36, 0xd5, 0x04, 0x1d, 0xfe, 0x09, 0x00, - 0x00, 0xff, 0xff, 0x9e, 0xb9, 0x7d, 0xe4, 0x9c, 0x03, 0x00, 0x00, +var fileDescriptor_87d0a6eb50df3146 = []byte{ + // 504 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x93, 0x31, 0x6f, 0xd3, 0x4e, + 0x18, 0xc6, 0xed, 0x7f, 0xd2, 0x36, 0xbd, 0x7f, 0x04, 0xad, 0x4b, 0x54, 0xab, 0x20, 0x5f, 0x74, + 0x03, 0x8a, 0x90, 0xb0, 0x81, 0x6c, 0xd9, 0xb0, 0x00, 0x29, 0x08, 0x14, 0x6a, 0x89, 0x85, 0xc5, + 0xb2, 0x73, 0x57, 0xf7, 0x94, 0xd8, 0x17, 0x7c, 0x67, 0x48, 0xbe, 0x01, 0x23, 0x23, 0x63, 0x3e, + 0x4e, 0xc7, 0x8e, 0x88, 0xe1, 0x84, 0x92, 0x05, 0xb1, 0x91, 0x99, 0x01, 0xf9, 0xae, 0x31, 0x69, + 0x8b, 0xc4, 0xca, 0xf6, 0xde, 0xf3, 0x3e, 0xcf, 0xef, 0xee, 0x7c, 0x7e, 0xc1, 0x3d, 0x9e, 0x10, + 0x6f, 0x4c, 0x92, 0x68, 0x38, 0xf3, 0x58, 0x8e, 0x49, 0x1e, 0x33, 0x36, 0xf2, 0xde, 0x3d, 0x8c, + 0x89, 0x88, 0x3c, 0x32, 0x9d, 0x30, 0x5e, 0xe4, 0xc4, 0x9d, 0xe4, 0x4c, 0x30, 0xeb, 0x36, 0x4f, + 0x88, 0xab, 0xbd, 0x6e, 0xe5, 0x75, 0xb5, 0xf7, 0xe8, 0x56, 0xc2, 0x12, 0xa6, 0x7c, 0x5e, 0x59, + 0xe9, 0x08, 0xfa, 0x61, 0x82, 0xd6, 0xa0, 0xb4, 0xfa, 0x8c, 0x8d, 0x06, 0x18, 0xf3, 0xa7, 0x17, + 0x48, 0xeb, 0x39, 0xb8, 0xa1, 0x18, 0x61, 0x09, 0x09, 0x0b, 0x8a, 0x6d, 0xb3, 0x6d, 0x76, 0x76, + 0x7d, 0xb4, 0x90, 0xb0, 0x59, 0x45, 0x5e, 0xf7, 0x9f, 0x7c, 0x97, 0xf0, 0x8a, 0x33, 0xb8, 0xb2, + 0xb6, 0xba, 0xa0, 0xc1, 0x30, 0xe6, 0x8a, 0xf2, 0x9f, 0xa2, 0x1c, 0x2e, 0x24, 0xdc, 0x29, 0xf7, + 0xd3, 0x80, 0xaa, 0x1d, 0x54, 0x95, 0xd5, 0x07, 0xfb, 0x27, 0xc5, 0xf8, 0x84, 0x8e, 0xc7, 0x29, + 0xc9, 0x44, 0xf8, 0xb6, 0x20, 0x05, 0xb1, 0x6b, 0xed, 0x5a, 0xa7, 0xee, 0xdf, 0x59, 0x49, 0x68, + 0xcf, 0xa2, 0x74, 0xdc, 0x43, 0xd7, 0x2c, 0x28, 0xd8, 0xdb, 0xd0, 0x8e, 0x4b, 0xa9, 0xd7, 0xfc, + 0x30, 0x87, 0xc6, 0xa7, 0x39, 0x34, 0xbe, 0xcd, 0xa1, 0x81, 0x7e, 0xd6, 0x40, 0xeb, 0x55, 0x94, + 0x0b, 0x3a, 0xa4, 0x93, 0x48, 0x50, 0x96, 0xfd, 0x3b, 0x77, 0x1e, 0x80, 0x83, 0xc9, 0xe6, 0xc9, + 0x42, 0x9a, 0x61, 0x32, 0xb5, 0x6b, 0x6d, 0xb3, 0x53, 0xf7, 0x9d, 0x95, 0x84, 0x47, 0xfa, 0xd6, + 0x7f, 0x30, 0xa1, 0xc0, 0xba, 0xa4, 0xf6, 0x4b, 0xd1, 0x7a, 0x01, 0x1a, 0xeb, 0x9f, 0xc4, 0xae, + 0xab, 0x53, 0x3c, 0x38, 0x93, 0xd0, 0xf8, 0x22, 0x61, 0x6b, 0xc8, 0x78, 0xca, 0x38, 0xc7, 0x23, + 0x97, 0x32, 0x2f, 0x8d, 0xc4, 0xa9, 0xdb, 0xcf, 0xc4, 0x4a, 0xc2, 0x9b, 0x7a, 0x8b, 0x75, 0x0c, + 0x05, 0x15, 0xc1, 0x3a, 0x06, 0x20, 0x26, 0x22, 0x8c, 0x52, 0x56, 0x64, 0xc2, 0xde, 0x52, 0xbc, + 0x47, 0x7f, 0xe3, 0xed, 0x6b, 0xde, 0xef, 0x20, 0x0a, 0x76, 0x63, 0x22, 0x1e, 0xab, 0xda, 0xea, + 0x81, 0x26, 0xe5, 0xe1, 0xc5, 0x8b, 0x11, 0x6c, 0x6f, 0xb7, 0xcd, 0x4e, 0xc3, 0x3f, 0x5c, 0x49, + 0x78, 0xa0, 0x73, 0x9b, 0x5d, 0x14, 0xfc, 0x4f, 0xf9, 0xb3, 0xf5, 0xca, 0xba, 0x0b, 0xb6, 0x72, + 0x56, 0x64, 0xd8, 0xde, 0x51, 0xdf, 0x67, 0x6f, 0x25, 0x61, 0x53, 0x87, 0x94, 0x8c, 0x02, 0xdd, + 0xbe, 0xfc, 0xfc, 0xfe, 0xcb, 0xb3, 0x85, 0x63, 0x9e, 0x2f, 0x1c, 0xf3, 0xeb, 0xc2, 0x31, 0x3f, + 0x2e, 0x1d, 0xe3, 0x7c, 0xe9, 0x18, 0x9f, 0x97, 0x8e, 0xf1, 0xa6, 0x9b, 0x50, 0x71, 0x5a, 0xc4, + 0xee, 0x90, 0xa5, 0x1e, 0x4f, 0xc8, 0xfd, 0x8c, 0x88, 0xf7, 0x2c, 0x1f, 0x95, 0xb5, 0x37, 0xbd, + 0x3e, 0x84, 0x62, 0x36, 0x21, 0x3c, 0xde, 0x56, 0x83, 0xd4, 0xfd, 0x15, 0x00, 0x00, 0xff, 0xff, + 0x7b, 0x4a, 0xac, 0x42, 0xa9, 0x03, 0x00, 0x00, } func (m *OrderBookOddsExposure) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/types/funder.go b/x/legacy/orderbook/types/funder.go similarity index 100% rename from x/orderbook/types/funder.go rename to x/legacy/orderbook/types/funder.go diff --git a/x/orderbook/types/genesis.go b/x/legacy/orderbook/types/genesis.go similarity index 100% rename from x/orderbook/types/genesis.go rename to x/legacy/orderbook/types/genesis.go diff --git a/x/orderbook/types/genesis.pb.go b/x/legacy/orderbook/types/genesis.pb.go similarity index 86% rename from x/orderbook/types/genesis.pb.go rename to x/legacy/orderbook/types/genesis.pb.go index 7c5dfe68..6ef24a91 100644 --- a/x/orderbook/types/genesis.pb.go +++ b/x/legacy/orderbook/types/genesis.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/genesis.proto +// source: sge/legacy/orderbook/v1beta/genesis.proto package types @@ -55,7 +55,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_4a689324a065c0a7, []int{0} + return fileDescriptor_4b711a4d3f2602e1, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -148,45 +148,46 @@ func (m *GenesisState) GetStats() OrderBookStats { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.orderbook.GenesisState") + proto.RegisterType((*GenesisState)(nil), "sge.legacy.orderbook.v1beta.GenesisState") } func init() { - proto.RegisterFile("sgenetwork/sge/orderbook/genesis.proto", fileDescriptor_4a689324a065c0a7) + proto.RegisterFile("sge/legacy/orderbook/v1beta/genesis.proto", fileDescriptor_4b711a4d3f2602e1) } -var fileDescriptor_4a689324a065c0a7 = []byte{ - // 475 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x94, 0xcf, 0x6b, 0xd4, 0x40, - 0x14, 0xc7, 0x37, 0xb6, 0xdd, 0xea, 0x54, 0x11, 0x16, 0x85, 0xb8, 0x62, 0x0c, 0xb6, 0xd6, 0x1c, - 0x6a, 0x22, 0xf5, 0xee, 0x21, 0xf8, 0x03, 0x41, 0x68, 0xd4, 0x9b, 0x97, 0x30, 0xd9, 0x0c, 0xe9, - 0xb0, 0x6d, 0x5e, 0x98, 0x99, 0xc5, 0xcd, 0x5d, 0x2f, 0x9e, 0xfc, 0xb3, 0x7a, 0xec, 0xd1, 0x93, - 0xc8, 0x2e, 0xfe, 0x1f, 0x92, 0x99, 0xc9, 0x36, 0xa9, 0x99, 0x36, 0xb0, 0xb7, 0x21, 0xf3, 0x7d, - 0xef, 0xf3, 0x9d, 0x2f, 0x79, 0x0f, 0xed, 0xf3, 0x8c, 0xe4, 0x44, 0x7c, 0x05, 0x36, 0x0d, 0x78, - 0x46, 0x02, 0x60, 0x29, 0x61, 0x09, 0xc0, 0x34, 0xa8, 0xbe, 0x73, 0xca, 0xfd, 0x82, 0x81, 0x80, - 0x91, 0x7d, 0xa1, 0xf3, 0x79, 0x46, 0xfc, 0x95, 0x6e, 0x7c, 0x2f, 0x83, 0x0c, 0xa4, 0x28, 0xa8, - 0x4e, 0x4a, 0x3f, 0x7e, 0x6a, 0xec, 0x5b, 0x60, 0x86, 0x4f, 0x75, 0xdb, 0xb1, 0x67, 0x94, 0xad, - 0x4e, 0x5a, 0x79, 0x70, 0x55, 0x43, 0x41, 0x27, 0xb4, 0xc0, 0x82, 0x42, 0xae, 0xd5, 0x7b, 0x46, - 0x35, 0x17, 0x58, 0xd4, 0xf4, 0x67, 0x46, 0x15, 0x99, 0x17, 0xc0, 0x67, 0x8c, 0x28, 0xe1, 0x93, - 0xbf, 0xdb, 0xe8, 0xf6, 0x3b, 0x95, 0xc7, 0x67, 0x81, 0x05, 0x19, 0xbd, 0x42, 0x43, 0xf5, 0x0e, - 0xdb, 0x72, 0x2d, 0x6f, 0xe7, 0xd0, 0xf5, 0x4d, 0xf9, 0xf8, 0x91, 0xd4, 0x85, 0x9b, 0x67, 0xbf, - 0x1f, 0x0f, 0x3e, 0xe9, 0xaa, 0xd1, 0x47, 0x74, 0x57, 0x2a, 0xe2, 0x4a, 0x12, 0x9f, 0x50, 0x2e, - 0xec, 0x1b, 0xee, 0x86, 0xb7, 0x73, 0xb8, 0x6b, 0x6e, 0x74, 0x54, 0x9d, 0x42, 0x80, 0xa9, 0xee, - 0x75, 0x07, 0xea, 0x0f, 0x1f, 0x28, 0x17, 0xa3, 0x12, 0x3d, 0x6a, 0xb4, 0x6c, 0x85, 0xa2, 0x00, - 0x1b, 0x12, 0xf0, 0xa2, 0x07, 0x20, 0x6a, 0x16, 0x6b, 0xda, 0x18, 0x3a, 0x6f, 0x25, 0x3a, 0x47, - 0x76, 0x03, 0x5d, 0x67, 0xa7, 0xa8, 0x9b, 0x92, 0x1a, 0xf4, 0xa0, 0x1e, 0xa5, 0x29, 0x7f, 0xa3, - 0x6b, 0x35, 0xf4, 0xfe, 0x0a, 0x5a, 0x5f, 0x48, 0xde, 0x0c, 0x3d, 0x6c, 0xbf, 0xaf, 0x8d, 0xdc, - 0xba, 0x0e, 0xd9, 0x7a, 0xc1, 0x25, 0xe4, 0x83, 0xa2, 0xeb, 0x52, 0x62, 0xbf, 0x5b, 0x68, 0xcf, - 0xc0, 0x4d, 0xca, 0x98, 0xe6, 0x29, 0x99, 0x2b, 0x03, 0xc3, 0x75, 0x0c, 0xb8, 0x9d, 0x06, 0xc2, - 0xf2, 0x7d, 0xd5, 0x5f, 0xfa, 0xf8, 0x61, 0xa1, 0xfd, 0x63, 0xca, 0x05, 0x30, 0x3a, 0xc1, 0x27, - 0xf1, 0x55, 0x51, 0x6c, 0xaf, 0xe3, 0x64, 0xf7, 0x02, 0x12, 0x19, 0x43, 0xf9, 0xf6, 0x5f, 0x28, - 0x09, 0x11, 0x71, 0x81, 0x29, 0xbb, 0x64, 0xe5, 0xa6, 0xb4, 0xe2, 0xf7, 0xb4, 0x12, 0x12, 0x11, - 0x61, 0xca, 0x3a, 0x33, 0xd1, 0x77, 0x2d, 0x1b, 0xaf, 0xd1, 0x96, 0x9c, 0x6c, 0xfb, 0x96, 0x9c, - 0x47, 0xaf, 0xc7, 0xff, 0x56, 0x4d, 0x72, 0x3d, 0x97, 0xaa, 0x38, 0x7c, 0x7b, 0xb6, 0x70, 0xac, - 0xf3, 0x85, 0x63, 0xfd, 0x59, 0x38, 0xd6, 0xcf, 0xa5, 0x33, 0x38, 0x5f, 0x3a, 0x83, 0x5f, 0x4b, - 0x67, 0xf0, 0xe5, 0x20, 0xa3, 0xe2, 0x78, 0x96, 0xf8, 0x13, 0x38, 0xad, 0x56, 0xc5, 0xf3, 0xe6, - 0xda, 0x98, 0x37, 0x16, 0x87, 0x28, 0x0b, 0xc2, 0x93, 0xa1, 0x5c, 0x1b, 0x2f, 0xff, 0x05, 0x00, - 0x00, 0xff, 0xff, 0x7b, 0x59, 0x46, 0x26, 0x5e, 0x05, 0x00, 0x00, +var fileDescriptor_4b711a4d3f2602e1 = []byte{ + // 490 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x94, 0x41, 0x6b, 0xd4, 0x40, + 0x14, 0xc7, 0x37, 0xb6, 0x5d, 0xeb, 0x54, 0x11, 0x16, 0x85, 0x75, 0x8b, 0x71, 0xb1, 0x52, 0x57, + 0x8b, 0x09, 0xdd, 0xfd, 0x04, 0x06, 0xa4, 0x08, 0x4a, 0x17, 0xf5, 0xe4, 0x25, 0x4c, 0x36, 0x43, + 0x3a, 0xec, 0x36, 0x2f, 0xce, 0xbc, 0x6a, 0x02, 0x1e, 0xbc, 0xe9, 0x45, 0xf0, 0x63, 0xf5, 0xd8, + 0xa3, 0x27, 0x91, 0xdd, 0x2f, 0x22, 0x99, 0x99, 0xb4, 0x9b, 0x36, 0x8d, 0x81, 0xbd, 0x2d, 0x33, + 0xff, 0xff, 0xfb, 0xfd, 0xe7, 0x6d, 0xde, 0x23, 0xcf, 0x64, 0xc4, 0xdc, 0x19, 0x8b, 0xe8, 0x24, + 0x73, 0x41, 0x84, 0x4c, 0x04, 0x00, 0x53, 0xf7, 0xf3, 0x7e, 0xc0, 0x90, 0xba, 0x11, 0x8b, 0x99, + 0xe4, 0xd2, 0x49, 0x04, 0x20, 0x74, 0xb6, 0x65, 0xc4, 0x1c, 0x2d, 0x75, 0xce, 0xa5, 0x8e, 0x96, + 0xf6, 0xee, 0x45, 0x10, 0x81, 0xd2, 0xb9, 0xf9, 0x2f, 0x6d, 0xe9, 0x3d, 0xaf, 0xab, 0xce, 0xd2, + 0x04, 0xe4, 0x89, 0x60, 0x46, 0xbb, 0x57, 0xa7, 0xbd, 0xe0, 0x69, 0xf1, 0xa0, 0x4e, 0x9c, 0x50, + 0x41, 0x8f, 0x4d, 0xea, 0x9e, 0xfb, 0x1f, 0x25, 0xf2, 0x09, 0x4f, 0x28, 0x72, 0x88, 0x8d, 0xe1, + 0x69, 0x9d, 0x41, 0x22, 0x45, 0x53, 0xf9, 0xf1, 0xb7, 0x4d, 0x72, 0xfb, 0x40, 0x77, 0xe8, 0x3d, + 0x52, 0x64, 0x9d, 0x97, 0xa4, 0xad, 0xd1, 0x5d, 0xab, 0x6f, 0x0d, 0xb6, 0x86, 0x3b, 0x4e, 0x4d, + 0xc7, 0x9c, 0xb1, 0x92, 0x7a, 0xeb, 0xa7, 0x7f, 0x1e, 0xb5, 0xde, 0x19, 0x63, 0xe7, 0x03, 0xb9, + 0xab, 0x84, 0x7e, 0xae, 0xf4, 0x67, 0x5c, 0x62, 0xf7, 0x46, 0x7f, 0x6d, 0xb0, 0x35, 0xdc, 0xad, + 0xad, 0x75, 0x98, 0x1f, 0x78, 0x00, 0x53, 0x53, 0xee, 0x0e, 0x14, 0x07, 0x6f, 0xb8, 0xc4, 0xce, + 0x57, 0xf2, 0x70, 0xa9, 0x6a, 0xe9, 0xd1, 0x9a, 0xb1, 0xa6, 0x18, 0xa3, 0x66, 0x8c, 0xf1, 0xb2, + 0xdf, 0x00, 0x7b, 0x50, 0x79, 0xab, 0xe8, 0x9f, 0x48, 0x77, 0x89, 0x5e, 0xfc, 0xeb, 0x1a, 0xbc, + 0xae, 0xc0, 0xc3, 0x66, 0xe0, 0xc3, 0x30, 0x94, 0xaf, 0x8c, 0xdd, 0x70, 0xef, 0x9f, 0x73, 0x8b, + 0x0b, 0x85, 0x4c, 0xc9, 0x76, 0xf9, 0x95, 0x65, 0xea, 0x46, 0x03, 0x6a, 0xe9, 0x1d, 0x97, 0xa8, + 0x0f, 0x92, 0xaa, 0x4b, 0x45, 0xfe, 0x61, 0x91, 0x27, 0xd7, 0xa0, 0x83, 0xcc, 0xe7, 0x71, 0xc8, + 0x52, 0x9d, 0xa1, 0xbd, 0x62, 0x86, 0x7e, 0x65, 0x06, 0x2f, 0x7b, 0x9d, 0x23, 0x54, 0x94, 0x9f, + 0x16, 0xd9, 0x3d, 0xe2, 0x12, 0x41, 0xf0, 0x09, 0x9d, 0xf9, 0x75, 0x0d, 0xb9, 0xb9, 0x62, 0x98, + 0x9d, 0x0b, 0xce, 0xf8, 0xda, 0xd6, 0x7c, 0xbf, 0xd2, 0x9a, 0x80, 0xa1, 0x9f, 0x50, 0x2e, 0x2e, + 0xa5, 0xd9, 0x54, 0x69, 0xf6, 0x9b, 0xa7, 0xf1, 0x18, 0x8e, 0x29, 0x17, 0x95, 0x9d, 0x31, 0x77, + 0xa5, 0x24, 0x07, 0x64, 0x43, 0x0d, 0x72, 0xf7, 0x96, 0x9a, 0xd3, 0xbd, 0x66, 0x9f, 0x5f, 0x3e, + 0xe4, 0xc5, 0xbc, 0x6a, 0xbf, 0xf7, 0xf6, 0x74, 0x6e, 0x5b, 0x67, 0x73, 0xdb, 0xfa, 0x3b, 0xb7, + 0xad, 0x5f, 0x0b, 0xbb, 0x75, 0xb6, 0xb0, 0x5b, 0xbf, 0x17, 0x76, 0xeb, 0xe3, 0x28, 0xe2, 0x78, + 0x74, 0x12, 0x38, 0x13, 0x38, 0xce, 0x37, 0xd0, 0x8b, 0x98, 0xe1, 0x17, 0x10, 0x53, 0xb5, 0x8d, + 0xd2, 0xab, 0xeb, 0x05, 0xb3, 0x84, 0xc9, 0xa0, 0xad, 0x16, 0xcb, 0xe8, 0x5f, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x09, 0x17, 0xf4, 0xee, 0x95, 0x05, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/types/hooks.go b/x/legacy/orderbook/types/hooks.go similarity index 100% rename from x/orderbook/types/hooks.go rename to x/legacy/orderbook/types/hooks.go diff --git a/x/orderbook/types/keys.go b/x/legacy/orderbook/types/keys.go similarity index 100% rename from x/orderbook/types/keys.go rename to x/legacy/orderbook/types/keys.go diff --git a/x/orderbook/types/messages_params.go b/x/legacy/orderbook/types/messages_params.go similarity index 100% rename from x/orderbook/types/messages_params.go rename to x/legacy/orderbook/types/messages_params.go diff --git a/x/orderbook/types/orderbook.go b/x/legacy/orderbook/types/orderbook.go similarity index 100% rename from x/orderbook/types/orderbook.go rename to x/legacy/orderbook/types/orderbook.go diff --git a/x/orderbook/types/orderbook.pb.go b/x/legacy/orderbook/types/orderbook.pb.go similarity index 76% rename from x/orderbook/types/orderbook.pb.go rename to x/legacy/orderbook/types/orderbook.pb.go index bbdcf716..f9285bf1 100644 --- a/x/orderbook/types/orderbook.pb.go +++ b/x/legacy/orderbook/types/orderbook.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/orderbook.proto +// source: sge/legacy/orderbook/v1beta/orderbook.proto package types @@ -56,7 +56,7 @@ func (x OrderBookStatus) String() string { } func (OrderBookStatus) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_99b9fb43f10754c7, []int{0} + return fileDescriptor_09a2cd9d52504ba0, []int{0} } // OrderBook represents the order book maintained against a market. @@ -68,13 +68,13 @@ type OrderBook struct { // odds_count is the count of the odds in the order book. OddsCount uint64 `protobuf:"varint,3,opt,name=odds_count,json=oddsCount,proto3" json:"odds_count,omitempty" yaml:"odds_count"` // status represents the status of the order book. - Status OrderBookStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sgenetwork.sge.orderbook.OrderBookStatus" json:"status,omitempty"` + Status OrderBookStatus `protobuf:"varint,4,opt,name=status,proto3,enum=sge.legacy.orderbook.v1beta.OrderBookStatus" json:"status,omitempty"` } func (m *OrderBook) Reset() { *m = OrderBook{} } func (*OrderBook) ProtoMessage() {} func (*OrderBook) Descriptor() ([]byte, []int) { - return fileDescriptor_99b9fb43f10754c7, []int{0} + return fileDescriptor_09a2cd9d52504ba0, []int{0} } func (m *OrderBook) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -104,41 +104,42 @@ func (m *OrderBook) XXX_DiscardUnknown() { var xxx_messageInfo_OrderBook proto.InternalMessageInfo func init() { - proto.RegisterEnum("sgenetwork.sge.orderbook.OrderBookStatus", OrderBookStatus_name, OrderBookStatus_value) - proto.RegisterType((*OrderBook)(nil), "sgenetwork.sge.orderbook.OrderBook") + proto.RegisterEnum("sge.legacy.orderbook.v1beta.OrderBookStatus", OrderBookStatus_name, OrderBookStatus_value) + proto.RegisterType((*OrderBook)(nil), "sge.legacy.orderbook.v1beta.OrderBook") } func init() { - proto.RegisterFile("sgenetwork/sge/orderbook/orderbook.proto", fileDescriptor_99b9fb43f10754c7) + proto.RegisterFile("sge/legacy/orderbook/v1beta/orderbook.proto", fileDescriptor_09a2cd9d52504ba0) } -var fileDescriptor_99b9fb43f10754c7 = []byte{ - // 398 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x28, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0x4a, 0x49, 0x2d, - 0x4a, 0xca, 0xcf, 0xcf, 0x46, 0xb0, 0xf4, 0x0a, 0x8a, 0xf2, 0x4b, 0xf2, 0x85, 0x24, 0x10, 0x2a, - 0xf5, 0x8a, 0xd3, 0x53, 0xf5, 0xe0, 0xf2, 0x52, 0x22, 0xe9, 0xf9, 0xe9, 0xf9, 0x60, 0x45, 0xfa, - 0x20, 0x16, 0x44, 0xbd, 0x52, 0x2b, 0x13, 0x17, 0xa7, 0x3f, 0x48, 0x8d, 0x53, 0x7e, 0x7e, 0xb6, - 0x90, 0x02, 0x17, 0x73, 0x69, 0x66, 0x8a, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xa7, 0x13, 0xdf, 0xa3, - 0x7b, 0xf2, 0xcc, 0xa1, 0x9e, 0x2e, 0xaf, 0xee, 0xc9, 0x83, 0x44, 0x83, 0x40, 0x84, 0x90, 0x3f, - 0x97, 0x70, 0x41, 0x62, 0x51, 0x49, 0x66, 0x72, 0x66, 0x41, 0x62, 0x49, 0x66, 0x7e, 0x5e, 0x7c, - 0x72, 0x7e, 0x69, 0x5e, 0x89, 0x04, 0x93, 0x02, 0xa3, 0x06, 0x8b, 0x93, 0xdc, 0xa7, 0x7b, 0xf2, - 0x52, 0x95, 0x89, 0xb9, 0x39, 0x56, 0x4a, 0x58, 0x14, 0x29, 0x05, 0x09, 0xa1, 0x88, 0x3a, 0x83, - 0x04, 0x85, 0x4c, 0xb8, 0xb8, 0xf2, 0x53, 0x52, 0x8a, 0xa1, 0xe6, 0x30, 0x83, 0xcd, 0x11, 0xfd, - 0x74, 0x4f, 0x5e, 0x10, 0x62, 0x0e, 0x42, 0x4e, 0x29, 0x88, 0x13, 0xc4, 0x81, 0xe8, 0x72, 0xe4, - 0x62, 0x2b, 0x2e, 0x49, 0x2c, 0x29, 0x2d, 0x96, 0x60, 0x51, 0x60, 0xd4, 0xe0, 0x33, 0xd2, 0xd4, - 0xc3, 0xe5, 0x6f, 0x3d, 0xb8, 0xef, 0x82, 0xc1, 0x1a, 0x82, 0xa0, 0x1a, 0xad, 0x78, 0x3a, 0x16, - 0xc8, 0x33, 0xcc, 0x58, 0x20, 0xcf, 0xf0, 0x62, 0x81, 0x3c, 0x83, 0xd6, 0x32, 0x46, 0x2e, 0x7e, - 0x34, 0x95, 0x42, 0x8a, 0x5c, 0xb2, 0xfe, 0x41, 0x2e, 0xae, 0x41, 0xf1, 0x4e, 0xfe, 0xfe, 0xde, - 0xf1, 0xc1, 0x21, 0x8e, 0x21, 0xa1, 0xc1, 0xf1, 0xa1, 0x7e, 0xc1, 0x01, 0xae, 0xce, 0x9e, 0x6e, - 0x9e, 0xae, 0x2e, 0x02, 0x0c, 0x42, 0xca, 0x5c, 0xf2, 0x98, 0x4a, 0xa0, 0x94, 0xa3, 0x73, 0x88, - 0x67, 0x98, 0xab, 0x00, 0xa3, 0x90, 0x2a, 0x97, 0x22, 0x4e, 0x45, 0x41, 0xae, 0xc1, 0xfe, 0x3e, - 0x61, 0xae, 0x2e, 0x02, 0x4c, 0x42, 0x2a, 0x5c, 0x0a, 0x38, 0x95, 0x05, 0xbb, 0x86, 0x84, 0xf8, - 0xb8, 0xba, 0x08, 0x30, 0x3b, 0xb9, 0x9d, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, - 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, - 0x94, 0x4e, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0x2e, 0x28, 0x91, 0xe8, 0x22, - 0x27, 0x98, 0x0a, 0xa4, 0x24, 0x53, 0x52, 0x59, 0x90, 0x5a, 0x9c, 0xc4, 0x06, 0x8e, 0x7f, 0x63, - 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0xbb, 0x00, 0x56, 0x95, 0x5b, 0x02, 0x00, 0x00, +var fileDescriptor_09a2cd9d52504ba0 = []byte{ + // 411 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2e, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x2f, 0x4a, 0x49, 0x2d, 0x4a, 0xca, 0xcf, 0xcf, + 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x44, 0x08, 0xe8, 0x15, 0x14, 0xe5, 0x97, 0xe4, 0x0b, + 0x49, 0x17, 0xa7, 0xa7, 0xea, 0x41, 0x14, 0xeb, 0x21, 0xe4, 0x20, 0x8a, 0xa5, 0x44, 0xd2, 0xf3, + 0xd3, 0xf3, 0xc1, 0xea, 0xf4, 0x41, 0x2c, 0x88, 0x16, 0xa5, 0x0e, 0x26, 0x2e, 0x4e, 0x7f, 0x90, + 0x52, 0xa7, 0xfc, 0xfc, 0x6c, 0x21, 0x05, 0x2e, 0xe6, 0xd2, 0xcc, 0x14, 0x09, 0x46, 0x05, 0x46, + 0x0d, 0x4e, 0x27, 0xbe, 0x47, 0xf7, 0xe4, 0x99, 0x43, 0x3d, 0x5d, 0x5e, 0xdd, 0x93, 0x07, 0x89, + 0x06, 0x81, 0x08, 0x21, 0x7f, 0x2e, 0xe1, 0x82, 0xc4, 0xa2, 0x92, 0xcc, 0xe4, 0xcc, 0x82, 0xc4, + 0x92, 0xcc, 0xfc, 0xbc, 0xf8, 0xe4, 0xfc, 0xd2, 0xbc, 0x12, 0x09, 0x26, 0x05, 0x46, 0x0d, 0x16, + 0x27, 0xb9, 0x4f, 0xf7, 0xe4, 0xa5, 0x2a, 0x13, 0x73, 0x73, 0xac, 0x94, 0xb0, 0x28, 0x52, 0x0a, + 0x12, 0x42, 0x11, 0x75, 0x06, 0x09, 0x0a, 0x99, 0x70, 0x71, 0xe5, 0xa7, 0xa4, 0x14, 0x43, 0xcd, + 0x61, 0x06, 0x9b, 0x23, 0xfa, 0xe9, 0x9e, 0xbc, 0x20, 0xc4, 0x1c, 0x84, 0x9c, 0x52, 0x10, 0x27, + 0x88, 0x03, 0xd1, 0xe5, 0xc2, 0xc5, 0x56, 0x5c, 0x92, 0x58, 0x52, 0x5a, 0x2c, 0xc1, 0xa2, 0xc0, + 0xa8, 0xc1, 0x67, 0xa4, 0xa3, 0x87, 0xc7, 0xeb, 0x7a, 0x70, 0x0f, 0x06, 0x83, 0xf5, 0x04, 0x41, + 0xf5, 0x5a, 0xf1, 0x74, 0x2c, 0x90, 0x67, 0x98, 0xb1, 0x40, 0x9e, 0xe1, 0xc5, 0x02, 0x79, 0x06, + 0xad, 0x65, 0x8c, 0x5c, 0xfc, 0x68, 0x2a, 0x85, 0x14, 0xb9, 0x64, 0xfd, 0x83, 0x5c, 0x5c, 0x83, + 0xe2, 0x9d, 0xfc, 0xfd, 0xbd, 0xe3, 0x83, 0x43, 0x1c, 0x43, 0x42, 0x83, 0xe3, 0x43, 0xfd, 0x82, + 0x03, 0x5c, 0x9d, 0x3d, 0xdd, 0x3c, 0x5d, 0x5d, 0x04, 0x18, 0x84, 0x94, 0xb9, 0xe4, 0x31, 0x95, + 0x40, 0x29, 0x47, 0xe7, 0x10, 0xcf, 0x30, 0x57, 0x01, 0x46, 0x21, 0x55, 0x2e, 0x45, 0x9c, 0x8a, + 0x82, 0x5c, 0x83, 0xfd, 0x7d, 0xc2, 0x5c, 0x5d, 0x04, 0x98, 0x84, 0x54, 0xb8, 0x14, 0x70, 0x2a, + 0x0b, 0x76, 0x0d, 0x09, 0xf1, 0x71, 0x75, 0x11, 0x60, 0x76, 0xf2, 0x3d, 0xf1, 0x48, 0x8e, 0xf1, + 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, + 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xe3, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, + 0x5c, 0xfd, 0xe2, 0xf4, 0x54, 0xdd, 0xbc, 0xd4, 0x92, 0xf2, 0xfc, 0xa2, 0x6c, 0x10, 0x5b, 0xbf, + 0x02, 0x33, 0x19, 0x95, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, 0x81, 0x53, 0x82, 0x31, 0x20, 0x00, + 0x00, 0xff, 0xff, 0x61, 0x29, 0xe0, 0xa4, 0x6b, 0x02, 0x00, 0x00, } func (m *OrderBook) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/types/params.go b/x/legacy/orderbook/types/params.go similarity index 100% rename from x/orderbook/types/params.go rename to x/legacy/orderbook/types/params.go diff --git a/x/orderbook/types/params.pb.go b/x/legacy/orderbook/types/params.pb.go similarity index 79% rename from x/orderbook/types/params.pb.go rename to x/legacy/orderbook/types/params.pb.go index d49f9449..a0c093de 100644 --- a/x/orderbook/types/params.pb.go +++ b/x/legacy/orderbook/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/params.proto +// source: sge/legacy/orderbook/v1beta/params.proto package types @@ -38,7 +38,7 @@ type Params struct { func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_c4a36fa63136acd4, []int{0} + return fileDescriptor_fb8630afe6b3a9b6, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -89,36 +89,36 @@ func (m *Params) GetRequeueThreshold() uint64 { } func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.orderbook.Params") + proto.RegisterType((*Params)(nil), "sge.legacy.orderbook.v1beta.Params") } func init() { - proto.RegisterFile("sgenetwork/sge/orderbook/params.proto", fileDescriptor_c4a36fa63136acd4) + proto.RegisterFile("sge/legacy/orderbook/v1beta/params.proto", fileDescriptor_fb8630afe6b3a9b6) } -var fileDescriptor_c4a36fa63136acd4 = []byte{ - // 322 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2d, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0x4a, 0x49, 0x2d, - 0x4a, 0xca, 0xcf, 0xcf, 0xd6, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, - 0xc9, 0x17, 0x92, 0x40, 0x28, 0xd3, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0x2b, 0x93, 0x12, 0x49, 0xcf, - 0x4f, 0xcf, 0x07, 0x2b, 0xd2, 0x07, 0xb1, 0x20, 0xea, 0x95, 0x16, 0x33, 0x71, 0xb1, 0x05, 0x80, - 0x0d, 0x10, 0xca, 0xe6, 0x92, 0xcd, 0x4d, 0xac, 0x88, 0x07, 0xeb, 0x88, 0x07, 0x69, 0x89, 0x2f, - 0x48, 0x2c, 0x2a, 0xc9, 0x4c, 0xce, 0x2c, 0x48, 0x2c, 0xc9, 0xcc, 0xcf, 0x2b, 0x96, 0x60, 0x54, - 0x60, 0xd4, 0x60, 0x71, 0xd2, 0xf8, 0x74, 0x4f, 0x5e, 0xa5, 0x32, 0x31, 0x37, 0xc7, 0x4a, 0x09, - 0xaf, 0x72, 0xa5, 0x20, 0xa9, 0xdc, 0xc4, 0x0a, 0x7f, 0x90, 0xb4, 0x53, 0x7e, 0x7e, 0x76, 0x00, - 0x8a, 0xa4, 0x50, 0x38, 0x97, 0x58, 0x52, 0x62, 0x49, 0x72, 0x46, 0x7c, 0x71, 0x6a, 0x49, 0x49, - 0x4e, 0x6a, 0x6e, 0x6a, 0x5e, 0x49, 0x7c, 0x72, 0x7e, 0x69, 0x5e, 0x89, 0x04, 0x13, 0xd8, 0x16, - 0xc5, 0x4f, 0xf7, 0xe4, 0x65, 0x21, 0xb6, 0x60, 0x57, 0xa7, 0x14, 0x24, 0x02, 0x96, 0x08, 0x86, - 0x8b, 0x3b, 0x83, 0x84, 0x85, 0x3c, 0xb9, 0x04, 0x8b, 0x52, 0x0b, 0x4b, 0x53, 0x4b, 0x53, 0xe3, - 0x4b, 0x32, 0x8a, 0x52, 0x8b, 0x33, 0xf2, 0x73, 0x52, 0x24, 0x98, 0xc1, 0x66, 0xca, 0x7c, 0xba, - 0x27, 0x2f, 0x01, 0x31, 0x13, 0x43, 0x89, 0x52, 0x90, 0x00, 0x54, 0x2c, 0x04, 0x26, 0x64, 0xc5, - 0x31, 0x63, 0x81, 0x3c, 0xc3, 0x8b, 0x05, 0xf2, 0x8c, 0x4e, 0x6e, 0x27, 0x1e, 0xc9, 0x31, 0x5e, - 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, - 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x93, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, - 0x0b, 0x8a, 0x16, 0x5d, 0xe4, 0x28, 0xaa, 0x40, 0x8a, 0xa4, 0x92, 0xca, 0x82, 0xd4, 0xe2, 0x24, - 0x36, 0x70, 0xa0, 0x1b, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0xf7, 0x51, 0x34, 0x7e, 0xcd, 0x01, - 0x00, 0x00, +var fileDescriptor_fb8630afe6b3a9b6 = []byte{ + // 332 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x91, 0x3f, 0x4b, 0xf3, 0x50, + 0x18, 0xc5, 0x93, 0xbe, 0x2f, 0x45, 0x32, 0x69, 0x28, 0x12, 0xaa, 0x4d, 0x34, 0x38, 0x74, 0x31, + 0x17, 0xe9, 0xd6, 0xb1, 0x4e, 0x0e, 0x62, 0xa9, 0x82, 0xe0, 0x12, 0x6e, 0xd2, 0x87, 0x9b, 0x90, + 0x3f, 0x4f, 0xbc, 0xf7, 0x46, 0xdb, 0x6f, 0xe1, 0xe8, 0x58, 0xf0, 0xcb, 0x38, 0x76, 0x74, 0x2a, + 0xd2, 0x2e, 0xce, 0xfd, 0x04, 0x92, 0x1b, 0x2d, 0x48, 0xc5, 0xed, 0xe1, 0x9c, 0xdf, 0x39, 0x07, + 0xee, 0x35, 0xba, 0x82, 0x01, 0x49, 0x81, 0xd1, 0x70, 0x4a, 0x90, 0x8f, 0x81, 0x07, 0x88, 0x09, + 0x79, 0x38, 0x0b, 0x40, 0x52, 0x52, 0x50, 0x4e, 0x33, 0xe1, 0x15, 0x1c, 0x25, 0x9a, 0x07, 0x82, + 0x81, 0x57, 0x93, 0xde, 0x86, 0xf4, 0x6a, 0xb2, 0xdd, 0x62, 0xc8, 0x50, 0x71, 0xa4, 0xba, 0xea, + 0x88, 0xfb, 0xd2, 0x30, 0x9a, 0x43, 0xd5, 0x61, 0x26, 0x46, 0x27, 0xa3, 0x13, 0x5f, 0x05, 0xfd, + 0x2a, 0xe9, 0x17, 0x94, 0xcb, 0x38, 0x8c, 0x0b, 0x2a, 0x63, 0xcc, 0x85, 0xa5, 0x1f, 0xe9, 0xdd, + 0xff, 0x83, 0xee, 0x7a, 0xe1, 0x9c, 0x4c, 0x69, 0x96, 0xf6, 0xdd, 0x3f, 0x71, 0x77, 0xd4, 0xce, + 0xe8, 0xe4, 0xaa, 0xb2, 0x07, 0x88, 0xc9, 0xf0, 0x87, 0x69, 0xde, 0x1a, 0xfb, 0x01, 0x95, 0x61, + 0xe4, 0x0b, 0x90, 0x32, 0x85, 0x0c, 0x72, 0xe9, 0x87, 0x58, 0xe6, 0xd2, 0x6a, 0xa8, 0x95, 0xe3, + 0xf5, 0xc2, 0xe9, 0xd4, 0x2b, 0xbf, 0x73, 0xee, 0xa8, 0xa5, 0x8c, 0xeb, 0x8d, 0x7e, 0x5e, 0xc9, + 0xe6, 0x85, 0xb1, 0xc7, 0xe1, 0xbe, 0x84, 0x12, 0x7c, 0x19, 0x71, 0x10, 0x11, 0xa6, 0x63, 0xeb, + 0x9f, 0xea, 0x3c, 0x5c, 0x2f, 0x1c, 0xab, 0xee, 0xdc, 0x42, 0xdc, 0xd1, 0xee, 0x97, 0x76, 0xf3, + 0x2d, 0xf5, 0x77, 0x9e, 0x67, 0x8e, 0xf6, 0x31, 0x73, 0xf4, 0xc1, 0xe5, 0xeb, 0xd2, 0xd6, 0xe7, + 0x4b, 0x5b, 0x7f, 0x5f, 0xda, 0xfa, 0xd3, 0xca, 0xd6, 0xe6, 0x2b, 0x5b, 0x7b, 0x5b, 0xd9, 0xda, + 0x5d, 0x8f, 0xc5, 0x32, 0x2a, 0x03, 0x2f, 0xc4, 0x8c, 0x08, 0x06, 0xa7, 0x39, 0xc8, 0x47, 0xe4, + 0x49, 0x75, 0x93, 0xc9, 0xf6, 0xaf, 0xc9, 0x69, 0x01, 0x22, 0x68, 0xaa, 0xb7, 0xef, 0x7d, 0x06, + 0x00, 0x00, 0xff, 0xff, 0xc7, 0x14, 0xad, 0x24, 0xda, 0x01, 0x00, 0x00, } func (this *Params) Equal(that interface{}) bool { diff --git a/x/orderbook/types/participation.go b/x/legacy/orderbook/types/participation.go similarity index 96% rename from x/orderbook/types/participation.go rename to x/legacy/orderbook/types/participation.go index 04b97d34..848282b6 100644 --- a/x/orderbook/types/participation.go +++ b/x/legacy/orderbook/types/participation.go @@ -5,9 +5,8 @@ import ( sdkerrors "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - housetypes "github.com/sge-network/sge/x/house/types" + housetypes "github.com/sge-network/sge/x/legacy/house/types" ) // NewOrderBookParticipation creates a new book participation object @@ -147,13 +146,13 @@ func (p *OrderBookParticipation) IsEligibleForNextRound() bool { // IsEligibleForNextRound determines if the participation has enough // liquidity to be used in the next round or not func (p *OrderBookParticipation) IsEligibleForNextRoundPreLiquidityReduction() bool { - maxLoss := sdk.MaxInt(sdkmath.ZeroInt(), p.CurrentRoundMaxLoss) + maxLoss := sdkmath.MaxInt(sdkmath.ZeroInt(), p.CurrentRoundMaxLoss) return p.CurrentRoundLiquidity.Sub(maxLoss).GT(sdkmath.ZeroInt()) } // TrimCurrentRoundLiquidity subtracts the max loss from the current round liquidity. func (p *OrderBookParticipation) TrimCurrentRoundLiquidity() { - maxLoss := sdk.MaxInt(sdkmath.ZeroInt(), p.CurrentRoundMaxLoss) + maxLoss := sdkmath.MaxInt(sdkmath.ZeroInt(), p.CurrentRoundMaxLoss) p.CurrentRoundLiquidity = p.CurrentRoundLiquidity.Sub(maxLoss) } diff --git a/x/orderbook/types/participation.pb.go b/x/legacy/orderbook/types/participation.pb.go similarity index 86% rename from x/orderbook/types/participation.pb.go rename to x/legacy/orderbook/types/participation.pb.go index d2258b21..96f9bbb7 100644 --- a/x/orderbook/types/participation.pb.go +++ b/x/legacy/orderbook/types/participation.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/participation.proto +// source: sge/legacy/orderbook/v1beta/participation.proto package types @@ -69,7 +69,7 @@ type OrderBookParticipation struct { func (m *OrderBookParticipation) Reset() { *m = OrderBookParticipation{} } func (*OrderBookParticipation) ProtoMessage() {} func (*OrderBookParticipation) Descriptor() ([]byte, []int) { - return fileDescriptor_325ee5284c02991d, []int{0} + return fileDescriptor_ad8ebc30312d296f, []int{0} } func (m *OrderBookParticipation) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -114,7 +114,7 @@ func (m *ParticipationBetPair) Reset() { *m = ParticipationBetPair{} } func (m *ParticipationBetPair) String() string { return proto.CompactTextString(m) } func (*ParticipationBetPair) ProtoMessage() {} func (*ParticipationBetPair) Descriptor() ([]byte, []int) { - return fileDescriptor_325ee5284c02991d, []int{1} + return fileDescriptor_ad8ebc30312d296f, []int{1} } func (m *ParticipationBetPair) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -179,7 +179,7 @@ func (m *SettledOrderbookParticipation) Reset() { *m = SettledOrderbookP func (m *SettledOrderbookParticipation) String() string { return proto.CompactTextString(m) } func (*SettledOrderbookParticipation) ProtoMessage() {} func (*SettledOrderbookParticipation) Descriptor() ([]byte, []int) { - return fileDescriptor_325ee5284c02991d, []int{2} + return fileDescriptor_ad8ebc30312d296f, []int{2} } func (m *SettledOrderbookParticipation) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -230,71 +230,71 @@ func (m *SettledOrderbookParticipation) GetParticipantAddress() string { } func init() { - proto.RegisterType((*OrderBookParticipation)(nil), "sgenetwork.sge.orderbook.OrderBookParticipation") - proto.RegisterType((*ParticipationBetPair)(nil), "sgenetwork.sge.orderbook.ParticipationBetPair") - proto.RegisterType((*SettledOrderbookParticipation)(nil), "sgenetwork.sge.orderbook.SettledOrderbookParticipation") + proto.RegisterType((*OrderBookParticipation)(nil), "sge.legacy.orderbook.v1beta.OrderBookParticipation") + proto.RegisterType((*ParticipationBetPair)(nil), "sge.legacy.orderbook.v1beta.ParticipationBetPair") + proto.RegisterType((*SettledOrderbookParticipation)(nil), "sge.legacy.orderbook.v1beta.SettledOrderbookParticipation") } func init() { - proto.RegisterFile("sgenetwork/sge/orderbook/participation.proto", fileDescriptor_325ee5284c02991d) + proto.RegisterFile("sge/legacy/orderbook/v1beta/participation.proto", fileDescriptor_ad8ebc30312d296f) } -var fileDescriptor_325ee5284c02991d = []byte{ - // 849 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x56, 0x4d, 0x6f, 0xe3, 0x44, - 0x18, 0x8e, 0xf7, 0xa3, 0x6d, 0x86, 0x34, 0x0d, 0xde, 0xa4, 0x6b, 0x82, 0xd6, 0x53, 0x8d, 0xc4, - 0xaa, 0x12, 0xbb, 0x09, 0x88, 0x4f, 0xad, 0x04, 0x68, 0x0d, 0x8a, 0x54, 0x58, 0x48, 0x99, 0x85, - 0xcb, 0x4a, 0xc8, 0x38, 0xf1, 0xc4, 0x1d, 0x25, 0xf6, 0x84, 0x99, 0xb1, 0x9a, 0xfe, 0x03, 0xc4, - 0x89, 0x23, 0x17, 0xa4, 0xfe, 0x08, 0xf8, 0x0f, 0x3d, 0x56, 0x9c, 0x10, 0x07, 0x0b, 0xa5, 0x1c, - 0x10, 0xc7, 0x9c, 0x39, 0x20, 0xcf, 0x24, 0x8e, 0x93, 0x06, 0x2c, 0x71, 0xdd, 0xdb, 0xcc, 0xfb, - 0xf1, 0x3c, 0xcf, 0x3b, 0xf6, 0xbc, 0xef, 0x80, 0x07, 0x22, 0x20, 0x11, 0x91, 0xa7, 0x8c, 0x0f, - 0xdb, 0x22, 0x20, 0x6d, 0xc6, 0x7d, 0xc2, 0x7b, 0x8c, 0x0d, 0xdb, 0x63, 0x8f, 0x4b, 0xda, 0xa7, - 0x63, 0x4f, 0x52, 0x16, 0xb5, 0xc6, 0x9c, 0x49, 0x66, 0x5a, 0xcb, 0xe8, 0x96, 0x08, 0x48, 0x2b, - 0x8b, 0x6e, 0xd6, 0x03, 0x16, 0x30, 0x15, 0xd4, 0x4e, 0x57, 0x3a, 0xbe, 0xf9, 0x52, 0x9f, 0x89, - 0x90, 0x09, 0x57, 0x3b, 0xf4, 0x46, 0xbb, 0xd0, 0x8f, 0x15, 0xb0, 0xdf, 0x4d, 0xd3, 0x1d, 0xc6, - 0x86, 0xc7, 0x79, 0x2e, 0xf3, 0x3e, 0xb8, 0x4d, 0x23, 0x9f, 0x4c, 0x2c, 0xe3, 0xc0, 0x38, 0xbc, - 0xe5, 0xd4, 0x66, 0x09, 0xac, 0x9c, 0x79, 0xe1, 0xe8, 0x11, 0x52, 0x66, 0x84, 0xb5, 0xdb, 0xfc, - 0x18, 0x54, 0x95, 0x00, 0x37, 0x55, 0xe0, 0xc6, 0xd4, 0xb7, 0x6e, 0x1c, 0x18, 0x87, 0x65, 0x07, - 0x4d, 0x13, 0x58, 0xc9, 0xb0, 0xbf, 0x3c, 0xfa, 0xe8, 0xaf, 0x04, 0xae, 0x45, 0xe2, 0xb5, 0xbd, - 0x19, 0x80, 0x3b, 0x59, 0xc1, 0x91, 0x74, 0x3d, 0xdf, 0xe7, 0x44, 0x08, 0xeb, 0xa6, 0x02, 0x7c, - 0x7b, 0x96, 0xc0, 0xa6, 0x56, 0xb0, 0x21, 0x08, 0xfd, 0xf2, 0xd3, 0xc3, 0xfa, 0xbc, 0xb6, 0xc7, - 0xda, 0xf4, 0x54, 0x72, 0x1a, 0x05, 0xd8, 0xcc, 0x45, 0xcf, 0x3d, 0x66, 0x17, 0x94, 0x47, 0xf4, - 0x9b, 0x98, 0xfa, 0x54, 0x9e, 0x59, 0xb7, 0x14, 0xfc, 0xeb, 0x17, 0x09, 0x2c, 0xfd, 0x96, 0xc0, - 0x86, 0x06, 0x11, 0xfe, 0xb0, 0x45, 0x59, 0x3b, 0xf4, 0xe4, 0x49, 0xeb, 0x28, 0x92, 0xb3, 0x04, - 0xd6, 0x34, 0x77, 0x96, 0x87, 0xf0, 0x12, 0xc3, 0x7c, 0x0f, 0xdc, 0x1c, 0x10, 0x62, 0xdd, 0x56, - 0x50, 0xaf, 0x16, 0x41, 0x01, 0x0d, 0x35, 0x20, 0x04, 0xe1, 0x34, 0xcf, 0x3c, 0x05, 0x77, 0xfb, - 0x31, 0xe7, 0x24, 0x92, 0x2e, 0x67, 0x71, 0xe4, 0xbb, 0x4b, 0x75, 0x5b, 0x0a, 0xf2, 0x83, 0x22, - 0x48, 0x5b, 0x43, 0xfe, 0x0b, 0x0a, 0xc2, 0x8d, 0xb9, 0x07, 0xa7, 0x8e, 0x27, 0x99, 0xee, 0xcf, - 0x41, 0x9d, 0x4c, 0xc6, 0x4c, 0xc4, 0x9c, 0x08, 0x37, 0x62, 0xd2, 0x1d, 0xd0, 0xd1, 0x88, 0xf8, - 0xd6, 0xb6, 0xfa, 0xe8, 0x70, 0x96, 0xc0, 0x97, 0x35, 0xf0, 0xa6, 0x28, 0x84, 0xcd, 0xcc, 0xfc, - 0x19, 0x93, 0x1d, 0x65, 0x34, 0x7b, 0xa0, 0x26, 0x99, 0xf4, 0x46, 0x6e, 0x8f, 0x48, 0xd7, 0x0b, - 0x59, 0x1c, 0x49, 0x6b, 0x47, 0x15, 0xf1, 0x6e, 0x51, 0x11, 0x77, 0x35, 0xd7, 0x7a, 0x3a, 0xc2, - 0x55, 0x65, 0x72, 0x88, 0x7c, 0xac, 0x0c, 0xe6, 0x77, 0x06, 0xb0, 0x57, 0x4b, 0xbd, 0x46, 0x59, - 0x56, 0x94, 0x9d, 0x22, 0xca, 0x57, 0x36, 0x9d, 0xdb, 0x75, 0x01, 0xcd, 0xfc, 0xf1, 0x7d, 0xb1, - 0x2a, 0xe6, 0x13, 0xb0, 0x13, 0x7a, 0x13, 0x77, 0xc4, 0x84, 0xb0, 0x80, 0x62, 0x7d, 0xad, 0x88, - 0x75, 0x4f, 0xb3, 0x2e, 0xd2, 0x10, 0xde, 0x0e, 0xbd, 0xc9, 0x13, 0x26, 0x84, 0x29, 0xc0, 0xfe, - 0xaa, 0x96, 0x0c, 0xfa, 0x05, 0x05, 0xfd, 0x7e, 0x11, 0xf4, 0xbd, 0x4d, 0x05, 0x2d, 0x89, 0xee, - 0xe4, 0x0b, 0xf9, 0x74, 0x4e, 0xfa, 0xb3, 0x01, 0xe0, 0xe6, 0x04, 0x97, 0xf9, 0xbe, 0x50, 0xb7, - 0xba, 0xa2, 0xe8, 0x87, 0xd3, 0x04, 0x36, 0x3f, 0xbc, 0x0e, 0xd1, 0xf5, 0x7d, 0xa1, 0xef, 0x78, - 0x11, 0xd0, 0x2c, 0x81, 0xf7, 0xff, 0x4b, 0x62, 0x16, 0x88, 0x70, 0x11, 0x94, 0xf9, 0x0c, 0xec, - 0x7a, 0x7d, 0x19, 0x7b, 0xa3, 0xb4, 0xb7, 0x0d, 0xa8, 0xb4, 0x76, 0x95, 0xc8, 0xb7, 0x8a, 0xce, - 0xa8, 0xae, 0x05, 0xac, 0xe4, 0x22, 0x5c, 0xd1, 0xfb, 0x63, 0xb5, 0x35, 0xdf, 0x04, 0x80, 0x0a, - 0x57, 0x10, 0x29, 0xd3, 0xfb, 0x50, 0x3d, 0x30, 0x0e, 0x77, 0x9c, 0xc6, 0x2c, 0x81, 0x2f, 0xce, - 0x9b, 0x60, 0xe6, 0x43, 0xb8, 0x4c, 0xc5, 0x53, 0xbd, 0x36, 0xbf, 0x06, 0x7b, 0x9c, 0xc8, 0x98, - 0x47, 0xc4, 0x5f, 0xfc, 0x88, 0x7b, 0x4a, 0xd3, 0x3b, 0x45, 0x9a, 0xf6, 0x35, 0xee, 0x5a, 0x36, - 0xc2, 0xd5, 0x85, 0x65, 0xfe, 0xb7, 0x7d, 0x05, 0xaa, 0x9c, 0xd0, 0xb0, 0x17, 0x73, 0x41, 0x7c, - 0x37, 0x6d, 0x3a, 0x35, 0xdd, 0x1e, 0x8b, 0x08, 0x1a, 0x0b, 0x82, 0x7c, 0x32, 0xc2, 0xbb, 0x4b, - 0x43, 0x87, 0x90, 0x47, 0x95, 0x6f, 0xcf, 0x61, 0xe9, 0x87, 0x73, 0x58, 0xfa, 0xf3, 0x1c, 0x96, - 0xd0, 0x1f, 0x06, 0xa8, 0xaf, 0x8c, 0x05, 0x87, 0xc8, 0x63, 0x8f, 0xf2, 0x0d, 0x5d, 0xdf, 0xf8, - 0xdf, 0x5d, 0xbf, 0x9b, 0xeb, 0xfa, 0x29, 0x87, 0xab, 0xe7, 0xce, 0x0d, 0xd5, 0x82, 0xec, 0x0d, - 0x5d, 0x7f, 0x19, 0x84, 0x72, 0xdd, 0x3d, 0xb5, 0x1e, 0xa9, 0x91, 0xd4, 0x06, 0xdb, 0xe9, 0xdd, - 0x4d, 0x55, 0xe9, 0xd1, 0xd1, 0x98, 0x26, 0x70, 0xcb, 0x21, 0x52, 0xeb, 0x59, 0x38, 0xf1, 0x62, - 0x81, 0xfe, 0x36, 0xc0, 0xbd, 0xf9, 0x17, 0xec, 0x2e, 0x86, 0xe9, 0xf3, 0x33, 0x0d, 0x9d, 0xce, - 0xc5, 0xd4, 0x36, 0x2e, 0xa7, 0xb6, 0xf1, 0xfb, 0xd4, 0x36, 0xbe, 0xbf, 0xb2, 0x4b, 0x97, 0x57, - 0x76, 0xe9, 0xd7, 0x2b, 0xbb, 0xf4, 0xec, 0x41, 0x40, 0xe5, 0x49, 0xdc, 0x6b, 0xf5, 0x59, 0x98, - 0x3e, 0x4c, 0x1e, 0xe6, 0x1f, 0x29, 0x93, 0xdc, 0x33, 0x45, 0x9e, 0x8d, 0x89, 0xe8, 0x6d, 0xa9, - 0x47, 0xc5, 0x1b, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0x73, 0xdb, 0x4c, 0x09, 0xcf, 0x08, 0x00, - 0x00, +var fileDescriptor_ad8ebc30312d296f = []byte{ + // 859 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x56, 0xcb, 0x8f, 0xdb, 0x44, + 0x18, 0x8f, 0xfb, 0xd8, 0xc7, 0x90, 0xcd, 0x2e, 0x6e, 0xb2, 0x35, 0xa9, 0xea, 0x59, 0x8d, 0x44, + 0xb5, 0x12, 0x6a, 0x4c, 0x55, 0x5e, 0xaa, 0x04, 0xa8, 0x06, 0xad, 0xb4, 0xd0, 0x92, 0x65, 0x0a, + 0x97, 0x4a, 0xc8, 0x38, 0xf1, 0xc4, 0x1d, 0xc5, 0xf6, 0x84, 0x99, 0x31, 0x4d, 0xfe, 0x03, 0xc4, + 0x89, 0x23, 0x17, 0xa4, 0xfd, 0x23, 0xe0, 0x7f, 0xe8, 0x71, 0xc5, 0x09, 0x71, 0xb0, 0x50, 0x96, + 0x03, 0xe2, 0x98, 0x33, 0x07, 0xe4, 0x99, 0xc4, 0x79, 0x82, 0x25, 0xae, 0xdc, 0x3c, 0xdf, 0xf7, + 0xfd, 0x1e, 0x9f, 0xed, 0xf9, 0x66, 0x80, 0x23, 0x42, 0xe2, 0x44, 0x24, 0xf4, 0xbb, 0x23, 0x87, + 0xf1, 0x80, 0xf0, 0x0e, 0x63, 0x7d, 0xe7, 0xeb, 0x7b, 0x1d, 0x22, 0x7d, 0x67, 0xe0, 0x73, 0x49, + 0xbb, 0x74, 0xe0, 0x4b, 0xca, 0x92, 0xd6, 0x80, 0x33, 0xc9, 0xcc, 0x5b, 0x22, 0x24, 0x2d, 0x0d, + 0x68, 0x15, 0x80, 0x96, 0x06, 0x34, 0xeb, 0x21, 0x0b, 0x99, 0xaa, 0x73, 0xf2, 0x27, 0x0d, 0x69, + 0xbe, 0xd2, 0x65, 0x22, 0x66, 0xc2, 0xd3, 0x09, 0xbd, 0xd0, 0x29, 0xf4, 0x43, 0x15, 0x1c, 0xb6, + 0x73, 0x16, 0x97, 0xb1, 0xfe, 0xd9, 0xa2, 0x9c, 0x79, 0x07, 0x5c, 0xa7, 0x49, 0x40, 0x86, 0x96, + 0x71, 0x64, 0x1c, 0x5f, 0x73, 0x0f, 0x26, 0x19, 0xac, 0x8e, 0xfc, 0x38, 0x7a, 0x80, 0x54, 0x18, + 0x61, 0x9d, 0x36, 0x3f, 0x02, 0x35, 0xe5, 0xc3, 0xcb, 0x8d, 0x78, 0x29, 0x0d, 0xac, 0x2b, 0x47, + 0xc6, 0xf1, 0xae, 0x8b, 0xc6, 0x19, 0xac, 0x16, 0xdc, 0x9f, 0x9f, 0x7e, 0xf8, 0x67, 0x06, 0x57, + 0x2a, 0xf1, 0xca, 0xda, 0x0c, 0xc1, 0x8d, 0xa2, 0xe7, 0x44, 0x7a, 0x7e, 0x10, 0x70, 0x22, 0x84, + 0x75, 0x55, 0x11, 0xbe, 0x35, 0xc9, 0x60, 0x53, 0x3b, 0xd8, 0x50, 0x84, 0x7e, 0xfe, 0xf1, 0x6e, + 0x7d, 0xda, 0xdb, 0x43, 0x1d, 0x7a, 0x22, 0x39, 0x4d, 0x42, 0x6c, 0x2e, 0x54, 0x4f, 0x33, 0x66, + 0x1b, 0xec, 0x46, 0xf4, 0xab, 0x94, 0x06, 0x54, 0x8e, 0xac, 0x6b, 0x8a, 0xfe, 0xde, 0x8b, 0x0c, + 0x56, 0x7e, 0xcd, 0x60, 0x43, 0x93, 0x88, 0xa0, 0xdf, 0xa2, 0xcc, 0x89, 0x7d, 0xf9, 0xac, 0x75, + 0x9a, 0xc8, 0x49, 0x06, 0x0f, 0xb4, 0x76, 0x81, 0x43, 0x78, 0xce, 0x61, 0xbe, 0x0b, 0xae, 0xf6, + 0x08, 0xb1, 0xae, 0x2b, 0xaa, 0xd7, 0xca, 0xa8, 0x80, 0xa6, 0xea, 0x11, 0x82, 0x70, 0x8e, 0x33, + 0x9f, 0x83, 0x9b, 0xdd, 0x94, 0x73, 0x92, 0x48, 0x8f, 0xb3, 0x34, 0x09, 0xbc, 0xb9, 0xbb, 0x2d, + 0x45, 0xf9, 0x7e, 0x19, 0xa5, 0xad, 0x29, 0xff, 0x81, 0x05, 0xe1, 0xc6, 0x34, 0x83, 0xf3, 0xc4, + 0xa3, 0xc2, 0xf7, 0xa7, 0xa0, 0x4e, 0x86, 0x03, 0x26, 0x52, 0x4e, 0x84, 0x97, 0x30, 0xe9, 0xf5, + 0x68, 0x14, 0x91, 0xc0, 0xda, 0x56, 0x1f, 0x1d, 0x4e, 0x32, 0x78, 0x4b, 0x13, 0x6f, 0xaa, 0x42, + 0xd8, 0x2c, 0xc2, 0x9f, 0x30, 0x79, 0xa2, 0x82, 0x66, 0x07, 0x1c, 0x48, 0x26, 0xfd, 0xc8, 0xeb, + 0x10, 0xe9, 0xf9, 0x31, 0x4b, 0x13, 0x69, 0xed, 0xa8, 0x26, 0xde, 0x29, 0x6b, 0xe2, 0xa6, 0xd6, + 0x5a, 0x85, 0x23, 0x5c, 0x53, 0x21, 0x97, 0xc8, 0x87, 0x2a, 0x60, 0x7e, 0x6b, 0x00, 0x7b, 0xb9, + 0xd5, 0x35, 0xc9, 0x5d, 0x25, 0x79, 0x52, 0x26, 0xf9, 0xea, 0xa6, 0xf7, 0xb6, 0x6e, 0xa0, 0xb9, + 0xf8, 0xfa, 0x3e, 0x5b, 0x36, 0xf3, 0x31, 0xd8, 0x89, 0xfd, 0xa1, 0x17, 0x31, 0x21, 0x2c, 0xa0, + 0x54, 0x5f, 0x2f, 0x53, 0xdd, 0xd7, 0xaa, 0x33, 0x18, 0xc2, 0xdb, 0xb1, 0x3f, 0x7c, 0xc4, 0x84, + 0x30, 0x05, 0x38, 0x5c, 0xf6, 0x52, 0x50, 0xbf, 0xa4, 0xa8, 0xdf, 0x2b, 0xa3, 0xbe, 0xbd, 0xa9, + 0xa1, 0xb9, 0xd0, 0x8d, 0xc5, 0x46, 0x1e, 0x4f, 0x45, 0x7f, 0x32, 0x00, 0xdc, 0x0c, 0xf0, 0x58, + 0x10, 0x08, 0xb5, 0xab, 0xab, 0x4a, 0xbe, 0x3f, 0xce, 0x60, 0xf3, 0x83, 0x75, 0x8a, 0x76, 0x10, + 0x08, 0xbd, 0xc7, 0xcb, 0x88, 0x26, 0x19, 0xbc, 0xf3, 0x6f, 0x16, 0x8b, 0x42, 0x84, 0xcb, 0xa8, + 0xcc, 0xa7, 0x60, 0xcf, 0xef, 0xca, 0xd4, 0x8f, 0xf2, 0xd9, 0xd6, 0xa3, 0xd2, 0xda, 0x53, 0x26, + 0xdf, 0x2c, 0x7b, 0x47, 0x75, 0x6d, 0x60, 0x09, 0x8b, 0x70, 0x55, 0xaf, 0xcf, 0xd4, 0xd2, 0x7c, + 0x03, 0x00, 0x2a, 0x3c, 0x41, 0xa4, 0xcc, 0xf7, 0x43, 0xed, 0xc8, 0x38, 0xde, 0x71, 0x1b, 0x93, + 0x0c, 0xbe, 0x3c, 0x1d, 0x82, 0x45, 0x0e, 0xe1, 0x5d, 0x2a, 0x9e, 0xe8, 0x67, 0xf3, 0x4b, 0xb0, + 0xcf, 0x89, 0x4c, 0x79, 0x42, 0x82, 0xd9, 0x8f, 0xb8, 0xaf, 0x3c, 0xbd, 0x5d, 0xe6, 0xe9, 0x50, + 0xf3, 0xae, 0xa0, 0x11, 0xae, 0xcd, 0x22, 0xd3, 0xbf, 0xed, 0x0b, 0x50, 0xe3, 0x84, 0xc6, 0x9d, + 0x94, 0x0b, 0x12, 0x78, 0xf9, 0xd0, 0x39, 0xd0, 0xe3, 0xb1, 0x4c, 0xa0, 0x31, 0x13, 0x58, 0x04, + 0x23, 0xbc, 0x37, 0x0f, 0x9c, 0x10, 0xf2, 0xa0, 0xfa, 0xcd, 0x39, 0xac, 0x7c, 0x7f, 0x0e, 0x2b, + 0x7f, 0x9c, 0xc3, 0x0a, 0xfa, 0xdd, 0x00, 0xf5, 0xa5, 0x63, 0xc1, 0x25, 0xf2, 0xcc, 0xa7, 0x7c, + 0xc3, 0xd4, 0x37, 0xfe, 0xf3, 0xd4, 0x6f, 0x2f, 0x4c, 0xfd, 0x5c, 0xc3, 0xd3, 0xe7, 0xce, 0x15, + 0x35, 0x82, 0xec, 0x0d, 0x53, 0x7f, 0x5e, 0x84, 0x16, 0xa6, 0x7b, 0x1e, 0x3d, 0x55, 0x47, 0x92, + 0x03, 0xb6, 0xf3, 0xbd, 0x9b, 0xbb, 0xd2, 0x47, 0x47, 0x63, 0x9c, 0xc1, 0x2d, 0x97, 0x48, 0xed, + 0x67, 0x96, 0xc4, 0xb3, 0x07, 0xf4, 0x97, 0x01, 0x6e, 0x4f, 0xbf, 0x60, 0x7b, 0x76, 0xa6, 0xfe, + 0x7f, 0x4e, 0x43, 0xf7, 0xf1, 0x8b, 0xb1, 0x6d, 0x5c, 0x8c, 0x6d, 0xe3, 0xb7, 0xb1, 0x6d, 0x7c, + 0x77, 0x69, 0x57, 0x2e, 0x2e, 0xed, 0xca, 0x2f, 0x97, 0x76, 0xe5, 0xe9, 0xfd, 0x90, 0xca, 0x67, + 0x69, 0xa7, 0xd5, 0x65, 0x71, 0x7e, 0x53, 0xb9, 0x9b, 0x10, 0xf9, 0x9c, 0xf1, 0xbe, 0xba, 0xb5, + 0x0c, 0xd7, 0xef, 0x2d, 0x72, 0x34, 0x20, 0xa2, 0xb3, 0xa5, 0xee, 0x16, 0xf7, 0xff, 0x0e, 0x00, + 0x00, 0xff, 0xff, 0x38, 0x79, 0x3e, 0x47, 0xdc, 0x08, 0x00, 0x00, } func (m *OrderBookParticipation) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/types/participation_bet.go b/x/legacy/orderbook/types/participation_bet.go similarity index 100% rename from x/orderbook/types/participation_bet.go rename to x/legacy/orderbook/types/participation_bet.go diff --git a/x/orderbook/types/query.pb.go b/x/legacy/orderbook/types/query.pb.go similarity index 92% rename from x/orderbook/types/query.pb.go rename to x/legacy/orderbook/types/query.pb.go index 10a24488..39ed220a 100644 --- a/x/orderbook/types/query.pb.go +++ b/x/legacy/orderbook/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/query.proto +// source: sge/legacy/orderbook/v1beta/query.proto package types @@ -39,7 +39,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{0} + return fileDescriptor_ee861fabfd512297, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -79,7 +79,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{1} + return fileDescriptor_ee861fabfd512297, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -128,7 +128,7 @@ func (m *QueryOrderBooksRequest) Reset() { *m = QueryOrderBooksRequest{} func (m *QueryOrderBooksRequest) String() string { return proto.CompactTextString(m) } func (*QueryOrderBooksRequest) ProtoMessage() {} func (*QueryOrderBooksRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{2} + return fileDescriptor_ee861fabfd512297, []int{2} } func (m *QueryOrderBooksRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -184,7 +184,7 @@ func (m *QueryOrderBooksResponse) Reset() { *m = QueryOrderBooksResponse func (m *QueryOrderBooksResponse) String() string { return proto.CompactTextString(m) } func (*QueryOrderBooksResponse) ProtoMessage() {} func (*QueryOrderBooksResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{3} + return fileDescriptor_ee861fabfd512297, []int{3} } func (m *QueryOrderBooksResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -237,7 +237,7 @@ func (m *QueryOrderBookRequest) Reset() { *m = QueryOrderBookRequest{} } func (m *QueryOrderBookRequest) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookRequest) ProtoMessage() {} func (*QueryOrderBookRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{4} + return fileDescriptor_ee861fabfd512297, []int{4} } func (m *QueryOrderBookRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -284,7 +284,7 @@ func (m *QueryOrderBookResponse) Reset() { *m = QueryOrderBookResponse{} func (m *QueryOrderBookResponse) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookResponse) ProtoMessage() {} func (*QueryOrderBookResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{5} + return fileDescriptor_ee861fabfd512297, []int{5} } func (m *QueryOrderBookResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -334,7 +334,7 @@ func (m *QueryOrderBookParticipationsRequest) Reset() { *m = QueryOrderB func (m *QueryOrderBookParticipationsRequest) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookParticipationsRequest) ProtoMessage() {} func (*QueryOrderBookParticipationsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{6} + return fileDescriptor_ee861fabfd512297, []int{6} } func (m *QueryOrderBookParticipationsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -389,7 +389,7 @@ func (m *QueryOrderBookParticipationsResponse) Reset() { *m = QueryOrder func (m *QueryOrderBookParticipationsResponse) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookParticipationsResponse) ProtoMessage() {} func (*QueryOrderBookParticipationsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{7} + return fileDescriptor_ee861fabfd512297, []int{7} } func (m *QueryOrderBookParticipationsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -446,7 +446,7 @@ func (m *QueryOrderBookParticipationRequest) Reset() { *m = QueryOrderBo func (m *QueryOrderBookParticipationRequest) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookParticipationRequest) ProtoMessage() {} func (*QueryOrderBookParticipationRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{8} + return fileDescriptor_ee861fabfd512297, []int{8} } func (m *QueryOrderBookParticipationRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -500,7 +500,7 @@ func (m *QueryOrderBookParticipationResponse) Reset() { *m = QueryOrderB func (m *QueryOrderBookParticipationResponse) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookParticipationResponse) ProtoMessage() {} func (*QueryOrderBookParticipationResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{9} + return fileDescriptor_ee861fabfd512297, []int{9} } func (m *QueryOrderBookParticipationResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -549,7 +549,7 @@ func (m *QueryOrderBookExposuresRequest) Reset() { *m = QueryOrderBookEx func (m *QueryOrderBookExposuresRequest) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookExposuresRequest) ProtoMessage() {} func (*QueryOrderBookExposuresRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{10} + return fileDescriptor_ee861fabfd512297, []int{10} } func (m *QueryOrderBookExposuresRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -604,7 +604,7 @@ func (m *QueryOrderBookExposuresResponse) Reset() { *m = QueryOrderBookE func (m *QueryOrderBookExposuresResponse) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookExposuresResponse) ProtoMessage() {} func (*QueryOrderBookExposuresResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{11} + return fileDescriptor_ee861fabfd512297, []int{11} } func (m *QueryOrderBookExposuresResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -660,7 +660,7 @@ func (m *QueryOrderBookExposureRequest) Reset() { *m = QueryOrderBookExp func (m *QueryOrderBookExposureRequest) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookExposureRequest) ProtoMessage() {} func (*QueryOrderBookExposureRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{12} + return fileDescriptor_ee861fabfd512297, []int{12} } func (m *QueryOrderBookExposureRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -714,7 +714,7 @@ func (m *QueryOrderBookExposureResponse) Reset() { *m = QueryOrderBookEx func (m *QueryOrderBookExposureResponse) String() string { return proto.CompactTextString(m) } func (*QueryOrderBookExposureResponse) ProtoMessage() {} func (*QueryOrderBookExposureResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{13} + return fileDescriptor_ee861fabfd512297, []int{13} } func (m *QueryOrderBookExposureResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -767,7 +767,7 @@ func (m *QueryOrderBookParticipationExposuresRequest) String() string { } func (*QueryOrderBookParticipationExposuresRequest) ProtoMessage() {} func (*QueryOrderBookParticipationExposuresRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{14} + return fileDescriptor_ee861fabfd512297, []int{14} } func (m *QueryOrderBookParticipationExposuresRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -826,7 +826,7 @@ func (m *QueryOrderBookParticipationExposuresResponse) String() string { } func (*QueryOrderBookParticipationExposuresResponse) ProtoMessage() {} func (*QueryOrderBookParticipationExposuresResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{15} + return fileDescriptor_ee861fabfd512297, []int{15} } func (m *QueryOrderBookParticipationExposuresResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -884,7 +884,7 @@ func (m *QueryParticipationExposuresRequest) Reset() { *m = QueryPartici func (m *QueryParticipationExposuresRequest) String() string { return proto.CompactTextString(m) } func (*QueryParticipationExposuresRequest) ProtoMessage() {} func (*QueryParticipationExposuresRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{16} + return fileDescriptor_ee861fabfd512297, []int{16} } func (m *QueryParticipationExposuresRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -947,7 +947,7 @@ func (m *QueryParticipationExposuresResponse) Reset() { *m = QueryPartic func (m *QueryParticipationExposuresResponse) String() string { return proto.CompactTextString(m) } func (*QueryParticipationExposuresResponse) ProtoMessage() {} func (*QueryParticipationExposuresResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{17} + return fileDescriptor_ee861fabfd512297, []int{17} } func (m *QueryParticipationExposuresResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1007,7 +1007,7 @@ func (m *QueryHistoricalParticipationExposuresRequest) String() string { } func (*QueryHistoricalParticipationExposuresRequest) ProtoMessage() {} func (*QueryHistoricalParticipationExposuresRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{18} + return fileDescriptor_ee861fabfd512297, []int{18} } func (m *QueryHistoricalParticipationExposuresRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1066,7 +1066,7 @@ func (m *QueryHistoricalParticipationExposuresResponse) String() string { } func (*QueryHistoricalParticipationExposuresResponse) ProtoMessage() {} func (*QueryHistoricalParticipationExposuresResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{19} + return fileDescriptor_ee861fabfd512297, []int{19} } func (m *QueryHistoricalParticipationExposuresResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1126,7 +1126,7 @@ func (m *QueryParticipationFulfilledBetsRequest) Reset() { func (m *QueryParticipationFulfilledBetsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParticipationFulfilledBetsRequest) ProtoMessage() {} func (*QueryParticipationFulfilledBetsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{20} + return fileDescriptor_ee861fabfd512297, []int{20} } func (m *QueryParticipationFulfilledBetsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1191,7 +1191,7 @@ func (m *QueryParticipationFulfilledBetsResponse) Reset() { func (m *QueryParticipationFulfilledBetsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParticipationFulfilledBetsResponse) ProtoMessage() {} func (*QueryParticipationFulfilledBetsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{21} + return fileDescriptor_ee861fabfd512297, []int{21} } func (m *QueryParticipationFulfilledBetsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1249,7 +1249,7 @@ func (m *QuerySettledOrderBookParticipationsOfHeightRequest) String() string { } func (*QuerySettledOrderBookParticipationsOfHeightRequest) ProtoMessage() {} func (*QuerySettledOrderBookParticipationsOfHeightRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{22} + return fileDescriptor_ee861fabfd512297, []int{22} } func (m *QuerySettledOrderBookParticipationsOfHeightRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1307,7 +1307,7 @@ func (m *QuerySettledOrderBookParticipationsOfHeightResponse) String() string { } func (*QuerySettledOrderBookParticipationsOfHeightResponse) ProtoMessage() {} func (*QuerySettledOrderBookParticipationsOfHeightResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ed7e5b0ca5b647cb, []int{23} + return fileDescriptor_ee861fabfd512297, []int{23} } func (m *QuerySettledOrderBookParticipationsOfHeightResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1351,116 +1351,117 @@ func (m *QuerySettledOrderBookParticipationsOfHeightResponse) GetPagination() *q } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.orderbook.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.orderbook.QueryParamsResponse") - proto.RegisterType((*QueryOrderBooksRequest)(nil), "sgenetwork.sge.orderbook.QueryOrderBooksRequest") - proto.RegisterType((*QueryOrderBooksResponse)(nil), "sgenetwork.sge.orderbook.QueryOrderBooksResponse") - proto.RegisterType((*QueryOrderBookRequest)(nil), "sgenetwork.sge.orderbook.QueryOrderBookRequest") - proto.RegisterType((*QueryOrderBookResponse)(nil), "sgenetwork.sge.orderbook.QueryOrderBookResponse") - proto.RegisterType((*QueryOrderBookParticipationsRequest)(nil), "sgenetwork.sge.orderbook.QueryOrderBookParticipationsRequest") - proto.RegisterType((*QueryOrderBookParticipationsResponse)(nil), "sgenetwork.sge.orderbook.QueryOrderBookParticipationsResponse") - proto.RegisterType((*QueryOrderBookParticipationRequest)(nil), "sgenetwork.sge.orderbook.QueryOrderBookParticipationRequest") - proto.RegisterType((*QueryOrderBookParticipationResponse)(nil), "sgenetwork.sge.orderbook.QueryOrderBookParticipationResponse") - proto.RegisterType((*QueryOrderBookExposuresRequest)(nil), "sgenetwork.sge.orderbook.QueryOrderBookExposuresRequest") - proto.RegisterType((*QueryOrderBookExposuresResponse)(nil), "sgenetwork.sge.orderbook.QueryOrderBookExposuresResponse") - proto.RegisterType((*QueryOrderBookExposureRequest)(nil), "sgenetwork.sge.orderbook.QueryOrderBookExposureRequest") - proto.RegisterType((*QueryOrderBookExposureResponse)(nil), "sgenetwork.sge.orderbook.QueryOrderBookExposureResponse") - proto.RegisterType((*QueryOrderBookParticipationExposuresRequest)(nil), "sgenetwork.sge.orderbook.QueryOrderBookParticipationExposuresRequest") - proto.RegisterType((*QueryOrderBookParticipationExposuresResponse)(nil), "sgenetwork.sge.orderbook.QueryOrderBookParticipationExposuresResponse") - proto.RegisterType((*QueryParticipationExposuresRequest)(nil), "sgenetwork.sge.orderbook.QueryParticipationExposuresRequest") - proto.RegisterType((*QueryParticipationExposuresResponse)(nil), "sgenetwork.sge.orderbook.QueryParticipationExposuresResponse") - proto.RegisterType((*QueryHistoricalParticipationExposuresRequest)(nil), "sgenetwork.sge.orderbook.QueryHistoricalParticipationExposuresRequest") - proto.RegisterType((*QueryHistoricalParticipationExposuresResponse)(nil), "sgenetwork.sge.orderbook.QueryHistoricalParticipationExposuresResponse") - proto.RegisterType((*QueryParticipationFulfilledBetsRequest)(nil), "sgenetwork.sge.orderbook.QueryParticipationFulfilledBetsRequest") - proto.RegisterType((*QueryParticipationFulfilledBetsResponse)(nil), "sgenetwork.sge.orderbook.QueryParticipationFulfilledBetsResponse") - proto.RegisterType((*QuerySettledOrderBookParticipationsOfHeightRequest)(nil), "sgenetwork.sge.orderbook.QuerySettledOrderBookParticipationsOfHeightRequest") - proto.RegisterType((*QuerySettledOrderBookParticipationsOfHeightResponse)(nil), "sgenetwork.sge.orderbook.QuerySettledOrderBookParticipationsOfHeightResponse") + proto.RegisterType((*QueryParamsRequest)(nil), "sge.legacy.orderbook.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.legacy.orderbook.v1beta.QueryParamsResponse") + proto.RegisterType((*QueryOrderBooksRequest)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBooksRequest") + proto.RegisterType((*QueryOrderBooksResponse)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBooksResponse") + proto.RegisterType((*QueryOrderBookRequest)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookRequest") + proto.RegisterType((*QueryOrderBookResponse)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookResponse") + proto.RegisterType((*QueryOrderBookParticipationsRequest)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsRequest") + proto.RegisterType((*QueryOrderBookParticipationsResponse)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationsResponse") + proto.RegisterType((*QueryOrderBookParticipationRequest)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationRequest") + proto.RegisterType((*QueryOrderBookParticipationResponse)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationResponse") + proto.RegisterType((*QueryOrderBookExposuresRequest)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresRequest") + proto.RegisterType((*QueryOrderBookExposuresResponse)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookExposuresResponse") + proto.RegisterType((*QueryOrderBookExposureRequest)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookExposureRequest") + proto.RegisterType((*QueryOrderBookExposureResponse)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookExposureResponse") + proto.RegisterType((*QueryOrderBookParticipationExposuresRequest)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresRequest") + proto.RegisterType((*QueryOrderBookParticipationExposuresResponse)(nil), "sge.legacy.orderbook.v1beta.QueryOrderBookParticipationExposuresResponse") + proto.RegisterType((*QueryParticipationExposuresRequest)(nil), "sge.legacy.orderbook.v1beta.QueryParticipationExposuresRequest") + proto.RegisterType((*QueryParticipationExposuresResponse)(nil), "sge.legacy.orderbook.v1beta.QueryParticipationExposuresResponse") + proto.RegisterType((*QueryHistoricalParticipationExposuresRequest)(nil), "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresRequest") + proto.RegisterType((*QueryHistoricalParticipationExposuresResponse)(nil), "sge.legacy.orderbook.v1beta.QueryHistoricalParticipationExposuresResponse") + proto.RegisterType((*QueryParticipationFulfilledBetsRequest)(nil), "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsRequest") + proto.RegisterType((*QueryParticipationFulfilledBetsResponse)(nil), "sge.legacy.orderbook.v1beta.QueryParticipationFulfilledBetsResponse") + proto.RegisterType((*QuerySettledOrderBookParticipationsOfHeightRequest)(nil), "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightRequest") + proto.RegisterType((*QuerySettledOrderBookParticipationsOfHeightResponse)(nil), "sge.legacy.orderbook.v1beta.QuerySettledOrderBookParticipationsOfHeightResponse") } func init() { - proto.RegisterFile("sgenetwork/sge/orderbook/query.proto", fileDescriptor_ed7e5b0ca5b647cb) -} - -var fileDescriptor_ed7e5b0ca5b647cb = []byte{ - // 1242 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x59, 0x4f, 0x6f, 0xdc, 0x44, - 0x14, 0xcf, 0xa4, 0x25, 0x90, 0x97, 0xaa, 0x52, 0x5f, 0xd2, 0x6c, 0xb2, 0xa2, 0x9b, 0xd4, 0x0d, - 0x49, 0xa0, 0x89, 0x9d, 0xa4, 0xa8, 0x7f, 0xa4, 0xa4, 0xc0, 0xaa, 0x4d, 0x53, 0xd4, 0x2a, 0x61, - 0xab, 0x5c, 0x40, 0x22, 0x78, 0x77, 0x27, 0x8e, 0x95, 0xcd, 0x8e, 0xbb, 0xf6, 0x42, 0xaa, 0x28, - 0x17, 0x40, 0xe2, 0x86, 0x10, 0x3d, 0xf4, 0x00, 0x12, 0x9f, 0x80, 0x6f, 0xc0, 0x0d, 0x24, 0x7a, - 0x8c, 0xd4, 0x03, 0x9c, 0x2a, 0x94, 0x45, 0xa2, 0x07, 0x2e, 0x7c, 0x01, 0x40, 0x1e, 0x8f, 0x9d, - 0xf5, 0xae, 0xbd, 0xfe, 0x93, 0x95, 0x4a, 0xb9, 0x39, 0x9e, 0x79, 0xef, 0xfd, 0xfe, 0xbc, 0x19, - 0xcf, 0x64, 0x61, 0xc2, 0xd4, 0x68, 0x95, 0x5a, 0x9f, 0xb0, 0xda, 0xb6, 0x62, 0x6a, 0x54, 0x61, - 0xb5, 0x32, 0xad, 0x15, 0x19, 0xdb, 0x56, 0xee, 0xd7, 0x69, 0xed, 0x81, 0x6c, 0xd4, 0x98, 0xc5, - 0x70, 0xe4, 0x68, 0x96, 0x6c, 0x6a, 0x54, 0xf6, 0x66, 0x65, 0xdf, 0x28, 0x31, 0x73, 0x87, 0x99, - 0x4a, 0x51, 0x35, 0xa9, 0x13, 0xa2, 0x7c, 0x3c, 0x5f, 0xa4, 0x96, 0x3a, 0xaf, 0x18, 0xaa, 0xa6, - 0x57, 0x55, 0x4b, 0x67, 0x55, 0x27, 0x4b, 0x76, 0x48, 0x63, 0x1a, 0xe3, 0x8f, 0x8a, 0xfd, 0x24, - 0xde, 0xbe, 0xaa, 0x31, 0xa6, 0x55, 0xa8, 0xa2, 0x1a, 0xba, 0xa2, 0x56, 0xab, 0xcc, 0xe2, 0x21, - 0xa6, 0x18, 0x7d, 0x2d, 0x14, 0x9f, 0xa1, 0xd6, 0xd4, 0x1d, 0x77, 0xda, 0x74, 0xe8, 0x34, 0xef, - 0x49, 0xcc, 0x9c, 0xe9, 0x94, 0xd0, 0xd2, 0x4b, 0xba, 0xd1, 0x0c, 0x79, 0x2a, 0x74, 0x36, 0xdd, - 0x35, 0x98, 0x59, 0xaf, 0x51, 0x67, 0xa2, 0x34, 0x04, 0xf8, 0x9e, 0xcd, 0x7e, 0x8d, 0xa3, 0x2a, - 0xd0, 0xfb, 0x75, 0x6a, 0x5a, 0xd2, 0x3a, 0x0c, 0xfa, 0xde, 0x9a, 0x06, 0xab, 0x9a, 0x14, 0xaf, - 0x43, 0x9f, 0x83, 0x7e, 0x84, 0x8c, 0x93, 0xe9, 0x81, 0x85, 0x71, 0x39, 0x4c, 0x5f, 0xd9, 0x89, - 0xcc, 0x9f, 0x7c, 0xfc, 0x74, 0xac, 0xa7, 0x20, 0xa2, 0xa4, 0x5d, 0x18, 0xe6, 0x69, 0x57, 0xed, - 0x69, 0x79, 0xc6, 0xb6, 0xdd, 0x82, 0x38, 0x0c, 0x7d, 0xa6, 0xa5, 0x5a, 0x75, 0x27, 0x73, 0x7f, - 0x41, 0xfc, 0x85, 0xcb, 0x00, 0x47, 0x76, 0x8c, 0xf4, 0xf2, 0xaa, 0x93, 0xb2, 0xe3, 0x9d, 0x6c, - 0x7b, 0x27, 0x3b, 0x76, 0x0b, 0xef, 0xe4, 0x35, 0x55, 0xa3, 0x22, 0x67, 0xa1, 0x29, 0x52, 0xfa, - 0x9e, 0x40, 0xa6, 0xad, 0xb4, 0x60, 0x75, 0x1b, 0xc0, 0xc3, 0x6d, 0xd7, 0x3f, 0x31, 0x3d, 0xb0, - 0x70, 0x21, 0x9c, 0x99, 0x97, 0x41, 0x90, 0x6b, 0x0a, 0xc6, 0x5b, 0x01, 0x70, 0xa7, 0x22, 0xe1, - 0x3a, 0x38, 0x7c, 0x78, 0x97, 0xe0, 0xac, 0x1f, 0xae, 0x2b, 0xd4, 0x04, 0x9c, 0xe6, 0xf5, 0x36, - 0xec, 0x82, 0x1b, 0x75, 0xbd, 0x2c, 0x04, 0x3b, 0xc5, 0xdc, 0x99, 0xeb, 0x7a, 0x59, 0x2a, 0xb6, - 0x0a, 0xed, 0x91, 0x5d, 0x11, 0x64, 0x79, 0xbc, 0xb0, 0x31, 0x01, 0xd9, 0x7e, 0xaf, 0x8c, 0xf4, - 0x90, 0xc0, 0x05, 0x7f, 0x91, 0xb5, 0xe6, 0x46, 0x34, 0x13, 0x21, 0xee, 0x9a, 0xd1, 0x0d, 0x02, - 0x13, 0x9d, 0x51, 0x09, 0x21, 0x6a, 0x30, 0xda, 0x04, 0xcb, 0xb7, 0x86, 0xdc, 0x26, 0x98, 0x8b, - 0xa1, 0x8b, 0x2f, 0xbb, 0x10, 0x29, 0xc3, 0x82, 0x6b, 0x77, 0xaf, 0x3d, 0xf6, 0x40, 0xea, 0x40, - 0x32, 0x99, 0xf2, 0x0a, 0x0c, 0xfa, 0xd8, 0x6f, 0xe8, 0xd5, 0x32, 0xdd, 0xe5, 0xe8, 0x4e, 0x16, - 0xd0, 0x37, 0x74, 0xdb, 0x1e, 0x91, 0x1e, 0x75, 0x36, 0xde, 0x53, 0xd8, 0x80, 0x91, 0x30, 0x85, - 0x45, 0xe3, 0xa5, 0x15, 0x78, 0x38, 0x58, 0x60, 0xe9, 0x4b, 0x02, 0x39, 0x3f, 0xb2, 0x9b, 0x62, - 0xb7, 0x7b, 0x4e, 0xdd, 0xf8, 0x84, 0xc0, 0x58, 0x28, 0x20, 0x21, 0x93, 0x06, 0x43, 0x4d, 0x88, - 0xdc, 0xed, 0xd9, 0xed, 0x41, 0x25, 0x86, 0x44, 0xab, 0xe5, 0xb2, 0xe9, 0xe6, 0x15, 0x0a, 0x21, - 0x6b, 0x2b, 0xd8, 0xbd, 0xee, 0xfb, 0x08, 0xce, 0x05, 0x93, 0x4a, 0x26, 0xf2, 0x28, 0xbc, 0xc2, - 0xca, 0x65, 0x93, 0x8f, 0xf7, 0xf2, 0xf1, 0x97, 0xed, 0xbf, 0xed, 0xfd, 0xeb, 0x8b, 0x50, 0x23, - 0x3d, 0xd9, 0x28, 0x0c, 0x06, 0xc8, 0x26, 0x1a, 0x2b, 0xa5, 0x6a, 0x67, 0xda, 0x54, 0x93, 0xbe, - 0x21, 0x70, 0xb1, 0x43, 0xb3, 0x3f, 0xe7, 0xfe, 0xfa, 0x83, 0xc0, 0x4c, 0x3c, 0x74, 0x42, 0xb5, - 0x2a, 0x64, 0xfc, 0x8b, 0x3d, 0x41, 0xbf, 0x05, 0xa6, 0x76, 0x57, 0xa4, 0x11, 0x58, 0xb7, 0x7b, - 0x3d, 0xf7, 0x23, 0x11, 0x5b, 0x5e, 0x37, 0xe4, 0x4f, 0xba, 0xe5, 0xb5, 0xf8, 0x75, 0x22, 0xb5, - 0x5f, 0x4f, 0xdd, 0xad, 0xf3, 0xff, 0x6a, 0xd3, 0xb7, 0x6e, 0x43, 0xae, 0xe8, 0xa6, 0xc5, 0x6a, - 0x7a, 0x49, 0xad, 0xfc, 0x97, 0xd6, 0xcb, 0x33, 0x02, 0xb3, 0x31, 0xe1, 0xbd, 0xe8, 0x4e, 0xfc, - 0x4c, 0x60, 0xb2, 0xbd, 0xd5, 0x96, 0xeb, 0x95, 0x4d, 0xbd, 0x52, 0xa1, 0xe5, 0x3c, 0xb5, 0x5e, - 0x94, 0x45, 0xf3, 0x0b, 0x81, 0xa9, 0x48, 0x26, 0xc2, 0xae, 0x12, 0xf8, 0x91, 0x6c, 0x14, 0xa9, - 0xe5, 0x3a, 0x25, 0xc7, 0x74, 0x2a, 0x4f, 0xad, 0x35, 0x55, 0xaf, 0xb9, 0xdf, 0x04, 0xa3, 0x65, - 0xac, 0x8b, 0x1e, 0x7d, 0x47, 0x60, 0x81, 0x33, 0xbb, 0x47, 0x2d, 0xab, 0x42, 0xcb, 0x21, 0x67, - 0xd6, 0xd5, 0xcd, 0x15, 0xaa, 0x6b, 0x5b, 0x96, 0xeb, 0x97, 0x5f, 0x58, 0x92, 0x56, 0x58, 0x3c, - 0x0f, 0xa7, 0x8a, 0x15, 0x56, 0xda, 0xde, 0xd8, 0xe2, 0xe9, 0x39, 0x93, 0x13, 0x85, 0x01, 0xfe, - 0xce, 0xa9, 0x68, 0x6f, 0x58, 0x97, 0x12, 0x21, 0x14, 0x3e, 0x7c, 0x08, 0xa7, 0xbb, 0x7a, 0xa4, - 0x6e, 0xc9, 0xd6, 0x35, 0x0b, 0x16, 0x9e, 0x0d, 0xc2, 0x4b, 0x9c, 0x20, 0x7e, 0x4e, 0xa0, 0xcf, - 0xb9, 0xb5, 0xe2, 0x4c, 0x38, 0xca, 0xf6, 0xcb, 0x72, 0x76, 0x36, 0xe6, 0x6c, 0xa7, 0xba, 0x74, - 0xee, 0xd3, 0x27, 0xbf, 0x3f, 0xec, 0xcd, 0xe0, 0xd9, 0xc0, 0xff, 0x0b, 0xe0, 0xd7, 0x04, 0xe0, - 0xe8, 0x92, 0x8a, 0x73, 0x11, 0xc9, 0xdb, 0xae, 0xd2, 0xd9, 0xf9, 0x04, 0x11, 0x02, 0xd2, 0x18, - 0x87, 0x34, 0x8a, 0x99, 0x16, 0x48, 0x7b, 0xce, 0x2d, 0x7c, 0x1f, 0x1f, 0x11, 0xe8, 0xf7, 0xe2, - 0x50, 0x89, 0x5b, 0xc1, 0x85, 0x34, 0x17, 0x3f, 0x40, 0x20, 0x9a, 0xe2, 0x88, 0xce, 0xe3, 0x58, - 0x2b, 0x22, 0xff, 0x46, 0xb5, 0x8f, 0x07, 0x04, 0x32, 0x21, 0x4d, 0x89, 0x4b, 0x71, 0xcb, 0x06, - 0x5e, 0x5c, 0xb3, 0xd7, 0xd3, 0x86, 0x0b, 0x0e, 0x97, 0x39, 0x87, 0x39, 0x94, 0x23, 0x38, 0x28, - 0x2d, 0xbd, 0xdd, 0x20, 0x30, 0x1c, 0x9c, 0x1b, 0x17, 0x53, 0x41, 0x72, 0x09, 0x2d, 0xa5, 0x8c, - 0x16, 0x7c, 0xee, 0x70, 0x3e, 0xcb, 0x78, 0x23, 0x19, 0x1f, 0x65, 0x2f, 0xe0, 0xb3, 0xb1, 0x8f, - 0x3f, 0x10, 0xc0, 0xf6, 0x5b, 0x11, 0x5e, 0x8d, 0x8b, 0xb1, 0xf5, 0x24, 0x91, 0xbd, 0x96, 0x22, - 0x52, 0x30, 0x9b, 0xe7, 0xcc, 0x2e, 0xe2, 0xeb, 0x51, 0xcc, 0xbc, 0x8f, 0x3f, 0xfe, 0x44, 0xe0, - 0x4c, 0x5b, 0x46, 0xbc, 0x92, 0x14, 0x83, 0x0b, 0xfe, 0x6a, 0xf2, 0x40, 0x81, 0x7d, 0x91, 0x63, - 0xbf, 0x8c, 0x6f, 0xc6, 0xc6, 0xae, 0xec, 0xb9, 0xd7, 0xae, 0x7d, 0xfc, 0x8b, 0xc0, 0x58, 0xc4, - 0xdd, 0x01, 0x6f, 0xa6, 0x6a, 0x9b, 0x36, 0x7f, 0x96, 0x8f, 0x9b, 0x46, 0x10, 0x7e, 0x8b, 0x13, - 0xbe, 0x86, 0x57, 0x12, 0xb5, 0xe1, 0xec, 0x91, 0x75, 0x7f, 0x12, 0x18, 0x0e, 0xa1, 0xba, 0x18, - 0xbd, 0x95, 0x77, 0x60, 0xb8, 0x94, 0x32, 0x5a, 0x10, 0x5b, 0xe7, 0xc4, 0x56, 0xf1, 0x6e, 0x4a, - 0x62, 0x21, 0x0b, 0xed, 0x1f, 0x02, 0xe3, 0x51, 0xc7, 0x5d, 0x8c, 0x32, 0x27, 0xe6, 0x71, 0x3e, - 0x7b, 0xeb, 0xd8, 0x79, 0x84, 0x18, 0xef, 0x72, 0x31, 0x6e, 0x60, 0x3e, 0x4a, 0x8c, 0x2d, 0x2f, - 0xe3, 0x6c, 0x98, 0xe1, 0x7f, 0x13, 0xc8, 0x86, 0x9f, 0x1d, 0xf1, 0xed, 0x24, 0xb6, 0x05, 0x1d, - 0xa0, 0xb3, 0xef, 0x1c, 0x23, 0x83, 0xe0, 0xfb, 0x01, 0xe7, 0xbb, 0x8e, 0xf7, 0xba, 0xb1, 0xb9, - 0x2a, 0x9b, 0x6e, 0x0d, 0x7e, 0xfe, 0xc5, 0xcf, 0x7a, 0x61, 0x32, 0xde, 0x01, 0x0e, 0xef, 0x44, - 0x50, 0x49, 0x74, 0x52, 0xcd, 0xde, 0xed, 0x52, 0xb6, 0x88, 0xbd, 0xae, 0x45, 0x13, 0xd3, 0xc9, - 0xaa, 0xec, 0x35, 0x9f, 0x6e, 0xf7, 0xf3, 0xcb, 0x8f, 0x0f, 0x73, 0xe4, 0xe0, 0x30, 0x47, 0x7e, - 0x3b, 0xcc, 0x91, 0xaf, 0x1a, 0xb9, 0x9e, 0x83, 0x46, 0xae, 0xe7, 0xd7, 0x46, 0xae, 0xe7, 0xfd, - 0x19, 0x4d, 0xb7, 0xb6, 0xea, 0x45, 0xb9, 0xc4, 0x76, 0xec, 0xcc, 0xb3, 0xcd, 0xbf, 0x9c, 0xec, - 0x36, 0xd5, 0xb1, 0x1e, 0x18, 0xd4, 0x2c, 0xf6, 0xf1, 0x5f, 0x4e, 0x2e, 0xfd, 0x1b, 0x00, 0x00, - 0xff, 0xff, 0x73, 0xdc, 0x46, 0x8f, 0x83, 0x1a, 0x00, 0x00, + proto.RegisterFile("sge/legacy/orderbook/v1beta/query.proto", fileDescriptor_ee861fabfd512297) +} + +var fileDescriptor_ee861fabfd512297 = []byte{ + // 1256 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x59, 0xcd, 0x6f, 0x1b, 0x45, + 0x14, 0xcf, 0x38, 0x25, 0x90, 0xd7, 0xaa, 0x52, 0x5f, 0xd2, 0x38, 0x31, 0xd4, 0x69, 0xb7, 0x55, + 0x52, 0x1a, 0xb2, 0xdb, 0xc4, 0x55, 0x11, 0xb4, 0x28, 0xa9, 0x09, 0x21, 0x2d, 0xad, 0x12, 0x5c, + 0x45, 0x42, 0x70, 0x08, 0x6b, 0x7b, 0xb2, 0x59, 0xe2, 0x78, 0x1c, 0xef, 0x1a, 0x12, 0x45, 0xb9, + 0x20, 0x38, 0xd0, 0x03, 0x42, 0xea, 0x05, 0xf1, 0x21, 0xfe, 0x85, 0xfe, 0x0d, 0x70, 0xa0, 0xe2, + 0x54, 0x09, 0xa9, 0x42, 0x1c, 0x10, 0x24, 0x08, 0x09, 0xb8, 0x71, 0xe1, 0x8a, 0x76, 0x76, 0xd6, + 0xf1, 0xda, 0xeb, 0xfd, 0xca, 0x4a, 0xa5, 0xbd, 0xd9, 0xde, 0x79, 0xef, 0xfd, 0x3e, 0xde, 0xcc, + 0xce, 0x93, 0x61, 0xdc, 0xd0, 0xa8, 0x52, 0xa1, 0x9a, 0x5a, 0xda, 0x56, 0x58, 0xbd, 0x4c, 0xeb, + 0x45, 0xc6, 0xd6, 0x95, 0xf7, 0xa7, 0x8a, 0xd4, 0x54, 0x95, 0xcd, 0x06, 0xad, 0x6f, 0xcb, 0xb5, + 0x3a, 0x33, 0x19, 0x3e, 0x6b, 0x68, 0x54, 0xb6, 0x17, 0xca, 0xcd, 0x85, 0xb2, 0xbd, 0x30, 0x73, + 0xa1, 0xc4, 0x8c, 0x0d, 0x66, 0x28, 0x45, 0xd5, 0xa0, 0x76, 0x94, 0x48, 0x31, 0xa5, 0xd4, 0x54, + 0x4d, 0xaf, 0xaa, 0xa6, 0xce, 0xaa, 0x76, 0xa2, 0xcc, 0xa0, 0xc6, 0x34, 0xc6, 0x3f, 0x2a, 0xd6, + 0x27, 0xf1, 0xeb, 0x73, 0x1a, 0x63, 0x5a, 0x85, 0x2a, 0x6a, 0x4d, 0x57, 0xd4, 0x6a, 0x95, 0x99, + 0x3c, 0xc4, 0x10, 0x4f, 0x2f, 0xf8, 0xa1, 0xa4, 0x5b, 0x35, 0x66, 0x34, 0xea, 0x54, 0xac, 0x9d, + 0xf0, 0x5b, 0x7b, 0x80, 0xdc, 0x5e, 0x7c, 0xde, 0x6f, 0x71, 0x4d, 0xad, 0xab, 0x1b, 0x0e, 0x04, + 0x25, 0x60, 0xa5, 0xa9, 0x97, 0xf4, 0x5a, 0x0b, 0x4f, 0x69, 0x10, 0xf0, 0x4d, 0x4b, 0x89, 0x25, + 0x9e, 0xa5, 0x40, 0x37, 0x1b, 0xd4, 0x30, 0xa5, 0xb7, 0x60, 0xc0, 0xf5, 0xab, 0x51, 0x63, 0x55, + 0x83, 0xe2, 0x35, 0xe8, 0xb3, 0xab, 0x0d, 0x93, 0xd3, 0xe4, 0xfc, 0xd1, 0xe9, 0xb3, 0xb2, 0x8f, + 0xdc, 0xb2, 0x1d, 0x9c, 0x3f, 0x72, 0xff, 0x97, 0xd1, 0x9e, 0x82, 0x08, 0x94, 0xb6, 0x60, 0x88, + 0x67, 0x5e, 0xb4, 0x56, 0xe7, 0x19, 0x5b, 0x77, 0x6a, 0xe2, 0x10, 0xf4, 0x19, 0xa6, 0x6a, 0x36, + 0xec, 0xe4, 0xfd, 0x05, 0xf1, 0x0d, 0xe7, 0x01, 0x0e, 0xdc, 0x19, 0x4e, 0xf1, 0xc2, 0x63, 0xb2, + 0x6d, 0xa5, 0x6c, 0x59, 0x29, 0xdb, 0x0d, 0x20, 0xac, 0x94, 0x97, 0x54, 0x8d, 0x8a, 0x9c, 0x85, + 0x96, 0x48, 0xe9, 0x1e, 0x81, 0x74, 0x47, 0x69, 0x41, 0xec, 0x26, 0x40, 0x13, 0xbe, 0x55, 0xbf, + 0x97, 0xd7, 0xf0, 0x23, 0xd7, 0x4c, 0x22, 0xf8, 0xb5, 0xc4, 0xe3, 0xeb, 0x1e, 0x88, 0xc7, 0x03, + 0x11, 0xdb, 0x50, 0x5c, 0x90, 0x5f, 0x81, 0x93, 0x6e, 0xc4, 0x8e, 0x56, 0xe7, 0xe0, 0x38, 0xaf, + 0xb7, 0x62, 0x15, 0x5c, 0x69, 0xe8, 0x65, 0xa1, 0xd9, 0x31, 0xe6, 0xac, 0x5c, 0xd6, 0xcb, 0x12, + 0x6d, 0xd7, 0xba, 0xc9, 0xf7, 0x0d, 0xc1, 0x97, 0xc7, 0x0b, 0x33, 0xa3, 0xf1, 0xed, 0x6f, 0x56, + 0x92, 0xee, 0x12, 0x38, 0xeb, 0xae, 0xb3, 0xd4, 0xda, 0x68, 0x46, 0x24, 0xd0, 0x89, 0xd9, 0xfd, + 0x07, 0x81, 0x73, 0xfe, 0xa8, 0x84, 0x16, 0x0d, 0x18, 0x69, 0x81, 0xe5, 0xda, 0x23, 0x4e, 0x2b, + 0xe4, 0xc2, 0x49, 0xe3, 0x2a, 0x20, 0x74, 0x4a, 0x33, 0xef, 0xf2, 0xc9, 0x35, 0xc9, 0x0e, 0x48, + 0x3e, 0x3c, 0xa3, 0x89, 0xaf, 0xc0, 0x80, 0x4b, 0x80, 0x15, 0xbd, 0x5a, 0xa6, 0x5b, 0x1c, 0xdd, + 0x91, 0x02, 0xba, 0x1e, 0x5d, 0xb7, 0x9e, 0x48, 0x5f, 0xf8, 0x7b, 0xdf, 0x14, 0xd9, 0x80, 0xe1, + 0x6e, 0x22, 0x8b, 0xf6, 0x3b, 0x84, 0xc6, 0x43, 0xde, 0x1a, 0x4b, 0x9f, 0x12, 0xc8, 0xba, 0xc1, + 0xbd, 0x26, 0x0e, 0xe1, 0x47, 0xd4, 0x93, 0x0f, 0x09, 0x8c, 0x76, 0x05, 0x24, 0x94, 0x7a, 0x0f, + 0x06, 0x5b, 0x10, 0x39, 0x6f, 0x0d, 0xa7, 0x13, 0xa7, 0xc3, 0xa9, 0xb4, 0x58, 0x2e, 0x1b, 0x4e, + 0x6a, 0x21, 0x12, 0xb2, 0x8e, 0x9a, 0xc9, 0xf5, 0xe0, 0xbb, 0x70, 0xca, 0x9b, 0x57, 0x34, 0x9d, + 0x47, 0xe0, 0x19, 0x56, 0x2e, 0x1b, 0xfc, 0x79, 0x8a, 0x3f, 0x7f, 0xda, 0xfa, 0x6e, 0x9d, 0x65, + 0x77, 0xba, 0x7a, 0xd9, 0x54, 0x6e, 0x0d, 0x06, 0x3c, 0x94, 0x13, 0xed, 0x15, 0x5f, 0xb8, 0x13, + 0x1d, 0xc2, 0x49, 0x5f, 0x12, 0x98, 0xf0, 0xe9, 0xfa, 0x47, 0xdc, 0x65, 0x7f, 0x11, 0x78, 0x21, + 0x1c, 0x3a, 0x21, 0xdc, 0x26, 0xa4, 0xdd, 0xbb, 0x3e, 0x5a, 0xd7, 0x79, 0x66, 0x77, 0xb6, 0x66, + 0xcd, 0xb3, 0x74, 0x72, 0x9d, 0xf7, 0x1d, 0x11, 0xc7, 0x5f, 0x12, 0x0e, 0x44, 0x3d, 0xfe, 0xda, + 0x2c, 0xeb, 0x8d, 0x6d, 0xd9, 0x6f, 0xce, 0x31, 0xfa, 0x04, 0x3b, 0xf5, 0x95, 0xd3, 0x96, 0x0b, + 0xba, 0x61, 0xb2, 0xba, 0x5e, 0x52, 0x2b, 0xff, 0xa7, 0x5d, 0xf3, 0x37, 0x81, 0xc9, 0x90, 0xf0, + 0x9e, 0x00, 0x33, 0xbe, 0x27, 0x30, 0xd6, 0xd9, 0x70, 0xf3, 0x8d, 0xca, 0xaa, 0x5e, 0xa9, 0xd0, + 0x72, 0x9e, 0x9a, 0x8f, 0xcb, 0xd6, 0xf9, 0x99, 0xc0, 0x78, 0x20, 0x13, 0xe1, 0xd8, 0x2a, 0xb8, + 0x91, 0xac, 0x14, 0xa9, 0xe9, 0x98, 0x35, 0x15, 0xde, 0xac, 0x3c, 0x35, 0x97, 0x54, 0xbd, 0xee, + 0xbc, 0x1f, 0x6a, 0x6d, 0xcf, 0x12, 0xb4, 0xe9, 0x1b, 0x02, 0xd3, 0x9c, 0xdc, 0x6d, 0x6a, 0x9a, + 0x15, 0x5a, 0xee, 0x72, 0x97, 0x5d, 0x5c, 0x5d, 0xa0, 0xba, 0xb6, 0x66, 0x3a, 0x96, 0xb9, 0xb5, + 0x25, 0x71, 0xb5, 0xc5, 0x33, 0x70, 0xac, 0x58, 0x61, 0xa5, 0xf5, 0x95, 0x35, 0x9e, 0x9e, 0x33, + 0xe9, 0x2d, 0x1c, 0xe5, 0xbf, 0xd9, 0x15, 0xad, 0x93, 0x2b, 0x17, 0x09, 0xa1, 0xb0, 0x42, 0x85, + 0xe3, 0x49, 0x5f, 0xb5, 0xdb, 0x12, 0x26, 0xe6, 0xc2, 0xf4, 0xbd, 0x41, 0x78, 0x8a, 0x73, 0xc4, + 0x3b, 0x04, 0xfa, 0xec, 0xb1, 0x16, 0x15, 0x5f, 0xa0, 0x9d, 0x33, 0x75, 0xe6, 0x62, 0xf8, 0x00, + 0x1b, 0x83, 0x74, 0xea, 0xc3, 0x1f, 0x7f, 0xbf, 0x9b, 0x4a, 0xe3, 0x49, 0x3e, 0xd5, 0x1f, 0x8c, + 0xf3, 0xf6, 0x28, 0x8d, 0x9f, 0x13, 0x80, 0x83, 0x59, 0x16, 0x73, 0xc1, 0xf9, 0x3b, 0x86, 0xee, + 0xcc, 0xa5, 0x68, 0x41, 0x02, 0xd8, 0x28, 0x07, 0x36, 0x82, 0xe9, 0x36, 0x60, 0x3b, 0xf6, 0xc8, + 0xbe, 0x8b, 0x5f, 0x13, 0xe8, 0x6f, 0xc6, 0xe1, 0x74, 0x84, 0x22, 0x0e, 0xb0, 0x5c, 0xa4, 0x18, + 0x81, 0x6b, 0x9c, 0xe3, 0x3a, 0x83, 0xa3, 0xed, 0xb8, 0xdc, 0x07, 0xd8, 0x2e, 0x3e, 0x24, 0x90, + 0xee, 0xd2, 0xa9, 0x38, 0x1b, 0xa1, 0xb2, 0xe7, 0xa0, 0x9b, 0xb9, 0x76, 0x88, 0x0c, 0x82, 0xc9, + 0x65, 0xce, 0xe4, 0x22, 0xca, 0x01, 0x4c, 0x94, 0xb6, 0x9e, 0xff, 0x93, 0xc0, 0x90, 0x77, 0x6e, + 0x9c, 0x89, 0x8b, 0xca, 0xa1, 0x35, 0x1b, 0x3f, 0x81, 0x60, 0x75, 0x93, 0xb3, 0x9a, 0xc7, 0xb9, + 0x68, 0xac, 0x94, 0x1d, 0x8f, 0x57, 0xcb, 0x2e, 0x7e, 0x4b, 0x00, 0x3b, 0x07, 0x29, 0xbc, 0x12, + 0x01, 0x66, 0xfb, 0x9d, 0x23, 0x73, 0x35, 0x5e, 0xb0, 0xe0, 0x37, 0xc5, 0xf9, 0x4d, 0xe0, 0xf3, + 0x41, 0xfc, 0x9a, 0x37, 0x05, 0xfc, 0x81, 0xc0, 0x89, 0x8e, 0x8c, 0xf8, 0x72, 0x0c, 0x18, 0x0e, + 0x85, 0x2b, 0xb1, 0x62, 0x05, 0x83, 0xab, 0x9c, 0xc1, 0x65, 0xbc, 0x14, 0x9a, 0x81, 0xb2, 0xe3, + 0x8c, 0x6c, 0xbb, 0xf8, 0x2f, 0x81, 0xd1, 0x80, 0xa1, 0x03, 0x17, 0xe2, 0x76, 0x51, 0x87, 0x57, + 0xd7, 0x13, 0xc8, 0x24, 0x68, 0xcf, 0x70, 0xda, 0x2f, 0xe1, 0x8b, 0x91, 0x1a, 0x73, 0xf2, 0xc0, + 0xc6, 0x7f, 0x08, 0x0c, 0x75, 0x21, 0x3c, 0x13, 0xea, 0xdc, 0xf7, 0xe1, 0x39, 0x1b, 0x3f, 0x81, + 0xa0, 0xb7, 0xcc, 0xe9, 0x2d, 0xe2, 0xad, 0x98, 0xf4, 0xba, 0x6c, 0xc0, 0x8f, 0x53, 0x70, 0x3a, + 0xe8, 0xb6, 0x8c, 0x21, 0x5c, 0x0a, 0x39, 0x10, 0x64, 0x6e, 0x24, 0x91, 0x4a, 0x48, 0x72, 0x83, + 0x4b, 0x32, 0x87, 0xf9, 0x20, 0x49, 0xd6, 0x9a, 0x19, 0x27, 0xbb, 0x99, 0xff, 0x51, 0x0a, 0x32, + 0xdd, 0x6f, 0x9f, 0xf8, 0x6a, 0x44, 0xff, 0xbc, 0x6e, 0xe1, 0x99, 0xb9, 0xc3, 0x25, 0x11, 0xac, + 0xdf, 0xe1, 0xac, 0x97, 0xf1, 0x76, 0x12, 0x07, 0xb0, 0xb2, 0xea, 0xd4, 0xe0, 0xf7, 0x68, 0xfc, + 0x24, 0x05, 0x63, 0xe1, 0x6e, 0x81, 0xb8, 0x18, 0xcc, 0x26, 0xd2, 0x8d, 0x37, 0xb3, 0x94, 0x5c, + 0xc2, 0x80, 0x93, 0xb0, 0x4d, 0x19, 0xc3, 0xce, 0xaa, 0xec, 0xb4, 0x5e, 0x94, 0x77, 0xf3, 0xb7, + 0xee, 0xef, 0x65, 0xc9, 0x83, 0xbd, 0x2c, 0xf9, 0x75, 0x2f, 0x4b, 0x3e, 0xdb, 0xcf, 0xf6, 0x3c, + 0xd8, 0xcf, 0xf6, 0xfc, 0xb4, 0x9f, 0xed, 0x79, 0x3b, 0xa7, 0xe9, 0xe6, 0x5a, 0xa3, 0x28, 0x97, + 0xd8, 0x86, 0x95, 0x79, 0xb2, 0x4a, 0xcd, 0x0f, 0x58, 0x7d, 0x9d, 0x57, 0xd9, 0xea, 0xfc, 0xeb, + 0xc6, 0xdc, 0xae, 0x51, 0xa3, 0xd8, 0xc7, 0xff, 0xac, 0xc9, 0xfd, 0x17, 0x00, 0x00, 0xff, 0xff, + 0x4c, 0x50, 0x15, 0xd9, 0x08, 0x1b, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1518,7 +1519,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -1527,7 +1528,7 @@ func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts . func (c *queryClient) OrderBooks(ctx context.Context, in *QueryOrderBooksRequest, opts ...grpc.CallOption) (*QueryOrderBooksResponse, error) { out := new(QueryOrderBooksResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/OrderBooks", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/OrderBooks", in, out, opts...) if err != nil { return nil, err } @@ -1536,7 +1537,7 @@ func (c *queryClient) OrderBooks(ctx context.Context, in *QueryOrderBooksRequest func (c *queryClient) OrderBook(ctx context.Context, in *QueryOrderBookRequest, opts ...grpc.CallOption) (*QueryOrderBookResponse, error) { out := new(QueryOrderBookResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/OrderBook", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/OrderBook", in, out, opts...) if err != nil { return nil, err } @@ -1545,7 +1546,7 @@ func (c *queryClient) OrderBook(ctx context.Context, in *QueryOrderBookRequest, func (c *queryClient) OrderBookParticipations(ctx context.Context, in *QueryOrderBookParticipationsRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationsResponse, error) { out := new(QueryOrderBookParticipationsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/OrderBookParticipations", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipations", in, out, opts...) if err != nil { return nil, err } @@ -1554,7 +1555,7 @@ func (c *queryClient) OrderBookParticipations(ctx context.Context, in *QueryOrde func (c *queryClient) OrderBookParticipation(ctx context.Context, in *QueryOrderBookParticipationRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationResponse, error) { out := new(QueryOrderBookParticipationResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/OrderBookParticipation", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipation", in, out, opts...) if err != nil { return nil, err } @@ -1563,7 +1564,7 @@ func (c *queryClient) OrderBookParticipation(ctx context.Context, in *QueryOrder func (c *queryClient) OrderBookExposures(ctx context.Context, in *QueryOrderBookExposuresRequest, opts ...grpc.CallOption) (*QueryOrderBookExposuresResponse, error) { out := new(QueryOrderBookExposuresResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/OrderBookExposures", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/OrderBookExposures", in, out, opts...) if err != nil { return nil, err } @@ -1572,7 +1573,7 @@ func (c *queryClient) OrderBookExposures(ctx context.Context, in *QueryOrderBook func (c *queryClient) OrderBookExposure(ctx context.Context, in *QueryOrderBookExposureRequest, opts ...grpc.CallOption) (*QueryOrderBookExposureResponse, error) { out := new(QueryOrderBookExposureResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/OrderBookExposure", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/OrderBookExposure", in, out, opts...) if err != nil { return nil, err } @@ -1581,7 +1582,7 @@ func (c *queryClient) OrderBookExposure(ctx context.Context, in *QueryOrderBookE func (c *queryClient) OrderBookParticipationExposures(ctx context.Context, in *QueryOrderBookParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryOrderBookParticipationExposuresResponse, error) { out := new(QueryOrderBookParticipationExposuresResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/OrderBookParticipationExposures", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipationExposures", in, out, opts...) if err != nil { return nil, err } @@ -1590,7 +1591,7 @@ func (c *queryClient) OrderBookParticipationExposures(ctx context.Context, in *Q func (c *queryClient) ParticipationExposures(ctx context.Context, in *QueryParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryParticipationExposuresResponse, error) { out := new(QueryParticipationExposuresResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/ParticipationExposures", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/ParticipationExposures", in, out, opts...) if err != nil { return nil, err } @@ -1599,7 +1600,7 @@ func (c *queryClient) ParticipationExposures(ctx context.Context, in *QueryParti func (c *queryClient) HistoricalParticipationExposures(ctx context.Context, in *QueryHistoricalParticipationExposuresRequest, opts ...grpc.CallOption) (*QueryHistoricalParticipationExposuresResponse, error) { out := new(QueryHistoricalParticipationExposuresResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/HistoricalParticipationExposures", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/HistoricalParticipationExposures", in, out, opts...) if err != nil { return nil, err } @@ -1608,7 +1609,7 @@ func (c *queryClient) HistoricalParticipationExposures(ctx context.Context, in * func (c *queryClient) ParticipationFulfilledBets(ctx context.Context, in *QueryParticipationFulfilledBetsRequest, opts ...grpc.CallOption) (*QueryParticipationFulfilledBetsResponse, error) { out := new(QueryParticipationFulfilledBetsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/ParticipationFulfilledBets", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/ParticipationFulfilledBets", in, out, opts...) if err != nil { return nil, err } @@ -1617,7 +1618,7 @@ func (c *queryClient) ParticipationFulfilledBets(ctx context.Context, in *QueryP func (c *queryClient) SettledOrderBookParticipationsOfHeight(ctx context.Context, in *QuerySettledOrderBookParticipationsOfHeightRequest, opts ...grpc.CallOption) (*QuerySettledOrderBookParticipationsOfHeightResponse, error) { out := new(QuerySettledOrderBookParticipationsOfHeightResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Query/SettledOrderBookParticipationsOfHeight", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Query/SettledOrderBookParticipationsOfHeight", in, out, opts...) if err != nil { return nil, err } @@ -1714,7 +1715,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/Params", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -1732,7 +1733,7 @@ func _Query_OrderBooks_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/OrderBooks", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/OrderBooks", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).OrderBooks(ctx, req.(*QueryOrderBooksRequest)) @@ -1750,7 +1751,7 @@ func _Query_OrderBook_Handler(srv interface{}, ctx context.Context, dec func(int } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/OrderBook", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/OrderBook", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).OrderBook(ctx, req.(*QueryOrderBookRequest)) @@ -1768,7 +1769,7 @@ func _Query_OrderBookParticipations_Handler(srv interface{}, ctx context.Context } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/OrderBookParticipations", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipations", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).OrderBookParticipations(ctx, req.(*QueryOrderBookParticipationsRequest)) @@ -1786,7 +1787,7 @@ func _Query_OrderBookParticipation_Handler(srv interface{}, ctx context.Context, } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/OrderBookParticipation", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipation", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).OrderBookParticipation(ctx, req.(*QueryOrderBookParticipationRequest)) @@ -1804,7 +1805,7 @@ func _Query_OrderBookExposures_Handler(srv interface{}, ctx context.Context, dec } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/OrderBookExposures", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/OrderBookExposures", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).OrderBookExposures(ctx, req.(*QueryOrderBookExposuresRequest)) @@ -1822,7 +1823,7 @@ func _Query_OrderBookExposure_Handler(srv interface{}, ctx context.Context, dec } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/OrderBookExposure", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/OrderBookExposure", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).OrderBookExposure(ctx, req.(*QueryOrderBookExposureRequest)) @@ -1840,7 +1841,7 @@ func _Query_OrderBookParticipationExposures_Handler(srv interface{}, ctx context } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/OrderBookParticipationExposures", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/OrderBookParticipationExposures", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).OrderBookParticipationExposures(ctx, req.(*QueryOrderBookParticipationExposuresRequest)) @@ -1858,7 +1859,7 @@ func _Query_ParticipationExposures_Handler(srv interface{}, ctx context.Context, } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/ParticipationExposures", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/ParticipationExposures", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ParticipationExposures(ctx, req.(*QueryParticipationExposuresRequest)) @@ -1876,7 +1877,7 @@ func _Query_HistoricalParticipationExposures_Handler(srv interface{}, ctx contex } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/HistoricalParticipationExposures", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/HistoricalParticipationExposures", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).HistoricalParticipationExposures(ctx, req.(*QueryHistoricalParticipationExposuresRequest)) @@ -1894,7 +1895,7 @@ func _Query_ParticipationFulfilledBets_Handler(srv interface{}, ctx context.Cont } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/ParticipationFulfilledBets", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/ParticipationFulfilledBets", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ParticipationFulfilledBets(ctx, req.(*QueryParticipationFulfilledBetsRequest)) @@ -1912,7 +1913,7 @@ func _Query_SettledOrderBookParticipationsOfHeight_Handler(srv interface{}, ctx } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Query/SettledOrderBookParticipationsOfHeight", + FullMethod: "/sge.legacy.orderbook.v1beta.Query/SettledOrderBookParticipationsOfHeight", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).SettledOrderBookParticipationsOfHeight(ctx, req.(*QuerySettledOrderBookParticipationsOfHeightRequest)) @@ -1920,8 +1921,9 @@ func _Query_SettledOrderBookParticipationsOfHeight_Handler(srv interface{}, ctx return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.orderbook.Query", + ServiceName: "sge.legacy.orderbook.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -1974,7 +1976,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/orderbook/query.proto", + Metadata: "sge/legacy/orderbook/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/types/query.pb.gw.go b/x/legacy/orderbook/types/query.pb.gw.go similarity index 99% rename from x/orderbook/types/query.pb.gw.go rename to x/legacy/orderbook/types/query.pb.gw.go index 3c5b3495..40c6e4e2 100644 --- a/x/orderbook/types/query.pb.gw.go +++ b/x/legacy/orderbook/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/query.proto +// source: sge/legacy/orderbook/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/orderbook/types/stats.pb.go b/x/legacy/orderbook/types/stats.pb.go similarity index 82% rename from x/orderbook/types/stats.pb.go rename to x/legacy/orderbook/types/stats.pb.go index ca757d8f..153bf3f6 100644 --- a/x/orderbook/types/stats.pb.go +++ b/x/legacy/orderbook/types/stats.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/stats.proto +// source: sge/legacy/orderbook/v1beta/stats.proto package types @@ -33,7 +33,7 @@ func (m *OrderBookStats) Reset() { *m = OrderBookStats{} } func (m *OrderBookStats) String() string { return proto.CompactTextString(m) } func (*OrderBookStats) ProtoMessage() {} func (*OrderBookStats) Descriptor() ([]byte, []int) { - return fileDescriptor_3f23c49f1ff7e427, []int{0} + return fileDescriptor_997c9300ade81ee8, []int{0} } func (m *OrderBookStats) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -70,27 +70,28 @@ func (m *OrderBookStats) GetResolvedUnsettled() []string { } func init() { - proto.RegisterType((*OrderBookStats)(nil), "sgenetwork.sge.orderbook.OrderBookStats") + proto.RegisterType((*OrderBookStats)(nil), "sge.legacy.orderbook.v1beta.OrderBookStats") } func init() { - proto.RegisterFile("sgenetwork/sge/orderbook/stats.proto", fileDescriptor_3f23c49f1ff7e427) + proto.RegisterFile("sge/legacy/orderbook/v1beta/stats.proto", fileDescriptor_997c9300ade81ee8) } -var fileDescriptor_3f23c49f1ff7e427 = []byte{ - // 180 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x29, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0x4a, 0x49, 0x2d, - 0x4a, 0xca, 0xcf, 0xcf, 0xd6, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, - 0x17, 0x92, 0x40, 0xa8, 0xd2, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0xab, 0x52, 0xb2, 0xe7, 0xe2, 0xf3, - 0x07, 0x71, 0x9c, 0xf2, 0xf3, 0xb3, 0x83, 0x41, 0x3a, 0x84, 0x74, 0xb9, 0x84, 0x8a, 0x52, 0x8b, - 0xf3, 0x73, 0xca, 0x52, 0x53, 0xe2, 0x4b, 0xf3, 0x8a, 0x53, 0x4b, 0x4a, 0x72, 0x52, 0x53, 0x24, - 0x18, 0x15, 0x98, 0x35, 0x38, 0x83, 0x04, 0x61, 0x32, 0xa1, 0x30, 0x09, 0x27, 0xb7, 0x13, 0x8f, - 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, - 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0xd2, 0x49, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, - 0x4b, 0xce, 0xcf, 0x05, 0x39, 0x4d, 0x17, 0xd9, 0x99, 0x15, 0x48, 0x0e, 0x2d, 0xa9, 0x2c, 0x48, - 0x2d, 0x4e, 0x62, 0x03, 0xbb, 0xd4, 0x18, 0x10, 0x00, 0x00, 0xff, 0xff, 0x7b, 0xf6, 0xfd, 0x77, - 0xd1, 0x00, 0x00, 0x00, +var fileDescriptor_997c9300ade81ee8 = []byte{ + // 196 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2f, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x2f, 0x4a, 0x49, 0x2d, 0x4a, 0xca, 0xcf, 0xcf, + 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, + 0xca, 0x2f, 0xc9, 0x17, 0x92, 0x2e, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd4, 0x83, 0x2b, 0xd4, 0x83, + 0x28, 0x54, 0xb2, 0xe7, 0xe2, 0xf3, 0x07, 0x89, 0x39, 0xe5, 0xe7, 0x67, 0x07, 0x83, 0x34, 0x09, + 0xe9, 0x72, 0x09, 0x15, 0xa5, 0x16, 0xe7, 0xe7, 0x94, 0xa5, 0xa6, 0xc4, 0x97, 0xe6, 0x15, 0xa7, + 0x96, 0x94, 0xe4, 0xa4, 0xa6, 0x48, 0x30, 0x2a, 0x30, 0x6b, 0x70, 0x06, 0x09, 0xc2, 0x64, 0x42, + 0x61, 0x12, 0x4e, 0xbe, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, + 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0x65, 0x9c, + 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0xab, 0x5f, 0x9c, 0x9e, 0xaa, 0x9b, 0x97, + 0x5a, 0x52, 0x9e, 0x5f, 0x94, 0x0d, 0x62, 0xeb, 0x57, 0x60, 0xba, 0xbc, 0xa4, 0xb2, 0x20, 0xb5, + 0x38, 0x89, 0x0d, 0xec, 0x66, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0xdc, 0xab, 0x83, 0xd9, + 0xde, 0x00, 0x00, 0x00, } func (m *OrderBookStats) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/types/tx.pb.go b/x/legacy/orderbook/types/tx.pb.go similarity index 81% rename from x/orderbook/types/tx.pb.go rename to x/legacy/orderbook/types/tx.pb.go index d3cdb026..f818836f 100644 --- a/x/orderbook/types/tx.pb.go +++ b/x/legacy/orderbook/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/orderbook/tx.proto +// source: sge/legacy/orderbook/v1beta/tx.proto package types @@ -44,7 +44,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_40bc64b0300596fa, []int{0} + return fileDescriptor_3ce4fe93ba61e862, []int{0} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -96,7 +96,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_40bc64b0300596fa, []int{1} + return fileDescriptor_3ce4fe93ba61e862, []int{1} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -126,37 +126,40 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.orderbook.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.orderbook.MsgUpdateParamsResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/orderbook/tx.proto", fileDescriptor_40bc64b0300596fa) } - -var fileDescriptor_40bc64b0300596fa = []byte{ - // 365 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0x4a, 0x49, 0x2d, - 0x4a, 0xca, 0xcf, 0xcf, 0xd6, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x92, 0x40, - 0x28, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0x2b, 0x91, 0x12, 0x4c, 0xcc, 0xcd, 0xcc, 0xcb, 0xd7, - 0x07, 0x93, 0x10, 0xc5, 0x52, 0xe2, 0xc9, 0xf9, 0xc5, 0xb9, 0xf9, 0xc5, 0xfa, 0xb9, 0xc5, 0xe9, - 0xfa, 0x65, 0x86, 0x20, 0x0a, 0x2a, 0x21, 0x09, 0x91, 0x88, 0x07, 0xf3, 0xf4, 0x21, 0x1c, 0xa8, - 0x94, 0x48, 0x7a, 0x7e, 0x7a, 0x3e, 0x44, 0x1c, 0xc4, 0x82, 0x8a, 0xaa, 0xe2, 0x74, 0x59, 0x41, - 0x62, 0x51, 0x62, 0x2e, 0x54, 0xb3, 0xd2, 0x66, 0x46, 0x2e, 0x7e, 0xdf, 0xe2, 0xf4, 0xd0, 0x82, - 0x94, 0xc4, 0x92, 0xd4, 0x00, 0xb0, 0x8c, 0x90, 0x19, 0x17, 0x67, 0x62, 0x69, 0x49, 0x46, 0x7e, - 0x51, 0x66, 0x49, 0xa5, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xa7, 0x93, 0xc4, 0xa5, 0x2d, 0xba, 0x22, - 0x50, 0x5b, 0x1d, 0x53, 0x52, 0x8a, 0x52, 0x8b, 0x8b, 0x83, 0x4b, 0x8a, 0x32, 0xf3, 0xd2, 0x83, - 0x10, 0x4a, 0x85, 0x9c, 0xb9, 0xd8, 0x20, 0x66, 0x4b, 0x30, 0x29, 0x30, 0x6a, 0x70, 0x1b, 0x29, - 0xe8, 0xe1, 0xf2, 0xba, 0x1e, 0xc4, 0x26, 0x27, 0xce, 0x13, 0xf7, 0xe4, 0x19, 0x56, 0x3c, 0xdf, - 0xa0, 0xc5, 0x18, 0x04, 0xd5, 0x6a, 0xa5, 0x7c, 0x69, 0x8b, 0xae, 0x60, 0x71, 0x7a, 0xaa, 0x2e, - 0x54, 0xa3, 0x82, 0xa1, 0x9e, 0xb9, 0x9e, 0x61, 0xd3, 0xf3, 0x0d, 0x5a, 0x08, 0x9b, 0x94, 0x0c, - 0xb8, 0xc4, 0xd1, 0x1c, 0x1d, 0x94, 0x5a, 0x5c, 0x90, 0x9f, 0x57, 0x9c, 0x6a, 0x25, 0x8a, 0x55, - 0xbf, 0x51, 0x1f, 0x23, 0x17, 0xb3, 0x6f, 0x71, 0xba, 0x50, 0x1b, 0x23, 0x17, 0x0f, 0x8a, 0x67, - 0x35, 0x71, 0x3b, 0x12, 0xcd, 0x0a, 0x29, 0x43, 0xa2, 0x95, 0xc2, 0x5c, 0xa3, 0x24, 0x71, 0x0a, - 0x9b, 0x6b, 0x3a, 0x98, 0x18, 0x9d, 0xdc, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, - 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, - 0x21, 0x4a, 0x27, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x1f, 0x49, 0x2b, - 0x38, 0x16, 0x2b, 0x90, 0x53, 0x58, 0x65, 0x41, 0x6a, 0x71, 0x12, 0x1b, 0x38, 0x1e, 0x8d, 0x01, - 0x01, 0x00, 0x00, 0xff, 0xff, 0xce, 0x2b, 0x0f, 0x62, 0x8a, 0x02, 0x00, 0x00, + proto.RegisterType((*MsgUpdateParams)(nil), "sge.legacy.orderbook.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.legacy.orderbook.v1beta.MsgUpdateParamsResponse") +} + +func init() { + proto.RegisterFile("sge/legacy/orderbook/v1beta/tx.proto", fileDescriptor_3ce4fe93ba61e862) +} + +var fileDescriptor_3ce4fe93ba61e862 = []byte{ + // 377 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x29, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x2f, 0x4a, 0x49, 0x2d, 0x4a, 0xca, 0xcf, 0xcf, + 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, + 0x17, 0x92, 0x2e, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0xd2, 0x83, 0xab, 0xd2, 0x83, 0xa8, 0x92, 0x12, + 0x4c, 0xcc, 0xcd, 0xcc, 0xcb, 0xd7, 0x07, 0x93, 0x10, 0xf5, 0x52, 0xe2, 0xc9, 0xf9, 0xc5, 0xb9, + 0xf9, 0xc5, 0xfa, 0xb9, 0xc5, 0xe9, 0xfa, 0x65, 0x86, 0x20, 0x0a, 0x2a, 0x21, 0x09, 0x91, 0x88, + 0x07, 0xf3, 0xf4, 0x21, 0x1c, 0xa8, 0x94, 0x48, 0x7a, 0x7e, 0x7a, 0x3e, 0x44, 0x1c, 0xc4, 0x82, + 0x8a, 0x6a, 0xe0, 0x73, 0x5f, 0x41, 0x62, 0x51, 0x62, 0x2e, 0x54, 0xbf, 0xd2, 0x36, 0x46, 0x2e, + 0x7e, 0xdf, 0xe2, 0xf4, 0xd0, 0x82, 0x94, 0xc4, 0x92, 0xd4, 0x00, 0xb0, 0x8c, 0x90, 0x19, 0x17, + 0x67, 0x62, 0x69, 0x49, 0x46, 0x7e, 0x51, 0x66, 0x49, 0xa5, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xa7, + 0x93, 0xc4, 0xa5, 0x2d, 0xba, 0x22, 0x50, 0x8b, 0x1d, 0x53, 0x52, 0x8a, 0x52, 0x8b, 0x8b, 0x83, + 0x4b, 0x8a, 0x32, 0xf3, 0xd2, 0x83, 0x10, 0x4a, 0x85, 0xdc, 0xb8, 0xd8, 0x20, 0x66, 0x4b, 0x30, + 0x29, 0x30, 0x6a, 0x70, 0x1b, 0x29, 0xeb, 0xe1, 0x09, 0x00, 0x3d, 0x88, 0x65, 0x4e, 0x9c, 0x27, + 0xee, 0xc9, 0x33, 0xac, 0x78, 0xbe, 0x41, 0x8b, 0x31, 0x08, 0xaa, 0xdb, 0x4a, 0xf9, 0xd2, 0x16, + 0x5d, 0xc1, 0xe2, 0xf4, 0x54, 0xdd, 0xbc, 0xd4, 0x92, 0xf2, 0xfc, 0xa2, 0x6c, 0x05, 0x43, 0x3d, + 0x73, 0x3d, 0xc3, 0xa6, 0xe7, 0x1b, 0xb4, 0x10, 0x96, 0x29, 0x19, 0x70, 0x89, 0xa3, 0xb9, 0x3b, + 0x28, 0xb5, 0xb8, 0x20, 0x3f, 0xaf, 0x38, 0xd5, 0x4a, 0x14, 0xab, 0x7e, 0xa3, 0x29, 0x8c, 0x5c, + 0xcc, 0xbe, 0xc5, 0xe9, 0x42, 0x3d, 0x8c, 0x5c, 0x3c, 0x28, 0xfe, 0xd5, 0xc1, 0xeb, 0x4e, 0x34, + 0x5b, 0xa4, 0x4c, 0x48, 0x51, 0x0d, 0x73, 0x93, 0x92, 0xc4, 0x29, 0x6c, 0x6e, 0xea, 0x60, 0x62, + 0x74, 0xf2, 0x3d, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, + 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xe3, 0xf4, 0xcc, + 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x7d, 0x24, 0xad, 0x20, 0xb6, 0x7e, 0x05, 0x66, + 0xf4, 0x96, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, 0x81, 0xe3, 0xd5, 0x18, 0x10, 0x00, 0x00, 0xff, + 0xff, 0x68, 0xd3, 0xa2, 0x4f, 0xa3, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -187,7 +190,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { // Deprecated: Do not use. func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.orderbook.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.orderbook.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -223,7 +226,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.orderbook.Msg/UpdateParams", + FullMethod: "/sge.legacy.orderbook.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -231,8 +234,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.orderbook.Msg", + ServiceName: "sge.legacy.orderbook.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -241,7 +245,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/orderbook/tx.proto", + Metadata: "sge/legacy/orderbook/v1beta/tx.proto", } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/abci.go b/x/legacy/ovm/abci.go similarity index 86% rename from x/ovm/abci.go rename to x/legacy/ovm/abci.go index 2319ff66..bd6c2b32 100644 --- a/x/ovm/abci.go +++ b/x/legacy/ovm/abci.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/keeper" + "github.com/sge-network/sge/x/legacy/ovm/keeper" ) // EndBlocker settles the active bets of resolved markets diff --git a/x/ovm/client/cli/query.go b/x/legacy/ovm/client/cli/query.go similarity index 92% rename from x/ovm/client/cli/query.go rename to x/legacy/ovm/client/cli/query.go index ad85861d..893803bb 100644 --- a/x/ovm/client/cli/query.go +++ b/x/legacy/ovm/client/cli/query.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // GetQueryCmd returns the cli query commands for this module diff --git a/x/house/client/cli/query_params.go b/x/legacy/ovm/client/cli/query_params.go similarity index 93% rename from x/house/client/cli/query_params.go rename to x/legacy/ovm/client/cli/query_params.go index 9815995f..a665d816 100644 --- a/x/house/client/cli/query_params.go +++ b/x/legacy/ovm/client/cli/query_params.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/house/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // CmdQueryParams returns a command object instance for module params diff --git a/x/ovm/client/cli/query_proposal.go b/x/legacy/ovm/client/cli/query_proposal.go similarity index 97% rename from x/ovm/client/cli/query_proposal.go rename to x/legacy/ovm/client/cli/query_proposal.go index ee012715..ac3fe39a 100644 --- a/x/ovm/client/cli/query_proposal.go +++ b/x/legacy/ovm/client/cli/query_proposal.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) var _ = strconv.Itoa(0) diff --git a/x/ovm/client/cli/query_pub_keys.go b/x/legacy/ovm/client/cli/query_pub_keys.go similarity index 94% rename from x/ovm/client/cli/query_pub_keys.go rename to x/legacy/ovm/client/cli/query_pub_keys.go index 23034ce2..4c3cbead 100644 --- a/x/ovm/client/cli/query_pub_keys.go +++ b/x/legacy/ovm/client/cli/query_pub_keys.go @@ -6,7 +6,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // CmdPubKeysList returns a command object instance for querying the public keys diff --git a/x/ovm/client/cli/tx.go b/x/legacy/ovm/client/cli/tx.go similarity index 92% rename from x/ovm/client/cli/tx.go rename to x/legacy/ovm/client/cli/tx.go index c495abe5..a0e3bc52 100644 --- a/x/ovm/client/cli/tx.go +++ b/x/legacy/ovm/client/cli/tx.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // GetTxCmd returns the transaction commands for this module diff --git a/x/ovm/client/cli/tx_pubkeys_proposal.go b/x/legacy/ovm/client/cli/tx_pubkeys_proposal.go similarity index 95% rename from x/ovm/client/cli/tx_pubkeys_proposal.go rename to x/legacy/ovm/client/cli/tx_pubkeys_proposal.go index ef75a71c..dec415f8 100644 --- a/x/ovm/client/cli/tx_pubkeys_proposal.go +++ b/x/legacy/ovm/client/cli/tx_pubkeys_proposal.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // CmdChangePubkeysListProposal is the command object for change of public keys diff --git a/x/ovm/client/cli/tx_pubkeys_vote.go b/x/legacy/ovm/client/cli/tx_pubkeys_vote.go similarity index 95% rename from x/ovm/client/cli/tx_pubkeys_vote.go rename to x/legacy/ovm/client/cli/tx_pubkeys_vote.go index 1aa1ab61..7b892fb6 100644 --- a/x/ovm/client/cli/tx_pubkeys_vote.go +++ b/x/legacy/ovm/client/cli/tx_pubkeys_vote.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) var _ = strconv.Itoa(0) diff --git a/x/ovm/genesis.go b/x/legacy/ovm/genesis.go similarity index 92% rename from x/ovm/genesis.go rename to x/legacy/ovm/genesis.go index 5b2ce56b..e0d3db16 100644 --- a/x/ovm/genesis.go +++ b/x/legacy/ovm/genesis.go @@ -3,8 +3,8 @@ package ovm import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/keeper" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/keeper" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // InitGenesis initializes the module's state from a provided genesis diff --git a/x/market/keeper/export_test.go b/x/legacy/ovm/keeper/export_test.go similarity index 100% rename from x/market/keeper/export_test.go rename to x/legacy/ovm/keeper/export_test.go diff --git a/x/market/keeper/grpc_query.go b/x/legacy/ovm/keeper/grpc_query.go similarity index 56% rename from x/market/keeper/grpc_query.go rename to x/legacy/ovm/keeper/grpc_query.go index 397279ce..e1d101ef 100644 --- a/x/market/keeper/grpc_query.go +++ b/x/legacy/ovm/keeper/grpc_query.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) var _ types.QueryServer = Keeper{} diff --git a/x/ovm/keeper/grpc_query_params.go b/x/legacy/ovm/keeper/grpc_query_params.go similarity index 91% rename from x/ovm/keeper/grpc_query_params.go rename to x/legacy/ovm/keeper/grpc_query_params.go index 69b9001f..3de5edeb 100644 --- a/x/ovm/keeper/grpc_query_params.go +++ b/x/legacy/ovm/keeper/grpc_query_params.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // Params returns the params of the module diff --git a/x/ovm/keeper/grpc_query_pubkeys.go b/x/legacy/ovm/keeper/grpc_query_pubkeys.go similarity index 92% rename from x/ovm/keeper/grpc_query_pubkeys.go rename to x/legacy/ovm/keeper/grpc_query_pubkeys.go index 740c3ff8..95228f77 100644 --- a/x/ovm/keeper/grpc_query_pubkeys.go +++ b/x/legacy/ovm/keeper/grpc_query_pubkeys.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // PubKeys returns list of the public keys diff --git a/x/ovm/keeper/grpc_query_pubkeys_proposal.go b/x/legacy/ovm/keeper/grpc_query_pubkeys_proposal.go similarity index 95% rename from x/ovm/keeper/grpc_query_pubkeys_proposal.go rename to x/legacy/ovm/keeper/grpc_query_pubkeys_proposal.go index 572df1a9..30d3cfb7 100644 --- a/x/ovm/keeper/grpc_query_pubkeys_proposal.go +++ b/x/legacy/ovm/keeper/grpc_query_pubkeys_proposal.go @@ -6,12 +6,12 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // PublicKeysChangeProposal returns a specific proposal by its id and status diff --git a/x/ovm/keeper/keeper.go b/x/legacy/ovm/keeper/keeper.go similarity index 89% rename from x/ovm/keeper/keeper.go rename to x/legacy/ovm/keeper/keeper.go index 65d82622..c965f8d2 100644 --- a/x/ovm/keeper/keeper.go +++ b/x/legacy/ovm/keeper/keeper.go @@ -3,14 +3,14 @@ package keeper import ( "fmt" + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/log" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // Keeper is the type for module properties diff --git a/x/ovm/keeper/key_vault.go b/x/legacy/ovm/keeper/key_vault.go similarity index 92% rename from x/ovm/keeper/key_vault.go rename to x/legacy/ovm/keeper/key_vault.go index 65fe7451..64fdaae7 100644 --- a/x/ovm/keeper/key_vault.go +++ b/x/legacy/ovm/keeper/key_vault.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // SetKeyVault sets the key vault and overwrite the old values. diff --git a/x/bet/keeper/msg_server.go b/x/legacy/ovm/keeper/msg_server.go similarity index 85% rename from x/bet/keeper/msg_server.go rename to x/legacy/ovm/keeper/msg_server.go index 52402959..afbc491d 100644 --- a/x/bet/keeper/msg_server.go +++ b/x/legacy/ovm/keeper/msg_server.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) type msgServer struct { diff --git a/x/bet/keeper/msg_server_params.go b/x/legacy/ovm/keeper/msg_server_params.go similarity index 93% rename from x/bet/keeper/msg_server_params.go rename to x/legacy/ovm/keeper/msg_server_params.go index d3be132e..0c80fce6 100644 --- a/x/bet/keeper/msg_server_params.go +++ b/x/legacy/ovm/keeper/msg_server_params.go @@ -7,7 +7,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { diff --git a/x/ovm/keeper/msg_server_pubkeys_proposal.go b/x/legacy/ovm/keeper/msg_server_pubkeys_proposal.go similarity index 96% rename from x/ovm/keeper/msg_server_pubkeys_proposal.go rename to x/legacy/ovm/keeper/msg_server_pubkeys_proposal.go index 334b4b3e..839dab88 100644 --- a/x/ovm/keeper/msg_server_pubkeys_proposal.go +++ b/x/legacy/ovm/keeper/msg_server_pubkeys_proposal.go @@ -8,7 +8,7 @@ import ( sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // SubmitPubkeysChangeProposal is the main transaction of OVM to add or delete the keys to the chain. diff --git a/x/ovm/keeper/msg_server_vote.go b/x/legacy/ovm/keeper/msg_server_vote.go similarity index 98% rename from x/ovm/keeper/msg_server_vote.go rename to x/legacy/ovm/keeper/msg_server_vote.go index 86c0e2ab..e536effe 100644 --- a/x/ovm/keeper/msg_server_vote.go +++ b/x/legacy/ovm/keeper/msg_server_vote.go @@ -9,7 +9,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // VotePubkeysChange is the main transaction of OVM to vote for a pubkeys list change proposal. diff --git a/x/market/keeper/params.go b/x/legacy/ovm/keeper/params.go similarity index 88% rename from x/market/keeper/params.go rename to x/legacy/ovm/keeper/params.go index dcae921d..36d76c52 100644 --- a/x/market/keeper/params.go +++ b/x/legacy/ovm/keeper/params.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/market/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // GetParams get all parameters as types.Params diff --git a/x/ovm/keeper/proposal.go b/x/legacy/ovm/keeper/proposal.go similarity index 95% rename from x/ovm/keeper/proposal.go rename to x/legacy/ovm/keeper/proposal.go index 9cd0c2e9..24273ace 100644 --- a/x/ovm/keeper/proposal.go +++ b/x/legacy/ovm/keeper/proposal.go @@ -3,9 +3,10 @@ package keeper import ( "fmt" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // SetPubkeysChangeProposal sets a pubkey list change proposal in the store. @@ -38,7 +39,7 @@ func (k Keeper) GetAllPubkeysChangeProposalsByStatus( status types.ProposalStatus, ) (list []types.PublicKeysChangeProposal, err error) { store := k.getPubKeysChangeProposalStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, types.PubkeysChangeProposalPrefix(status)) + iterator := storetypes.KVStorePrefixIterator(store, types.PubkeysChangeProposalPrefix(status)) defer func() { err = iterator.Close() @@ -58,7 +59,7 @@ func (k Keeper) GetAllPubkeysChangeProposals( ctx sdk.Context, ) (list []types.PublicKeysChangeProposal, err error) { store := k.getPubKeysChangeProposalStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer func() { err = iterator.Close() diff --git a/x/ovm/keeper/stats.go b/x/legacy/ovm/keeper/stats.go similarity index 92% rename from x/ovm/keeper/stats.go rename to x/legacy/ovm/keeper/stats.go index afb4e1b3..7f56d85c 100644 --- a/x/ovm/keeper/stats.go +++ b/x/legacy/ovm/keeper/stats.go @@ -4,7 +4,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // SetProposalStats sets proposal statistics in the store diff --git a/x/ovm/keeper/ticket.go b/x/legacy/ovm/keeper/ticket.go similarity index 98% rename from x/ovm/keeper/ticket.go rename to x/legacy/ovm/keeper/ticket.go index 250c98a1..20f8c0b8 100644 --- a/x/ovm/keeper/ticket.go +++ b/x/legacy/ovm/keeper/ticket.go @@ -6,7 +6,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // VerifyTicket validates a ticket. diff --git a/x/ovm/keeper/view.go b/x/legacy/ovm/keeper/view.go similarity index 90% rename from x/ovm/keeper/view.go rename to x/legacy/ovm/keeper/view.go index 9852757e..7d18e7cf 100644 --- a/x/ovm/keeper/view.go +++ b/x/legacy/ovm/keeper/view.go @@ -1,10 +1,10 @@ package keeper import ( - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // getPubKeysChangeProposalStore returns pubkeys list change store ready for iterating. diff --git a/x/ovm/module.go b/x/legacy/ovm/module.go similarity index 90% rename from x/ovm/module.go rename to x/legacy/ovm/module.go index eca41c83..a07eb2fb 100644 --- a/x/ovm/module.go +++ b/x/legacy/ovm/module.go @@ -18,9 +18,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/ovm/client/cli" - "github.com/sge-network/sge/x/ovm/keeper" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/client/cli" + "github.com/sge-network/sge/x/legacy/ovm/keeper" + "github.com/sge-network/sge/x/legacy/ovm/types" ) var ( @@ -110,8 +110,8 @@ func NewAppModule( keeper keeper.Keeper, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, -) AppModule { - return AppModule{ +) *AppModule { + return &AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, accountKeeper: accountKeeper, @@ -119,6 +119,12 @@ func NewAppModule( } } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} + +// IsOnePerModuleType is a marker function just indicates that this is a one-per-module type. +func (am AppModule) IsOnePerModuleType() {} + // Name returns the module's name. func (am AppModule) Name() string { return am.AppModuleBasic.Name() } @@ -164,13 +170,12 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock executes all ABCI BeginBlock logic respective to the module. -func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} +func (AppModule) BeginBlock(_ sdk.Context) {} // EndBlock executes all ABCI EndBlock logic respective to the module. It // returns no validator updates. -func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { - // end blocker deprecated in favor of v2 - // EndBlocker(ctx, am.keeper) +func (am AppModule) EndBlock(ctx sdk.Context) []abci.ValidatorUpdate { + EndBlocker(ctx, am.keeper) return []abci.ValidatorUpdate{} } diff --git a/x/ovm/module_simulation.go b/x/legacy/ovm/module_simulation.go similarity index 89% rename from x/ovm/module_simulation.go rename to x/legacy/ovm/module_simulation.go index a198605f..03ff587a 100644 --- a/x/ovm/module_simulation.go +++ b/x/legacy/ovm/module_simulation.go @@ -6,14 +6,13 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/sge-network/sge/testutil/sample" - ovmsimulation "github.com/sge-network/sge/x/ovm/simulation" - "github.com/sge-network/sge/x/ovm/types" + ovmsimulation "github.com/sge-network/sge/x/legacy/ovm/simulation" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // avoid unused import issue @@ -43,7 +42,7 @@ func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedP } // RegisterStoreDecoder registers a decoder -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { sdr[types.StoreKey] = ovmsimulation.NewDecodeStore(am.cdc) } @@ -53,7 +52,6 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp var weightMsgChangePubkeysListProposal int simState.AppParams.GetOrGenerate( - simState.Cdc, opWeightMsgChangePubkeysListProposal, &weightMsgChangePubkeysListProposal, nil, diff --git a/x/ovm/simulation/decoder.go b/x/legacy/ovm/simulation/decoder.go similarity index 95% rename from x/ovm/simulation/decoder.go rename to x/legacy/ovm/simulation/decoder.go index f1a3aea2..feed0cf5 100644 --- a/x/ovm/simulation/decoder.go +++ b/x/legacy/ovm/simulation/decoder.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // NewDecodeStore returns a decoder function closure that unmarshals the KVPair's diff --git a/x/ovm/simulation/errors.go b/x/legacy/ovm/simulation/errors.go similarity index 100% rename from x/ovm/simulation/errors.go rename to x/legacy/ovm/simulation/errors.go diff --git a/x/ovm/simulation/genesis.go b/x/legacy/ovm/simulation/genesis.go similarity index 90% rename from x/ovm/simulation/genesis.go rename to x/legacy/ovm/simulation/genesis.go index 8e30ff56..b1411f63 100644 --- a/x/ovm/simulation/genesis.go +++ b/x/legacy/ovm/simulation/genesis.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // RandomizedGenState generates a random GenesisState for ovm diff --git a/x/ovm/simulation/proposal.go b/x/legacy/ovm/simulation/proposal.go similarity index 90% rename from x/ovm/simulation/proposal.go rename to x/legacy/ovm/simulation/proposal.go index c0a04613..467b789b 100644 --- a/x/ovm/simulation/proposal.go +++ b/x/legacy/ovm/simulation/proposal.go @@ -8,8 +8,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/ovm/keeper" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/ovm/keeper" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // SimulateMsgChangePubkeysListProposal simulates MsgChangePubkeysListProposal message registration diff --git a/x/reward/simulation/proposals.go b/x/legacy/ovm/simulation/proposals.go similarity index 95% rename from x/reward/simulation/proposals.go rename to x/legacy/ovm/simulation/proposals.go index 10d500d7..1f8ef92a 100644 --- a/x/reward/simulation/proposals.go +++ b/x/legacy/ovm/simulation/proposals.go @@ -8,7 +8,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/ovm/types" ) // Simulation operation weights constants diff --git a/x/orderbook/simulation/simap.go b/x/legacy/ovm/simulation/simap.go similarity index 100% rename from x/orderbook/simulation/simap.go rename to x/legacy/ovm/simulation/simap.go diff --git a/x/ovm/types/codec.go b/x/legacy/ovm/types/codec.go similarity index 100% rename from x/ovm/types/codec.go rename to x/legacy/ovm/types/codec.go diff --git a/x/ovm/types/consts.go b/x/legacy/ovm/types/consts.go similarity index 100% rename from x/ovm/types/consts.go rename to x/legacy/ovm/types/consts.go diff --git a/x/ovm/types/errors.go b/x/legacy/ovm/types/errors.go similarity index 100% rename from x/ovm/types/errors.go rename to x/legacy/ovm/types/errors.go diff --git a/x/ovm/types/events.go b/x/legacy/ovm/types/events.go similarity index 100% rename from x/ovm/types/events.go rename to x/legacy/ovm/types/events.go diff --git a/x/ovm/types/expected_keepers.go b/x/legacy/ovm/types/expected_keepers.go similarity index 70% rename from x/ovm/types/expected_keepers.go rename to x/legacy/ovm/types/expected_keepers.go index 298564e1..b052d360 100644 --- a/x/ovm/types/expected_keepers.go +++ b/x/legacy/ovm/types/expected_keepers.go @@ -1,19 +1,19 @@ package types import ( - sdk "github.com/cosmos/cosmos-sdk/types" + context "context" - "github.com/cosmos/cosmos-sdk/x/auth/types" + sdk "github.com/cosmos/cosmos-sdk/types" ) // AccountKeeper defines the expected account keeper used for simulations (noalias) type AccountKeeper interface { - GetAccount(ctx sdk.Context, addr sdk.AccAddress) types.AccountI + GetAccount(ctx context.Context, addr sdk.AccAddress) sdk.AccountI // Methods imported from account should be defined here } // BankKeeper defines the expected interface needed to retrieve account balances. type BankKeeper interface { - SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins + SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins // Methods imported from bank should be defined here } diff --git a/x/ovm/types/export_test.go b/x/legacy/ovm/types/export_test.go similarity index 100% rename from x/ovm/types/export_test.go rename to x/legacy/ovm/types/export_test.go diff --git a/x/ovm/types/genesis.go b/x/legacy/ovm/types/genesis.go similarity index 100% rename from x/ovm/types/genesis.go rename to x/legacy/ovm/types/genesis.go diff --git a/x/ovm/types/genesis.pb.go b/x/legacy/ovm/types/genesis.pb.go similarity index 81% rename from x/ovm/types/genesis.pb.go rename to x/legacy/ovm/types/genesis.pb.go index 968933e4..76917c8f 100644 --- a/x/ovm/types/genesis.pb.go +++ b/x/legacy/ovm/types/genesis.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/genesis.proto +// source: sge/legacy/ovm/v1beta/genesis.proto package types @@ -40,7 +40,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_38b9a617643a053f, []int{0} + return fileDescriptor_584180a8bd51d4dc, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -98,35 +98,37 @@ func (m *GenesisState) GetProposalStats() ProposalStats { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.ovm.GenesisState") + proto.RegisterType((*GenesisState)(nil), "sge.legacy.ovm.v1beta.GenesisState") } -func init() { proto.RegisterFile("sgenetwork/sge/ovm/genesis.proto", fileDescriptor_38b9a617643a053f) } +func init() { + proto.RegisterFile("sge/legacy/ovm/v1beta/genesis.proto", fileDescriptor_584180a8bd51d4dc) +} -var fileDescriptor_38b9a617643a053f = []byte{ - // 338 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x91, 0xbf, 0x4e, 0xf3, 0x30, - 0x14, 0xc5, 0x93, 0xb6, 0xaa, 0xbe, 0x2f, 0x05, 0x06, 0x0b, 0xa1, 0x28, 0x42, 0xee, 0x9f, 0x01, - 0x75, 0x00, 0x47, 0x2a, 0x0b, 0x1b, 0x08, 0x06, 0x86, 0x4a, 0xa8, 0x02, 0x89, 0x81, 0x25, 0x72, - 0x2a, 0xcb, 0xad, 0x92, 0xd4, 0x56, 0xae, 0x53, 0xc8, 0x5b, 0xf0, 0x56, 0x74, 0xec, 0xc8, 0x84, - 0x50, 0xfb, 0x22, 0x28, 0xae, 0x0b, 0x54, 0x78, 0x4b, 0xec, 0xdf, 0x39, 0xbe, 0xe7, 0x1e, 0xaf, - 0x03, 0x9c, 0xcd, 0x98, 0x7a, 0x16, 0x79, 0x12, 0x02, 0x67, 0xa1, 0x98, 0x67, 0x61, 0x75, 0x02, - 0x53, 0x20, 0x32, 0x17, 0x4a, 0x20, 0xf4, 0x43, 0x10, 0xe0, 0x8c, 0x88, 0x79, 0x16, 0x1c, 0x72, - 0xc1, 0x85, 0xbe, 0x0e, 0xab, 0xaf, 0x0d, 0x19, 0xb4, 0x2d, 0x5e, 0x92, 0xe6, 0x34, 0x33, 0x56, - 0x41, 0xcf, 0x02, 0x24, 0xac, 0x8c, 0xe6, 0xb4, 0x48, 0x95, 0x61, 0xba, 0x36, 0x93, 0x5c, 0x48, - 0x01, 0x34, 0x35, 0x08, 0xb6, 0x20, 0xa0, 0xa8, 0x32, 0xcf, 0xf4, 0xde, 0x6a, 0xde, 0xde, 0xed, - 0x26, 0xc3, 0x83, 0xa2, 0x8a, 0xa1, 0x0b, 0xaf, 0xb9, 0x99, 0xc3, 0x77, 0x3b, 0x6e, 0xbf, 0x35, - 0x08, 0xc8, 0xdf, 0x4c, 0x64, 0xa4, 0x89, 0xeb, 0xc6, 0xe2, 0xa3, 0xed, 0xdc, 0x1b, 0x1e, 0x5d, - 0x7a, 0xff, 0xbf, 0x07, 0xf4, 0x6b, 0x5a, 0x7c, 0x6c, 0x13, 0x0f, 0x59, 0xf9, 0x58, 0x31, 0x46, - 0xfe, 0x2f, 0x31, 0xff, 0x28, 0xf5, 0x7c, 0x59, 0xc4, 0x09, 0x2b, 0x21, 0x1a, 0x4f, 0xe8, 0x8c, - 0xb3, 0x68, 0x1b, 0x06, 0xfc, 0x7a, 0xa7, 0xde, 0x6f, 0x0d, 0x4e, 0xad, 0xc3, 0x14, 0x71, 0x3a, - 0x1d, 0x0f, 0x59, 0x09, 0x37, 0x5a, 0x35, 0x32, 0x22, 0xe3, 0x7f, 0x64, 0x3c, 0x77, 0x2f, 0x01, - 0xdd, 0x79, 0x07, 0x5b, 0xfb, 0x48, 0x6f, 0xc4, 0x6f, 0xe8, 0x99, 0xbb, 0xd6, 0x37, 0x0c, 0x59, - 0xed, 0x68, 0x9b, 0x7b, 0x5f, 0xee, 0x1c, 0x5e, 0x2d, 0x56, 0xd8, 0x5d, 0xae, 0xb0, 0xfb, 0xb9, - 0xc2, 0xee, 0xeb, 0x1a, 0x3b, 0xcb, 0x35, 0x76, 0xde, 0xd7, 0xd8, 0x79, 0x3a, 0xe1, 0x53, 0x35, - 0x29, 0x62, 0x32, 0x16, 0x59, 0xd5, 0xc1, 0xd9, 0xef, 0x3e, 0x5e, 0x74, 0x23, 0xaa, 0x94, 0x0c, - 0xe2, 0xa6, 0xae, 0xe4, 0xfc, 0x2b, 0x00, 0x00, 0xff, 0xff, 0x01, 0x1f, 0xc4, 0xc4, 0x68, 0x02, - 0x00, 0x00, +var fileDescriptor_584180a8bd51d4dc = []byte{ + // 349 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0x31, 0x4f, 0xfa, 0x40, + 0x18, 0xc6, 0x5b, 0x20, 0xe4, 0xff, 0x2f, 0xea, 0xd0, 0xa8, 0x69, 0x48, 0x2c, 0x88, 0x98, 0xb0, + 0x70, 0x17, 0x71, 0x74, 0xc3, 0x81, 0x81, 0x05, 0x35, 0x71, 0x70, 0x69, 0xae, 0xcd, 0x9b, 0x83, + 0xb4, 0xe5, 0x9a, 0xde, 0xb5, 0xda, 0x6f, 0xe1, 0xc7, 0x62, 0x24, 0x71, 0x71, 0x32, 0x06, 0xbe, + 0x88, 0xe9, 0xf5, 0x6a, 0x24, 0x69, 0xb7, 0x6b, 0xef, 0xf7, 0x3c, 0xcf, 0x3d, 0xef, 0x6b, 0x5c, + 0x71, 0x0a, 0x38, 0x00, 0x4a, 0xbc, 0x0c, 0xb3, 0x34, 0xc4, 0xe9, 0x8d, 0x0b, 0x82, 0x60, 0x0a, + 0x6b, 0xe0, 0x2b, 0x8e, 0xa2, 0x98, 0x09, 0x66, 0x9e, 0x71, 0x0a, 0xa8, 0x80, 0x10, 0x4b, 0x43, + 0x54, 0x40, 0xdd, 0x53, 0xca, 0x28, 0x93, 0x04, 0xce, 0x4f, 0x05, 0xdc, 0xbd, 0xae, 0x76, 0xf4, + 0x21, 0x73, 0x52, 0x92, 0x04, 0x42, 0x61, 0x83, 0x6a, 0x2c, 0x22, 0x31, 0x09, 0x55, 0x6e, 0x77, + 0x58, 0xc3, 0xc4, 0x2c, 0x62, 0x9c, 0x04, 0x8a, 0xba, 0xac, 0xa6, 0xb8, 0x20, 0x42, 0x19, 0x0d, + 0x3e, 0x1a, 0xc6, 0xd1, 0xac, 0xa8, 0xf4, 0x24, 0x88, 0x00, 0xf3, 0xce, 0x68, 0x17, 0x49, 0x96, + 0xde, 0xd7, 0x47, 0x9d, 0xc9, 0x05, 0xaa, 0xac, 0x88, 0x16, 0x12, 0x9a, 0xb6, 0x36, 0x5f, 0x3d, + 0xed, 0x51, 0x49, 0xcc, 0xa9, 0xf1, 0xff, 0xb7, 0x8d, 0xd5, 0x90, 0xfa, 0x5e, 0x8d, 0x7e, 0x0e, + 0xd9, 0x73, 0x8e, 0x29, 0x87, 0x7f, 0xbe, 0xfa, 0x36, 0x99, 0x61, 0x45, 0x89, 0xeb, 0x43, 0xc6, + 0x1d, 0x6f, 0x49, 0xd6, 0x14, 0x9c, 0xb2, 0x15, 0xb7, 0x9a, 0xfd, 0xe6, 0xa8, 0x33, 0xc1, 0x75, + 0x4f, 0x4a, 0xdc, 0x60, 0xe5, 0xcd, 0x21, 0xe3, 0xf7, 0x52, 0xb8, 0x50, 0x3a, 0x15, 0x71, 0xae, + 0x6c, 0x0f, 0x2f, 0xb9, 0xf9, 0x60, 0x9c, 0x94, 0x09, 0x8e, 0x1c, 0x8d, 0xd5, 0x92, 0x2f, 0x1f, + 0xd6, 0xc5, 0x28, 0x38, 0x9f, 0x57, 0x39, 0x80, 0xe3, 0xe8, 0xe0, 0xe7, 0x6c, 0xb3, 0xb3, 0xf5, + 0xed, 0xce, 0xd6, 0xbf, 0x77, 0xb6, 0xfe, 0xbe, 0xb7, 0xb5, 0xed, 0xde, 0xd6, 0x3e, 0xf7, 0xb6, + 0xf6, 0x32, 0xa6, 0x2b, 0xb1, 0x4c, 0x5c, 0xe4, 0xb1, 0x10, 0x73, 0x0a, 0xe3, 0x35, 0x88, 0x57, + 0x16, 0xfb, 0xf9, 0x19, 0xbf, 0xfd, 0xdd, 0x95, 0xc8, 0x22, 0xe0, 0x6e, 0x5b, 0x6e, 0xe9, 0xf6, + 0x27, 0x00, 0x00, 0xff, 0xff, 0x53, 0x68, 0x6a, 0x8b, 0x8d, 0x02, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/key_vault.go b/x/legacy/ovm/types/key_vault.go similarity index 100% rename from x/ovm/types/key_vault.go rename to x/legacy/ovm/types/key_vault.go diff --git a/x/ovm/types/key_vault.pb.go b/x/legacy/ovm/types/key_vault.pb.go similarity index 82% rename from x/ovm/types/key_vault.pb.go rename to x/legacy/ovm/types/key_vault.pb.go index fd9d4b98..9c07d3bb 100644 --- a/x/ovm/types/key_vault.pb.go +++ b/x/legacy/ovm/types/key_vault.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/key_vault.proto +// source: sge/legacy/ovm/v1beta/key_vault.proto package types @@ -32,7 +32,7 @@ func (m *KeyVault) Reset() { *m = KeyVault{} } func (m *KeyVault) String() string { return proto.CompactTextString(m) } func (*KeyVault) ProtoMessage() {} func (*KeyVault) Descriptor() ([]byte, []int) { - return fileDescriptor_c57e8bf69362e3d7, []int{0} + return fileDescriptor_b511099d42308962, []int{0} } func (m *KeyVault) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -69,26 +69,27 @@ func (m *KeyVault) GetPublicKeys() []string { } func init() { - proto.RegisterType((*KeyVault)(nil), "sgenetwork.sge.ovm.KeyVault") + proto.RegisterType((*KeyVault)(nil), "sge.legacy.ovm.v1beta.KeyVault") } func init() { - proto.RegisterFile("sgenetwork/sge/ovm/key_vault.proto", fileDescriptor_c57e8bf69362e3d7) + proto.RegisterFile("sge/legacy/ovm/v1beta/key_vault.proto", fileDescriptor_b511099d42308962) } -var fileDescriptor_c57e8bf69362e3d7 = []byte{ - // 169 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2a, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0xcb, 0xd5, 0xcf, - 0x4e, 0xad, 0x8c, 0x2f, 0x4b, 0x2c, 0xcd, 0x29, 0xd1, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, - 0x42, 0xa8, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0xcb, 0x2f, 0xcb, 0x55, 0xd2, 0xe6, 0xe2, 0xf0, 0x4e, - 0xad, 0x0c, 0x03, 0xa9, 0x12, 0x92, 0xe7, 0xe2, 0x2e, 0x28, 0x4d, 0xca, 0xc9, 0x4c, 0x8e, 0xcf, - 0x4e, 0xad, 0x2c, 0x96, 0x60, 0x54, 0x60, 0xd6, 0xe0, 0x0c, 0xe2, 0x82, 0x08, 0x79, 0xa7, 0x56, - 0x16, 0x3b, 0x39, 0x9c, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, - 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x5a, 0x7a, - 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0x2e, 0xc8, 0x7a, 0x5d, 0x64, 0xa7, 0x54, 0x80, - 0x1d, 0x53, 0x52, 0x59, 0x90, 0x5a, 0x9c, 0xc4, 0x06, 0x76, 0x89, 0x31, 0x20, 0x00, 0x00, 0xff, - 0xff, 0x51, 0xe3, 0x8a, 0x8c, 0xaf, 0x00, 0x00, 0x00, +var fileDescriptor_b511099d42308962 = []byte{ + // 185 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2d, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x2f, 0xcb, 0xd5, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, + 0x49, 0xd4, 0xcf, 0x4e, 0xad, 0x8c, 0x2f, 0x4b, 0x2c, 0xcd, 0x29, 0xd1, 0x2b, 0x28, 0xca, 0x2f, + 0xc9, 0x17, 0x12, 0x2d, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd3, 0xcb, 0x2f, 0xcb, 0xd5, 0x83, 0x28, + 0x53, 0xd2, 0xe6, 0xe2, 0xf0, 0x4e, 0xad, 0x0c, 0x03, 0x29, 0x14, 0x92, 0xe7, 0xe2, 0x2e, 0x28, + 0x4d, 0xca, 0xc9, 0x4c, 0x8e, 0xcf, 0x4e, 0xad, 0x2c, 0x96, 0x60, 0x54, 0x60, 0xd6, 0xe0, 0x0c, + 0xe2, 0x82, 0x08, 0x79, 0xa7, 0x56, 0x16, 0x3b, 0xb9, 0x9f, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, + 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, + 0xb1, 0x1c, 0x43, 0x94, 0x6e, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0xae, 0x7e, + 0x71, 0x7a, 0xaa, 0x6e, 0x5e, 0x6a, 0x49, 0x79, 0x7e, 0x51, 0x36, 0x88, 0xad, 0x5f, 0x81, 0xec, + 0xba, 0x92, 0xca, 0x82, 0xd4, 0xe2, 0x24, 0x36, 0xb0, 0x9b, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, + 0xff, 0x83, 0x13, 0x41, 0xe2, 0xbc, 0x00, 0x00, 0x00, } func (m *KeyVault) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/keys.go b/x/legacy/ovm/types/keys.go similarity index 100% rename from x/ovm/types/keys.go rename to x/legacy/ovm/types/keys.go diff --git a/x/ovm/types/message_pubkeys_proposal.go b/x/legacy/ovm/types/message_pubkeys_proposal.go similarity index 100% rename from x/ovm/types/message_pubkeys_proposal.go rename to x/legacy/ovm/types/message_pubkeys_proposal.go diff --git a/x/ovm/types/message_pubkeys_vote.go b/x/legacy/ovm/types/message_pubkeys_vote.go similarity index 100% rename from x/ovm/types/message_pubkeys_vote.go rename to x/legacy/ovm/types/message_pubkeys_vote.go diff --git a/x/ovm/types/messages_params.go b/x/legacy/ovm/types/messages_params.go similarity index 100% rename from x/ovm/types/messages_params.go rename to x/legacy/ovm/types/messages_params.go diff --git a/x/ovm/types/params.go b/x/legacy/ovm/types/params.go similarity index 100% rename from x/ovm/types/params.go rename to x/legacy/ovm/types/params.go diff --git a/x/market/types/params.pb.go b/x/legacy/ovm/types/params.pb.go similarity index 80% rename from x/market/types/params.pb.go rename to x/legacy/ovm/types/params.pb.go index c597c27a..2151632e 100644 --- a/x/market/types/params.pb.go +++ b/x/legacy/ovm/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/market/params.proto +// source: sge/legacy/ovm/v1beta/params.proto package types @@ -24,14 +24,13 @@ var _ = math.Inf const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // Params defines the parameters for the module. -// It contains bet constraints associated to a market. type Params struct { } func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_30c8b635732b997c, []int{0} + return fileDescriptor_5a92632cb96b8d0d, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -61,25 +60,26 @@ func (m *Params) XXX_DiscardUnknown() { var xxx_messageInfo_Params proto.InternalMessageInfo func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.market.Params") + proto.RegisterType((*Params)(nil), "sge.legacy.ovm.v1beta.Params") } func init() { - proto.RegisterFile("sgenetwork/sge/market/params.proto", fileDescriptor_30c8b635732b997c) + proto.RegisterFile("sge/legacy/ovm/v1beta/params.proto", fileDescriptor_5a92632cb96b8d0d) } -var fileDescriptor_30c8b635732b997c = []byte{ - // 155 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2a, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x4d, 0x2c, 0xca, 0x4e, - 0x2d, 0xd1, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, - 0x45, 0xa8, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0x91, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, - 0xab, 0xd0, 0x07, 0xb1, 0x20, 0x8a, 0x95, 0xf8, 0xb8, 0xd8, 0x02, 0xc0, 0x9a, 0xad, 0x58, 0x66, - 0x2c, 0x90, 0x67, 0x70, 0x72, 0x3e, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, - 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, - 0xcd, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x90, 0xd5, 0xba, 0xc8, 0xce, - 0xa8, 0x80, 0x39, 0xa4, 0xa4, 0xb2, 0x20, 0xb5, 0x38, 0x89, 0x0d, 0x6c, 0xb6, 0x31, 0x20, 0x00, - 0x00, 0xff, 0xff, 0xa3, 0xb3, 0x9c, 0x25, 0xae, 0x00, 0x00, 0x00, +var fileDescriptor_5a92632cb96b8d0d = []byte{ + // 169 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2a, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x2f, 0xcb, 0xd5, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, + 0x49, 0xd4, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, + 0x2d, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0xd1, 0xcb, 0x2f, 0xcb, 0xd5, 0x83, 0xa8, 0x91, 0x12, 0x49, + 0xcf, 0x4f, 0xcf, 0x07, 0xab, 0xd0, 0x07, 0xb1, 0x20, 0x8a, 0x95, 0xf8, 0xb8, 0xd8, 0x02, 0xc0, + 0x9a, 0xad, 0x58, 0x66, 0x2c, 0x90, 0x67, 0x70, 0x72, 0x3f, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, + 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, + 0x63, 0x39, 0x86, 0x28, 0xdd, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0xfd, + 0xe2, 0xf4, 0x54, 0xdd, 0xbc, 0xd4, 0x92, 0xf2, 0xfc, 0xa2, 0x6c, 0x10, 0x5b, 0xbf, 0x02, 0xd9, + 0x4d, 0x25, 0x95, 0x05, 0xa9, 0xc5, 0x49, 0x6c, 0x60, 0xf3, 0x8d, 0x01, 0x01, 0x00, 0x00, 0xff, + 0xff, 0x97, 0x7f, 0xe3, 0xb9, 0xb2, 0x00, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/proposal.go b/x/legacy/ovm/types/proposal.go similarity index 100% rename from x/ovm/types/proposal.go rename to x/legacy/ovm/types/proposal.go diff --git a/x/ovm/types/proposal.pb.go b/x/legacy/ovm/types/proposal.pb.go similarity index 79% rename from x/ovm/types/proposal.pb.go rename to x/legacy/ovm/types/proposal.pb.go index 3fb6dd8e..cbc776ee 100644 --- a/x/ovm/types/proposal.pb.go +++ b/x/legacy/ovm/types/proposal.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/proposal.proto +// source: sge/legacy/ovm/v1beta/proposal.proto package types @@ -57,7 +57,7 @@ func (x ProposalResult) String() string { } func (ProposalResult) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_68d5b3dc34bd8d1b, []int{0} + return fileDescriptor_fb8a796386c96608, []int{0} } // ProposalStatus is the enum type for the proposal status. @@ -89,7 +89,7 @@ func (x ProposalStatus) String() string { } func (ProposalStatus) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_68d5b3dc34bd8d1b, []int{1} + return fileDescriptor_fb8a796386c96608, []int{1} } // PublicKeysChangeProposal is the type for the proposal for additions and @@ -106,20 +106,20 @@ type PublicKeysChangeProposal struct { // start_ts is the block time that the proposal is set. StartTS int64 `protobuf:"varint,5,opt,name=start_ts,proto3" json:"start_ts"` // result is the result of the finished proposal. - Result ProposalResult `protobuf:"varint,6,opt,name=result,proto3,enum=sgenetwork.sge.ovm.ProposalResult" json:"result,omitempty"` + Result ProposalResult `protobuf:"varint,6,opt,name=result,proto3,enum=sge.legacy.ovm.v1beta.ProposalResult" json:"result,omitempty"` // result_meta is the metadata related to the result of the finished proposal. ResultMeta string `protobuf:"bytes,7,opt,name=result_meta,json=resultMeta,proto3" json:"result_meta,omitempty"` // finish_ts is the block time that the proposal is set as finished. FinishTS int64 `protobuf:"varint,8,opt,name=finish_ts,proto3" json:"finish_ts"` // status is the status of a proposal. - Status ProposalStatus `protobuf:"varint,9,opt,name=status,proto3,enum=sgenetwork.sge.ovm.ProposalStatus" json:"status,omitempty"` + Status ProposalStatus `protobuf:"varint,9,opt,name=status,proto3,enum=sge.legacy.ovm.v1beta.ProposalStatus" json:"status,omitempty"` } func (m *PublicKeysChangeProposal) Reset() { *m = PublicKeysChangeProposal{} } func (m *PublicKeysChangeProposal) String() string { return proto.CompactTextString(m) } func (*PublicKeysChangeProposal) ProtoMessage() {} func (*PublicKeysChangeProposal) Descriptor() ([]byte, []int) { - return fileDescriptor_68d5b3dc34bd8d1b, []int{0} + return fileDescriptor_fb8a796386c96608, []int{0} } func (m *PublicKeysChangeProposal) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -212,51 +212,54 @@ func (m *PublicKeysChangeProposal) GetStatus() ProposalStatus { } func init() { - proto.RegisterEnum("sgenetwork.sge.ovm.ProposalResult", ProposalResult_name, ProposalResult_value) - proto.RegisterEnum("sgenetwork.sge.ovm.ProposalStatus", ProposalStatus_name, ProposalStatus_value) - proto.RegisterType((*PublicKeysChangeProposal)(nil), "sgenetwork.sge.ovm.PublicKeysChangeProposal") -} - -func init() { proto.RegisterFile("sgenetwork/sge/ovm/proposal.proto", fileDescriptor_68d5b3dc34bd8d1b) } - -var fileDescriptor_68d5b3dc34bd8d1b = []byte{ - // 567 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x93, 0xcb, 0x6e, 0xda, 0x4c, - 0x14, 0xc7, 0x31, 0xe4, 0x3a, 0xe8, 0x43, 0x68, 0x14, 0x7d, 0x99, 0x90, 0xd6, 0x76, 0xb3, 0xa8, - 0xac, 0x48, 0x31, 0x15, 0x59, 0x54, 0xea, 0xaa, 0x5c, 0x8c, 0xea, 0x36, 0x0d, 0xd6, 0xd8, 0xa0, - 0xaa, 0xaa, 0x84, 0x8c, 0x3d, 0x31, 0x16, 0x98, 0x41, 0x9e, 0x81, 0x96, 0x57, 0xe8, 0xaa, 0x0f, - 0xd3, 0x87, 0xc8, 0x32, 0xea, 0xaa, 0x2b, 0x54, 0xc1, 0xae, 0xdb, 0xbe, 0x40, 0xe5, 0x4b, 0x43, - 0x21, 0x48, 0xdd, 0x1d, 0x9f, 0xff, 0x6f, 0xc6, 0xbf, 0x33, 0xd2, 0x01, 0x4f, 0x98, 0x47, 0x46, - 0x84, 0x7f, 0xa4, 0xe1, 0xa0, 0xcc, 0x3c, 0x52, 0xa6, 0xd3, 0xa0, 0x3c, 0x0e, 0xe9, 0x98, 0x32, - 0x7b, 0xa8, 0x8e, 0x43, 0xca, 0x29, 0x84, 0x2b, 0x44, 0x65, 0x1e, 0x51, 0xe9, 0x34, 0x28, 0x1d, - 0x79, 0xd4, 0xa3, 0x71, 0x5c, 0x8e, 0xaa, 0x84, 0x2c, 0x9d, 0x38, 0x94, 0x05, 0x94, 0x75, 0x93, - 0x20, 0xf9, 0x48, 0x23, 0x69, 0xcb, 0x7f, 0xb8, 0xef, 0x0c, 0x08, 0x4f, 0x81, 0xc7, 0x5b, 0x80, - 0x29, 0xe5, 0x24, 0x89, 0xcf, 0x7e, 0xe5, 0x00, 0x32, 0x26, 0xbd, 0xa1, 0xef, 0xbc, 0x21, 0x33, - 0x56, 0xef, 0xdb, 0x23, 0x8f, 0x18, 0xa9, 0x27, 0x2c, 0x80, 0xac, 0xef, 0x22, 0x41, 0x16, 0x94, - 0x1d, 0x9c, 0xf5, 0x5d, 0x58, 0x01, 0xfb, 0x4e, 0x48, 0x6c, 0x4e, 0x43, 0x94, 0x95, 0x05, 0xe5, - 0xb0, 0x86, 0xbe, 0x7d, 0xbd, 0x38, 0x4a, 0x7d, 0xaa, 0xae, 0x1b, 0x12, 0xc6, 0x4c, 0x1e, 0xfa, - 0x23, 0x0f, 0xff, 0x01, 0xe1, 0x07, 0xf0, 0x5f, 0x40, 0x5d, 0xff, 0xc6, 0x77, 0x6c, 0xee, 0xd3, - 0x11, 0x43, 0x39, 0x59, 0x50, 0xf2, 0x95, 0x67, 0xea, 0xc3, 0xe9, 0x55, 0x63, 0xd2, 0x1b, 0x3c, - 0xb0, 0x30, 0xec, 0xd9, 0x90, 0xda, 0x6e, 0x6d, 0xe7, 0x76, 0x2e, 0x65, 0xf0, 0xfa, 0x65, 0x50, - 0x05, 0xbb, 0xd1, 0x30, 0x0c, 0xed, 0xc8, 0x39, 0x25, 0x5f, 0x41, 0xdb, 0x6e, 0xed, 0x50, 0x4e, - 0x70, 0x82, 0xc1, 0x4b, 0x70, 0xc0, 0xb8, 0x1d, 0xf2, 0x2e, 0x67, 0x68, 0x57, 0x16, 0x94, 0x5c, - 0xed, 0x78, 0x31, 0x97, 0xf6, 0xcd, 0xa8, 0x67, 0x99, 0x3f, 0xe7, 0xd2, 0x7d, 0x8c, 0xef, 0x2b, - 0xf8, 0x02, 0xec, 0x85, 0x84, 0x4d, 0x86, 0x1c, 0xed, 0xc9, 0x82, 0x52, 0xa8, 0x9c, 0x6d, 0x75, - 0x4f, 0x75, 0x71, 0x4c, 0xe2, 0xf4, 0x04, 0x94, 0x40, 0x3e, 0xa9, 0xba, 0x01, 0xe1, 0x36, 0xda, - 0x8f, 0x9e, 0x0d, 0x83, 0xa4, 0xf5, 0x96, 0x70, 0x1b, 0x3e, 0x07, 0x87, 0x37, 0xfe, 0xc8, 0x67, - 0xfd, 0x48, 0xe9, 0x20, 0x56, 0x3a, 0x59, 0xcc, 0xa5, 0x83, 0x66, 0xdc, 0x8c, 0x9d, 0x56, 0x00, - 0x5e, 0x95, 0x91, 0x15, 0xe3, 0x36, 0x9f, 0x30, 0x74, 0xf8, 0x6f, 0x2b, 0x33, 0x26, 0x71, 0x7a, - 0xe2, 0xfc, 0xb3, 0x00, 0x0a, 0xeb, 0xc2, 0x50, 0x02, 0xa7, 0x06, 0x6e, 0x19, 0x2d, 0xb3, 0x7a, - 0xd5, 0xc5, 0x9a, 0xd9, 0xbe, 0xb2, 0xba, 0xed, 0x6b, 0xd3, 0xd0, 0xea, 0x7a, 0x53, 0xd7, 0x1a, - 0xc5, 0x0c, 0x7c, 0x04, 0xd0, 0x26, 0x50, 0x35, 0x0c, 0xdc, 0xea, 0x68, 0x8d, 0xa2, 0xb0, 0x2d, - 0xc5, 0xda, 0x6b, 0xad, 0x6e, 0x69, 0x8d, 0x62, 0x16, 0x9e, 0x82, 0xe3, 0xcd, 0x54, 0x7b, 0x67, - 0xe8, 0x58, 0x6b, 0x14, 0x73, 0xe7, 0x83, 0x95, 0x4b, 0xa2, 0xb9, 0xe6, 0x62, 0x5a, 0x55, 0xab, - 0x6d, 0x6e, 0xb8, 0x94, 0xc0, 0xff, 0x9b, 0x40, 0xb5, 0x6e, 0xe9, 0x1d, 0x6d, 0xc3, 0x24, 0xcd, - 0x9a, 0xfa, 0xb5, 0x6e, 0xbe, 0x8a, 0x4c, 0x6a, 0x2f, 0x6f, 0x17, 0xa2, 0x70, 0xb7, 0x10, 0x85, - 0x1f, 0x0b, 0x51, 0xf8, 0xb2, 0x14, 0x33, 0x77, 0x4b, 0x31, 0xf3, 0x7d, 0x29, 0x66, 0xde, 0x3f, - 0xf5, 0x7c, 0xde, 0x9f, 0xf4, 0x54, 0x87, 0x06, 0xd1, 0xa2, 0x5c, 0xfc, 0xbd, 0x34, 0x9f, 0x92, - 0xbd, 0x9a, 0x8d, 0x09, 0xeb, 0xed, 0xc5, 0x8b, 0x73, 0xf9, 0x3b, 0x00, 0x00, 0xff, 0xff, 0xc6, - 0x67, 0x3a, 0x16, 0xe2, 0x03, 0x00, 0x00, + proto.RegisterEnum("sge.legacy.ovm.v1beta.ProposalResult", ProposalResult_name, ProposalResult_value) + proto.RegisterEnum("sge.legacy.ovm.v1beta.ProposalStatus", ProposalStatus_name, ProposalStatus_value) + proto.RegisterType((*PublicKeysChangeProposal)(nil), "sge.legacy.ovm.v1beta.PublicKeysChangeProposal") +} + +func init() { + proto.RegisterFile("sge/legacy/ovm/v1beta/proposal.proto", fileDescriptor_fb8a796386c96608) +} + +var fileDescriptor_fb8a796386c96608 = []byte{ + // 579 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x93, 0x4d, 0x6f, 0xd3, 0x30, + 0x1c, 0xc6, 0x9b, 0x76, 0xaf, 0x9e, 0x98, 0x2a, 0x6b, 0xb0, 0x6c, 0x43, 0x49, 0x34, 0x81, 0x14, + 0x4d, 0x5a, 0xa2, 0x75, 0x07, 0x4e, 0x1c, 0xfa, 0x92, 0x41, 0x60, 0x6c, 0x91, 0x93, 0x56, 0x88, + 0x4b, 0xe4, 0x26, 0x5e, 0x1a, 0xb5, 0xa9, 0xab, 0xd8, 0x2d, 0xf4, 0x2b, 0x70, 0xe2, 0xc3, 0xf0, + 0x21, 0x76, 0x9c, 0x38, 0x71, 0xaa, 0x50, 0x7b, 0xe3, 0x4b, 0x80, 0xf2, 0xc2, 0x4a, 0x4b, 0x27, + 0x71, 0x7b, 0xf2, 0xfc, 0x7f, 0x76, 0x7e, 0xb6, 0x64, 0xf0, 0x8c, 0x05, 0x44, 0xef, 0x91, 0x00, + 0x7b, 0x63, 0x9d, 0x8e, 0x22, 0x7d, 0x74, 0xd6, 0x26, 0x1c, 0xeb, 0x83, 0x98, 0x0e, 0x28, 0xc3, + 0x3d, 0x6d, 0x10, 0x53, 0x4e, 0xe1, 0x63, 0x16, 0x10, 0x2d, 0xa3, 0x34, 0x3a, 0x8a, 0xb4, 0x8c, + 0x3a, 0x3c, 0xf0, 0x28, 0x8b, 0x28, 0x73, 0x53, 0x48, 0xcf, 0x3e, 0xb2, 0x15, 0x87, 0x7b, 0x01, + 0x0d, 0x68, 0xd6, 0x27, 0x29, 0x6f, 0x8f, 0x57, 0xff, 0x8d, 0x87, 0x5e, 0x97, 0xf0, 0x9c, 0x51, + 0x56, 0x33, 0x23, 0xca, 0x49, 0x46, 0x1c, 0xff, 0x2a, 0x01, 0xd1, 0x1a, 0xb6, 0x7b, 0xa1, 0xf7, + 0x96, 0x8c, 0x59, 0xbd, 0x83, 0xfb, 0x01, 0xb1, 0x72, 0x61, 0xb8, 0x0b, 0x8a, 0xa1, 0x2f, 0x0a, + 0x8a, 0xa0, 0xae, 0xa1, 0x62, 0xe8, 0xc3, 0x0a, 0xd8, 0xf4, 0x62, 0x82, 0x39, 0x8d, 0xc5, 0xa2, + 0x22, 0xa8, 0xdb, 0x35, 0xf1, 0xdb, 0xd7, 0xd3, 0xbd, 0xdc, 0xb5, 0xea, 0xfb, 0x31, 0x61, 0xcc, + 0xe6, 0x71, 0xd8, 0x0f, 0xd0, 0x1f, 0x10, 0xba, 0xe0, 0x51, 0x44, 0xfd, 0xf0, 0x26, 0xf4, 0x30, + 0x0f, 0x69, 0x9f, 0x89, 0x25, 0x45, 0x50, 0x77, 0x2a, 0xe7, 0xda, 0xca, 0x6b, 0xd0, 0xac, 0x61, + 0xbb, 0xfb, 0x8f, 0x88, 0x85, 0xc7, 0x3d, 0x8a, 0xfd, 0xda, 0xda, 0xed, 0x44, 0x2e, 0xa0, 0xc5, + 0xfd, 0xe0, 0x19, 0x58, 0x4f, 0xce, 0xc3, 0xc4, 0x35, 0xa5, 0xa4, 0xee, 0x54, 0x8e, 0x1e, 0xd8, + 0xb8, 0x45, 0x39, 0x41, 0x19, 0x09, 0xcf, 0xc1, 0x16, 0xe3, 0x38, 0xe6, 0x2e, 0x67, 0xe2, 0xba, + 0x22, 0xa8, 0xa5, 0xda, 0xfe, 0x74, 0x22, 0x6f, 0xda, 0x49, 0xe7, 0xd8, 0x3f, 0x27, 0xf2, 0xfd, + 0x18, 0xdd, 0x27, 0xf8, 0x12, 0x6c, 0xc4, 0x84, 0x0d, 0x7b, 0x5c, 0xdc, 0x50, 0x04, 0x75, 0xb7, + 0xf2, 0xfc, 0xa1, 0x13, 0xe4, 0xd2, 0x28, 0x85, 0x51, 0xbe, 0x08, 0xca, 0x60, 0x27, 0x4b, 0x6e, + 0x44, 0x38, 0x16, 0x37, 0x93, 0xfb, 0x43, 0x20, 0xab, 0xde, 0x11, 0x8e, 0xe1, 0x0b, 0xb0, 0x7d, + 0x13, 0xf6, 0x43, 0xd6, 0x49, 0xac, 0xb6, 0x52, 0xab, 0x83, 0xe9, 0x44, 0xde, 0xba, 0x48, 0xcb, + 0x54, 0x6b, 0x0e, 0xa0, 0x79, 0x4c, 0xc4, 0x18, 0xc7, 0x7c, 0xc8, 0xc4, 0xed, 0xff, 0x12, 0xb3, + 0x53, 0x18, 0xe5, 0x8b, 0x4e, 0x3e, 0x0b, 0x60, 0x77, 0xd1, 0x19, 0xca, 0xe0, 0xc8, 0x42, 0xd7, + 0xd6, 0xb5, 0x5d, 0xbd, 0x74, 0x91, 0x61, 0x37, 0x2f, 0x1d, 0xb7, 0x79, 0x65, 0x5b, 0x46, 0xdd, + 0xbc, 0x30, 0x8d, 0x46, 0xb9, 0x00, 0x9f, 0x02, 0x71, 0x19, 0xa8, 0x5a, 0x16, 0xba, 0x6e, 0x19, + 0x8d, 0xb2, 0xb0, 0x6a, 0x8a, 0x8c, 0x37, 0x46, 0xdd, 0x31, 0x1a, 0xe5, 0x22, 0x3c, 0x02, 0xfb, + 0xcb, 0x53, 0xe3, 0xbd, 0x65, 0x22, 0xa3, 0x51, 0x2e, 0x9d, 0x74, 0xe7, 0x2e, 0x99, 0xe6, 0x82, + 0x8b, 0xed, 0x54, 0x9d, 0xa6, 0xbd, 0xe4, 0x72, 0x08, 0x9e, 0x2c, 0x03, 0xd5, 0xba, 0x63, 0xb6, + 0x8c, 0x25, 0x93, 0x7c, 0x76, 0x61, 0x5e, 0x99, 0xf6, 0xeb, 0xc4, 0xa4, 0xf6, 0xea, 0x76, 0x2a, + 0x09, 0x77, 0x53, 0x49, 0xf8, 0x31, 0x95, 0x84, 0x2f, 0x33, 0xa9, 0x70, 0x37, 0x93, 0x0a, 0xdf, + 0x67, 0x52, 0xe1, 0xc3, 0x69, 0x10, 0xf2, 0xce, 0xb0, 0xad, 0x79, 0x34, 0xd2, 0x59, 0x40, 0x4e, + 0xfb, 0x84, 0x7f, 0xa4, 0x71, 0x37, 0xc9, 0xfa, 0xa7, 0xbf, 0x1f, 0x14, 0x1f, 0x0f, 0x08, 0x6b, + 0x6f, 0xa4, 0x6f, 0xe9, 0xfc, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0xef, 0x25, 0x8b, 0xd7, 0x01, + 0x04, 0x00, 0x00, } func (m *PublicKeysChangeProposal) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/query.pb.go b/x/legacy/ovm/types/query.pb.go similarity index 88% rename from x/ovm/types/query.pb.go rename to x/legacy/ovm/types/query.pb.go index f741f14e..5372c920 100644 --- a/x/ovm/types/query.pb.go +++ b/x/legacy/ovm/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/query.proto +// source: sge/legacy/ovm/v1beta/query.proto package types @@ -39,7 +39,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{0} + return fileDescriptor_540087383b5674a2, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -79,7 +79,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{1} + return fileDescriptor_540087383b5674a2, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -124,7 +124,7 @@ func (m *QueryPubKeysRequest) Reset() { *m = QueryPubKeysRequest{} } func (m *QueryPubKeysRequest) String() string { return proto.CompactTextString(m) } func (*QueryPubKeysRequest) ProtoMessage() {} func (*QueryPubKeysRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{2} + return fileDescriptor_540087383b5674a2, []int{2} } func (m *QueryPubKeysRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -164,7 +164,7 @@ func (m *QueryPubKeysResponse) Reset() { *m = QueryPubKeysResponse{} } func (m *QueryPubKeysResponse) String() string { return proto.CompactTextString(m) } func (*QueryPubKeysResponse) ProtoMessage() {} func (*QueryPubKeysResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{3} + return fileDescriptor_540087383b5674a2, []int{3} } func (m *QueryPubKeysResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -204,14 +204,14 @@ func (m *QueryPubKeysResponse) GetList() []string { // Query/PublicKeysChangeProposal RPC method. type QueryPublicKeysChangeProposalRequest struct { Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` - Status ProposalStatus `protobuf:"varint,2,opt,name=status,proto3,enum=sgenetwork.sge.ovm.ProposalStatus" json:"status,omitempty"` + Status ProposalStatus `protobuf:"varint,2,opt,name=status,proto3,enum=sge.legacy.ovm.v1beta.ProposalStatus" json:"status,omitempty"` } func (m *QueryPublicKeysChangeProposalRequest) Reset() { *m = QueryPublicKeysChangeProposalRequest{} } func (m *QueryPublicKeysChangeProposalRequest) String() string { return proto.CompactTextString(m) } func (*QueryPublicKeysChangeProposalRequest) ProtoMessage() {} func (*QueryPublicKeysChangeProposalRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{4} + return fileDescriptor_540087383b5674a2, []int{4} } func (m *QueryPublicKeysChangeProposalRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -265,7 +265,7 @@ func (m *QueryPublicKeysChangeProposalResponse) Reset() { *m = QueryPubl func (m *QueryPublicKeysChangeProposalResponse) String() string { return proto.CompactTextString(m) } func (*QueryPublicKeysChangeProposalResponse) ProtoMessage() {} func (*QueryPublicKeysChangeProposalResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{5} + return fileDescriptor_540087383b5674a2, []int{5} } func (m *QueryPublicKeysChangeProposalResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -305,14 +305,14 @@ func (m *QueryPublicKeysChangeProposalResponse) GetProposal() PublicKeysChangePr // Query/PublicKeysChangeProposals RPC method. type QueryPublicKeysChangeProposalsRequest struct { Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` - Status ProposalStatus `protobuf:"varint,2,opt,name=status,proto3,enum=sgenetwork.sge.ovm.ProposalStatus" json:"status,omitempty"` + Status ProposalStatus `protobuf:"varint,2,opt,name=status,proto3,enum=sge.legacy.ovm.v1beta.ProposalStatus" json:"status,omitempty"` } func (m *QueryPublicKeysChangeProposalsRequest) Reset() { *m = QueryPublicKeysChangeProposalsRequest{} } func (m *QueryPublicKeysChangeProposalsRequest) String() string { return proto.CompactTextString(m) } func (*QueryPublicKeysChangeProposalsRequest) ProtoMessage() {} func (*QueryPublicKeysChangeProposalsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{6} + return fileDescriptor_540087383b5674a2, []int{6} } func (m *QueryPublicKeysChangeProposalsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -369,7 +369,7 @@ func (m *QueryPublicKeysChangeProposalsResponse) Reset() { func (m *QueryPublicKeysChangeProposalsResponse) String() string { return proto.CompactTextString(m) } func (*QueryPublicKeysChangeProposalsResponse) ProtoMessage() {} func (*QueryPublicKeysChangeProposalsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_a7cac1d680082419, []int{7} + return fileDescriptor_540087383b5674a2, []int{7} } func (m *QueryPublicKeysChangeProposalsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -413,59 +413,59 @@ func (m *QueryPublicKeysChangeProposalsResponse) GetPagination() *query.PageResp } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.ovm.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.ovm.QueryParamsResponse") - proto.RegisterType((*QueryPubKeysRequest)(nil), "sgenetwork.sge.ovm.QueryPubKeysRequest") - proto.RegisterType((*QueryPubKeysResponse)(nil), "sgenetwork.sge.ovm.QueryPubKeysResponse") - proto.RegisterType((*QueryPublicKeysChangeProposalRequest)(nil), "sgenetwork.sge.ovm.QueryPublicKeysChangeProposalRequest") - proto.RegisterType((*QueryPublicKeysChangeProposalResponse)(nil), "sgenetwork.sge.ovm.QueryPublicKeysChangeProposalResponse") - proto.RegisterType((*QueryPublicKeysChangeProposalsRequest)(nil), "sgenetwork.sge.ovm.QueryPublicKeysChangeProposalsRequest") - proto.RegisterType((*QueryPublicKeysChangeProposalsResponse)(nil), "sgenetwork.sge.ovm.QueryPublicKeysChangeProposalsResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/ovm/query.proto", fileDescriptor_a7cac1d680082419) } - -var fileDescriptor_a7cac1d680082419 = []byte{ - // 611 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x54, 0x4d, 0x6f, 0xd3, 0x40, - 0x10, 0x8d, 0x43, 0x08, 0x74, 0x91, 0x8a, 0xba, 0x2d, 0x22, 0xb5, 0x90, 0x5b, 0x0c, 0x4d, 0x42, - 0x01, 0xaf, 0x1a, 0x2e, 0xa5, 0x27, 0x54, 0x24, 0x38, 0x20, 0x41, 0x30, 0x37, 0x2e, 0xd5, 0x3a, - 0x59, 0x6d, 0xad, 0x26, 0x5e, 0xd7, 0xbb, 0x4e, 0x88, 0xaa, 0x5e, 0xf8, 0x05, 0x48, 0xfc, 0x0c, - 0x7e, 0x04, 0x48, 0x5c, 0x7a, 0xac, 0xc4, 0x85, 0x13, 0x42, 0x09, 0x7f, 0x82, 0x1b, 0xf2, 0xee, - 0x3a, 0x1f, 0x34, 0x89, 0x45, 0xb8, 0x59, 0x9e, 0x37, 0xef, 0xbd, 0x79, 0x9e, 0x31, 0xb0, 0x38, - 0x25, 0x01, 0x11, 0x5d, 0x16, 0x1d, 0x21, 0x4e, 0x09, 0x62, 0x9d, 0x36, 0x3a, 0x8e, 0x49, 0xd4, - 0x73, 0xc2, 0x88, 0x09, 0x06, 0xe1, 0xa8, 0xee, 0x70, 0x4a, 0x1c, 0xd6, 0x69, 0x9b, 0x6b, 0x94, - 0x51, 0x26, 0xcb, 0x28, 0x79, 0x52, 0x48, 0x73, 0xbb, 0xc1, 0x78, 0x9b, 0x71, 0xe4, 0x61, 0x4e, - 0x14, 0x05, 0xea, 0xec, 0x78, 0x44, 0xe0, 0x1d, 0x14, 0x62, 0xea, 0x07, 0x58, 0xf8, 0x2c, 0xd0, - 0xd8, 0x5b, 0x94, 0x31, 0xda, 0x22, 0x08, 0x87, 0x3e, 0xc2, 0x41, 0xc0, 0x84, 0x2c, 0x72, 0x5d, - 0xdd, 0x98, 0xe2, 0x29, 0xc4, 0x11, 0x6e, 0xa7, 0x80, 0xdb, 0xd3, 0x00, 0x11, 0x0b, 0x19, 0xc7, - 0x2d, 0x05, 0xb1, 0xd7, 0x00, 0x7c, 0x9d, 0x78, 0xa8, 0xcb, 0x3e, 0x97, 0x1c, 0xc7, 0x84, 0x0b, - 0xfb, 0x15, 0x58, 0x9d, 0x78, 0xcb, 0x43, 0x16, 0x70, 0x02, 0x77, 0x41, 0x51, 0xf1, 0x97, 0x8c, - 0x4d, 0xa3, 0x7a, 0xad, 0x66, 0x3a, 0x17, 0xa7, 0x76, 0x54, 0xcf, 0x7e, 0xe1, 0xec, 0xc7, 0x46, - 0xce, 0xd5, 0x78, 0xfb, 0x46, 0x4a, 0x18, 0x7b, 0x2f, 0x48, 0x6f, 0xa8, 0xb3, 0x0d, 0xd6, 0x26, - 0x5f, 0x6b, 0x21, 0x08, 0x0a, 0x2d, 0x9f, 0x8b, 0x92, 0xb1, 0x79, 0xa9, 0xba, 0xe4, 0xca, 0x67, - 0x3b, 0x02, 0x77, 0x53, 0x6c, 0xcb, 0x6f, 0x24, 0xf0, 0xa7, 0x87, 0x38, 0xa0, 0xa4, 0xae, 0x07, - 0xd2, 0x9c, 0x70, 0x19, 0xe4, 0xfd, 0xa6, 0x34, 0x58, 0x70, 0xf3, 0x7e, 0x13, 0xee, 0x81, 0x22, - 0x17, 0x58, 0xc4, 0xbc, 0x94, 0xdf, 0x34, 0xaa, 0xcb, 0x35, 0x7b, 0xaa, 0x69, 0x4d, 0xf2, 0x46, - 0x22, 0x5d, 0xdd, 0x61, 0x77, 0xc1, 0x56, 0x86, 0xa6, 0x36, 0xfc, 0x12, 0x5c, 0x4d, 0x83, 0xd5, - 0xd9, 0x3c, 0x98, 0x2a, 0x33, 0x83, 0x47, 0xa7, 0x35, 0xe4, 0xb0, 0x3f, 0x19, 0x19, 0xca, 0x69, - 0x84, 0xf0, 0x19, 0x00, 0xa3, 0xb5, 0xd1, 0xda, 0x65, 0x47, 0xed, 0x98, 0x93, 0xec, 0x98, 0xa3, - 0xd6, 0x54, 0xef, 0x98, 0x53, 0xc7, 0x94, 0xe8, 0x5e, 0x77, 0xac, 0xf3, 0xbf, 0x62, 0xfa, 0x6a, - 0x80, 0x72, 0x96, 0x5b, 0x1d, 0x54, 0x1d, 0x2c, 0xa5, 0x43, 0x72, 0xf9, 0x79, 0x17, 0x4b, 0x6a, - 0x44, 0x02, 0x9f, 0x4f, 0x04, 0x90, 0x97, 0x01, 0x54, 0x32, 0x03, 0x50, 0x76, 0xc6, 0x13, 0xa8, - 0xfd, 0x2e, 0x80, 0xcb, 0x72, 0x0a, 0x18, 0x81, 0xa2, 0xda, 0x62, 0x58, 0x9e, 0xe6, 0xed, 0xe2, - 0xc1, 0x98, 0x95, 0x4c, 0x9c, 0x12, 0xb4, 0x6f, 0xbe, 0xff, 0xf6, 0xeb, 0x63, 0x7e, 0x05, 0x5e, - 0xff, 0xeb, 0x62, 0x61, 0x17, 0x5c, 0xd1, 0x57, 0x00, 0xe7, 0x90, 0x4d, 0x9c, 0x8f, 0x59, 0xcd, - 0x06, 0x6a, 0xd9, 0x75, 0x29, 0xbb, 0x0a, 0x57, 0x46, 0xb2, 0xb1, 0x77, 0x70, 0x94, 0xa8, 0x7d, - 0x31, 0x40, 0x69, 0x56, 0xda, 0x70, 0x77, 0x9e, 0xc2, 0xbc, 0x33, 0x34, 0x1f, 0x2f, 0xd0, 0xa9, - 0xcd, 0x22, 0x69, 0xf6, 0x1e, 0xac, 0x8c, 0x9b, 0x4d, 0xbc, 0x1e, 0xa4, 0x5f, 0x1d, 0x9d, 0xa8, - 0xcd, 0x3b, 0x45, 0x27, 0x7e, 0xf3, 0x14, 0x7e, 0x36, 0xc0, 0xfa, 0xcc, 0xd5, 0x83, 0xff, 0xee, - 0x64, 0x18, 0xf0, 0xde, 0x22, 0xad, 0x7a, 0x8a, 0xfb, 0x72, 0x8a, 0x2d, 0x78, 0x67, 0xe6, 0x14, - 0x7c, 0x38, 0xc6, 0xfe, 0x93, 0xb3, 0xbe, 0x65, 0x9c, 0xf7, 0x2d, 0xe3, 0x67, 0xdf, 0x32, 0x3e, - 0x0c, 0xac, 0xdc, 0xf9, 0xc0, 0xca, 0x7d, 0x1f, 0x58, 0xb9, 0xb7, 0x65, 0xea, 0x8b, 0xc3, 0xd8, - 0x73, 0x1a, 0xac, 0x9d, 0x10, 0x3d, 0x1c, 0xff, 0x9f, 0xbf, 0x93, 0xb4, 0xa2, 0x17, 0x12, 0xee, - 0x15, 0xe5, 0xff, 0xfc, 0xd1, 0x9f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x29, 0x22, 0xb0, 0x10, 0xa9, - 0x06, 0x00, 0x00, + proto.RegisterType((*QueryParamsRequest)(nil), "sge.legacy.ovm.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.legacy.ovm.v1beta.QueryParamsResponse") + proto.RegisterType((*QueryPubKeysRequest)(nil), "sge.legacy.ovm.v1beta.QueryPubKeysRequest") + proto.RegisterType((*QueryPubKeysResponse)(nil), "sge.legacy.ovm.v1beta.QueryPubKeysResponse") + proto.RegisterType((*QueryPublicKeysChangeProposalRequest)(nil), "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalRequest") + proto.RegisterType((*QueryPublicKeysChangeProposalResponse)(nil), "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalResponse") + proto.RegisterType((*QueryPublicKeysChangeProposalsRequest)(nil), "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsRequest") + proto.RegisterType((*QueryPublicKeysChangeProposalsResponse)(nil), "sge.legacy.ovm.v1beta.QueryPublicKeysChangeProposalsResponse") +} + +func init() { proto.RegisterFile("sge/legacy/ovm/v1beta/query.proto", fileDescriptor_540087383b5674a2) } + +var fileDescriptor_540087383b5674a2 = []byte{ + // 618 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0x4d, 0x4f, 0x13, 0x4f, + 0x18, 0xef, 0xf6, 0x0f, 0xfd, 0xcb, 0x98, 0x60, 0x18, 0x20, 0x96, 0x46, 0xd7, 0xba, 0x52, 0x28, + 0x25, 0xcc, 0x84, 0x7a, 0x44, 0x2e, 0x98, 0xc8, 0xc1, 0x4b, 0x59, 0x6e, 0x5e, 0xc8, 0x6c, 0x3b, + 0x19, 0x36, 0xb4, 0x3b, 0x4b, 0x67, 0xb6, 0x52, 0x49, 0x2f, 0x7e, 0x02, 0x8d, 0xdf, 0xc3, 0x6f, + 0x21, 0xe1, 0x48, 0xe2, 0xc5, 0x93, 0x31, 0xad, 0x1f, 0xc4, 0xec, 0xcc, 0x6c, 0x5f, 0x22, 0x4b, + 0x49, 0xbd, 0x6d, 0xb6, 0xbf, 0xb7, 0xe7, 0xd7, 0xe7, 0x69, 0xc1, 0x73, 0xc1, 0x28, 0x6e, 0x52, + 0x46, 0xea, 0x5d, 0xcc, 0x3b, 0x2d, 0xdc, 0xd9, 0xf5, 0xa8, 0x24, 0xf8, 0x3c, 0xa2, 0xed, 0x2e, + 0x0a, 0xdb, 0x5c, 0x72, 0xb8, 0x2a, 0x18, 0x45, 0x1a, 0x82, 0x78, 0xa7, 0x85, 0x34, 0xa4, 0x50, + 0xa9, 0x73, 0xd1, 0xe2, 0x02, 0x7b, 0x44, 0x50, 0x8d, 0x37, 0xe4, 0x5d, 0x1c, 0x12, 0xe6, 0x07, + 0x44, 0xfa, 0x3c, 0xd0, 0x12, 0x85, 0x15, 0xc6, 0x19, 0x57, 0x8f, 0x38, 0x7e, 0x32, 0x6f, 0x9f, + 0x30, 0xce, 0x59, 0x93, 0x62, 0x12, 0xfa, 0x98, 0x04, 0x01, 0x97, 0x8a, 0x22, 0xcc, 0xa7, 0xce, + 0xed, 0xc9, 0x42, 0xd2, 0x26, 0xad, 0x04, 0xb3, 0x9e, 0x82, 0x69, 0xf3, 0x90, 0x0b, 0xd2, 0xd4, + 0x28, 0x67, 0x05, 0xc0, 0xa3, 0x38, 0x5f, 0x4d, 0x51, 0x5d, 0x7a, 0x1e, 0x51, 0x21, 0x1d, 0x17, + 0x2c, 0x4f, 0xbc, 0x15, 0x21, 0x0f, 0x04, 0x85, 0x7b, 0x20, 0xa7, 0x2d, 0xf2, 0x56, 0xd1, 0x2a, + 0x3f, 0xac, 0x3e, 0x45, 0xb7, 0x8e, 0x8f, 0x34, 0xed, 0x60, 0xee, 0xfa, 0xe7, 0xb3, 0x8c, 0x6b, + 0x28, 0xce, 0x6a, 0xa2, 0x19, 0x79, 0x6f, 0x69, 0x77, 0x68, 0x55, 0x01, 0x2b, 0x93, 0xaf, 0x8d, + 0x17, 0x04, 0x73, 0x4d, 0x5f, 0xc8, 0xbc, 0x55, 0xfc, 0xaf, 0xbc, 0xe0, 0xaa, 0x67, 0x27, 0x02, + 0xeb, 0x09, 0xb6, 0xe9, 0xd7, 0x63, 0xf8, 0xeb, 0x53, 0x12, 0x30, 0x5a, 0x33, 0x33, 0x19, 0x4d, + 0xb8, 0x08, 0xb2, 0x7e, 0x43, 0x65, 0x9c, 0x73, 0xb3, 0x7e, 0x03, 0xee, 0x83, 0x9c, 0x90, 0x44, + 0x46, 0x22, 0x9f, 0x2d, 0x5a, 0xe5, 0xc5, 0x6a, 0x29, 0x2d, 0xb7, 0xd1, 0x39, 0x56, 0x60, 0xd7, + 0x90, 0x9c, 0x0f, 0xa0, 0x34, 0xc5, 0xd6, 0x64, 0x3e, 0x02, 0x0f, 0x92, 0x7a, 0x4d, 0x43, 0x38, + 0xcd, 0x29, 0x45, 0xca, 0x74, 0x36, 0x94, 0x71, 0xbe, 0x5a, 0x53, 0xcc, 0x93, 0x22, 0xe1, 0x1b, + 0x00, 0x46, 0xbb, 0x65, 0xec, 0x37, 0x90, 0x5e, 0x44, 0x14, 0x2f, 0x22, 0xd2, 0x8b, 0x6b, 0x16, + 0x11, 0xd5, 0x08, 0xa3, 0x86, 0xeb, 0x8e, 0x31, 0xff, 0xb5, 0xac, 0x2b, 0x0b, 0x6c, 0x4c, 0x0b, + 0x6c, 0xea, 0x3a, 0x06, 0x0b, 0xc9, 0x9c, 0x42, 0x7d, 0xcf, 0x33, 0xf7, 0x35, 0xd2, 0x81, 0x87, + 0x13, 0x35, 0x64, 0x55, 0x0d, 0x9b, 0x53, 0x6b, 0xd0, 0x89, 0xc6, 0x7b, 0xa8, 0x7e, 0x9e, 0x07, + 0xf3, 0x6a, 0x10, 0x78, 0x01, 0x72, 0x7a, 0xa3, 0xe1, 0x56, 0x4a, 0xbc, 0xbf, 0x4f, 0xa8, 0x50, + 0xb9, 0x0f, 0x54, 0xdb, 0x3a, 0x8f, 0x3f, 0x7e, 0xff, 0xfd, 0x25, 0xbb, 0x04, 0x1f, 0xe1, 0xf8, + 0x66, 0xe3, 0x63, 0xd5, 0x37, 0x03, 0x7b, 0xe0, 0x7f, 0x73, 0x17, 0xf0, 0x6e, 0xbd, 0x89, 0x9b, + 0x2a, 0x6c, 0xdf, 0x0b, 0x6b, 0xcc, 0xd7, 0x94, 0xf9, 0x32, 0x5c, 0x1a, 0x99, 0x47, 0xde, 0xc9, + 0x59, 0xec, 0x79, 0x65, 0x81, 0x7c, 0x5a, 0xf3, 0x70, 0x6f, 0x8a, 0xc9, 0x5d, 0x17, 0x5a, 0x78, + 0x35, 0x1b, 0xd9, 0x44, 0xc6, 0x2a, 0xf2, 0x16, 0xdc, 0x1c, 0x8f, 0x1c, 0x27, 0x3e, 0x49, 0xf6, + 0x00, 0x5f, 0xea, 0x75, 0xec, 0xe1, 0x4b, 0xbf, 0xd1, 0x83, 0xdf, 0x2c, 0xb0, 0x96, 0xba, 0x8f, + 0x70, 0xa6, 0x30, 0xc3, 0xb2, 0xf7, 0x67, 0x64, 0x9b, 0x59, 0xb6, 0xd5, 0x2c, 0x25, 0xf8, 0x22, + 0x75, 0x16, 0x31, 0x1c, 0xe6, 0xe0, 0xf0, 0xba, 0x6f, 0x5b, 0x37, 0x7d, 0xdb, 0xfa, 0xd5, 0xb7, + 0xad, 0x4f, 0x03, 0x3b, 0x73, 0x33, 0xb0, 0x33, 0x3f, 0x06, 0x76, 0xe6, 0xdd, 0x0e, 0xf3, 0xe5, + 0x69, 0xe4, 0xa1, 0x3a, 0x6f, 0xc5, 0x42, 0x3b, 0x01, 0x95, 0xef, 0x79, 0xfb, 0x4c, 0x89, 0x5e, + 0x8c, 0xff, 0x0d, 0xc8, 0x6e, 0x48, 0x85, 0x97, 0x53, 0xbf, 0xfe, 0x2f, 0xff, 0x04, 0x00, 0x00, + 0xff, 0xff, 0x49, 0x61, 0x37, 0x92, 0xe3, 0x06, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -500,7 +500,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.ovm.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.ovm.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -509,7 +509,7 @@ func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts . func (c *queryClient) PubKeys(ctx context.Context, in *QueryPubKeysRequest, opts ...grpc.CallOption) (*QueryPubKeysResponse, error) { out := new(QueryPubKeysResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.ovm.Query/PubKeys", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.ovm.v1beta.Query/PubKeys", in, out, opts...) if err != nil { return nil, err } @@ -518,7 +518,7 @@ func (c *queryClient) PubKeys(ctx context.Context, in *QueryPubKeysRequest, opts func (c *queryClient) PublicKeysChangeProposal(ctx context.Context, in *QueryPublicKeysChangeProposalRequest, opts ...grpc.CallOption) (*QueryPublicKeysChangeProposalResponse, error) { out := new(QueryPublicKeysChangeProposalResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.ovm.Query/PublicKeysChangeProposal", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.ovm.v1beta.Query/PublicKeysChangeProposal", in, out, opts...) if err != nil { return nil, err } @@ -527,7 +527,7 @@ func (c *queryClient) PublicKeysChangeProposal(ctx context.Context, in *QueryPub func (c *queryClient) PublicKeysChangeProposals(ctx context.Context, in *QueryPublicKeysChangeProposalsRequest, opts ...grpc.CallOption) (*QueryPublicKeysChangeProposalsResponse, error) { out := new(QueryPublicKeysChangeProposalsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.ovm.Query/PublicKeysChangeProposals", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.ovm.v1beta.Query/PublicKeysChangeProposals", in, out, opts...) if err != nil { return nil, err } @@ -577,7 +577,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.ovm.Query/Params", + FullMethod: "/sge.legacy.ovm.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -595,7 +595,7 @@ func _Query_PubKeys_Handler(srv interface{}, ctx context.Context, dec func(inter } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.ovm.Query/PubKeys", + FullMethod: "/sge.legacy.ovm.v1beta.Query/PubKeys", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PubKeys(ctx, req.(*QueryPubKeysRequest)) @@ -613,7 +613,7 @@ func _Query_PublicKeysChangeProposal_Handler(srv interface{}, ctx context.Contex } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.ovm.Query/PublicKeysChangeProposal", + FullMethod: "/sge.legacy.ovm.v1beta.Query/PublicKeysChangeProposal", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PublicKeysChangeProposal(ctx, req.(*QueryPublicKeysChangeProposalRequest)) @@ -631,7 +631,7 @@ func _Query_PublicKeysChangeProposals_Handler(srv interface{}, ctx context.Conte } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.ovm.Query/PublicKeysChangeProposals", + FullMethod: "/sge.legacy.ovm.v1beta.Query/PublicKeysChangeProposals", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PublicKeysChangeProposals(ctx, req.(*QueryPublicKeysChangeProposalsRequest)) @@ -639,8 +639,9 @@ func _Query_PublicKeysChangeProposals_Handler(srv interface{}, ctx context.Conte return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.ovm.Query", + ServiceName: "sge.legacy.ovm.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -661,7 +662,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/ovm/query.proto", + Metadata: "sge/legacy/ovm/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/query.pb.gw.go b/x/legacy/ovm/types/query.pb.gw.go similarity index 99% rename from x/ovm/types/query.pb.gw.go rename to x/legacy/ovm/types/query.pb.gw.go index 7559c9a5..99336401 100644 --- a/x/ovm/types/query.pb.gw.go +++ b/x/legacy/ovm/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/ovm/query.proto +// source: sge/legacy/ovm/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/ovm/types/stats.pb.go b/x/legacy/ovm/types/stats.pb.go similarity index 81% rename from x/ovm/types/stats.pb.go rename to x/legacy/ovm/types/stats.pb.go index 52cbb048..5c9283ae 100644 --- a/x/ovm/types/stats.pb.go +++ b/x/legacy/ovm/types/stats.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/stats.proto +// source: sge/legacy/ovm/v1beta/stats.proto package types @@ -32,7 +32,7 @@ func (m *ProposalStats) Reset() { *m = ProposalStats{} } func (m *ProposalStats) String() string { return proto.CompactTextString(m) } func (*ProposalStats) ProtoMessage() {} func (*ProposalStats) Descriptor() ([]byte, []int) { - return fileDescriptor_194a174fcf0c1b0d, []int{0} + return fileDescriptor_ecd6d01cb0888f69, []int{0} } func (m *ProposalStats) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -69,25 +69,26 @@ func (m *ProposalStats) GetPubkeysChangeCount() uint64 { } func init() { - proto.RegisterType((*ProposalStats)(nil), "sgenetwork.sge.ovm.ProposalStats") + proto.RegisterType((*ProposalStats)(nil), "sge.legacy.ovm.v1beta.ProposalStats") } -func init() { proto.RegisterFile("sgenetwork/sge/ovm/stats.proto", fileDescriptor_194a174fcf0c1b0d) } +func init() { proto.RegisterFile("sge/legacy/ovm/v1beta/stats.proto", fileDescriptor_ecd6d01cb0888f69) } -var fileDescriptor_194a174fcf0c1b0d = []byte{ - // 181 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2b, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0xcb, 0xd5, 0x2f, - 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x42, 0xc8, 0xeb, 0x15, - 0xa7, 0xa7, 0xea, 0xe5, 0x97, 0xe5, 0x2a, 0x39, 0x72, 0xf1, 0x06, 0x14, 0xe5, 0x17, 0xe4, 0x17, - 0x27, 0xe6, 0x04, 0x83, 0x94, 0x0a, 0x19, 0x70, 0x89, 0x14, 0x94, 0x26, 0x65, 0xa7, 0x56, 0x16, - 0xc7, 0x27, 0x67, 0x24, 0xe6, 0xa5, 0xa7, 0xc6, 0x27, 0xe7, 0x97, 0xe6, 0x95, 0x48, 0x30, 0x2a, - 0x30, 0x6a, 0xb0, 0x04, 0x09, 0x41, 0xe5, 0x9c, 0xc1, 0x52, 0xce, 0x20, 0x19, 0x27, 0x87, 0x13, - 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, - 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0x52, 0x4b, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, - 0xd2, 0x4b, 0xce, 0xcf, 0x05, 0x39, 0x48, 0x17, 0xd9, 0x71, 0x15, 0x60, 0xe7, 0x95, 0x54, 0x16, - 0xa4, 0x16, 0x27, 0xb1, 0x81, 0xdd, 0x67, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x0b, 0x85, 0x9e, - 0xf0, 0xc1, 0x00, 0x00, 0x00, +var fileDescriptor_ecd6d01cb0888f69 = []byte{ + // 197 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x2f, 0xcb, 0xd5, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, + 0x49, 0xd4, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x2d, + 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd1, 0xcb, 0x2f, 0xcb, 0xd5, 0x83, 0x28, 0x51, 0x72, 0xe4, 0xe2, + 0x0d, 0x28, 0xca, 0x2f, 0xc8, 0x2f, 0x4e, 0xcc, 0x09, 0x06, 0xa9, 0x16, 0x32, 0xe0, 0x12, 0x29, + 0x28, 0x4d, 0xca, 0x4e, 0xad, 0x2c, 0x8e, 0x4f, 0xce, 0x48, 0xcc, 0x4b, 0x4f, 0x8d, 0x4f, 0xce, + 0x2f, 0xcd, 0x2b, 0x91, 0x60, 0x54, 0x60, 0xd4, 0x60, 0x09, 0x12, 0x82, 0xca, 0x39, 0x83, 0xa5, + 0x9c, 0x41, 0x32, 0x4e, 0xee, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, + 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, + 0x9b, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0xab, 0x5f, 0x9c, 0x9e, 0xaa, 0x9b, + 0x97, 0x5a, 0x52, 0x9e, 0x5f, 0x94, 0x0d, 0x62, 0xeb, 0x57, 0x20, 0xbb, 0xb7, 0xa4, 0xb2, 0x20, + 0xb5, 0x38, 0x89, 0x0d, 0xec, 0x52, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x87, 0x97, 0xae, + 0xa3, 0xce, 0x00, 0x00, 0x00, } func (m *ProposalStats) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/ticket.go b/x/legacy/ovm/types/ticket.go similarity index 100% rename from x/ovm/types/ticket.go rename to x/legacy/ovm/types/ticket.go diff --git a/x/ovm/types/ticket.pb.go b/x/legacy/ovm/types/ticket.pb.go similarity index 84% rename from x/ovm/types/ticket.pb.go rename to x/legacy/ovm/types/ticket.pb.go index 36661ab7..9eb00a7d 100644 --- a/x/ovm/types/ticket.pb.go +++ b/x/legacy/ovm/types/ticket.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/ticket.proto +// source: sge/legacy/ovm/v1beta/ticket.proto package types @@ -35,7 +35,7 @@ func (m *PubkeysChangeProposalPayload) Reset() { *m = PubkeysChangePropo func (m *PubkeysChangeProposalPayload) String() string { return proto.CompactTextString(m) } func (*PubkeysChangeProposalPayload) ProtoMessage() {} func (*PubkeysChangeProposalPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_927c5f9e79be7a2e, []int{0} + return fileDescriptor_3f542d143f63c24d, []int{0} } func (m *PubkeysChangeProposalPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -83,14 +83,14 @@ type ProposalVotePayload struct { // proposal_id is the id of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` // vote is the chosen option for the vote. - Vote ProposalVote `protobuf:"varint,2,opt,name=vote,proto3,enum=sgenetwork.sge.ovm.ProposalVote" json:"vote,omitempty"` + Vote ProposalVote `protobuf:"varint,2,opt,name=vote,proto3,enum=sge.legacy.ovm.v1beta.ProposalVote" json:"vote,omitempty"` } func (m *ProposalVotePayload) Reset() { *m = ProposalVotePayload{} } func (m *ProposalVotePayload) String() string { return proto.CompactTextString(m) } func (*ProposalVotePayload) ProtoMessage() {} func (*ProposalVotePayload) Descriptor() ([]byte, []int) { - return fileDescriptor_927c5f9e79be7a2e, []int{1} + return fileDescriptor_3f542d143f63c24d, []int{1} } func (m *ProposalVotePayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -134,32 +134,34 @@ func (m *ProposalVotePayload) GetVote() ProposalVote { } func init() { - proto.RegisterType((*PubkeysChangeProposalPayload)(nil), "sgenetwork.sge.ovm.PubkeysChangeProposalPayload") - proto.RegisterType((*ProposalVotePayload)(nil), "sgenetwork.sge.ovm.ProposalVotePayload") + proto.RegisterType((*PubkeysChangeProposalPayload)(nil), "sge.legacy.ovm.v1beta.PubkeysChangeProposalPayload") + proto.RegisterType((*ProposalVotePayload)(nil), "sge.legacy.ovm.v1beta.ProposalVotePayload") } -func init() { proto.RegisterFile("sgenetwork/sge/ovm/ticket.proto", fileDescriptor_927c5f9e79be7a2e) } +func init() { + proto.RegisterFile("sge/legacy/ovm/v1beta/ticket.proto", fileDescriptor_3f542d143f63c24d) +} -var fileDescriptor_927c5f9e79be7a2e = []byte{ - // 273 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x90, 0xbd, 0x4e, 0x84, 0x40, - 0x14, 0x46, 0x19, 0xdd, 0x98, 0x38, 0xab, 0x16, 0xd8, 0x10, 0xa3, 0xb3, 0xb8, 0x85, 0xa1, 0x71, - 0x48, 0xd4, 0x07, 0x30, 0x5a, 0x6d, 0x6c, 0x08, 0x85, 0x85, 0x0d, 0xe1, 0xe7, 0x86, 0x25, 0x0c, - 0x5c, 0xc2, 0x0c, 0xb8, 0xbc, 0x85, 0x8f, 0x65, 0xb9, 0xa5, 0xa5, 0x81, 0x17, 0x31, 0x80, 0x1b, - 0x49, 0xdc, 0xf6, 0xe4, 0xbb, 0x27, 0x33, 0x87, 0x2e, 0x64, 0x0c, 0x39, 0xa8, 0x77, 0x2c, 0x53, - 0x5b, 0xc6, 0x60, 0x63, 0x9d, 0xd9, 0x2a, 0x09, 0x53, 0x50, 0xbc, 0x28, 0x51, 0xa1, 0xae, 0xff, - 0x0d, 0xb8, 0x8c, 0x81, 0x63, 0x9d, 0x5d, 0x5c, 0xed, 0x39, 0xaa, 0x51, 0xc1, 0x78, 0xb2, 0x0c, - 0xe8, 0xa5, 0x53, 0x05, 0x29, 0x34, 0xf2, 0x79, 0xed, 0xe7, 0x31, 0x38, 0x25, 0x16, 0x28, 0x7d, - 0xe1, 0xf8, 0x8d, 0x40, 0x3f, 0xd2, 0x17, 0x74, 0x5e, 0x54, 0x81, 0x48, 0x42, 0xaf, 0xdf, 0x18, - 0xc4, 0x3c, 0xb4, 0x8e, 0x5d, 0x3a, 0xa2, 0x17, 0x68, 0xa4, 0x7e, 0x4d, 0x4f, 0x04, 0xf8, 0x11, - 0x94, 0x5e, 0x92, 0x47, 0xb0, 0x31, 0x0e, 0x4c, 0x62, 0x9d, 0xba, 0xf3, 0x91, 0xad, 0x7a, 0xb4, - 0x14, 0xf4, 0x7c, 0xa7, 0x7d, 0x45, 0x05, 0x53, 0xf5, 0x2f, 0xf6, 0x92, 0xc8, 0x20, 0x26, 0xb1, - 0x66, 0x2e, 0xdd, 0xa1, 0x55, 0xa4, 0x3f, 0xd0, 0x59, 0xff, 0xd2, 0x41, 0x79, 0x76, 0x67, 0xf2, - 0xff, 0xbf, 0xe3, 0x53, 0xaf, 0x3b, 0xac, 0x9f, 0x1e, 0x3f, 0x5b, 0x46, 0xb6, 0x2d, 0x23, 0xdf, - 0x2d, 0x23, 0x1f, 0x1d, 0xd3, 0xb6, 0x1d, 0xd3, 0xbe, 0x3a, 0xa6, 0xbd, 0xdd, 0xc4, 0x89, 0x5a, - 0x57, 0x01, 0x0f, 0x31, 0xeb, 0x53, 0xdc, 0x4e, 0xb3, 0x6c, 0xc6, 0x9a, 0x4d, 0x01, 0x32, 0x38, - 0x1a, 0xd2, 0xdc, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0x9b, 0xd6, 0x02, 0x4e, 0x70, 0x01, 0x00, - 0x00, +var fileDescriptor_3f542d143f63c24d = []byte{ + // 287 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x90, 0xbf, 0x4e, 0xf3, 0x30, + 0x14, 0xc5, 0xeb, 0xef, 0xab, 0x90, 0x70, 0x81, 0x21, 0x08, 0xa9, 0x42, 0xc8, 0x84, 0xb2, 0x74, + 0xa9, 0x2d, 0x60, 0x60, 0x87, 0x01, 0x55, 0x2c, 0x55, 0x06, 0x06, 0x96, 0xca, 0x4e, 0xae, 0xdc, + 0x28, 0x7f, 0x6e, 0x14, 0x3b, 0xa1, 0x79, 0x0b, 0x1e, 0x8b, 0xb1, 0x23, 0x23, 0x4a, 0x5e, 0x04, + 0x25, 0xa1, 0x52, 0x86, 0x6e, 0xd6, 0x4f, 0xe7, 0xfc, 0xe4, 0x7b, 0xe8, 0xcc, 0x68, 0x10, 0x31, + 0x68, 0xe9, 0x57, 0x02, 0xcb, 0x44, 0x94, 0x77, 0x0a, 0xac, 0x14, 0x36, 0xf4, 0x23, 0xb0, 0x3c, + 0xcb, 0xd1, 0xa2, 0x73, 0x61, 0x34, 0xf0, 0x3e, 0xc3, 0xb1, 0x4c, 0x78, 0x9f, 0xb9, 0x74, 0x0f, + 0x57, 0x4b, 0xb4, 0xd0, 0x17, 0x67, 0x8a, 0x5e, 0xad, 0x0a, 0x15, 0x41, 0x65, 0x9e, 0x37, 0x32, + 0xd5, 0xb0, 0xca, 0x31, 0x43, 0x23, 0xe3, 0x95, 0xac, 0x62, 0x94, 0x81, 0x73, 0x4d, 0x27, 0x59, + 0xa1, 0xe2, 0xd0, 0x5f, 0xb7, 0x99, 0x29, 0x71, 0xff, 0xcf, 0x8f, 0x3d, 0xda, 0xa3, 0x57, 0xa8, + 0x8c, 0x73, 0x43, 0x4f, 0x62, 0x90, 0x01, 0xe4, 0xeb, 0x30, 0x0d, 0x60, 0x3b, 0xfd, 0xe7, 0x92, + 0xf9, 0xa9, 0x37, 0xe9, 0xd9, 0xb2, 0x45, 0x33, 0xa4, 0xe7, 0x7b, 0xed, 0x1b, 0x5a, 0x18, 0xaa, + 0xff, 0xf0, 0x3a, 0x0c, 0xa6, 0xc4, 0x25, 0xf3, 0xb1, 0x47, 0xf7, 0x68, 0x19, 0x38, 0x8f, 0x74, + 0xdc, 0xfe, 0xb4, 0x53, 0x9e, 0xdd, 0xdf, 0xf2, 0x83, 0x37, 0xf2, 0xa1, 0xda, 0xeb, 0x0a, 0x4f, + 0x2f, 0x5f, 0x35, 0x23, 0xbb, 0x9a, 0x91, 0x9f, 0x9a, 0x91, 0xcf, 0x86, 0x8d, 0x76, 0x0d, 0x1b, + 0x7d, 0x37, 0x6c, 0xf4, 0xbe, 0xd0, 0xa1, 0xdd, 0x14, 0x8a, 0xfb, 0x98, 0x08, 0xa3, 0x61, 0x91, + 0x82, 0xfd, 0xc0, 0x3c, 0x6a, 0xdf, 0x62, 0x3b, 0x5c, 0xca, 0x56, 0x19, 0x18, 0x75, 0xd4, 0x8d, + 0xf4, 0xf0, 0x1b, 0x00, 0x00, 0xff, 0xff, 0x77, 0x09, 0x28, 0x94, 0x83, 0x01, 0x00, 0x00, } func (m *PubkeysChangeProposalPayload) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/ticket_jwt.go b/x/legacy/ovm/types/ticket_jwt.go similarity index 100% rename from x/ovm/types/ticket_jwt.go rename to x/legacy/ovm/types/ticket_jwt.go diff --git a/x/ovm/types/tx.pb.go b/x/legacy/ovm/types/tx.pb.go similarity index 88% rename from x/ovm/types/tx.pb.go rename to x/legacy/ovm/types/tx.pb.go index 9f5dbe1f..311086f6 100644 --- a/x/ovm/types/tx.pb.go +++ b/x/legacy/ovm/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/tx.proto +// source: sge/legacy/ovm/v1beta/tx.proto package types @@ -44,7 +44,7 @@ func (m *MsgSubmitPubkeysChangeProposalRequest) Reset() { *m = MsgSubmit func (m *MsgSubmitPubkeysChangeProposalRequest) String() string { return proto.CompactTextString(m) } func (*MsgSubmitPubkeysChangeProposalRequest) ProtoMessage() {} func (*MsgSubmitPubkeysChangeProposalRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_f051013778245841, []int{0} + return fileDescriptor_633ba242b03a5b58, []int{0} } func (m *MsgSubmitPubkeysChangeProposalRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -99,7 +99,7 @@ func (m *MsgSubmitPubkeysChangeProposalResponse) Reset() { func (m *MsgSubmitPubkeysChangeProposalResponse) String() string { return proto.CompactTextString(m) } func (*MsgSubmitPubkeysChangeProposalResponse) ProtoMessage() {} func (*MsgSubmitPubkeysChangeProposalResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f051013778245841, []int{1} + return fileDescriptor_633ba242b03a5b58, []int{1} } func (m *MsgSubmitPubkeysChangeProposalResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -151,7 +151,7 @@ func (m *MsgVotePubkeysChangeRequest) Reset() { *m = MsgVotePubkeysChang func (m *MsgVotePubkeysChangeRequest) String() string { return proto.CompactTextString(m) } func (*MsgVotePubkeysChangeRequest) ProtoMessage() {} func (*MsgVotePubkeysChangeRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_f051013778245841, []int{2} + return fileDescriptor_633ba242b03a5b58, []int{2} } func (m *MsgVotePubkeysChangeRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -211,7 +211,7 @@ func (m *MsgVotePubkeysChangeResponse) Reset() { *m = MsgVotePubkeysChan func (m *MsgVotePubkeysChangeResponse) String() string { return proto.CompactTextString(m) } func (*MsgVotePubkeysChangeResponse) ProtoMessage() {} func (*MsgVotePubkeysChangeResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f051013778245841, []int{3} + return fileDescriptor_633ba242b03a5b58, []int{3} } func (m *MsgVotePubkeysChangeResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -260,7 +260,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_f051013778245841, []int{4} + return fileDescriptor_633ba242b03a5b58, []int{4} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -312,7 +312,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f051013778245841, []int{5} + return fileDescriptor_633ba242b03a5b58, []int{5} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -342,53 +342,54 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgSubmitPubkeysChangeProposalRequest)(nil), "sgenetwork.sge.ovm.MsgSubmitPubkeysChangeProposalRequest") - proto.RegisterType((*MsgSubmitPubkeysChangeProposalResponse)(nil), "sgenetwork.sge.ovm.MsgSubmitPubkeysChangeProposalResponse") - proto.RegisterType((*MsgVotePubkeysChangeRequest)(nil), "sgenetwork.sge.ovm.MsgVotePubkeysChangeRequest") - proto.RegisterType((*MsgVotePubkeysChangeResponse)(nil), "sgenetwork.sge.ovm.MsgVotePubkeysChangeResponse") - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.ovm.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.ovm.MsgUpdateParamsResponse") + proto.RegisterType((*MsgSubmitPubkeysChangeProposalRequest)(nil), "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalRequest") + proto.RegisterType((*MsgSubmitPubkeysChangeProposalResponse)(nil), "sge.legacy.ovm.v1beta.MsgSubmitPubkeysChangeProposalResponse") + proto.RegisterType((*MsgVotePubkeysChangeRequest)(nil), "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeRequest") + proto.RegisterType((*MsgVotePubkeysChangeResponse)(nil), "sge.legacy.ovm.v1beta.MsgVotePubkeysChangeResponse") + proto.RegisterType((*MsgUpdateParams)(nil), "sge.legacy.ovm.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.legacy.ovm.v1beta.MsgUpdateParamsResponse") } -func init() { proto.RegisterFile("sgenetwork/sge/ovm/tx.proto", fileDescriptor_f051013778245841) } +func init() { proto.RegisterFile("sge/legacy/ovm/v1beta/tx.proto", fileDescriptor_633ba242b03a5b58) } -var fileDescriptor_f051013778245841 = []byte{ - // 558 bytes of a gzipped FileDescriptorProto +var fileDescriptor_633ba242b03a5b58 = []byte{ + // 566 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x54, 0xcf, 0x6b, 0x13, 0x41, - 0x14, 0xce, 0x24, 0x90, 0x9a, 0xb1, 0xa5, 0x64, 0xa8, 0x76, 0xdd, 0xc8, 0x36, 0xa4, 0x18, 0x4a, - 0x25, 0xbb, 0x4d, 0x04, 0x7f, 0x04, 0x04, 0x8d, 0x27, 0x91, 0x40, 0xd8, 0xa2, 0x07, 0x2f, 0x61, - 0xb3, 0x19, 0x26, 0x4b, 0xdc, 0x9d, 0x75, 0xdf, 0x6c, 0x4c, 0xf4, 0xa4, 0xa7, 0x1e, 0xbd, 0xea, - 0xc5, 0xab, 0x17, 0xa1, 0x87, 0xfe, 0x11, 0xc5, 0x53, 0xe9, 0xc9, 0x93, 0x48, 0x72, 0xe8, 0xbf, - 0x21, 0xd9, 0xdd, 0x98, 0xb4, 0xdd, 0x98, 0x20, 0x78, 0x49, 0xf6, 0xbd, 0xf7, 0x7d, 0xf3, 0xbe, - 0x8f, 0xf7, 0x78, 0x38, 0x07, 0x8c, 0x3a, 0x54, 0xbc, 0xe1, 0x5e, 0x57, 0x03, 0x46, 0x35, 0xde, - 0xb3, 0x35, 0xd1, 0x57, 0x5d, 0x8f, 0x0b, 0x4e, 0xc8, 0xb4, 0xa8, 0x02, 0xa3, 0x2a, 0xef, 0xd9, - 0x72, 0xd6, 0xb0, 0x2d, 0x87, 0x6b, 0xc1, 0x6f, 0x08, 0x93, 0x37, 0x4d, 0x0e, 0x36, 0x07, 0xcd, - 0x06, 0xa6, 0xf5, 0xca, 0xe3, 0xbf, 0xa8, 0x70, 0x23, 0x2c, 0x34, 0x83, 0x48, 0x0b, 0x83, 0xa8, - 0xb4, 0xc1, 0x38, 0xe3, 0x61, 0x7e, 0xfc, 0x15, 0x65, 0xb7, 0x62, 0xd4, 0xb8, 0x86, 0x67, 0xd8, - 0x11, 0xad, 0xf0, 0x1e, 0xe1, 0x5b, 0x75, 0x60, 0xfb, 0x7e, 0xcb, 0xb6, 0x44, 0xc3, 0x6f, 0x75, - 0xe9, 0x00, 0x9e, 0x74, 0x0c, 0x87, 0xd1, 0x86, 0xc7, 0x5d, 0x0e, 0xc6, 0x2b, 0x9d, 0xbe, 0xf6, - 0x29, 0x08, 0x52, 0xc1, 0x2b, 0xa6, 0x47, 0x0d, 0xc1, 0x3d, 0x09, 0xe5, 0xd1, 0x4e, 0xa6, 0x26, - 0x9d, 0x1e, 0x95, 0x36, 0x22, 0x0d, 0x8f, 0xdb, 0x6d, 0x8f, 0x02, 0xec, 0x0b, 0xcf, 0x72, 0x98, - 0x3e, 0x01, 0x92, 0xeb, 0x38, 0x2d, 0x2c, 0xb3, 0x4b, 0x85, 0x94, 0x1c, 0x53, 0xf4, 0x28, 0xaa, - 0xae, 0x7e, 0x38, 0x3b, 0xdc, 0x9d, 0xa0, 0x0a, 0x35, 0x5c, 0x5c, 0x24, 0x01, 0x5c, 0xee, 0x00, - 0x25, 0x12, 0x5e, 0x01, 0xdf, 0x34, 0x29, 0x40, 0xa0, 0xe1, 0x8a, 0x3e, 0x09, 0x0b, 0x5f, 0x10, - 0xce, 0xd5, 0x81, 0xbd, 0xe0, 0x82, 0x9e, 0x7b, 0xe2, 0x3f, 0xa8, 0x27, 0x45, 0xbc, 0xde, 0xe3, - 0x82, 0x7a, 0xcd, 0x2e, 0x1d, 0x34, 0x2d, 0xa7, 0x4d, 0xfb, 0x52, 0x2a, 0x8f, 0x76, 0xd6, 0xf4, - 0xb5, 0x20, 0xfd, 0x8c, 0x0e, 0x9e, 0x8e, 0x93, 0x17, 0x5c, 0xde, 0xc7, 0x37, 0xe3, 0x05, 0x2e, - 0xf4, 0xf6, 0x0d, 0xe1, 0xf5, 0x3a, 0xb0, 0xe7, 0x6e, 0xdb, 0x10, 0xb4, 0x11, 0x4c, 0x8f, 0xdc, - 0xc5, 0x19, 0xc3, 0x17, 0x1d, 0xee, 0x59, 0x62, 0xb0, 0xd0, 0xd1, 0x14, 0x4a, 0x1e, 0xe2, 0x74, - 0x38, 0xff, 0xc0, 0xd3, 0xd5, 0x8a, 0xac, 0x5e, 0x5e, 0x49, 0x35, 0xec, 0x51, 0xcb, 0x1c, 0xff, - 0xdc, 0x4a, 0x7c, 0x3d, 0x3b, 0xdc, 0x45, 0x7a, 0x44, 0xaa, 0x6e, 0x9f, 0x1e, 0x95, 0xb2, 0xc0, - 0x68, 0x29, 0xa2, 0xe4, 0xcb, 0xea, 0x3d, 0xb5, 0x3c, 0xf6, 0x39, 0xed, 0x51, 0xd8, 0xc3, 0x9b, - 0x17, 0xe4, 0x4e, 0x4c, 0x56, 0xaf, 0xc5, 0xf2, 0x2b, 0x9f, 0x53, 0x38, 0x55, 0x07, 0x46, 0x3e, - 0x21, 0x9c, 0xfb, 0xcb, 0x1e, 0x90, 0x07, 0x71, 0x6a, 0x97, 0x5a, 0x5f, 0xb9, 0xfa, 0x2f, 0xd4, - 0x50, 0x75, 0x21, 0x75, 0x90, 0x44, 0xe4, 0x1d, 0xce, 0x5e, 0x1a, 0x1e, 0xd1, 0xe6, 0xbc, 0x3a, - 0x6f, 0x0f, 0xe5, 0xbd, 0xe5, 0x09, 0xb3, 0xcd, 0xdf, 0xe2, 0xd5, 0x73, 0xe3, 0xdf, 0x9e, 0xf3, - 0xcc, 0x2c, 0x48, 0xbe, 0xbd, 0x04, 0xe8, 0x4f, 0x1b, 0xe9, 0x7b, 0xdc, 0x64, 0x0e, 0x92, 0xa8, - 0xf6, 0xe8, 0x78, 0xa8, 0xa0, 0x93, 0xa1, 0x82, 0x7e, 0x0d, 0x15, 0xf4, 0x71, 0xa4, 0x24, 0x4e, - 0x46, 0x4a, 0xe2, 0xc7, 0x48, 0x49, 0xbc, 0x2c, 0x32, 0x4b, 0x74, 0xfc, 0x96, 0x6a, 0x72, 0x5b, - 0x9b, 0xa1, 0x06, 0x97, 0xa6, 0x1f, 0x5e, 0xbe, 0x81, 0x4b, 0xa1, 0x95, 0x0e, 0x6e, 0xcd, 0x9d, - 0xdf, 0x01, 0x00, 0x00, 0xff, 0xff, 0x34, 0x62, 0xbf, 0x4b, 0x1c, 0x05, 0x00, 0x00, + 0x14, 0xce, 0x34, 0x90, 0x9a, 0xb1, 0xa5, 0x64, 0x68, 0xed, 0x1a, 0x75, 0x0d, 0x2b, 0x86, 0x52, + 0xc8, 0xae, 0x49, 0x41, 0x25, 0x28, 0x68, 0x3c, 0x88, 0x48, 0x20, 0x6c, 0xd1, 0x83, 0x97, 0xb0, + 0xd9, 0x3c, 0x26, 0x4b, 0xba, 0x3b, 0xeb, 0xce, 0x6c, 0xcc, 0xde, 0xac, 0xa7, 0x1e, 0xfd, 0x0f, + 0xbc, 0x7a, 0x92, 0x1c, 0xfa, 0x47, 0x14, 0x4f, 0xa5, 0x27, 0x4f, 0x22, 0xc9, 0xa1, 0xff, 0x86, + 0xec, 0x8f, 0xd8, 0xb4, 0x6e, 0x4c, 0x15, 0xbc, 0xec, 0xce, 0x7b, 0xef, 0xfb, 0xe6, 0x7d, 0x1f, + 0xef, 0x31, 0x58, 0xe6, 0x14, 0xb4, 0x3d, 0xa0, 0x86, 0x19, 0x68, 0x6c, 0x60, 0x6b, 0x83, 0x6a, + 0x07, 0x84, 0xa1, 0x89, 0xa1, 0xea, 0x7a, 0x4c, 0x30, 0xb2, 0xc1, 0x29, 0xa8, 0x71, 0x5d, 0x65, + 0x03, 0x5b, 0x8d, 0xeb, 0xc5, 0x82, 0x61, 0x5b, 0x0e, 0xd3, 0xa2, 0x6f, 0x8c, 0x2c, 0x6e, 0x9a, + 0x8c, 0xdb, 0x8c, 0x6b, 0x36, 0xa7, 0xda, 0xa0, 0x1a, 0xfe, 0x92, 0xc2, 0xf5, 0xb8, 0xd0, 0x8e, + 0x22, 0x2d, 0x0e, 0x92, 0xd2, 0x3a, 0x65, 0x94, 0xc5, 0xf9, 0xf0, 0x94, 0x64, 0x95, 0x74, 0x4d, + 0xae, 0xe1, 0x19, 0x76, 0xc2, 0x54, 0xf6, 0x11, 0xbe, 0xdb, 0xe4, 0x74, 0xd7, 0xef, 0xd8, 0x96, + 0x68, 0xf9, 0x9d, 0x3e, 0x04, 0xfc, 0x59, 0xcf, 0x70, 0x28, 0xb4, 0x3c, 0xe6, 0x32, 0x6e, 0xec, + 0xe9, 0xf0, 0xd6, 0x07, 0x2e, 0x48, 0x0d, 0x2f, 0x9b, 0x1e, 0x18, 0x82, 0x79, 0x12, 0x2a, 0xa1, + 0xad, 0x7c, 0x43, 0x3a, 0x39, 0xac, 0xac, 0x27, 0x32, 0x9e, 0x76, 0xbb, 0x1e, 0x70, 0xbe, 0x2b, + 0x3c, 0xcb, 0xa1, 0xfa, 0x14, 0x48, 0xae, 0xe1, 0x9c, 0xb0, 0xcc, 0x3e, 0x08, 0x69, 0x29, 0xa4, + 0xe8, 0x49, 0x54, 0x5f, 0xf9, 0x70, 0x3a, 0xda, 0x9e, 0xa2, 0x94, 0x06, 0x2e, 0x2f, 0x92, 0xc0, + 0x5d, 0xe6, 0x70, 0x20, 0x12, 0x5e, 0xe6, 0xbe, 0x69, 0x02, 0xe7, 0x91, 0x86, 0x2b, 0xfa, 0x34, + 0x54, 0x3e, 0x21, 0x7c, 0xa3, 0xc9, 0xe9, 0x6b, 0x26, 0xe0, 0xdc, 0x15, 0xff, 0x41, 0x3d, 0x29, + 0xe3, 0xb5, 0x01, 0x13, 0xe0, 0xb5, 0xfb, 0x10, 0xb4, 0x2d, 0xa7, 0x0b, 0x43, 0x29, 0x5b, 0x42, + 0x5b, 0xab, 0xfa, 0x6a, 0x94, 0x7e, 0x09, 0xc1, 0x8b, 0x30, 0x79, 0xc1, 0xe5, 0x43, 0x7c, 0x33, + 0x5d, 0xe0, 0x42, 0x6f, 0x23, 0x84, 0xd7, 0x9a, 0x9c, 0xbe, 0x72, 0xbb, 0x86, 0x80, 0x56, 0x34, + 0x3d, 0x72, 0x1f, 0xe7, 0x0d, 0x5f, 0xf4, 0x98, 0x67, 0x89, 0x60, 0xa1, 0xa3, 0x33, 0x28, 0x79, + 0x82, 0x73, 0xf1, 0xfc, 0x23, 0x4f, 0x57, 0x6b, 0xb7, 0xd4, 0xd4, 0xc5, 0x54, 0xe3, 0x36, 0x8d, + 0xfc, 0xd1, 0xf7, 0xdb, 0x99, 0xcf, 0xa7, 0xa3, 0x6d, 0xa4, 0x27, 0xbc, 0xfa, 0x9d, 0x93, 0xc3, + 0x4a, 0x81, 0x53, 0xa8, 0x38, 0x20, 0xde, 0x31, 0xaf, 0x5f, 0xaa, 0xaa, 0x0f, 0xd4, 0x6a, 0x68, + 0xf5, 0xac, 0x8d, 0x72, 0x0f, 0x6f, 0x5e, 0x50, 0x3c, 0xf5, 0x59, 0xdf, 0x48, 0xe5, 0xd7, 0xbe, + 0x64, 0x71, 0xb6, 0xc9, 0x29, 0x09, 0x07, 0xf9, 0x87, 0x55, 0x20, 0x8f, 0xe6, 0x08, 0xbe, 0xd4, + 0x12, 0x17, 0x1f, 0xff, 0x23, 0x3b, 0xd6, 0xae, 0x64, 0x0f, 0x96, 0x10, 0xd9, 0x47, 0xb8, 0xf0, + 0xdb, 0x18, 0x49, 0x6d, 0xfe, 0xcd, 0xf3, 0x96, 0xb2, 0xb8, 0xf3, 0x57, 0x9c, 0x59, 0x0d, 0xef, + 0x11, 0x5e, 0x39, 0xb7, 0x0f, 0xe5, 0xf9, 0x57, 0xcd, 0xe2, 0x8a, 0xea, 0xe5, 0x70, 0xbf, 0xba, + 0x49, 0x5f, 0xd3, 0xa6, 0x75, 0xb0, 0x84, 0x1a, 0xcf, 0x8f, 0xc6, 0x32, 0x3a, 0x1e, 0xcb, 0xe8, + 0xc7, 0x58, 0x46, 0x1f, 0x27, 0x72, 0xe6, 0x78, 0x22, 0x67, 0xbe, 0x4d, 0xe4, 0xcc, 0x9b, 0x0a, + 0xb5, 0x44, 0xcf, 0xef, 0xa8, 0x26, 0xb3, 0xb5, 0x19, 0x6a, 0x78, 0xd6, 0x86, 0xb3, 0x0f, 0x92, + 0x08, 0x5c, 0xe0, 0x9d, 0x5c, 0xf4, 0x12, 0xed, 0xfc, 0x0c, 0x00, 0x00, 0xff, 0xff, 0x7c, 0x74, + 0x92, 0x16, 0x43, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -425,7 +426,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { // Deprecated: Do not use. func (c *msgClient) SubmitPubkeysChangeProposal(ctx context.Context, in *MsgSubmitPubkeysChangeProposalRequest, opts ...grpc.CallOption) (*MsgSubmitPubkeysChangeProposalResponse, error) { out := new(MsgSubmitPubkeysChangeProposalResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.ovm.Msg/SubmitPubkeysChangeProposal", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.ovm.v1beta.Msg/SubmitPubkeysChangeProposal", in, out, opts...) if err != nil { return nil, err } @@ -435,7 +436,7 @@ func (c *msgClient) SubmitPubkeysChangeProposal(ctx context.Context, in *MsgSubm // Deprecated: Do not use. func (c *msgClient) VotePubkeysChange(ctx context.Context, in *MsgVotePubkeysChangeRequest, opts ...grpc.CallOption) (*MsgVotePubkeysChangeResponse, error) { out := new(MsgVotePubkeysChangeResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.ovm.Msg/VotePubkeysChange", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.ovm.v1beta.Msg/VotePubkeysChange", in, out, opts...) if err != nil { return nil, err } @@ -445,7 +446,7 @@ func (c *msgClient) VotePubkeysChange(ctx context.Context, in *MsgVotePubkeysCha // Deprecated: Do not use. func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.ovm.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.ovm.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -493,7 +494,7 @@ func _Msg_SubmitPubkeysChangeProposal_Handler(srv interface{}, ctx context.Conte } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.ovm.Msg/SubmitPubkeysChangeProposal", + FullMethod: "/sge.legacy.ovm.v1beta.Msg/SubmitPubkeysChangeProposal", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).SubmitPubkeysChangeProposal(ctx, req.(*MsgSubmitPubkeysChangeProposalRequest)) @@ -511,7 +512,7 @@ func _Msg_VotePubkeysChange_Handler(srv interface{}, ctx context.Context, dec fu } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.ovm.Msg/VotePubkeysChange", + FullMethod: "/sge.legacy.ovm.v1beta.Msg/VotePubkeysChange", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).VotePubkeysChange(ctx, req.(*MsgVotePubkeysChangeRequest)) @@ -529,7 +530,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.ovm.Msg/UpdateParams", + FullMethod: "/sge.legacy.ovm.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -537,8 +538,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.ovm.Msg", + ServiceName: "sge.legacy.ovm.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -555,7 +557,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/ovm/tx.proto", + Metadata: "sge/legacy/ovm/v1beta/tx.proto", } func (m *MsgSubmitPubkeysChangeProposalRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/ovm/types/vote.go b/x/legacy/ovm/types/vote.go similarity index 100% rename from x/ovm/types/vote.go rename to x/legacy/ovm/types/vote.go diff --git a/x/ovm/types/vote.pb.go b/x/legacy/ovm/types/vote.pb.go similarity index 78% rename from x/ovm/types/vote.pb.go rename to x/legacy/ovm/types/vote.pb.go index 7bb5f782..dd9f64c6 100644 --- a/x/ovm/types/vote.pb.go +++ b/x/legacy/ovm/types/vote.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/ovm/vote.proto +// source: sge/legacy/ovm/v1beta/vote.proto package types @@ -51,7 +51,7 @@ func (x ProposalVote) String() string { } func (ProposalVote) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_f9405d800fb1f522, []int{0} + return fileDescriptor_c582f040b99e19d0, []int{0} } // Vote is the type for the proposal vote. @@ -59,14 +59,14 @@ type Vote struct { // public_key is the public key of the voter. PublicKey string `protobuf:"bytes,1,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` // vote is the vote enum value. - Vote ProposalVote `protobuf:"varint,2,opt,name=vote,proto3,enum=sgenetwork.sge.ovm.ProposalVote" json:"vote,omitempty"` + Vote ProposalVote `protobuf:"varint,2,opt,name=vote,proto3,enum=sge.legacy.ovm.v1beta.ProposalVote" json:"vote,omitempty"` } func (m *Vote) Reset() { *m = Vote{} } func (m *Vote) String() string { return proto.CompactTextString(m) } func (*Vote) ProtoMessage() {} func (*Vote) Descriptor() ([]byte, []int) { - return fileDescriptor_f9405d800fb1f522, []int{0} + return fileDescriptor_c582f040b99e19d0, []int{0} } func (m *Vote) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -110,30 +110,31 @@ func (m *Vote) GetVote() ProposalVote { } func init() { - proto.RegisterEnum("sgenetwork.sge.ovm.ProposalVote", ProposalVote_name, ProposalVote_value) - proto.RegisterType((*Vote)(nil), "sgenetwork.sge.ovm.Vote") + proto.RegisterEnum("sge.legacy.ovm.v1beta.ProposalVote", ProposalVote_name, ProposalVote_value) + proto.RegisterType((*Vote)(nil), "sge.legacy.ovm.v1beta.Vote") } -func init() { proto.RegisterFile("sgenetwork/sge/ovm/vote.proto", fileDescriptor_f9405d800fb1f522) } +func init() { proto.RegisterFile("sge/legacy/ovm/v1beta/vote.proto", fileDescriptor_c582f040b99e19d0) } -var fileDescriptor_f9405d800fb1f522 = []byte{ - // 250 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2d, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0x2f, 0xcb, 0xd5, 0x2f, - 0xcb, 0x2f, 0x49, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x42, 0x48, 0xeb, 0x15, 0xa7, - 0xa7, 0xea, 0xe5, 0x97, 0xe5, 0x2a, 0x45, 0x73, 0xb1, 0x84, 0xe5, 0x97, 0xa4, 0x0a, 0xc9, 0x72, - 0x71, 0x15, 0x94, 0x26, 0xe5, 0x64, 0x26, 0xc7, 0x67, 0xa7, 0x56, 0x4a, 0x30, 0x2a, 0x30, 0x6a, - 0x70, 0x06, 0x71, 0x42, 0x44, 0xbc, 0x53, 0x2b, 0x85, 0x4c, 0xb8, 0x58, 0x40, 0x06, 0x49, 0x30, - 0x29, 0x30, 0x6a, 0xf0, 0x19, 0x29, 0xe8, 0x61, 0x9a, 0xa4, 0x17, 0x50, 0x94, 0x5f, 0x90, 0x5f, - 0x9c, 0x98, 0x03, 0x32, 0x2e, 0x08, 0xac, 0x5a, 0x2b, 0x8a, 0x8b, 0x07, 0x59, 0x54, 0x48, 0x96, - 0x4b, 0x32, 0x20, 0xc8, 0x3f, 0xc0, 0x3f, 0xd8, 0xd1, 0x27, 0x3e, 0xcc, 0x3f, 0xc4, 0x35, 0x3e, - 0xd4, 0x2f, 0x38, 0xc0, 0xd5, 0xd9, 0xd3, 0xcd, 0xd3, 0xd5, 0x45, 0x80, 0x41, 0x48, 0x84, 0x4b, - 0x00, 0x55, 0xda, 0xcf, 0x5f, 0x80, 0x51, 0x48, 0x94, 0x4b, 0x10, 0x55, 0x34, 0xd2, 0x35, 0x58, - 0x80, 0xc9, 0xc9, 0xe1, 0xc4, 0x23, 0x39, 0xc6, 0x0b, 0x8f, 0xe4, 0x18, 0x1f, 0x3c, 0x92, 0x63, - 0x9c, 0xf0, 0x58, 0x8e, 0xe1, 0xc2, 0x63, 0x39, 0x86, 0x1b, 0x8f, 0xe5, 0x18, 0xa2, 0xd4, 0xd2, - 0x33, 0x4b, 0x32, 0x4a, 0x93, 0xf4, 0x92, 0xf3, 0x73, 0x41, 0xa1, 0xa0, 0x8b, 0x1c, 0x22, 0x15, - 0xe0, 0x30, 0x29, 0xa9, 0x2c, 0x48, 0x2d, 0x4e, 0x62, 0x03, 0x87, 0x8a, 0x31, 0x20, 0x00, 0x00, - 0xff, 0xff, 0x27, 0xa6, 0x07, 0x11, 0x36, 0x01, 0x00, 0x00, +var fileDescriptor_c582f040b99e19d0 = []byte{ + // 266 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x28, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0xcf, 0x2f, 0xcb, 0xd5, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, + 0x49, 0xd4, 0x2f, 0xcb, 0x2f, 0x49, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x2d, 0x4e, + 0x4f, 0xd5, 0x83, 0xa8, 0xd0, 0xcb, 0x2f, 0xcb, 0xd5, 0x83, 0xa8, 0x50, 0x8a, 0xe3, 0x62, 0x09, + 0xcb, 0x2f, 0x49, 0x15, 0x92, 0xe5, 0xe2, 0x2a, 0x28, 0x4d, 0xca, 0xc9, 0x4c, 0x8e, 0xcf, 0x4e, + 0xad, 0x94, 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x0c, 0xe2, 0x84, 0x88, 0x78, 0xa7, 0x56, 0x0a, 0x99, + 0x73, 0xb1, 0x80, 0xcc, 0x92, 0x60, 0x52, 0x60, 0xd4, 0xe0, 0x33, 0x52, 0xd6, 0xc3, 0x6a, 0x98, + 0x5e, 0x40, 0x51, 0x7e, 0x41, 0x7e, 0x71, 0x62, 0x0e, 0xc8, 0xc4, 0x20, 0xb0, 0x06, 0xad, 0x28, + 0x2e, 0x1e, 0x64, 0x51, 0x21, 0x59, 0x2e, 0xc9, 0x80, 0x20, 0xff, 0x00, 0xff, 0x60, 0x47, 0x9f, + 0xf8, 0x30, 0xff, 0x10, 0xd7, 0xf8, 0x50, 0xbf, 0xe0, 0x00, 0x57, 0x67, 0x4f, 0x37, 0x4f, 0x57, + 0x17, 0x01, 0x06, 0x21, 0x11, 0x2e, 0x01, 0x54, 0x69, 0x3f, 0x7f, 0x01, 0x46, 0x21, 0x51, 0x2e, + 0x41, 0x54, 0xd1, 0x48, 0xd7, 0x60, 0x01, 0x26, 0x27, 0xf7, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, + 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, + 0x3c, 0x96, 0x63, 0x88, 0xd2, 0x4d, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, + 0x2f, 0x4e, 0x4f, 0xd5, 0xcd, 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0x06, 0xb1, 0xf5, 0x2b, 0x90, + 0xc3, 0xa9, 0xa4, 0xb2, 0x20, 0xb5, 0x38, 0x89, 0x0d, 0x1c, 0x44, 0xc6, 0x80, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x42, 0xf8, 0xe0, 0xa3, 0x46, 0x01, 0x00, 0x00, } func (m *Vote) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/client/cli/query.go b/x/legacy/reward/client/cli/query.go similarity index 94% rename from x/reward/client/cli/query.go rename to x/legacy/reward/client/cli/query.go index d8dd719a..b4621abc 100644 --- a/x/reward/client/cli/query.go +++ b/x/legacy/reward/client/cli/query.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) // GetQueryCmd returns the cli query commands for this module diff --git a/x/reward/client/cli/query_campaign.go b/x/legacy/reward/client/cli/query_campaign.go similarity index 96% rename from x/reward/client/cli/query_campaign.go rename to x/legacy/reward/client/cli/query_campaign.go index c7c3c2fa..97db42b2 100644 --- a/x/reward/client/cli/query_campaign.go +++ b/x/legacy/reward/client/cli/query_campaign.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func CmdListCampaign() *cobra.Command { diff --git a/x/subaccount/client/cli/query_params.go b/x/legacy/reward/client/cli/query_params.go similarity index 92% rename from x/subaccount/client/cli/query_params.go rename to x/legacy/reward/client/cli/query_params.go index 2205f025..71a45804 100644 --- a/x/subaccount/client/cli/query_params.go +++ b/x/legacy/reward/client/cli/query_params.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func CmdQueryParams() *cobra.Command { diff --git a/x/reward/client/cli/query_promoter.go b/x/legacy/reward/client/cli/query_promoter.go similarity index 96% rename from x/reward/client/cli/query_promoter.go rename to x/legacy/reward/client/cli/query_promoter.go index 0e41c208..7e9034de 100644 --- a/x/reward/client/cli/query_promoter.go +++ b/x/legacy/reward/client/cli/query_promoter.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func CmdListPromoters() *cobra.Command { diff --git a/x/reward/client/cli/query_reward.go b/x/legacy/reward/client/cli/query_reward.go similarity index 98% rename from x/reward/client/cli/query_reward.go rename to x/legacy/reward/client/cli/query_reward.go index a3a80676..f5974e54 100644 --- a/x/reward/client/cli/query_reward.go +++ b/x/legacy/reward/client/cli/query_reward.go @@ -9,7 +9,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func CmdListReward() *cobra.Command { diff --git a/x/reward/client/cli/tx.go b/x/legacy/reward/client/cli/tx.go similarity index 94% rename from x/reward/client/cli/tx.go rename to x/legacy/reward/client/cli/tx.go index ed1a3ef8..42b49a2a 100644 --- a/x/reward/client/cli/tx.go +++ b/x/legacy/reward/client/cli/tx.go @@ -9,7 +9,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) var DefaultRelativePacketTimeoutTimestamp = cast.ToUint64((time.Duration(10) * time.Minute).Nanoseconds()) diff --git a/x/reward/client/cli/tx_campaign.go b/x/legacy/reward/client/cli/tx_campaign.go similarity index 98% rename from x/reward/client/cli/tx_campaign.go rename to x/legacy/reward/client/cli/tx_campaign.go index e273b8be..064bb775 100644 --- a/x/reward/client/cli/tx_campaign.go +++ b/x/legacy/reward/client/cli/tx_campaign.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func CmdCreateCampaign() *cobra.Command { diff --git a/x/reward/client/cli/tx_promoter.go b/x/legacy/reward/client/cli/tx_promoter.go similarity index 97% rename from x/reward/client/cli/tx_promoter.go rename to x/legacy/reward/client/cli/tx_promoter.go index 762f3ad6..d74fa5cc 100644 --- a/x/reward/client/cli/tx_promoter.go +++ b/x/legacy/reward/client/cli/tx_promoter.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func CmdCreatePromoter() *cobra.Command { diff --git a/x/reward/client/cli/tx_reward.go b/x/legacy/reward/client/cli/tx_reward.go similarity index 95% rename from x/reward/client/cli/tx_reward.go rename to x/legacy/reward/client/cli/tx_reward.go index 629cf57a..0cc31942 100644 --- a/x/reward/client/cli/tx_reward.go +++ b/x/legacy/reward/client/cli/tx_reward.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func CmdGrantReward() *cobra.Command { diff --git a/x/reward/genesis.go b/x/legacy/reward/genesis.go similarity index 94% rename from x/reward/genesis.go rename to x/legacy/reward/genesis.go index 8a1d7b49..b1e527a7 100644 --- a/x/reward/genesis.go +++ b/x/legacy/reward/genesis.go @@ -5,8 +5,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/keeper" + "github.com/sge-network/sge/x/legacy/reward/types" ) // InitGenesis initializes the module's state from a provided genesis state. diff --git a/x/reward/keeper/campaign.go b/x/legacy/reward/keeper/campaign.go similarity index 90% rename from x/reward/keeper/campaign.go rename to x/legacy/reward/keeper/campaign.go index 2df1281c..842f47bb 100644 --- a/x/reward/keeper/campaign.go +++ b/x/legacy/reward/keeper/campaign.go @@ -1,9 +1,10 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) // SetCampaign set a specific campaign in the store from its index @@ -41,7 +42,7 @@ func (k Keeper) RemoveCampaign( // GetAllCampaign returns all campaign func (k Keeper) GetAllCampaign(ctx sdk.Context) (list []types.Campaign) { store := k.getCampaignStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer iterator.Close() diff --git a/x/reward/keeper/distribution.go b/x/legacy/reward/keeper/distribution.go similarity index 91% rename from x/reward/keeper/distribution.go rename to x/legacy/reward/keeper/distribution.go index 3010401e..2f414cd1 100644 --- a/x/reward/keeper/distribution.go +++ b/x/legacy/reward/keeper/distribution.go @@ -6,8 +6,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cast" - "github.com/sge-network/sge/x/reward/types" - subaccounttypes "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/reward/types" + subaccounttypes "github.com/sge-network/sge/x/legacy/subaccount/types" ) // DistributeRewards distributes the rewards according to the input distribution list. diff --git a/x/ovm/keeper/export_test.go b/x/legacy/reward/keeper/export_test.go similarity index 100% rename from x/ovm/keeper/export_test.go rename to x/legacy/reward/keeper/export_test.go diff --git a/x/reward/keeper/keeper.go b/x/legacy/reward/keeper/keeper.go similarity index 92% rename from x/reward/keeper/keeper.go rename to x/legacy/reward/keeper/keeper.go index 56626e4b..38059dd9 100644 --- a/x/reward/keeper/keeper.go +++ b/x/legacy/reward/keeper/keeper.go @@ -3,15 +3,14 @@ package keeper import ( "fmt" + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/cometbft/cometbft/libs/log" - "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) type ( @@ -63,7 +62,7 @@ func NewKeeper( modFunder: utils.NewModuleAccFunder( expectedKeepers.BankKeeper, expectedKeepers.AccountKeeper, - types.ErrorBank, + types.ErrBank, ), accountKeeper: expectedKeepers.AccountKeeper, betKeeper: betKeeper, diff --git a/x/ovm/keeper/msg_server.go b/x/legacy/reward/keeper/msg_server.go similarity index 84% rename from x/ovm/keeper/msg_server.go rename to x/legacy/reward/keeper/msg_server.go index ee3a0bde..2925ffd2 100644 --- a/x/ovm/keeper/msg_server.go +++ b/x/legacy/reward/keeper/msg_server.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) type msgServer struct { diff --git a/x/reward/keeper/msg_server_campaign.go b/x/legacy/reward/keeper/msg_server_campaign.go similarity index 95% rename from x/reward/keeper/msg_server_campaign.go rename to x/legacy/reward/keeper/msg_server_campaign.go index 277c0d38..a434d94b 100644 --- a/x/reward/keeper/msg_server_campaign.go +++ b/x/legacy/reward/keeper/msg_server_campaign.go @@ -11,7 +11,7 @@ import ( "github.com/spf13/cast" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func (k msgServer) CreateCampaign(goCtx context.Context, msg *types.MsgCreateCampaign) (*types.MsgCreateCampaignResponse, error) { @@ -33,7 +33,7 @@ func (k msgServer) CreateCampaign(goCtx context.Context, msg *types.MsgCreateCam } if msg.Creator != payload.Promoter { - if err := utils.ValidateMsgAuthorization(k.authzKeeper, ctx, msg.Creator, payload.Promoter, msg, + if err := utils.ValidateMsgAuthorization(ctx, k.authzKeeper, msg.Creator, payload.Promoter, msg, types.ErrAuthorizationNotFound, types.ErrAuthorizationNotAccepted); err != nil { return nil, err } @@ -55,7 +55,7 @@ func (k msgServer) CreateCampaign(goCtx context.Context, msg *types.MsgCreateCam return nil, sdkerrors.Wrapf(sdkerrtypes.ErrInvalidRequest, "defined reward amount %s is more than total funds %s", totalRewardAmount, msg.TotalFunds) } - totalRewardPercentage := sdk.ZeroDec() + totalRewardPercentage := sdkmath.LegacyZeroDec() if !payload.RewardAmount.MainAccountPercentage.IsNil() { totalRewardPercentage = totalRewardPercentage.Add(payload.RewardAmount.MainAccountPercentage) } @@ -64,7 +64,7 @@ func (k msgServer) CreateCampaign(goCtx context.Context, msg *types.MsgCreateCam } // check the sum of percentages, it should not be more than or equal to 1 (100%) - if totalRewardPercentage.GTE(sdk.OneDec()) { + if totalRewardPercentage.GTE(sdkmath.LegacyOneDec()) { return nil, sdkerrors.Wrapf(sdkerrtypes.ErrInvalidRequest, "defined reward percentage is equal or more than 1.0(100 percent), the provided value is %s", totalRewardPercentage) } @@ -132,7 +132,7 @@ func (k msgServer) UpdateCampaign(goCtx context.Context, msg *types.MsgUpdateCam // Checks if the msg creator is the same as the current owner if msg.Creator != campaign.Promoter { - if err := utils.ValidateMsgAuthorization(k.authzKeeper, ctx, msg.Creator, campaign.Promoter, msg, + if err := utils.ValidateMsgAuthorization(ctx, k.authzKeeper, msg.Creator, campaign.Promoter, msg, types.ErrAuthorizationNotFound, types.ErrAuthorizationNotAccepted); err != nil { return nil, err } @@ -186,7 +186,7 @@ func (k msgServer) WithdrawFunds(goCtx context.Context, msg *types.MsgWithdrawFu // Checks if the msg creator is the same as the current owner if msg.Creator != valFound.Promoter { - if err := utils.ValidateMsgAuthorization(k.authzKeeper, ctx, msg.Creator, valFound.Promoter, msg, + if err := utils.ValidateMsgAuthorization(ctx, k.authzKeeper, msg.Creator, valFound.Promoter, msg, types.ErrAuthorizationNotFound, types.ErrAuthorizationNotAccepted); err != nil { return nil, err } diff --git a/x/legacy/reward/keeper/msg_server_params.go b/x/legacy/reward/keeper/msg_server_params.go new file mode 100644 index 00000000..365e7a73 --- /dev/null +++ b/x/legacy/reward/keeper/msg_server_params.go @@ -0,0 +1,27 @@ +package keeper + +import ( + "context" + + sdkerrors "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + + "github.com/sge-network/sge/x/legacy/reward/types" +) + +func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { + ctx := sdk.UnwrapSDKContext(goCtx) + + if k.GetAuthority() != req.Authority { + return nil, sdkerrors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.GetAuthority(), req.Authority) + } + + if err := req.Params.Validate(); err != nil { + return nil, err + } + + k.SetParams(ctx, req.Params) + + return &types.MsgUpdateParamsResponse{}, nil +} diff --git a/x/reward/keeper/msg_server_promoter.go b/x/legacy/reward/keeper/msg_server_promoter.go similarity index 97% rename from x/reward/keeper/msg_server_promoter.go rename to x/legacy/reward/keeper/msg_server_promoter.go index ec32a142..4334f340 100644 --- a/x/reward/keeper/msg_server_promoter.go +++ b/x/legacy/reward/keeper/msg_server_promoter.go @@ -6,7 +6,7 @@ import ( sdkerrors "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func (k msgServer) CreatePromoter(goCtx context.Context, msg *types.MsgCreatePromoter) (*types.MsgCreatePromoterResponse, error) { diff --git a/x/reward/keeper/msg_server_reward.go b/x/legacy/reward/keeper/msg_server_reward.go similarity index 98% rename from x/reward/keeper/msg_server_reward.go rename to x/legacy/reward/keeper/msg_server_reward.go index 55092609..ab87ddbf 100644 --- a/x/reward/keeper/msg_server_reward.go +++ b/x/legacy/reward/keeper/msg_server_reward.go @@ -8,7 +8,7 @@ import ( sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" "github.com/spf13/cast" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func (k msgServer) GrantReward(goCtx context.Context, msg *types.MsgGrantReward) (*types.MsgGrantRewardResponse, error) { diff --git a/x/reward/keeper/params.go b/x/legacy/reward/keeper/params.go similarity index 86% rename from x/reward/keeper/params.go rename to x/legacy/reward/keeper/params.go index d2f0a3ad..0e68e57d 100644 --- a/x/reward/keeper/params.go +++ b/x/legacy/reward/keeper/params.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) // GetParams get all parameters as types.Params diff --git a/x/reward/keeper/promoter.go b/x/legacy/reward/keeper/promoter.go similarity index 92% rename from x/reward/keeper/promoter.go rename to x/legacy/reward/keeper/promoter.go index c9f14cee..3af46509 100644 --- a/x/reward/keeper/promoter.go +++ b/x/legacy/reward/keeper/promoter.go @@ -1,8 +1,10 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/reward/types" + + "github.com/sge-network/sge/x/legacy/reward/types" ) // SetPromoter set a specific promoter in the store from its index @@ -31,7 +33,7 @@ func (k Keeper) GetPromoter( // GetAllPromoter returns all promoters func (k Keeper) GetAllPromoter(ctx sdk.Context) (list []types.Promoter) { store := k.getPromoterStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer iterator.Close() diff --git a/x/reward/keeper/query.go b/x/legacy/reward/keeper/query.go similarity index 54% rename from x/reward/keeper/query.go rename to x/legacy/reward/keeper/query.go index 199fba49..d657dc5a 100644 --- a/x/reward/keeper/query.go +++ b/x/legacy/reward/keeper/query.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) var _ types.QueryServer = Keeper{} diff --git a/x/reward/keeper/query_campaign.go b/x/legacy/reward/keeper/query_campaign.go similarity index 94% rename from x/reward/keeper/query_campaign.go rename to x/legacy/reward/keeper/query_campaign.go index 7dc1d316..70748716 100644 --- a/x/reward/keeper/query_campaign.go +++ b/x/legacy/reward/keeper/query_campaign.go @@ -6,10 +6,10 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func (k Keeper) Campaigns(goCtx context.Context, req *types.QueryCampaignsRequest) (*types.QueryCampaignsResponse, error) { diff --git a/x/subaccount/keeper/query_params.go b/x/legacy/reward/keeper/query_params.go similarity index 89% rename from x/subaccount/keeper/query_params.go rename to x/legacy/reward/keeper/query_params.go index 022fa79d..e71eb10e 100644 --- a/x/subaccount/keeper/query_params.go +++ b/x/legacy/reward/keeper/query_params.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func (k Keeper) Params(goCtx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { diff --git a/x/reward/keeper/query_promoter.go b/x/legacy/reward/keeper/query_promoter.go similarity index 95% rename from x/reward/keeper/query_promoter.go rename to x/legacy/reward/keeper/query_promoter.go index e61e84d9..ed4b310a 100644 --- a/x/reward/keeper/query_promoter.go +++ b/x/legacy/reward/keeper/query_promoter.go @@ -3,10 +3,10 @@ package keeper import ( "context" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" ) diff --git a/x/reward/keeper/query_reward.go b/x/legacy/reward/keeper/query_reward.go similarity index 97% rename from x/reward/keeper/query_reward.go rename to x/legacy/reward/keeper/query_reward.go index b94ba110..d8d5da13 100644 --- a/x/reward/keeper/query_reward.go +++ b/x/legacy/reward/keeper/query_reward.go @@ -3,10 +3,10 @@ package keeper import ( "context" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" ) diff --git a/x/reward/keeper/reward.go b/x/legacy/reward/keeper/reward.go similarity index 91% rename from x/reward/keeper/reward.go rename to x/legacy/reward/keeper/reward.go index 2eee883a..6bac75da 100644 --- a/x/reward/keeper/reward.go +++ b/x/legacy/reward/keeper/reward.go @@ -1,9 +1,11 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) // SetReward set a specific reward in the store from its index @@ -41,7 +43,7 @@ func (k Keeper) RemoveReward( // GetAllRewards returns all reward func (k Keeper) GetAllRewards(ctx sdk.Context) (list []types.Reward) { store := k.getRewardStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer iterator.Close() @@ -57,7 +59,7 @@ func (k Keeper) GetAllRewards(ctx sdk.Context) (list []types.Reward) { // GetAllRewardsOfReceiverByPromoterAndCategory returns all reward by promoter and category func (k Keeper) GetAllRewardsOfReceiverByPromoterAndCategory(ctx sdk.Context) (list []types.RewardByCategory) { store := k.getRewardByReceiverAndCategoryStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer iterator.Close() @@ -88,7 +90,7 @@ func (k Keeper) GetRewardsOfReceiverByPromoterAndCategory( category types.RewardCategory, ) (list []types.RewardByCategory, err error) { store := k.getRewardByReceiverAndCategoryStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, types.GetRewardsOfReceiverByPromoterAndCategoryPrefix(promoterUID, addr, category)) + iterator := storetypes.KVStorePrefixIterator(store, types.GetRewardsOfReceiverByPromoterAndCategoryPrefix(promoterUID, addr, category)) defer func() { err = iterator.Close() @@ -115,7 +117,7 @@ func (k Keeper) HasRewardOfReceiverByPromoter(ctx sdk.Context, promoterUID, addr // GetAllRewardsByReceiverAndCategory returns all rewards by receiver and category func (k Keeper) GetAllRewardsByReceiverAndCategory(ctx sdk.Context) (list []types.RewardByCategory) { store := k.getRewardByReceiverAndCategoryStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer iterator.Close() @@ -137,7 +139,7 @@ func (k Keeper) SetRewardByCampaign(ctx sdk.Context, rewByCampaign types.RewardB // GetAllRewardsByCampaign returns all rewards by campaign func (k Keeper) GetAllRewardsByCampaign(ctx sdk.Context) (list []types.RewardByCampaign) { store := k.getRewardsByCampaignStore(ctx) - iterator := sdk.KVStorePrefixIterator(store, []byte{}) + iterator := storetypes.KVStorePrefixIterator(store, []byte{}) defer iterator.Close() diff --git a/x/reward/keeper/view.go b/x/legacy/reward/keeper/view.go similarity index 95% rename from x/reward/keeper/view.go rename to x/legacy/reward/keeper/view.go index 273f7d92..41ab24ed 100644 --- a/x/reward/keeper/view.go +++ b/x/legacy/reward/keeper/view.go @@ -1,10 +1,10 @@ package keeper import ( - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) // getCampaignStore gets the store containing all campaigns. diff --git a/x/reward/module.go b/x/legacy/reward/module.go similarity index 91% rename from x/reward/module.go rename to x/legacy/reward/module.go index a1ba4644..37df1790 100644 --- a/x/reward/module.go +++ b/x/legacy/reward/module.go @@ -17,9 +17,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/reward/client/cli" - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/client/cli" + "github.com/sge-network/sge/x/legacy/reward/keeper" + "github.com/sge-network/sge/x/legacy/reward/types" ) var ( @@ -108,8 +108,8 @@ func NewAppModule( keeper keeper.Keeper, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, -) AppModule { - return AppModule{ +) *AppModule { + return &AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, accountKeeper: accountKeeper, @@ -117,6 +117,12 @@ func NewAppModule( } } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} + +// IsOnePerModuleType is a marker function just indicates that this is a one-per-module type. +func (am AppModule) IsOnePerModuleType() {} + // Deprecated: use RegisterServices func (AppModule) QuerierRoute() string { return types.RouterKey } @@ -153,9 +159,9 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock contains the logic that is automatically triggered at the beginning of each block -func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} +func (am AppModule) BeginBlock(_ sdk.Context) {} // EndBlock contains the logic that is automatically triggered at the end of each block -func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { +func (am AppModule) EndBlock(_ sdk.Context) []abci.ValidatorUpdate { return []abci.ValidatorUpdate{} } diff --git a/x/reward/module_simulation.go b/x/legacy/reward/module_simulation.go similarity index 85% rename from x/reward/module_simulation.go rename to x/legacy/reward/module_simulation.go index 78f9c61c..daa5fa4d 100644 --- a/x/reward/module_simulation.go +++ b/x/legacy/reward/module_simulation.go @@ -8,14 +8,13 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/sge-network/sge/testutil/sample" - rewardsimulation "github.com/sge-network/sge/x/reward/simulation" - "github.com/sge-network/sge/x/reward/types" + rewardsimulation "github.com/sge-network/sge/x/legacy/reward/simulation" + "github.com/sge-network/sge/x/legacy/reward/types" ) // avoid unused import issue @@ -73,14 +72,14 @@ func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedP } // RegisterStoreDecoder registers a decoder -func (am AppModule) RegisterStoreDecoder(_ sdk.StoreDecoderRegistry) {} +func (am AppModule) RegisterStoreDecoder(_ simtypes.StoreDecoderRegistry) {} // WeightedOperations returns the all the gov module operations with their respective weights. func (am AppModule) WeightedOperations(simState module.SimulationState) []simtypes.WeightedOperation { operations := make([]simtypes.WeightedOperation, 0) var weightMsgCreateCampaign int - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgCreateCampaign, &weightMsgCreateCampaign, nil, + simState.AppParams.GetOrGenerate(opWeightMsgCreateCampaign, &weightMsgCreateCampaign, nil, func(_ *rand.Rand) { weightMsgCreateCampaign = defaultWeightMsgCreateCampaign }, @@ -91,7 +90,7 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp )) var weightMsgUpdateCampaign int - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgUpdateCampaign, &weightMsgUpdateCampaign, nil, + simState.AppParams.GetOrGenerate(opWeightMsgUpdateCampaign, &weightMsgUpdateCampaign, nil, func(_ *rand.Rand) { weightMsgUpdateCampaign = defaultWeightMsgUpdateCampaign }, @@ -102,7 +101,7 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp )) var weightMsgDeleteCampaign int - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgDeleteCampaign, &weightMsgDeleteCampaign, nil, + simState.AppParams.GetOrGenerate(opWeightMsgDeleteCampaign, &weightMsgDeleteCampaign, nil, func(_ *rand.Rand) { weightMsgDeleteCampaign = defaultWeightMsgDeleteCampaign }, diff --git a/x/reward/simulation/campaign.go b/x/legacy/reward/simulation/campaign.go similarity index 89% rename from x/reward/simulation/campaign.go rename to x/legacy/reward/simulation/campaign.go index 4107c822..4c852acf 100644 --- a/x/reward/simulation/campaign.go +++ b/x/legacy/reward/simulation/campaign.go @@ -7,14 +7,14 @@ import ( "github.com/google/uuid" - simappparams "cosmossdk.io/simapp/params" "github.com/cosmos/cosmos-sdk/baseapp" sdk "github.com/cosmos/cosmos-sdk/types" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/keeper" + "github.com/sge-network/sge/x/legacy/reward/types" ) // Prevent strconv unused error @@ -43,10 +43,9 @@ func SimulateMsgCreateCampaign( txCtx := simulation.OperationInput{ R: r, App: app, - TxGen: simappparams.MakeTestEncodingConfig().TxConfig, + TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: simAccount, ModuleName: types.ModuleName, @@ -89,10 +88,9 @@ func SimulateMsgUpdateCampaign( txCtx := simulation.OperationInput{ R: r, App: app, - TxGen: simappparams.MakeTestEncodingConfig().TxConfig, + TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: simAccount, ModuleName: types.ModuleName, @@ -135,10 +133,9 @@ func SimulateMsgDeleteCampaign( txCtx := simulation.OperationInput{ R: r, App: app, - TxGen: simappparams.MakeTestEncodingConfig().TxConfig, + TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: simAccount, ModuleName: types.ModuleName, diff --git a/x/reward/simulation/helpers.go b/x/legacy/reward/simulation/helpers.go similarity index 100% rename from x/reward/simulation/helpers.go rename to x/legacy/reward/simulation/helpers.go diff --git a/x/ovm/simulation/proposals.go b/x/legacy/reward/simulation/proposals.go similarity index 95% rename from x/ovm/simulation/proposals.go rename to x/legacy/reward/simulation/proposals.go index 3a3ce0c2..37b6c1d9 100644 --- a/x/ovm/simulation/proposals.go +++ b/x/legacy/reward/simulation/proposals.go @@ -8,7 +8,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/ovm/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) // Simulation operation weights constants diff --git a/x/reward/types/authz.pb.go b/x/legacy/reward/types/authz.pb.go similarity index 86% rename from x/reward/types/authz.pb.go rename to x/legacy/reward/types/authz.pb.go index aa1ec84f..07cbf013 100644 --- a/x/reward/types/authz.pb.go +++ b/x/legacy/reward/types/authz.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/authz.proto +// source: sge/legacy/reward/v1beta/authz.proto package types @@ -34,7 +34,7 @@ func (m *CreateCampaignAuthorization) Reset() { *m = CreateCampaignAutho func (m *CreateCampaignAuthorization) String() string { return proto.CompactTextString(m) } func (*CreateCampaignAuthorization) ProtoMessage() {} func (*CreateCampaignAuthorization) Descriptor() ([]byte, []int) { - return fileDescriptor_bb308e8b318ee96e, []int{0} + return fileDescriptor_be9179e357aa6ded, []int{0} } func (m *CreateCampaignAuthorization) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -73,7 +73,7 @@ func (m *UpdateCampaignAuthorization) Reset() { *m = UpdateCampaignAutho func (m *UpdateCampaignAuthorization) String() string { return proto.CompactTextString(m) } func (*UpdateCampaignAuthorization) ProtoMessage() {} func (*UpdateCampaignAuthorization) Descriptor() ([]byte, []int) { - return fileDescriptor_bb308e8b318ee96e, []int{1} + return fileDescriptor_be9179e357aa6ded, []int{1} } func (m *UpdateCampaignAuthorization) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -113,7 +113,7 @@ func (m *WithdrawCampaignAuthorization) Reset() { *m = WithdrawCampaignA func (m *WithdrawCampaignAuthorization) String() string { return proto.CompactTextString(m) } func (*WithdrawCampaignAuthorization) ProtoMessage() {} func (*WithdrawCampaignAuthorization) Descriptor() ([]byte, []int) { - return fileDescriptor_bb308e8b318ee96e, []int{2} + return fileDescriptor_be9179e357aa6ded, []int{2} } func (m *WithdrawCampaignAuthorization) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -143,32 +143,35 @@ func (m *WithdrawCampaignAuthorization) XXX_DiscardUnknown() { var xxx_messageInfo_WithdrawCampaignAuthorization proto.InternalMessageInfo func init() { - proto.RegisterType((*CreateCampaignAuthorization)(nil), "sgenetwork.sge.reward.CreateCampaignAuthorization") - proto.RegisterType((*UpdateCampaignAuthorization)(nil), "sgenetwork.sge.reward.UpdateCampaignAuthorization") - proto.RegisterType((*WithdrawCampaignAuthorization)(nil), "sgenetwork.sge.reward.WithdrawCampaignAuthorization") -} - -func init() { proto.RegisterFile("sgenetwork/sge/reward/authz.proto", fileDescriptor_bb308e8b318ee96e) } - -var fileDescriptor_bb308e8b318ee96e = []byte{ - // 267 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x2f, 0x4a, 0x2d, 0x4f, 0x2c, - 0x4a, 0xd1, 0x4f, 0x2c, 0x2d, 0xc9, 0xa8, 0xd2, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x45, - 0x28, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0x91, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xab, - 0xd0, 0x07, 0xb1, 0x20, 0x8a, 0x95, 0x62, 0xb9, 0xa4, 0x9d, 0x8b, 0x52, 0x13, 0x4b, 0x52, 0x9d, - 0x13, 0x73, 0x0b, 0x12, 0x33, 0xd3, 0xf3, 0x1c, 0x4b, 0x4b, 0x32, 0xf2, 0x8b, 0x32, 0xab, 0x12, - 0x4b, 0x32, 0xf3, 0xf3, 0x84, 0xec, 0xb8, 0xb8, 0x8b, 0x0b, 0x52, 0xf3, 0x52, 0xe2, 0x73, 0x32, - 0x73, 0x33, 0x4b, 0x24, 0x18, 0x15, 0x18, 0x35, 0x38, 0x9d, 0x64, 0x4f, 0xdc, 0x93, 0x67, 0xb8, - 0x75, 0x4f, 0x5e, 0x34, 0x39, 0xbf, 0x38, 0x37, 0xbf, 0xb8, 0x38, 0x25, 0x5b, 0x2f, 0x33, 0x5f, - 0x3f, 0x37, 0xb1, 0x24, 0x43, 0xcf, 0x33, 0xaf, 0x24, 0x88, 0x0b, 0xac, 0xc3, 0x07, 0xa4, 0x01, - 0x64, 0x7c, 0x68, 0x41, 0x0a, 0xcd, 0x8c, 0x4f, 0xe5, 0x92, 0x0d, 0xcf, 0x2c, 0xc9, 0x48, 0x29, - 0x4a, 0x2c, 0xc7, 0x6e, 0x81, 0x0b, 0x17, 0x5f, 0x39, 0x54, 0x01, 0x29, 0x76, 0xf0, 0xc2, 0x34, - 0x81, 0xad, 0x71, 0x72, 0x3e, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, - 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xcd, - 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x50, 0x74, 0xe8, 0x22, 0x47, 0x4d, - 0x05, 0x2c, 0x72, 0x4a, 0x2a, 0x0b, 0x52, 0x8b, 0x93, 0xd8, 0xc0, 0x01, 0x6e, 0x0c, 0x08, 0x00, - 0x00, 0xff, 0xff, 0xcc, 0xbb, 0x9d, 0xc3, 0xc2, 0x01, 0x00, 0x00, + proto.RegisterType((*CreateCampaignAuthorization)(nil), "sge.legacy.reward.v1beta.CreateCampaignAuthorization") + proto.RegisterType((*UpdateCampaignAuthorization)(nil), "sge.legacy.reward.v1beta.UpdateCampaignAuthorization") + proto.RegisterType((*WithdrawCampaignAuthorization)(nil), "sge.legacy.reward.v1beta.WithdrawCampaignAuthorization") +} + +func init() { + proto.RegisterFile("sge/legacy/reward/v1beta/authz.proto", fileDescriptor_be9179e357aa6ded) +} + +var fileDescriptor_be9179e357aa6ded = []byte{ + // 279 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x91, 0x31, 0x4b, 0xc3, 0x40, + 0x14, 0xc7, 0x93, 0x45, 0xf0, 0x44, 0x87, 0xa2, 0x50, 0x94, 0x5e, 0x45, 0x1c, 0x5c, 0xbc, 0x53, + 0xdc, 0x05, 0x5b, 0x17, 0xc5, 0x49, 0x10, 0x41, 0x10, 0xb9, 0x24, 0x8f, 0xcb, 0xd1, 0x26, 0xef, + 0xb8, 0x7b, 0x31, 0xb6, 0x9f, 0xc2, 0x8f, 0xd5, 0xb1, 0xa3, 0x38, 0x14, 0x49, 0xbe, 0x88, 0x24, + 0xd1, 0x45, 0x5c, 0x1c, 0xdc, 0xfe, 0xc3, 0xef, 0xff, 0xff, 0xc1, 0x7b, 0xec, 0xd0, 0x6b, 0x90, + 0x53, 0xd0, 0x2a, 0x9e, 0x49, 0x07, 0xa5, 0x72, 0x89, 0x7c, 0x3e, 0x8d, 0x80, 0x94, 0x54, 0x05, + 0xa5, 0x73, 0x61, 0x1d, 0x12, 0xf6, 0xfa, 0x5e, 0x83, 0xe8, 0x28, 0xd1, 0x51, 0xa2, 0xa3, 0x76, + 0xb7, 0x35, 0x6a, 0x6c, 0x21, 0xd9, 0xa4, 0x8e, 0x3f, 0x78, 0x64, 0x7b, 0x63, 0x07, 0x8a, 0x60, + 0xac, 0x32, 0xab, 0x8c, 0xce, 0x2f, 0x0a, 0x4a, 0xd1, 0x99, 0xb9, 0x22, 0x83, 0x79, 0xef, 0x9c, + 0x6d, 0x78, 0x0b, 0x79, 0xf2, 0x34, 0x35, 0x99, 0xa1, 0x7e, 0xb8, 0x1f, 0x1e, 0xad, 0x8f, 0x06, + 0x8b, 0xd5, 0x30, 0x78, 0x5f, 0x0d, 0x77, 0x62, 0xf4, 0x19, 0x7a, 0x9f, 0x4c, 0x84, 0x41, 0x99, + 0x29, 0x4a, 0xc5, 0x55, 0x4e, 0xb7, 0xac, 0x6d, 0xdc, 0x34, 0x85, 0x66, 0xfe, 0xce, 0x26, 0xff, + 0x36, 0x0f, 0x6c, 0x70, 0x6f, 0x28, 0x4d, 0x9c, 0x2a, 0x7f, 0x17, 0x5c, 0xb2, 0xad, 0xf2, 0x0b, + 0xf8, 0x8b, 0x63, 0xf3, 0xbb, 0xd4, 0x6a, 0x46, 0xd7, 0x8b, 0x8a, 0x87, 0xcb, 0x8a, 0x87, 0x1f, + 0x15, 0x0f, 0x5f, 0x6b, 0x1e, 0x2c, 0x6b, 0x1e, 0xbc, 0xd5, 0x3c, 0x78, 0x38, 0xd1, 0x86, 0xd2, + 0x22, 0x12, 0x31, 0x66, 0xd2, 0x6b, 0x38, 0xce, 0x81, 0x4a, 0x74, 0x93, 0x26, 0xcb, 0x97, 0x1f, + 0xdf, 0xa2, 0x99, 0x05, 0x1f, 0xad, 0xb5, 0x77, 0x3f, 0xfb, 0x0c, 0x00, 0x00, 0xff, 0xff, 0xc7, + 0x60, 0xee, 0x54, 0xcf, 0x01, 0x00, 0x00, } func (m *CreateCampaignAuthorization) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/types/campaign.go b/x/legacy/reward/types/campaign.go similarity index 100% rename from x/reward/types/campaign.go rename to x/legacy/reward/types/campaign.go diff --git a/x/reward/types/campaign.pb.go b/x/legacy/reward/types/campaign.pb.go similarity index 86% rename from x/reward/types/campaign.pb.go rename to x/legacy/reward/types/campaign.pb.go index 4f0b2639..2879a9a4 100644 --- a/x/reward/types/campaign.pb.go +++ b/x/legacy/reward/types/campaign.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/campaign.proto +// source: sge/legacy/reward/v1beta/campaign.proto package types @@ -39,11 +39,11 @@ type Campaign struct { // end_ts is the end timestamp of a campaign. EndTS uint64 `protobuf:"varint,5,opt,name=end_ts,proto3" json:"end_ts"` // reward_category is the category of reward. - RewardCategory RewardCategory `protobuf:"varint,6,opt,name=reward_category,json=rewardCategory,proto3,enum=sgenetwork.sge.reward.RewardCategory" json:"reward_category,omitempty"` + RewardCategory RewardCategory `protobuf:"varint,6,opt,name=reward_category,json=rewardCategory,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"reward_category,omitempty"` // reward_type is the type of reward. - RewardType RewardType `protobuf:"varint,7,opt,name=reward_type,json=rewardType,proto3,enum=sgenetwork.sge.reward.RewardType" json:"reward_type,omitempty"` + RewardType RewardType `protobuf:"varint,7,opt,name=reward_type,json=rewardType,proto3,enum=sge.legacy.reward.v1beta.RewardType" json:"reward_type,omitempty"` // amount_type is the type of reward amount. - RewardAmountType RewardAmountType `protobuf:"varint,8,opt,name=reward_amount_type,json=rewardAmountType,proto3,enum=sgenetwork.sge.reward.RewardAmountType" json:"reward_amount_type,omitempty"` + RewardAmountType RewardAmountType `protobuf:"varint,8,opt,name=reward_amount_type,json=rewardAmountType,proto3,enum=sge.legacy.reward.v1beta.RewardAmountType" json:"reward_amount_type,omitempty"` // reward_amount is the amount defined for a reward. RewardAmount *RewardAmount `protobuf:"bytes,9,opt,name=reward_amount,json=rewardAmount,proto3" json:"reward_amount,omitempty"` // pool is the tracker of campaign funds. @@ -63,7 +63,7 @@ func (m *Campaign) Reset() { *m = Campaign{} } func (m *Campaign) String() string { return proto.CompactTextString(m) } func (*Campaign) ProtoMessage() {} func (*Campaign) Descriptor() ([]byte, []int) { - return fileDescriptor_e2342810052fed89, []int{0} + return fileDescriptor_b79a53afb6e192b3, []int{0} } func (m *Campaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -201,7 +201,7 @@ func (m *Pool) Reset() { *m = Pool{} } func (m *Pool) String() string { return proto.CompactTextString(m) } func (*Pool) ProtoMessage() {} func (*Pool) Descriptor() ([]byte, []int) { - return fileDescriptor_e2342810052fed89, []int{1} + return fileDescriptor_b79a53afb6e192b3, []int{1} } func (m *Pool) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -239,7 +239,7 @@ func (m *CampaignConstraints) Reset() { *m = CampaignConstraints{} } func (m *CampaignConstraints) String() string { return proto.CompactTextString(m) } func (*CampaignConstraints) ProtoMessage() {} func (*CampaignConstraints) Descriptor() ([]byte, []int) { - return fileDescriptor_e2342810052fed89, []int{2} + return fileDescriptor_b79a53afb6e192b3, []int{2} } func (m *CampaignConstraints) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -269,58 +269,59 @@ func (m *CampaignConstraints) XXX_DiscardUnknown() { var xxx_messageInfo_CampaignConstraints proto.InternalMessageInfo func init() { - proto.RegisterType((*Campaign)(nil), "sgenetwork.sge.reward.Campaign") - proto.RegisterType((*Pool)(nil), "sgenetwork.sge.reward.Pool") - proto.RegisterType((*CampaignConstraints)(nil), "sgenetwork.sge.reward.CampaignConstraints") + proto.RegisterType((*Campaign)(nil), "sge.legacy.reward.v1beta.Campaign") + proto.RegisterType((*Pool)(nil), "sge.legacy.reward.v1beta.Pool") + proto.RegisterType((*CampaignConstraints)(nil), "sge.legacy.reward.v1beta.CampaignConstraints") } func init() { - proto.RegisterFile("sgenetwork/sge/reward/campaign.proto", fileDescriptor_e2342810052fed89) + proto.RegisterFile("sge/legacy/reward/v1beta/campaign.proto", fileDescriptor_b79a53afb6e192b3) } -var fileDescriptor_e2342810052fed89 = []byte{ - // 653 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x94, 0x4d, 0x4f, 0x13, 0x41, - 0x18, 0xc7, 0xbb, 0x52, 0xca, 0x76, 0x0a, 0xc5, 0x0c, 0x10, 0x47, 0x48, 0xba, 0x75, 0xd5, 0x58, - 0x35, 0x6c, 0x13, 0x50, 0x0f, 0xde, 0x68, 0x35, 0x91, 0x68, 0x8c, 0x19, 0xe0, 0x62, 0x4c, 0x9a, - 0x61, 0x77, 0xb2, 0x6c, 0xe8, 0xee, 0x6c, 0x66, 0x06, 0x4b, 0x6f, 0x7e, 0x04, 0x3f, 0x8c, 0x1f, - 0x82, 0x23, 0xf1, 0x64, 0x4c, 0xdc, 0x98, 0xe5, 0xc6, 0xd1, 0x4f, 0x60, 0x66, 0x66, 0x5b, 0xc0, - 0x94, 0x17, 0x2f, 0x9d, 0x97, 0xe7, 0xff, 0xff, 0x3d, 0x4f, 0x77, 0x9f, 0x7d, 0xc0, 0x03, 0x11, - 0xd2, 0x84, 0xca, 0x01, 0xe3, 0xfb, 0x6d, 0x11, 0xd2, 0x36, 0xa7, 0x03, 0xc2, 0x83, 0xb6, 0x4f, - 0xe2, 0x94, 0x44, 0x61, 0xe2, 0xa5, 0x9c, 0x49, 0x06, 0x97, 0xce, 0x54, 0x9e, 0x08, 0xa9, 0x67, - 0x54, 0xcb, 0x8b, 0x21, 0x0b, 0x99, 0x56, 0xb4, 0xd5, 0xce, 0x88, 0x97, 0xef, 0xfa, 0x4c, 0xc4, - 0x4c, 0xf4, 0x4c, 0xc0, 0x1c, 0x8a, 0x90, 0x3b, 0x39, 0x9b, 0x59, 0x8c, 0xc6, 0xfd, 0x52, 0x01, - 0x76, 0xb7, 0x48, 0x0f, 0xd7, 0xc0, 0x8c, 0xcf, 0x29, 0x91, 0x8c, 0x23, 0xab, 0x69, 0xb5, 0xaa, - 0x1d, 0xf4, 0xfd, 0xdb, 0xea, 0x62, 0xc1, 0xdc, 0x08, 0x02, 0x4e, 0x85, 0xd8, 0x92, 0x3c, 0x4a, - 0x42, 0x3c, 0x12, 0xc2, 0x26, 0x98, 0x3a, 0x88, 0x02, 0x74, 0x4b, 0xeb, 0xeb, 0x79, 0xe6, 0x4c, - 0xed, 0x6c, 0xbe, 0x3a, 0xcd, 0x1c, 0x75, 0x8b, 0xd5, 0x0f, 0x7c, 0x06, 0xec, 0x94, 0xb3, 0x98, - 0x49, 0xca, 0xd1, 0xd4, 0x35, 0xd8, 0xb1, 0x12, 0xae, 0x03, 0x5b, 0x48, 0xc2, 0x65, 0x4f, 0x0a, - 0x54, 0x6e, 0x5a, 0xad, 0x72, 0xe7, 0x4e, 0x9e, 0x39, 0x33, 0x5b, 0xea, 0x6e, 0x7b, 0xeb, 0x34, - 0x73, 0xc6, 0x61, 0x3c, 0xde, 0xc1, 0xa7, 0xa0, 0x42, 0x93, 0x40, 0x59, 0xa6, 0xb5, 0x65, 0x21, - 0xcf, 0x9c, 0xe9, 0xd7, 0x49, 0xa0, 0x0d, 0x45, 0x08, 0x17, 0x2b, 0x7c, 0x0f, 0xe6, 0xcd, 0xa3, - 0xe8, 0xf9, 0x44, 0xd2, 0x90, 0xf1, 0x21, 0xaa, 0x34, 0xad, 0x56, 0x7d, 0xed, 0xa1, 0x37, 0xf1, - 0x05, 0x78, 0x58, 0x2f, 0xdd, 0x42, 0x8c, 0xeb, 0xfc, 0xc2, 0x19, 0x76, 0x40, 0xad, 0xe0, 0xc9, - 0x61, 0x4a, 0xd1, 0x8c, 0x66, 0xdd, 0xbb, 0x92, 0xb5, 0x3d, 0x4c, 0x29, 0x06, 0x7c, 0xbc, 0x87, - 0x3b, 0x00, 0x16, 0x0c, 0x12, 0xb3, 0x83, 0x44, 0x1a, 0x94, 0xad, 0x51, 0x8f, 0xae, 0x44, 0x6d, - 0x68, 0xbd, 0x06, 0xde, 0xe6, 0xff, 0xdc, 0xc0, 0x37, 0x60, 0xee, 0x02, 0x16, 0x55, 0x9b, 0x56, - 0xab, 0xb6, 0x76, 0xff, 0x06, 0x44, 0x3c, 0x7b, 0x9e, 0x06, 0x9f, 0x83, 0x72, 0xca, 0x58, 0x1f, - 0x01, 0x0d, 0x58, 0xb9, 0x04, 0xf0, 0x81, 0xb1, 0x7e, 0xa7, 0x7c, 0x94, 0x39, 0x25, 0xac, 0xe5, - 0x70, 0x05, 0x54, 0x23, 0xd1, 0x23, 0xbe, 0x8c, 0x3e, 0x53, 0x54, 0x6b, 0x5a, 0x2d, 0x1b, 0xdb, - 0x91, 0xd8, 0xd0, 0x67, 0x08, 0x41, 0x39, 0xa6, 0x92, 0xa0, 0x39, 0xd5, 0x1c, 0x58, 0xef, 0x95, - 0xc1, 0x27, 0x69, 0xcf, 0xd7, 0xd5, 0xd6, 0xd5, 0xcb, 0xc4, 0xb6, 0x4f, 0xd2, 0xae, 0x2e, 0xe2, - 0x1d, 0xa8, 0xf9, 0x2c, 0x11, 0x92, 0x93, 0x28, 0x91, 0x02, 0xcd, 0xeb, 0x5a, 0x9e, 0x5c, 0x52, - 0xcb, 0xa8, 0xbb, 0xbb, 0x67, 0x0e, 0x7c, 0xde, 0xee, 0xfe, 0xb2, 0x40, 0x59, 0x15, 0x0c, 0xbb, - 0x60, 0x5a, 0x32, 0x49, 0xfa, 0x45, 0xf3, 0xaf, 0xaa, 0xfa, 0x7f, 0x66, 0xce, 0x92, 0xe9, 0x54, - 0x11, 0xec, 0x7b, 0x11, 0x6b, 0xc7, 0x44, 0xee, 0x79, 0x9b, 0x89, 0xfc, 0x93, 0x39, 0xb3, 0x43, - 0x12, 0xf7, 0x5f, 0xba, 0xda, 0xe3, 0x62, 0xe3, 0x55, 0x10, 0x91, 0xd2, 0x44, 0x16, 0x5f, 0xc4, - 0x4d, 0x21, 0xda, 0xe3, 0x62, 0xe3, 0x85, 0x6f, 0x41, 0x75, 0x10, 0xc9, 0xbd, 0x80, 0x93, 0x41, - 0x52, 0x7c, 0x33, 0xff, 0x09, 0x3a, 0xf3, 0xbb, 0x02, 0x2c, 0x4c, 0x78, 0x06, 0xf0, 0x13, 0xa8, - 0xc7, 0xe4, 0xb0, 0xb7, 0x4b, 0xe5, 0xa8, 0x29, 0xcc, 0xdf, 0x7e, 0x71, 0x5d, 0xa2, 0x25, 0x93, - 0xe8, 0xa2, 0xd9, 0xc5, 0xb3, 0x31, 0x39, 0xec, 0x50, 0x69, 0xfa, 0xa4, 0xd3, 0x3d, 0xca, 0x1b, - 0xd6, 0x71, 0xde, 0xb0, 0x7e, 0xe7, 0x0d, 0xeb, 0xeb, 0x49, 0xa3, 0x74, 0x7c, 0xd2, 0x28, 0xfd, - 0x38, 0x69, 0x94, 0x3e, 0x3e, 0x0e, 0x23, 0xb9, 0x77, 0xb0, 0xeb, 0xf9, 0x2c, 0x56, 0x53, 0x69, - 0xf5, 0xfc, 0x84, 0x3a, 0x1c, 0xcd, 0x28, 0xd5, 0xf6, 0x62, 0xb7, 0xa2, 0x67, 0xd4, 0xfa, 0xdf, - 0x00, 0x00, 0x00, 0xff, 0xff, 0x07, 0x9a, 0x8a, 0xce, 0x37, 0x05, 0x00, 0x00, +var fileDescriptor_b79a53afb6e192b3 = []byte{ + // 663 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x94, 0xcd, 0x6e, 0xd3, 0x40, + 0x10, 0xc7, 0x63, 0x9a, 0xa6, 0xce, 0xa6, 0x4d, 0xd1, 0xb6, 0x15, 0xa6, 0x48, 0x76, 0x64, 0xf1, + 0x11, 0x81, 0x62, 0x43, 0x8b, 0x10, 0xe2, 0xd6, 0x84, 0x1e, 0x4a, 0x0f, 0xc0, 0xb6, 0x48, 0x08, + 0x21, 0x45, 0x1b, 0x7b, 0xe5, 0x5a, 0x8d, 0xbd, 0xd6, 0xee, 0xb6, 0x69, 0xde, 0x02, 0xf1, 0x2c, + 0x3c, 0x44, 0x8f, 0x15, 0x27, 0x84, 0x84, 0x85, 0xd2, 0x5b, 0x8f, 0x3c, 0x01, 0xda, 0x5d, 0x37, + 0xfd, 0x10, 0x51, 0xca, 0x25, 0x99, 0x1d, 0xff, 0xff, 0xbf, 0x19, 0xdb, 0x33, 0x06, 0x8f, 0x78, + 0x44, 0xfc, 0x3e, 0x89, 0x70, 0x30, 0xf4, 0x19, 0x19, 0x60, 0x16, 0xfa, 0x87, 0xcf, 0x7a, 0x44, + 0x60, 0x3f, 0xc0, 0x49, 0x86, 0xe3, 0x28, 0xf5, 0x32, 0x46, 0x05, 0x85, 0x16, 0x8f, 0x88, 0xa7, + 0x85, 0x9e, 0x16, 0x7a, 0x5a, 0xb8, 0x7a, 0x37, 0xa0, 0x3c, 0xa1, 0xbc, 0xab, 0x74, 0xbe, 0x3e, + 0x68, 0xd3, 0xea, 0x72, 0x44, 0x23, 0xaa, 0xf3, 0x32, 0x2a, 0xb2, 0x0f, 0x26, 0xd6, 0x2c, 0xc0, + 0x4a, 0xe6, 0x7e, 0xad, 0x00, 0xb3, 0x53, 0x34, 0x01, 0xd7, 0xc0, 0x5c, 0xc0, 0x08, 0x16, 0x94, + 0x59, 0x46, 0xc3, 0x68, 0x56, 0xdb, 0xd6, 0xf7, 0x6f, 0xad, 0xe5, 0xa2, 0xd8, 0x46, 0x18, 0x32, + 0xc2, 0xf9, 0x8e, 0x60, 0x71, 0x1a, 0xa1, 0x73, 0x21, 0x6c, 0x80, 0x99, 0x83, 0x38, 0xb4, 0x6e, + 0x29, 0x7d, 0x7d, 0x94, 0x3b, 0x33, 0x1f, 0xb6, 0x5e, 0x9f, 0xe5, 0x8e, 0xcc, 0x22, 0xf9, 0x03, + 0x9f, 0x03, 0x33, 0x63, 0x34, 0xa1, 0x82, 0x30, 0x6b, 0x66, 0x0a, 0x76, 0xac, 0x84, 0xeb, 0xc0, + 0xe4, 0x02, 0x33, 0xd1, 0x15, 0xdc, 0x2a, 0x37, 0x8c, 0x66, 0xb9, 0x7d, 0x67, 0x94, 0x3b, 0x73, + 0x3b, 0x32, 0xb7, 0xbb, 0x73, 0x96, 0x3b, 0xe3, 0xcb, 0x68, 0x1c, 0xc1, 0x27, 0xa0, 0x42, 0xd2, + 0x50, 0x5a, 0x66, 0x95, 0x65, 0x69, 0x94, 0x3b, 0xb3, 0x9b, 0x69, 0xa8, 0x0c, 0xc5, 0x25, 0x54, + 0xfc, 0xc3, 0xf7, 0x60, 0x51, 0x3f, 0x8a, 0x6e, 0x80, 0x05, 0x89, 0x28, 0x1b, 0x5a, 0x95, 0x86, + 0xd1, 0xac, 0xaf, 0x35, 0xbd, 0x49, 0xaf, 0xc1, 0x43, 0xea, 0xd4, 0x29, 0xf4, 0xa8, 0xce, 0xae, + 0x9c, 0xe1, 0x26, 0xa8, 0x15, 0x48, 0x31, 0xcc, 0x88, 0x35, 0xa7, 0x70, 0xf7, 0xa7, 0xe1, 0x76, + 0x87, 0x19, 0x41, 0x80, 0x8d, 0x63, 0xf8, 0x11, 0xc0, 0x02, 0x83, 0x13, 0x7a, 0x90, 0x0a, 0x4d, + 0x33, 0x15, 0xed, 0xf1, 0x34, 0xda, 0x86, 0xb2, 0x28, 0xe6, 0x6d, 0x76, 0x2d, 0x03, 0xb7, 0xc1, + 0xc2, 0x15, 0xb2, 0x55, 0x6d, 0x18, 0xcd, 0xda, 0xda, 0xc3, 0x9b, 0x41, 0xd1, 0xfc, 0x65, 0x20, + 0x7c, 0x09, 0xca, 0x19, 0xa5, 0x7d, 0x0b, 0x28, 0x86, 0x3d, 0x99, 0xf1, 0x8e, 0xd2, 0x7e, 0xbb, + 0x7c, 0x9c, 0x3b, 0x25, 0xa4, 0x1c, 0xf0, 0x1e, 0xa8, 0xc6, 0xbc, 0x8b, 0x03, 0x11, 0x1f, 0x12, + 0xab, 0xd6, 0x30, 0x9a, 0x26, 0x32, 0x63, 0xbe, 0xa1, 0xce, 0x10, 0x82, 0x72, 0x42, 0x04, 0xb6, + 0x16, 0xe4, 0xac, 0x20, 0x15, 0x4b, 0x43, 0x80, 0xb3, 0x6e, 0xa0, 0x7a, 0xae, 0xcb, 0x77, 0x8b, + 0xcc, 0x00, 0x67, 0x1d, 0xd5, 0xc7, 0x5b, 0x50, 0x0b, 0x68, 0xca, 0x05, 0xc3, 0x71, 0x2a, 0xb8, + 0xb5, 0xa8, 0xda, 0x69, 0x4d, 0x6e, 0xe7, 0x7c, 0xde, 0x3b, 0x17, 0x26, 0x74, 0x99, 0xe0, 0xfe, + 0x32, 0x40, 0x59, 0xf6, 0x0c, 0x3b, 0x60, 0x56, 0x50, 0x81, 0xfb, 0xc5, 0x3a, 0xb4, 0xe4, 0x2d, + 0xfc, 0xcc, 0x9d, 0x15, 0x3d, 0xbb, 0x3c, 0xdc, 0xf7, 0x62, 0xea, 0x27, 0x58, 0xec, 0x79, 0x5b, + 0xa9, 0xf8, 0x93, 0x3b, 0xf3, 0x43, 0x9c, 0xf4, 0x5f, 0xb9, 0xca, 0xe3, 0x22, 0xed, 0x95, 0x10, + 0x9e, 0x91, 0x54, 0x14, 0x3b, 0x72, 0x53, 0x88, 0xf2, 0xb8, 0x48, 0x7b, 0xe1, 0x36, 0xa8, 0x0e, + 0x62, 0xb1, 0x17, 0x32, 0x3c, 0x48, 0x8b, 0x2d, 0xfa, 0x4f, 0xd0, 0x85, 0xdf, 0xe5, 0x60, 0xe9, + 0x1f, 0xcf, 0x00, 0x7e, 0x06, 0xf5, 0x04, 0x1f, 0x75, 0x7b, 0x44, 0x9c, 0x4f, 0x87, 0xbe, 0xed, + 0x17, 0xd3, 0x0a, 0xad, 0xe8, 0x42, 0x57, 0xcd, 0x2e, 0x9a, 0x4f, 0xf0, 0x51, 0x9b, 0x08, 0x3d, + 0x2d, 0xed, 0x37, 0xc7, 0x23, 0xdb, 0x38, 0x19, 0xd9, 0xc6, 0xef, 0x91, 0x6d, 0x7c, 0x39, 0xb5, + 0x4b, 0x27, 0xa7, 0x76, 0xe9, 0xc7, 0xa9, 0x5d, 0xfa, 0xf4, 0x34, 0x8a, 0xc5, 0xde, 0x41, 0xcf, + 0x0b, 0x68, 0xe2, 0xf3, 0x88, 0xb4, 0x52, 0x22, 0x06, 0x94, 0xed, 0xcb, 0xd8, 0x3f, 0xba, 0xf6, + 0x0d, 0x93, 0x9b, 0xc0, 0x7b, 0x15, 0xf5, 0xf1, 0x5a, 0xff, 0x1b, 0x00, 0x00, 0xff, 0xff, 0x1b, + 0x2c, 0x4e, 0x75, 0x59, 0x05, 0x00, 0x00, } func (m *Campaign) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/types/campaign_authorizaton.go b/x/legacy/reward/types/campaign_authorizaton.go similarity index 93% rename from x/reward/types/campaign_authorizaton.go rename to x/legacy/reward/types/campaign_authorizaton.go index c7743b4b..21db0f7e 100644 --- a/x/reward/types/campaign_authorizaton.go +++ b/x/legacy/reward/types/campaign_authorizaton.go @@ -1,6 +1,8 @@ package types import ( + context "context" + sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" @@ -26,7 +28,7 @@ func (CreateCampaignAuthorization) MsgTypeURL() string { } // Accept implements Authorization.Accept. -func (a CreateCampaignAuthorization) Accept(_ sdk.Context, msg sdk.Msg) (authz.AcceptResponse, error) { +func (a CreateCampaignAuthorization) Accept(_ context.Context, msg sdk.Msg) (authz.AcceptResponse, error) { msgCreateCampaign, ok := msg.(*MsgCreateCampaign) if !ok { return authz.AcceptResponse{}, sdkerrtypes.ErrInvalidType.Wrap("type mismatch") @@ -78,7 +80,7 @@ func (UpdateCampaignAuthorization) MsgTypeURL() string { } // Accept implements Authorization.Accept. -func (a UpdateCampaignAuthorization) Accept(_ sdk.Context, msg sdk.Msg) (authz.AcceptResponse, error) { +func (a UpdateCampaignAuthorization) Accept(_ context.Context, msg sdk.Msg) (authz.AcceptResponse, error) { msgUpdateCampaign, ok := msg.(*MsgUpdateCampaign) if !ok { return authz.AcceptResponse{}, sdkerrtypes.ErrInvalidType.Wrap("type mismatch") @@ -136,7 +138,7 @@ func (WithdrawCampaignAuthorization) MsgTypeURL() string { } // Accept implements Authorization.Accept. -func (a WithdrawCampaignAuthorization) Accept(_ sdk.Context, msg sdk.Msg) (authz.AcceptResponse, error) { +func (a WithdrawCampaignAuthorization) Accept(_ context.Context, msg sdk.Msg) (authz.AcceptResponse, error) { mWithdraw, ok := msg.(*MsgWithdrawFunds) if !ok { return authz.AcceptResponse{}, sdkerrtypes.ErrInvalidType.Wrap("type mismatch") diff --git a/x/reward/types/codec.go b/x/legacy/reward/types/codec.go similarity index 100% rename from x/reward/types/codec.go rename to x/legacy/reward/types/codec.go diff --git a/x/reward/types/consts.go b/x/legacy/reward/types/consts.go similarity index 100% rename from x/reward/types/consts.go rename to x/legacy/reward/types/consts.go diff --git a/x/reward/types/errors.go b/x/legacy/reward/types/errors.go similarity index 98% rename from x/reward/types/errors.go rename to x/legacy/reward/types/errors.go index 335a0fd5..a6d088ac 100644 --- a/x/reward/types/errors.go +++ b/x/legacy/reward/types/errors.go @@ -12,7 +12,7 @@ var ( ErrInTicketValidation = sdkerrors.Register(ModuleName, 7101, "ticket validation failed") ErrAuthorizationNotFound = sdkerrors.Register(ModuleName, 7102, "no authorization found") ErrAuthorizationNotAccepted = sdkerrors.Register(ModuleName, 7103, "authorization not accepted") - ErrorBank = sdkerrors.Register(ModuleName, 7104, "bank error") + ErrBank = sdkerrors.Register(ModuleName, 7104, "bank error") ErrExpiredCampaign = sdkerrors.Register(ModuleName, 7105, "campaign is expired") ErrCampaignPoolBalance = sdkerrors.Register(ModuleName, 7106, "not enough campaign pool balance") ErrUnknownRewardType = sdkerrors.Register(ModuleName, 7107, "unknown reward type") diff --git a/x/reward/types/events.go b/x/legacy/reward/types/events.go similarity index 100% rename from x/reward/types/events.go rename to x/legacy/reward/types/events.go diff --git a/x/reward/types/expected_keepers.go b/x/legacy/reward/types/expected_keepers.go similarity index 76% rename from x/reward/types/expected_keepers.go rename to x/legacy/reward/types/expected_keepers.go index 3e4c2248..f43af71a 100644 --- a/x/reward/types/expected_keepers.go +++ b/x/legacy/reward/types/expected_keepers.go @@ -6,27 +6,26 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cosmos/cosmos-sdk/x/authz" - bettypes "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" - subaccounttypes "github.com/sge-network/sge/x/subaccount/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" + markettypes "github.com/sge-network/sge/x/legacy/market/types" + subaccounttypes "github.com/sge-network/sge/x/legacy/subaccount/types" ) // AccountKeeper defines the expected account keeper used for simulations (noalias) type AccountKeeper interface { - GetAccount(ctx sdk.Context, addr sdk.AccAddress) types.AccountI + GetAccount(ctx context.Context, addr sdk.AccAddress) sdk.AccountI GetModuleAddress(moduleName string) sdk.AccAddress // Methods imported from account should be defined here } // BankKeeper defines the expected interface needed to retrieve account balances. type BankKeeper interface { - SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins - SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, ecipientModule string, amt sdk.Coins) error - SendCoinsFromModuleToModule(ctx sdk.Context, senderModule, recipientModule string, amt sdk.Coins) error - SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error + SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins + SendCoinsFromAccountToModule(ctx context.Context, senderAddr sdk.AccAddress, ecipientModule string, amt sdk.Coins) error + SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt sdk.Coins) error + SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error // Methods imported from bank should be defined here } @@ -49,19 +48,19 @@ type OVMKeeper interface { // AuthzKeeper defines the expected authz keeper. type AuthzKeeper interface { GetAuthorization( - ctx sdk.Context, + ctx context.Context, grantee sdk.AccAddress, granter sdk.AccAddress, msgType string, ) (authz.Authorization, *time.Time) SaveGrant( - ctx sdk.Context, + ctx context.Context, grantee, granter sdk.AccAddress, authorization authz.Authorization, expiration *time.Time, ) error DeleteGrant( - ctx sdk.Context, + ctx context.Context, grantee, granter sdk.AccAddress, msgType string, ) error diff --git a/x/reward/types/funder.go b/x/legacy/reward/types/funder.go similarity index 100% rename from x/reward/types/funder.go rename to x/legacy/reward/types/funder.go diff --git a/x/reward/types/genesis.go b/x/legacy/reward/types/genesis.go similarity index 100% rename from x/reward/types/genesis.go rename to x/legacy/reward/types/genesis.go diff --git a/x/reward/types/genesis.pb.go b/x/legacy/reward/types/genesis.pb.go similarity index 85% rename from x/reward/types/genesis.pb.go rename to x/legacy/reward/types/genesis.pb.go index 86e5fb6d..705de595 100644 --- a/x/reward/types/genesis.pb.go +++ b/x/legacy/reward/types/genesis.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/genesis.proto +// source: sge/legacy/reward/v1beta/genesis.proto package types @@ -38,7 +38,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_3ffb36204eb6ffc8, []int{0} + return fileDescriptor_8e7cb7a9faf96feb, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -117,39 +117,40 @@ func (m *GenesisState) GetPromoterByAddressList() []PromoterByAddress { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.reward.GenesisState") + proto.RegisterType((*GenesisState)(nil), "sge.legacy.reward.v1beta.GenesisState") } func init() { - proto.RegisterFile("sgenetwork/sge/reward/genesis.proto", fileDescriptor_3ffb36204eb6ffc8) + proto.RegisterFile("sge/legacy/reward/v1beta/genesis.proto", fileDescriptor_8e7cb7a9faf96feb) } -var fileDescriptor_3ffb36204eb6ffc8 = []byte{ - // 381 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x92, 0x41, 0x4f, 0xea, 0x40, - 0x10, 0x80, 0xdb, 0x07, 0x8f, 0x97, 0x2c, 0x70, 0x69, 0x20, 0x8f, 0x90, 0x58, 0x08, 0x9a, 0x88, - 0x07, 0xdb, 0x04, 0x8f, 0x9e, 0x04, 0x13, 0x13, 0xe2, 0x81, 0xe0, 0xcd, 0x0b, 0xd9, 0xd2, 0xcd, - 0xda, 0x68, 0xd9, 0x66, 0x77, 0x0d, 0xf6, 0x5f, 0xf8, 0xb3, 0x38, 0x72, 0xf4, 0x44, 0x0c, 0xfc, - 0x11, 0xd3, 0x9d, 0xad, 0x56, 0x52, 0xaa, 0xa7, 0x6d, 0xa6, 0xdf, 0x7c, 0x33, 0x3b, 0x3b, 0xe8, - 0x58, 0x50, 0xb2, 0x20, 0x72, 0xc9, 0xf8, 0xa3, 0x2b, 0x28, 0x71, 0x39, 0x59, 0x62, 0xee, 0xbb, - 0x49, 0x50, 0x04, 0xc2, 0x89, 0x38, 0x93, 0xcc, 0x6a, 0x7e, 0x41, 0x8e, 0xa0, 0xc4, 0x01, 0xa8, - 0xdd, 0xa0, 0x8c, 0x32, 0x45, 0xb8, 0xc9, 0x17, 0xc0, 0xed, 0x5e, 0xbe, 0x31, 0xc2, 0x1c, 0x87, - 0x5a, 0xd8, 0x3e, 0xc9, 0x67, 0xe6, 0x38, 0x8c, 0x70, 0x40, 0x17, 0xc5, 0x26, 0x38, 0x8a, 0x4d, - 0x11, 0x67, 0x21, 0x93, 0x84, 0x03, 0xd5, 0xdb, 0x94, 0x51, 0xed, 0x06, 0xae, 0x74, 0x27, 0xb1, - 0x24, 0xd6, 0x25, 0xaa, 0x40, 0x43, 0x2d, 0xb3, 0x6b, 0xf6, 0xab, 0x83, 0x23, 0x27, 0xf7, 0x8a, - 0xce, 0x44, 0x41, 0xc3, 0xf2, 0x6a, 0xd3, 0x31, 0xa6, 0x3a, 0xc5, 0x1a, 0xa3, 0x7a, 0xda, 0xe9, - 0xec, 0x29, 0x10, 0xb2, 0xf5, 0xa7, 0x5b, 0xea, 0x57, 0x07, 0x9d, 0x03, 0x8e, 0x91, 0x66, 0xb5, - 0xa5, 0x96, 0xe6, 0xde, 0x06, 0x42, 0x5a, 0xd7, 0xa8, 0x0a, 0x18, 0x98, 0x4a, 0xca, 0x74, 0xa8, - 0x9b, 0xa9, 0x3a, 0xb4, 0x07, 0x41, 0x50, 0x59, 0x7c, 0xf4, 0x5f, 0x5b, 0xbc, 0x78, 0x36, 0xc7, - 0x92, 0x50, 0xc6, 0x63, 0x30, 0x96, 0x95, 0xf1, 0xb4, 0xd8, 0x18, 0x8f, 0x74, 0x8e, 0x76, 0x37, - 0xf8, 0x5e, 0x3c, 0xaf, 0x4a, 0x76, 0x02, 0x7f, 0x7f, 0x59, 0xe5, 0xdb, 0x24, 0x32, 0x55, 0x32, - 0x13, 0x19, 0xa3, 0x7a, 0xfa, 0x7a, 0xe0, 0xae, 0x14, 0x4e, 0x77, 0xa2, 0xd9, 0x74, 0xba, 0x69, - 0xae, 0x72, 0x51, 0xd4, 0xfa, 0x74, 0x79, 0xf1, 0x0c, 0xfb, 0x3e, 0x27, 0x42, 0x80, 0xf6, 0x9f, - 0xd2, 0xf6, 0x7f, 0xd2, 0xc6, 0x57, 0x90, 0xa4, 0xfd, 0xcd, 0x68, 0xff, 0x47, 0x52, 0x68, 0x38, - 0x5a, 0x6d, 0x6d, 0x73, 0xbd, 0xb5, 0xcd, 0xf7, 0xad, 0x6d, 0xbe, 0xee, 0x6c, 0x63, 0xbd, 0xb3, - 0x8d, 0xb7, 0x9d, 0x6d, 0xdc, 0x9f, 0xd1, 0x40, 0x3e, 0x3c, 0x7b, 0xce, 0x9c, 0x85, 0xc9, 0x82, - 0x9e, 0x67, 0x97, 0xf5, 0x25, 0x5d, 0x57, 0x19, 0x47, 0x44, 0x78, 0x15, 0xb5, 0xac, 0x17, 0x1f, - 0x01, 0x00, 0x00, 0xff, 0xff, 0xf4, 0x12, 0x9f, 0x58, 0x94, 0x03, 0x00, 0x00, +var fileDescriptor_8e7cb7a9faf96feb = []byte{ + // 395 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x92, 0xc1, 0x4e, 0xea, 0x40, + 0x14, 0x86, 0xdb, 0x0b, 0x97, 0x9b, 0x0c, 0xb0, 0x69, 0xb8, 0xb9, 0x0d, 0x8b, 0x5e, 0x42, 0xa2, + 0x12, 0x8d, 0xad, 0xe2, 0xde, 0x44, 0x58, 0x90, 0x18, 0x49, 0x08, 0xee, 0xdc, 0x90, 0x69, 0x39, + 0x19, 0xab, 0x94, 0x69, 0x66, 0x46, 0xb1, 0x6f, 0xe1, 0x63, 0xb1, 0x64, 0xe9, 0xca, 0x18, 0x78, + 0x04, 0x5f, 0xc0, 0x30, 0x33, 0x35, 0x48, 0xac, 0x65, 0x37, 0xed, 0x7c, 0xe7, 0xfb, 0xe7, 0x9c, + 0x19, 0xb4, 0xcf, 0x09, 0x78, 0x13, 0x20, 0x38, 0x48, 0x3c, 0x06, 0x33, 0xcc, 0xc6, 0xde, 0xe3, + 0xa9, 0x0f, 0x02, 0x7b, 0x04, 0xa6, 0xc0, 0x43, 0xee, 0xc6, 0x8c, 0x0a, 0x6a, 0xd9, 0x9c, 0x80, + 0xab, 0x38, 0x57, 0x71, 0xae, 0xe2, 0xea, 0x35, 0x42, 0x09, 0x95, 0x90, 0xb7, 0x5e, 0x29, 0xbe, + 0x7e, 0x90, 0xe9, 0x0d, 0x70, 0x14, 0xe3, 0x90, 0x4c, 0x35, 0xb8, 0x97, 0x09, 0xc6, 0x98, 0xe1, + 0x88, 0xe7, 0xfa, 0x62, 0x46, 0x23, 0x2a, 0x80, 0xe5, 0xfa, 0xf4, 0xb1, 0x25, 0xd6, 0x7c, 0x2f, + 0xa2, 0x4a, 0x4f, 0x75, 0x78, 0x2d, 0xb0, 0x00, 0xeb, 0x1c, 0x95, 0x54, 0xa0, 0x6d, 0x36, 0xcc, + 0x56, 0xb9, 0xdd, 0x70, 0xb3, 0x3a, 0x76, 0x07, 0x92, 0xeb, 0x14, 0xe7, 0xaf, 0xff, 0x8d, 0xa1, + 0xae, 0xb2, 0xfa, 0xa8, 0x9a, 0x76, 0x36, 0x9a, 0x84, 0x5c, 0xd8, 0xbf, 0x1a, 0x85, 0x56, 0xb9, + 0xdd, 0xcc, 0xd6, 0x74, 0x35, 0xae, 0x45, 0x95, 0xb4, 0xfc, 0x2a, 0xe4, 0xc2, 0xea, 0xa1, 0xb2, + 0xa2, 0x95, 0xac, 0x20, 0x65, 0x3f, 0x9c, 0x69, 0x28, 0xbf, 0xb4, 0x0a, 0xa9, 0x3d, 0x29, 0x22, + 0xe8, 0x9f, 0x16, 0xf9, 0xc9, 0x28, 0xc0, 0x02, 0x08, 0x65, 0x89, 0x92, 0x16, 0xa5, 0xf4, 0x30, + 0x57, 0x9a, 0x74, 0x75, 0x99, 0xd6, 0xd7, 0xd8, 0xd6, 0xff, 0xef, 0x82, 0x36, 0x47, 0xf1, 0x7b, + 0xf7, 0xa0, 0x2f, 0x23, 0xd9, 0x08, 0xda, 0x18, 0x4d, 0x1f, 0x55, 0xd3, 0x3b, 0x57, 0xfa, 0x52, + 0xde, 0xa4, 0x07, 0x1a, 0x4f, 0x27, 0x9d, 0x96, 0x4b, 0xdd, 0x1d, 0xb2, 0x3f, 0x75, 0x7e, 0x32, + 0xc2, 0xe3, 0x31, 0x03, 0xce, 0x95, 0xf9, 0x8f, 0x34, 0x1f, 0xed, 0x60, 0x4e, 0x2e, 0x54, 0x9d, + 0x8e, 0xf8, 0x1b, 0x6f, 0x6f, 0xac, 0xb3, 0x3a, 0x97, 0xf3, 0xa5, 0x63, 0x2e, 0x96, 0x8e, 0xf9, + 0xb6, 0x74, 0xcc, 0xe7, 0x95, 0x63, 0x2c, 0x56, 0x8e, 0xf1, 0xb2, 0x72, 0x8c, 0x9b, 0x13, 0x12, + 0x8a, 0xdb, 0x07, 0xdf, 0x0d, 0x68, 0xe4, 0x71, 0x02, 0xc7, 0x53, 0x10, 0x33, 0xca, 0xee, 0xd7, + 0x6b, 0xef, 0x69, 0xeb, 0x3d, 0x8b, 0x24, 0x06, 0xee, 0x97, 0xe4, 0x43, 0x3e, 0xfb, 0x08, 0x00, + 0x00, 0xff, 0xff, 0xfc, 0xbc, 0x26, 0x4a, 0xc2, 0x03, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/types/genesis_test.go b/x/legacy/reward/types/genesis_test.go similarity index 97% rename from x/reward/types/genesis_test.go rename to x/legacy/reward/types/genesis_test.go index 33160442..83a33adb 100644 --- a/x/reward/types/genesis_test.go +++ b/x/legacy/reward/types/genesis_test.go @@ -6,7 +6,7 @@ import ( "github.com/google/uuid" "github.com/stretchr/testify/require" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func TestGenesisState_Validate(t *testing.T) { diff --git a/x/reward/types/key_campaign.go b/x/legacy/reward/types/key_campaign.go similarity index 100% rename from x/reward/types/key_campaign.go rename to x/legacy/reward/types/key_campaign.go diff --git a/x/reward/types/key_promoter.go b/x/legacy/reward/types/key_promoter.go similarity index 100% rename from x/reward/types/key_promoter.go rename to x/legacy/reward/types/key_promoter.go diff --git a/x/reward/types/key_reward.go b/x/legacy/reward/types/key_reward.go similarity index 100% rename from x/reward/types/key_reward.go rename to x/legacy/reward/types/key_reward.go diff --git a/x/reward/types/keys.go b/x/legacy/reward/types/keys.go similarity index 100% rename from x/reward/types/keys.go rename to x/legacy/reward/types/keys.go diff --git a/x/reward/types/messages_campaign.go b/x/legacy/reward/types/messages_campaign.go similarity index 100% rename from x/reward/types/messages_campaign.go rename to x/legacy/reward/types/messages_campaign.go diff --git a/x/reward/types/messages_params.go b/x/legacy/reward/types/messages_params.go similarity index 100% rename from x/reward/types/messages_params.go rename to x/legacy/reward/types/messages_params.go diff --git a/x/reward/types/messages_promoter.go b/x/legacy/reward/types/messages_promoter.go similarity index 100% rename from x/reward/types/messages_promoter.go rename to x/legacy/reward/types/messages_promoter.go diff --git a/x/reward/types/messages_reward.go b/x/legacy/reward/types/messages_reward.go similarity index 100% rename from x/reward/types/messages_reward.go rename to x/legacy/reward/types/messages_reward.go diff --git a/x/reward/types/params.go b/x/legacy/reward/types/params.go similarity index 100% rename from x/reward/types/params.go rename to x/legacy/reward/types/params.go diff --git a/x/reward/types/params.pb.go b/x/legacy/reward/types/params.pb.go similarity index 79% rename from x/reward/types/params.pb.go rename to x/legacy/reward/types/params.pb.go index 7eeb0a25..9a0ba939 100644 --- a/x/reward/types/params.pb.go +++ b/x/legacy/reward/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/params.proto +// source: sge/legacy/reward/v1beta/params.proto package types @@ -30,7 +30,7 @@ type Params struct { func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_8a1741b7d6117690, []int{0} + return fileDescriptor_6f7adb5e9f0583b4, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -60,25 +60,26 @@ func (m *Params) XXX_DiscardUnknown() { var xxx_messageInfo_Params proto.InternalMessageInfo func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.reward.Params") + proto.RegisterType((*Params)(nil), "sge.legacy.reward.v1beta.Params") } func init() { - proto.RegisterFile("sgenetwork/sge/reward/params.proto", fileDescriptor_8a1741b7d6117690) + proto.RegisterFile("sge/legacy/reward/v1beta/params.proto", fileDescriptor_6f7adb5e9f0583b4) } -var fileDescriptor_8a1741b7d6117690 = []byte{ - // 155 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2a, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x2f, 0x4a, 0x2d, 0x4f, 0x2c, - 0x4a, 0xd1, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, - 0x45, 0xa8, 0xd1, 0x2b, 0x4e, 0x4f, 0xd5, 0x83, 0xa8, 0x91, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, - 0xab, 0xd0, 0x07, 0xb1, 0x20, 0x8a, 0x95, 0xf8, 0xb8, 0xd8, 0x02, 0xc0, 0x9a, 0xad, 0x58, 0x66, - 0x2c, 0x90, 0x67, 0x70, 0x72, 0x3e, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, - 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, - 0xcd, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x90, 0xd5, 0xba, 0xc8, 0xce, - 0xa8, 0x80, 0x39, 0xa4, 0xa4, 0xb2, 0x20, 0xb5, 0x38, 0x89, 0x0d, 0x6c, 0xb6, 0x31, 0x20, 0x00, - 0x00, 0xff, 0xff, 0xc7, 0x4e, 0x39, 0x14, 0xae, 0x00, 0x00, 0x00, +var fileDescriptor_6f7adb5e9f0583b4 = []byte{ + // 171 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2d, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0x2f, 0x4a, 0x2d, 0x4f, 0x2c, 0x4a, 0xd1, 0x2f, 0x33, + 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, + 0xc9, 0x17, 0x92, 0x28, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd3, 0x83, 0x28, 0xd3, 0x83, 0x28, 0x93, + 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd2, 0x07, 0xb1, 0x20, 0xea, 0x95, 0xf8, 0xb8, 0xd8, + 0x02, 0xc0, 0xfa, 0xad, 0x58, 0x66, 0x2c, 0x90, 0x67, 0x70, 0xf2, 0x3a, 0xf1, 0x48, 0x8e, 0xf1, + 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, + 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0x83, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, + 0x5c, 0xfd, 0xe2, 0xf4, 0x54, 0xdd, 0xbc, 0xd4, 0x92, 0xf2, 0xfc, 0xa2, 0x6c, 0x10, 0x5b, 0xbf, + 0x02, 0xcd, 0x65, 0x25, 0x95, 0x05, 0xa9, 0xc5, 0x49, 0x6c, 0x60, 0x2b, 0x8c, 0x01, 0x01, 0x00, + 0x00, 0xff, 0xff, 0x15, 0x93, 0x90, 0x1b, 0xbb, 0x00, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/types/pool.go b/x/legacy/reward/types/pool.go similarity index 100% rename from x/reward/types/pool.go rename to x/legacy/reward/types/pool.go diff --git a/x/reward/types/pool_test.go b/x/legacy/reward/types/pool_test.go similarity index 93% rename from x/reward/types/pool_test.go rename to x/legacy/reward/types/pool_test.go index bda9c811..19f50c60 100644 --- a/x/reward/types/pool_test.go +++ b/x/legacy/reward/types/pool_test.go @@ -7,7 +7,7 @@ import ( sdkmath "cosmossdk.io/math" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func TestCheckBalance(t *testing.T) { diff --git a/x/reward/types/promoter.go b/x/legacy/reward/types/promoter.go similarity index 100% rename from x/reward/types/promoter.go rename to x/legacy/reward/types/promoter.go diff --git a/x/reward/types/promoter.pb.go b/x/legacy/reward/types/promoter.pb.go similarity index 87% rename from x/reward/types/promoter.pb.go rename to x/legacy/reward/types/promoter.pb.go index 0d518d73..2f93cba1 100644 --- a/x/reward/types/promoter.pb.go +++ b/x/legacy/reward/types/promoter.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/promoter.proto +// source: sge/legacy/reward/v1beta/promoter.proto package types @@ -41,7 +41,7 @@ func (m *Promoter) Reset() { *m = Promoter{} } func (m *Promoter) String() string { return proto.CompactTextString(m) } func (*Promoter) ProtoMessage() {} func (*Promoter) Descriptor() ([]byte, []int) { - return fileDescriptor_fdd141f5acd4b4a9, []int{0} + return fileDescriptor_9b83bb4ce2a084f5, []int{0} } func (m *Promoter) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -108,7 +108,7 @@ func (m *PromoterConf) Reset() { *m = PromoterConf{} } func (m *PromoterConf) String() string { return proto.CompactTextString(m) } func (*PromoterConf) ProtoMessage() {} func (*PromoterConf) Descriptor() ([]byte, []int) { - return fileDescriptor_fdd141f5acd4b4a9, []int{1} + return fileDescriptor_9b83bb4ce2a084f5, []int{1} } func (m *PromoterConf) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -146,7 +146,7 @@ func (m *PromoterConf) GetCategoryCap() []CategoryCap { // CategoryCap is type to define category and its maximum cap. type CategoryCap struct { - Category RewardCategory `protobuf:"varint,1,opt,name=category,proto3,enum=sgenetwork.sge.reward.RewardCategory" json:"category,omitempty"` + Category RewardCategory `protobuf:"varint,1,opt,name=category,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"category,omitempty"` CapPerAcc int32 `protobuf:"varint,2,opt,name=cap_per_acc,json=capPerAcc,proto3" json:"cap_per_acc,omitempty"` } @@ -154,7 +154,7 @@ func (m *CategoryCap) Reset() { *m = CategoryCap{} } func (m *CategoryCap) String() string { return proto.CompactTextString(m) } func (*CategoryCap) ProtoMessage() {} func (*CategoryCap) Descriptor() ([]byte, []int) { - return fileDescriptor_fdd141f5acd4b4a9, []int{2} + return fileDescriptor_9b83bb4ce2a084f5, []int{2} } func (m *CategoryCap) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -209,7 +209,7 @@ func (m *PromoterByAddress) Reset() { *m = PromoterByAddress{} } func (m *PromoterByAddress) String() string { return proto.CompactTextString(m) } func (*PromoterByAddress) ProtoMessage() {} func (*PromoterByAddress) Descriptor() ([]byte, []int) { - return fileDescriptor_fdd141f5acd4b4a9, []int{3} + return fileDescriptor_9b83bb4ce2a084f5, []int{3} } func (m *PromoterByAddress) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -253,46 +253,46 @@ func (m *PromoterByAddress) GetAddress() string { } func init() { - proto.RegisterType((*Promoter)(nil), "sgenetwork.sge.reward.Promoter") - proto.RegisterType((*PromoterConf)(nil), "sgenetwork.sge.reward.PromoterConf") - proto.RegisterType((*CategoryCap)(nil), "sgenetwork.sge.reward.CategoryCap") - proto.RegisterType((*PromoterByAddress)(nil), "sgenetwork.sge.reward.PromoterByAddress") + proto.RegisterType((*Promoter)(nil), "sge.legacy.reward.v1beta.Promoter") + proto.RegisterType((*PromoterConf)(nil), "sge.legacy.reward.v1beta.PromoterConf") + proto.RegisterType((*CategoryCap)(nil), "sge.legacy.reward.v1beta.CategoryCap") + proto.RegisterType((*PromoterByAddress)(nil), "sge.legacy.reward.v1beta.PromoterByAddress") } func init() { - proto.RegisterFile("sgenetwork/sge/reward/promoter.proto", fileDescriptor_fdd141f5acd4b4a9) + proto.RegisterFile("sge/legacy/reward/v1beta/promoter.proto", fileDescriptor_9b83bb4ce2a084f5) } -var fileDescriptor_fdd141f5acd4b4a9 = []byte{ - // 435 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0x31, 0x8f, 0xd3, 0x30, - 0x14, 0xc7, 0x6b, 0x52, 0xe0, 0xea, 0x54, 0x27, 0x61, 0x1d, 0x52, 0x38, 0xa1, 0x24, 0x0a, 0x20, - 0x95, 0xe1, 0x52, 0xa9, 0xcc, 0x0c, 0x6d, 0x58, 0x10, 0xcb, 0xc9, 0x88, 0x05, 0x86, 0xc8, 0xe7, - 0xf8, 0x4c, 0x85, 0x1a, 0x5b, 0xb6, 0x4f, 0x47, 0xbf, 0x03, 0x03, 0x1f, 0x86, 0x95, 0xfd, 0xc6, - 0x13, 0x13, 0x53, 0x84, 0xd2, 0x8d, 0x4f, 0x81, 0x12, 0xdb, 0xb4, 0x27, 0x5d, 0x6f, 0x89, 0xe3, - 0xf7, 0x7e, 0xef, 0xd9, 0xfe, 0xbf, 0x3f, 0x7c, 0xae, 0x39, 0xab, 0x99, 0xb9, 0x14, 0xea, 0xcb, - 0x54, 0x73, 0x36, 0x55, 0xec, 0x92, 0xa8, 0x6a, 0x2a, 0x95, 0x58, 0x09, 0xc3, 0x54, 0x2e, 0x95, - 0x30, 0x02, 0x3d, 0xde, 0x52, 0xb9, 0xe6, 0x2c, 0xb7, 0xd4, 0xf1, 0x11, 0x17, 0x5c, 0xf4, 0xc4, - 0xb4, 0xfb, 0xb3, 0xf0, 0xf1, 0x13, 0x2a, 0xf4, 0x4a, 0xe8, 0xd2, 0x26, 0xec, 0xc6, 0xa5, 0xb2, - 0xdb, 0x4f, 0xb3, 0x8b, 0x65, 0xb2, 0x9f, 0x00, 0x1e, 0x9c, 0xba, 0xe3, 0xd1, 0x0c, 0x3e, 0xa4, - 0x8a, 0x11, 0x23, 0x54, 0x04, 0x52, 0x30, 0x19, 0x2d, 0xa2, 0x5f, 0x3f, 0x4e, 0x8e, 0x5c, 0xcf, - 0x79, 0x55, 0x29, 0xa6, 0xf5, 0x7b, 0xa3, 0x96, 0x35, 0xc7, 0x1e, 0x44, 0x29, 0x0c, 0x2e, 0x96, - 0x55, 0x74, 0xaf, 0xe7, 0x0f, 0xdb, 0x26, 0x09, 0x3e, 0xbc, 0x7d, 0xf3, 0xb7, 0x49, 0xba, 0x28, - 0xee, 0x3e, 0xe8, 0x29, 0x1c, 0x11, 0x5b, 0xcb, 0x74, 0x14, 0xa4, 0xc1, 0x64, 0x84, 0xb7, 0x01, - 0xf4, 0x1a, 0x0e, 0xa9, 0xa8, 0xcf, 0xa3, 0x61, 0x0a, 0x26, 0xe1, 0xec, 0x59, 0x7e, 0xeb, 0xdb, - 0x73, 0x7f, 0xc5, 0x42, 0xd4, 0xe7, 0x8b, 0xe1, 0x55, 0x93, 0x0c, 0x70, 0x5f, 0x96, 0x7d, 0x82, - 0xe3, 0xdd, 0x1c, 0x7a, 0x07, 0xc7, 0x94, 0x18, 0xc6, 0x85, 0x5a, 0x97, 0x94, 0xc8, 0x08, 0xa4, - 0xc1, 0x24, 0x9c, 0x65, 0x7b, 0xda, 0x16, 0x0e, 0x2d, 0x88, 0x74, 0x5d, 0x43, 0xba, 0x0d, 0x65, - 0x12, 0x86, 0x3b, 0x04, 0x9a, 0xc3, 0x03, 0x9f, 0xed, 0xf5, 0x39, 0x9c, 0xbd, 0xd8, 0xd3, 0x17, - 0xf7, 0x8b, 0xaf, 0xc5, 0xff, 0xcb, 0x50, 0x0c, 0x43, 0x4a, 0x64, 0x29, 0x99, 0x2a, 0x09, 0xa5, - 0xbd, 0x6a, 0xf7, 0xf1, 0x88, 0x12, 0x79, 0xca, 0xd4, 0x9c, 0xd2, 0xec, 0x1b, 0x80, 0x8f, 0xfc, - 0x7b, 0x16, 0x6b, 0x27, 0x39, 0x2a, 0xe0, 0xd8, 0x5b, 0xa4, 0xec, 0xc4, 0xb6, 0xc3, 0x49, 0xda, - 0x26, 0x09, 0x3d, 0x6c, 0x45, 0xbf, 0x81, 0xe1, 0x1b, 0xbb, 0x6e, 0xb8, 0x4e, 0x75, 0x37, 0xac, - 0x3b, 0x86, 0xeb, 0xc0, 0x45, 0x71, 0xd5, 0xc6, 0xe0, 0xba, 0x8d, 0xc1, 0x9f, 0x36, 0x06, 0xdf, - 0x37, 0xf1, 0xe0, 0x7a, 0x13, 0x0f, 0x7e, 0x6f, 0xe2, 0xc1, 0xc7, 0x97, 0x7c, 0x69, 0x3e, 0x5f, - 0x9c, 0xe5, 0x54, 0xac, 0x3a, 0x6f, 0x9d, 0xec, 0xfa, 0xec, 0xab, 0x77, 0x9a, 0x59, 0x4b, 0xa6, - 0xcf, 0x1e, 0xf4, 0x4e, 0x7b, 0xf5, 0x2f, 0x00, 0x00, 0xff, 0xff, 0xe0, 0xd7, 0x89, 0x57, 0xfd, - 0x02, 0x00, 0x00, +var fileDescriptor_9b83bb4ce2a084f5 = []byte{ + // 447 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0xc1, 0x6e, 0xd3, 0x30, + 0x18, 0xc7, 0x6b, 0x52, 0x60, 0x75, 0xaa, 0x49, 0x58, 0x3b, 0x84, 0x09, 0x25, 0x51, 0xa5, 0x41, + 0x2e, 0x4b, 0xa0, 0xbc, 0x00, 0x6b, 0x77, 0x81, 0x03, 0x9a, 0x8c, 0xb8, 0x70, 0x20, 0x72, 0x5d, + 0xcf, 0x54, 0xd0, 0xda, 0xb2, 0x3d, 0x46, 0xde, 0x81, 0x03, 0x0f, 0xc3, 0x03, 0x70, 0xdc, 0x71, + 0xe2, 0xc4, 0x29, 0x42, 0xe9, 0x8d, 0xa7, 0x40, 0xb1, 0x1d, 0xb6, 0x21, 0x65, 0x97, 0xc8, 0xfe, + 0xfb, 0xf7, 0xff, 0xec, 0xfc, 0xbf, 0x0f, 0x3e, 0xd1, 0x9c, 0x15, 0x9f, 0x18, 0x27, 0xb4, 0x2a, + 0x14, 0x3b, 0x27, 0x6a, 0x59, 0x7c, 0x7e, 0xb6, 0x60, 0x86, 0x14, 0x52, 0x89, 0xb5, 0x30, 0x4c, + 0xe5, 0x52, 0x09, 0x23, 0x50, 0xa4, 0x39, 0xcb, 0x1d, 0x98, 0x3b, 0x30, 0x77, 0xe0, 0xfe, 0x43, + 0x2a, 0xf4, 0x5a, 0xe8, 0xd2, 0x72, 0x85, 0xdb, 0x38, 0xd3, 0xfe, 0x1e, 0x17, 0x5c, 0x38, 0xbd, + 0x5d, 0x79, 0xf5, 0xa0, 0xf7, 0x4e, 0x5f, 0xd8, 0x62, 0x93, 0x1f, 0x00, 0xee, 0x9c, 0xf8, 0x47, + 0xa0, 0x29, 0xbc, 0x4f, 0x15, 0x23, 0x46, 0xa8, 0x08, 0xa4, 0x20, 0x1b, 0xcd, 0xa2, 0x9f, 0xdf, + 0x0f, 0xf7, 0xfc, 0x65, 0x47, 0xcb, 0xa5, 0x62, 0x5a, 0xbf, 0x31, 0x6a, 0xb5, 0xe1, 0xb8, 0x03, + 0x51, 0x0a, 0x83, 0xb3, 0xd5, 0x32, 0xba, 0x63, 0xf9, 0xdd, 0xa6, 0x4e, 0x82, 0xb7, 0x2f, 0x8f, + 0xff, 0xd4, 0x49, 0xab, 0xe2, 0xf6, 0x83, 0x1e, 0xc1, 0x11, 0x71, 0x5e, 0xa6, 0xa3, 0x20, 0x0d, + 0xb2, 0x11, 0xbe, 0x12, 0xd0, 0x0b, 0x38, 0xa4, 0x62, 0x73, 0x1a, 0x0d, 0x53, 0x90, 0x85, 0xd3, + 0xc7, 0x79, 0x5f, 0x02, 0x79, 0xf7, 0xca, 0xb9, 0xd8, 0x9c, 0xce, 0x86, 0x17, 0x75, 0x32, 0xc0, + 0xd6, 0x39, 0x79, 0x0f, 0xc7, 0xd7, 0xcf, 0xd0, 0x6b, 0x38, 0xa6, 0xc4, 0x30, 0x2e, 0x54, 0x55, + 0x52, 0x22, 0x23, 0x90, 0x06, 0x59, 0x38, 0x3d, 0xe8, 0xaf, 0x3c, 0xf7, 0xf4, 0x9c, 0x48, 0x5f, + 0x38, 0xa4, 0x57, 0xd2, 0x44, 0xc3, 0xf0, 0x1a, 0x81, 0x8e, 0xe1, 0x4e, 0x77, 0x6a, 0x53, 0xda, + 0x9d, 0x66, 0xfd, 0xa5, 0xb1, 0xdd, 0x75, 0x76, 0xfc, 0xcf, 0x89, 0x62, 0x18, 0x52, 0x22, 0x4b, + 0xc9, 0x54, 0x49, 0x28, 0xb5, 0xf1, 0xdd, 0xc5, 0x23, 0x4a, 0xe4, 0x09, 0x53, 0x47, 0x94, 0x4e, + 0xbe, 0x02, 0xf8, 0xa0, 0xfb, 0xab, 0x59, 0xe5, 0xb3, 0x47, 0x73, 0x38, 0xee, 0x26, 0xa6, 0x6c, + 0x53, 0x77, 0x5d, 0x4a, 0x9a, 0x3a, 0x09, 0x3b, 0xd8, 0xa5, 0x7f, 0x03, 0xc3, 0x37, 0x76, 0x6d, + 0x97, 0x7d, 0xfc, 0xbe, 0x6b, 0xb7, 0x74, 0xd9, 0x83, 0xb3, 0x57, 0x17, 0x4d, 0x0c, 0x2e, 0x9b, + 0x18, 0xfc, 0x6e, 0x62, 0xf0, 0x6d, 0x1b, 0x0f, 0x2e, 0xb7, 0xf1, 0xe0, 0xd7, 0x36, 0x1e, 0xbc, + 0x7b, 0xca, 0x57, 0xe6, 0xc3, 0xd9, 0x22, 0xa7, 0x62, 0x5d, 0x68, 0xce, 0x0e, 0x37, 0xcc, 0x9c, + 0x0b, 0xf5, 0xb1, 0x5d, 0x17, 0x5f, 0xfe, 0x1b, 0x40, 0x53, 0x49, 0xa6, 0x17, 0xf7, 0xec, 0xe4, + 0x3d, 0xff, 0x1b, 0x00, 0x00, 0xff, 0xff, 0xac, 0xcd, 0xc6, 0xa7, 0x16, 0x03, 0x00, 0x00, } func (m *Promoter) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/types/query.pb.go b/x/legacy/reward/types/query.pb.go similarity index 91% rename from x/reward/types/query.pb.go rename to x/legacy/reward/types/query.pb.go index c49e6fdc..9f532bd5 100644 --- a/x/reward/types/query.pb.go +++ b/x/legacy/reward/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/query.proto +// source: sge/legacy/reward/v1beta/query.proto package types @@ -39,7 +39,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{0} + return fileDescriptor_8cad129c0fe40d34, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -78,7 +78,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{1} + return fileDescriptor_8cad129c0fe40d34, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -124,7 +124,7 @@ func (m *QueryPromoterByAddressRequest) Reset() { *m = QueryPromoterByAd func (m *QueryPromoterByAddressRequest) String() string { return proto.CompactTextString(m) } func (*QueryPromoterByAddressRequest) ProtoMessage() {} func (*QueryPromoterByAddressRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{2} + return fileDescriptor_8cad129c0fe40d34, []int{2} } func (m *QueryPromoterByAddressRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -171,7 +171,7 @@ func (m *QueryPromoterByAddressResponse) Reset() { *m = QueryPromoterByA func (m *QueryPromoterByAddressResponse) String() string { return proto.CompactTextString(m) } func (*QueryPromoterByAddressResponse) ProtoMessage() {} func (*QueryPromoterByAddressResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{3} + return fileDescriptor_8cad129c0fe40d34, []int{3} } func (m *QueryPromoterByAddressResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -216,7 +216,7 @@ func (m *QueryPromotersRequest) Reset() { *m = QueryPromotersRequest{} } func (m *QueryPromotersRequest) String() string { return proto.CompactTextString(m) } func (*QueryPromotersRequest) ProtoMessage() {} func (*QueryPromotersRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{4} + return fileDescriptor_8cad129c0fe40d34, []int{4} } func (m *QueryPromotersRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -263,7 +263,7 @@ func (m *QueryPromotersResponse) Reset() { *m = QueryPromotersResponse{} func (m *QueryPromotersResponse) String() string { return proto.CompactTextString(m) } func (*QueryPromotersResponse) ProtoMessage() {} func (*QueryPromotersResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{5} + return fileDescriptor_8cad129c0fe40d34, []int{5} } func (m *QueryPromotersResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -315,7 +315,7 @@ func (m *QueryCampaignRequest) Reset() { *m = QueryCampaignRequest{} } func (m *QueryCampaignRequest) String() string { return proto.CompactTextString(m) } func (*QueryCampaignRequest) ProtoMessage() {} func (*QueryCampaignRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{6} + return fileDescriptor_8cad129c0fe40d34, []int{6} } func (m *QueryCampaignRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -360,7 +360,7 @@ func (m *QueryCampaignResponse) Reset() { *m = QueryCampaignResponse{} } func (m *QueryCampaignResponse) String() string { return proto.CompactTextString(m) } func (*QueryCampaignResponse) ProtoMessage() {} func (*QueryCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{7} + return fileDescriptor_8cad129c0fe40d34, []int{7} } func (m *QueryCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -405,7 +405,7 @@ func (m *QueryCampaignsRequest) Reset() { *m = QueryCampaignsRequest{} } func (m *QueryCampaignsRequest) String() string { return proto.CompactTextString(m) } func (*QueryCampaignsRequest) ProtoMessage() {} func (*QueryCampaignsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{8} + return fileDescriptor_8cad129c0fe40d34, []int{8} } func (m *QueryCampaignsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -452,7 +452,7 @@ func (m *QueryCampaignsResponse) Reset() { *m = QueryCampaignsResponse{} func (m *QueryCampaignsResponse) String() string { return proto.CompactTextString(m) } func (*QueryCampaignsResponse) ProtoMessage() {} func (*QueryCampaignsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{9} + return fileDescriptor_8cad129c0fe40d34, []int{9} } func (m *QueryCampaignsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -504,7 +504,7 @@ func (m *QueryRewardRequest) Reset() { *m = QueryRewardRequest{} } func (m *QueryRewardRequest) String() string { return proto.CompactTextString(m) } func (*QueryRewardRequest) ProtoMessage() {} func (*QueryRewardRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{10} + return fileDescriptor_8cad129c0fe40d34, []int{10} } func (m *QueryRewardRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -549,7 +549,7 @@ func (m *QueryRewardResponse) Reset() { *m = QueryRewardResponse{} } func (m *QueryRewardResponse) String() string { return proto.CompactTextString(m) } func (*QueryRewardResponse) ProtoMessage() {} func (*QueryRewardResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{11} + return fileDescriptor_8cad129c0fe40d34, []int{11} } func (m *QueryRewardResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -594,7 +594,7 @@ func (m *QueryRewardsRequest) Reset() { *m = QueryRewardsRequest{} } func (m *QueryRewardsRequest) String() string { return proto.CompactTextString(m) } func (*QueryRewardsRequest) ProtoMessage() {} func (*QueryRewardsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{12} + return fileDescriptor_8cad129c0fe40d34, []int{12} } func (m *QueryRewardsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -640,7 +640,7 @@ func (m *QueryRewardsResponse) Reset() { *m = QueryRewardsResponse{} } func (m *QueryRewardsResponse) String() string { return proto.CompactTextString(m) } func (*QueryRewardsResponse) ProtoMessage() {} func (*QueryRewardsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{13} + return fileDescriptor_8cad129c0fe40d34, []int{13} } func (m *QueryRewardsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -695,7 +695,7 @@ func (m *QueryRewardsByAddressRequest) Reset() { *m = QueryRewardsByAddr func (m *QueryRewardsByAddressRequest) String() string { return proto.CompactTextString(m) } func (*QueryRewardsByAddressRequest) ProtoMessage() {} func (*QueryRewardsByAddressRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{14} + return fileDescriptor_8cad129c0fe40d34, []int{14} } func (m *QueryRewardsByAddressRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -756,7 +756,7 @@ func (m *QueryRewardsByAddressResponse) Reset() { *m = QueryRewardsByAdd func (m *QueryRewardsByAddressResponse) String() string { return proto.CompactTextString(m) } func (*QueryRewardsByAddressResponse) ProtoMessage() {} func (*QueryRewardsByAddressResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{15} + return fileDescriptor_8cad129c0fe40d34, []int{15} } func (m *QueryRewardsByAddressResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -804,7 +804,7 @@ func (m *QueryRewardsByAddressResponse) GetPagination() *query.PageResponse { type QueryRewardsByAddressAndCategoryRequest struct { Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` - Category RewardCategory `protobuf:"varint,3,opt,name=category,proto3,enum=sgenetwork.sge.reward.RewardCategory" json:"category,omitempty"` + Category RewardCategory `protobuf:"varint,3,opt,name=category,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"category,omitempty"` PromoterUid string `protobuf:"bytes,4,opt,name=promoter_uid,json=promoterUid,proto3" json:"promoter_uid,omitempty"` } @@ -814,7 +814,7 @@ func (m *QueryRewardsByAddressAndCategoryRequest) Reset() { func (m *QueryRewardsByAddressAndCategoryRequest) String() string { return proto.CompactTextString(m) } func (*QueryRewardsByAddressAndCategoryRequest) ProtoMessage() {} func (*QueryRewardsByAddressAndCategoryRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{16} + return fileDescriptor_8cad129c0fe40d34, []int{16} } func (m *QueryRewardsByAddressAndCategoryRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -884,7 +884,7 @@ func (m *QueryRewardsByAddressAndCategoryResponse) Reset() { func (m *QueryRewardsByAddressAndCategoryResponse) String() string { return proto.CompactTextString(m) } func (*QueryRewardsByAddressAndCategoryResponse) ProtoMessage() {} func (*QueryRewardsByAddressAndCategoryResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{17} + return fileDescriptor_8cad129c0fe40d34, []int{17} } func (m *QueryRewardsByAddressAndCategoryResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -938,7 +938,7 @@ func (m *QueryRewardsByCampaignRequest) Reset() { *m = QueryRewardsByCam func (m *QueryRewardsByCampaignRequest) String() string { return proto.CompactTextString(m) } func (*QueryRewardsByCampaignRequest) ProtoMessage() {} func (*QueryRewardsByCampaignRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{18} + return fileDescriptor_8cad129c0fe40d34, []int{18} } func (m *QueryRewardsByCampaignRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -992,7 +992,7 @@ func (m *QueryRewardsByCampaignResponse) Reset() { *m = QueryRewardsByCa func (m *QueryRewardsByCampaignResponse) String() string { return proto.CompactTextString(m) } func (*QueryRewardsByCampaignResponse) ProtoMessage() {} func (*QueryRewardsByCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_102f3c906d210d41, []int{19} + return fileDescriptor_8cad129c0fe40d34, []int{19} } func (m *QueryRewardsByCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1036,97 +1036,100 @@ func (m *QueryRewardsByCampaignResponse) GetPagination() *query.PageResponse { } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.reward.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.reward.QueryParamsResponse") - proto.RegisterType((*QueryPromoterByAddressRequest)(nil), "sgenetwork.sge.reward.QueryPromoterByAddressRequest") - proto.RegisterType((*QueryPromoterByAddressResponse)(nil), "sgenetwork.sge.reward.QueryPromoterByAddressResponse") - proto.RegisterType((*QueryPromotersRequest)(nil), "sgenetwork.sge.reward.QueryPromotersRequest") - proto.RegisterType((*QueryPromotersResponse)(nil), "sgenetwork.sge.reward.QueryPromotersResponse") - proto.RegisterType((*QueryCampaignRequest)(nil), "sgenetwork.sge.reward.QueryCampaignRequest") - proto.RegisterType((*QueryCampaignResponse)(nil), "sgenetwork.sge.reward.QueryCampaignResponse") - proto.RegisterType((*QueryCampaignsRequest)(nil), "sgenetwork.sge.reward.QueryCampaignsRequest") - proto.RegisterType((*QueryCampaignsResponse)(nil), "sgenetwork.sge.reward.QueryCampaignsResponse") - proto.RegisterType((*QueryRewardRequest)(nil), "sgenetwork.sge.reward.QueryRewardRequest") - proto.RegisterType((*QueryRewardResponse)(nil), "sgenetwork.sge.reward.QueryRewardResponse") - proto.RegisterType((*QueryRewardsRequest)(nil), "sgenetwork.sge.reward.QueryRewardsRequest") - proto.RegisterType((*QueryRewardsResponse)(nil), "sgenetwork.sge.reward.QueryRewardsResponse") - proto.RegisterType((*QueryRewardsByAddressRequest)(nil), "sgenetwork.sge.reward.QueryRewardsByAddressRequest") - proto.RegisterType((*QueryRewardsByAddressResponse)(nil), "sgenetwork.sge.reward.QueryRewardsByAddressResponse") - proto.RegisterType((*QueryRewardsByAddressAndCategoryRequest)(nil), "sgenetwork.sge.reward.QueryRewardsByAddressAndCategoryRequest") - proto.RegisterType((*QueryRewardsByAddressAndCategoryResponse)(nil), "sgenetwork.sge.reward.QueryRewardsByAddressAndCategoryResponse") - proto.RegisterType((*QueryRewardsByCampaignRequest)(nil), "sgenetwork.sge.reward.QueryRewardsByCampaignRequest") - proto.RegisterType((*QueryRewardsByCampaignResponse)(nil), "sgenetwork.sge.reward.QueryRewardsByCampaignResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/reward/query.proto", fileDescriptor_102f3c906d210d41) } - -var fileDescriptor_102f3c906d210d41 = []byte{ - // 1039 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x98, 0xcf, 0x6f, 0xdc, 0x44, - 0x14, 0xc7, 0x33, 0x49, 0x48, 0xd2, 0xd7, 0x82, 0xda, 0x47, 0x8a, 0xca, 0x92, 0x6e, 0xba, 0xa6, - 0x6c, 0x92, 0x36, 0x6b, 0xab, 0xdb, 0x54, 0x40, 0x11, 0x94, 0x24, 0x82, 0x1e, 0x10, 0x52, 0x59, - 0xc4, 0x81, 0x4a, 0x28, 0xf2, 0xc6, 0x23, 0x63, 0xc1, 0xae, 0xb7, 0xb6, 0x97, 0xb2, 0x5a, 0xed, - 0x85, 0x0b, 0x12, 0x15, 0x12, 0x52, 0xc5, 0x95, 0x13, 0xe2, 0x0e, 0xe2, 0x18, 0x84, 0xb8, 0xf5, - 0x58, 0xc1, 0x85, 0x13, 0x42, 0x09, 0x37, 0xfe, 0x09, 0xe4, 0x99, 0x37, 0xde, 0x1f, 0x5e, 0xff, - 0x48, 0x64, 0xa4, 0x9e, 0xd6, 0xb1, 0xdf, 0x8f, 0xcf, 0x7c, 0xdf, 0xbc, 0x99, 0xa7, 0x40, 0xc5, - 0xb7, 0x79, 0x9b, 0x07, 0xf7, 0x5d, 0xef, 0x13, 0xc3, 0xb7, 0xb9, 0xe1, 0xf1, 0xfb, 0xa6, 0x67, - 0x19, 0xf7, 0xba, 0xdc, 0xeb, 0xe9, 0x1d, 0xcf, 0x0d, 0x5c, 0x3c, 0x3f, 0x34, 0xd1, 0x7d, 0x9b, - 0xeb, 0xd2, 0xa4, 0xb4, 0x6c, 0xbb, 0xb6, 0x2b, 0x2c, 0x8c, 0xf0, 0x49, 0x1a, 0x97, 0x9e, 0xdf, - 0x77, 0xfd, 0x96, 0xeb, 0xef, 0xc9, 0x0f, 0xf2, 0x0f, 0xfa, 0xb4, 0x62, 0xbb, 0xae, 0xfd, 0x29, - 0x37, 0xcc, 0x8e, 0x63, 0x98, 0xed, 0xb6, 0x1b, 0x98, 0x81, 0xe3, 0xb6, 0xd5, 0xd7, 0x2b, 0xd2, - 0xd6, 0x68, 0x9a, 0x3e, 0x97, 0xe9, 0x8d, 0xcf, 0xae, 0x35, 0x79, 0x60, 0x5e, 0x33, 0x3a, 0xa6, - 0xed, 0xb4, 0x85, 0x31, 0xd9, 0x6a, 0xd3, 0xa1, 0x3b, 0xa6, 0x67, 0xb6, 0x54, 0xbc, 0xcb, 0xd3, - 0x6d, 0xf6, 0xcd, 0x56, 0xc7, 0x74, 0xec, 0x8c, 0x48, 0xf2, 0x27, 0x3d, 0x52, 0xc7, 0x73, 0x5b, - 0x6e, 0xc0, 0x3d, 0x69, 0xa5, 0x2d, 0x03, 0xbe, 0x17, 0x52, 0xdf, 0x11, 0x10, 0x0d, 0x7e, 0xaf, - 0xcb, 0xfd, 0x40, 0x6b, 0xc0, 0xb3, 0x63, 0x6f, 0xfd, 0x8e, 0xdb, 0xf6, 0x39, 0xbe, 0x06, 0x0b, - 0x12, 0xf6, 0x02, 0xbb, 0xc4, 0xd6, 0x4f, 0xd7, 0x2f, 0xea, 0x53, 0x35, 0xd6, 0xa5, 0xdb, 0xce, - 0xfc, 0xa3, 0xbf, 0x56, 0x67, 0x1a, 0xe4, 0xa2, 0xbd, 0x0b, 0x17, 0x65, 0x4c, 0x02, 0xd8, 0xe9, - 0x6d, 0x5b, 0x96, 0xc7, 0x7d, 0x95, 0x14, 0x37, 0x61, 0xde, 0xb4, 0x2c, 0x4f, 0xc4, 0x3e, 0xb5, - 0x73, 0xe1, 0xf7, 0x9f, 0x6b, 0xcb, 0x54, 0x08, 0x32, 0x7c, 0x3f, 0xf0, 0x9c, 0xb6, 0xdd, 0x10, - 0x56, 0x5a, 0x1f, 0xca, 0x49, 0xe1, 0x88, 0xf6, 0x43, 0x58, 0x52, 0x8b, 0x25, 0xde, 0xd5, 0x24, - 0x5e, 0x15, 0x63, 0x25, 0x24, 0x4e, 0x4c, 0x1c, 0x85, 0xd3, 0xf6, 0xe0, 0xfc, 0x58, 0xf2, 0x68, - 0x0d, 0x6f, 0x03, 0x0c, 0xcb, 0x4e, 0x59, 0xab, 0x3a, 0x45, 0x0b, 0xf7, 0x88, 0x2e, 0xb7, 0x28, - 0xed, 0x11, 0xfd, 0x8e, 0x69, 0x73, 0xf2, 0x6d, 0x8c, 0x78, 0x6a, 0x07, 0x0c, 0x9e, 0x9b, 0xcc, - 0x30, 0x75, 0x59, 0x73, 0x05, 0x2e, 0x0b, 0x6f, 0x8f, 0xd1, 0xcf, 0x0a, 0xfa, 0xb5, 0x4c, 0x7a, - 0xc9, 0x35, 0x86, 0xbf, 0x0e, 0xcb, 0x82, 0x7e, 0x97, 0xb6, 0xad, 0x92, 0xe7, 0x2c, 0xcc, 0x75, - 0x1d, 0x4b, 0x56, 0xb8, 0x11, 0x3e, 0x6a, 0x77, 0x49, 0xc9, 0xa1, 0x25, 0x2d, 0x73, 0x1b, 0x96, - 0xd4, 0xa6, 0xcf, 0xa8, 0x9e, 0x72, 0xa5, 0xfd, 0x16, 0xb9, 0x45, 0x55, 0x52, 0x06, 0x85, 0x57, - 0xe9, 0x7b, 0x55, 0xa5, 0x91, 0x0c, 0x53, 0xf1, 0xe7, 0x4e, 0x80, 0x5f, 0x5c, 0x35, 0xaa, 0xd4, - 0xe3, 0x0d, 0x91, 0x30, 0xb9, 0x16, 0xaa, 0xeb, 0x95, 0xdd, 0xb0, 0xeb, 0x25, 0x6a, 0x46, 0xd7, - 0x4b, 0x37, 0xd5, 0xf5, 0xf2, 0xa5, 0xf6, 0xd1, 0x58, 0xcc, 0xc2, 0x2b, 0xf0, 0x1d, 0xa3, 0x9d, - 0x16, 0xc5, 0x27, 0xe8, 0xd7, 0x61, 0x51, 0x12, 0xf8, 0x24, 0x7f, 0x2e, 0x6a, 0xe5, 0x53, 0x9c, - 0xf6, 0xbf, 0x30, 0x58, 0x19, 0x05, 0x8c, 0x9d, 0x7a, 0x05, 0x29, 0x81, 0x75, 0x58, 0x34, 0x65, - 0x64, 0x81, 0x9b, 0x76, 0x80, 0x2a, 0x43, 0xac, 0xc0, 0x19, 0xd5, 0xfb, 0x7b, 0xe1, 0x5e, 0x98, - 0x13, 0x7b, 0xe1, 0xb4, 0x7a, 0xf7, 0x81, 0x63, 0x69, 0x3f, 0x32, 0x3a, 0xb6, 0xe3, 0xfc, 0xa4, - 0xf4, 0xed, 0x49, 0xa5, 0xd7, 0xd2, 0x95, 0xee, 0xed, 0x9a, 0x01, 0xb7, 0x5d, 0xaf, 0xf7, 0xbf, - 0x69, 0xfe, 0x60, 0x16, 0xd6, 0xa6, 0x32, 0x6f, 0xb7, 0x2d, 0x95, 0xfc, 0x49, 0x90, 0x5f, 0x9c, - 0x11, 0x12, 0x47, 0x48, 0xff, 0x4c, 0xfd, 0xa5, 0x54, 0xe9, 0x22, 0xf6, 0xc8, 0x2d, 0x56, 0xc1, - 0xf9, 0x78, 0x05, 0x0f, 0x18, 0xac, 0x67, 0xab, 0xf1, 0xc4, 0x16, 0xf3, 0xab, 0xd8, 0x06, 0x9c, - 0xbc, 0x54, 0x8a, 0x2a, 0x61, 0x05, 0xce, 0xa8, 0xb3, 0x57, 0x68, 0x39, 0x2b, 0xb5, 0x54, 0xef, - 0x42, 0x2d, 0x7f, 0x62, 0x34, 0x75, 0x4c, 0x81, 0x39, 0xb9, 0x82, 0x63, 0xe7, 0x7f, 0xe1, 0x0a, - 0xd6, 0x7f, 0x78, 0x1a, 0x9e, 0x12, 0xd0, 0xf8, 0x25, 0x83, 0x05, 0x39, 0x9b, 0xe1, 0x46, 0x02, - 0x55, 0x7c, 0x18, 0x2c, 0x5d, 0xc9, 0x63, 0x2a, 0xf3, 0x6a, 0xd5, 0x2f, 0xfe, 0xf8, 0xe7, 0xe1, - 0xec, 0x25, 0x2c, 0x87, 0x23, 0x67, 0x2d, 0x71, 0xd8, 0xc5, 0x03, 0x06, 0xe7, 0x62, 0x93, 0x1b, - 0x6e, 0xa5, 0x66, 0x4a, 0x98, 0x1b, 0x4b, 0x37, 0x8e, 0xe9, 0x45, 0xa8, 0x37, 0x05, 0xea, 0x16, - 0xd6, 0x13, 0x51, 0xc9, 0xb5, 0xd6, 0xec, 0xd5, 0xa8, 0x65, 0x8d, 0x7e, 0xf8, 0x30, 0xc0, 0x87, - 0x0c, 0x4e, 0x45, 0x93, 0x19, 0x6e, 0xe6, 0x01, 0x88, 0x70, 0x6b, 0x39, 0xad, 0x09, 0x73, 0x43, - 0x60, 0xbe, 0x88, 0x95, 0x2c, 0x4c, 0x1f, 0xbf, 0x65, 0xb0, 0xa4, 0x76, 0x13, 0x5e, 0x4d, 0x4b, - 0x33, 0xd1, 0x42, 0xa5, 0xcd, 0x7c, 0xc6, 0x84, 0xa4, 0x0b, 0xa4, 0x75, 0xac, 0x26, 0x21, 0xa9, - 0x96, 0x31, 0xfa, 0x5d, 0xc7, 0x92, 0x6a, 0x45, 0x13, 0x12, 0xe6, 0xca, 0x95, 0x4f, 0xad, 0xd8, - 0xd8, 0x95, 0xad, 0xd6, 0x7e, 0xc4, 0xf1, 0x35, 0x83, 0x05, 0xd9, 0x83, 0xe9, 0xcd, 0x30, 0x36, - 0x35, 0xa5, 0x37, 0xc3, 0xf8, 0xe0, 0xa4, 0x6d, 0x0a, 0x98, 0x2a, 0x5e, 0x4e, 0x82, 0xa1, 0x1f, - 0xa9, 0xd2, 0x03, 0x06, 0x8b, 0x74, 0xac, 0x60, 0x8e, 0x2c, 0x91, 0x42, 0x57, 0x73, 0xd9, 0x12, - 0xd2, 0x9a, 0x40, 0xaa, 0xe0, 0x6a, 0x3a, 0x92, 0x8f, 0xbf, 0x32, 0x38, 0x3b, 0x79, 0x61, 0xe0, - 0xf5, 0x1c, 0xa9, 0x62, 0xed, 0xb9, 0x75, 0x3c, 0x27, 0x02, 0x7d, 0x53, 0x80, 0xde, 0xc4, 0x57, - 0x32, 0x40, 0x8d, 0xfe, 0xe8, 0xfd, 0x37, 0x90, 0x0d, 0xca, 0x7d, 0x7f, 0x80, 0xff, 0x32, 0x78, - 0x21, 0xe5, 0xca, 0xc3, 0x37, 0x8e, 0xc3, 0x15, 0x9f, 0x1c, 0x4a, 0xb7, 0x4e, 0xec, 0x4f, 0x4b, - 0x7c, 0x47, 0x2c, 0xf1, 0x2d, 0xdc, 0x3d, 0xe9, 0x12, 0x8d, 0xbe, 0x9a, 0x03, 0x06, 0xf8, 0x1b, - 0x83, 0x73, 0xb1, 0x4b, 0x09, 0xf3, 0x69, 0x3f, 0x79, 0x1a, 0xdc, 0x38, 0xa6, 0x17, 0xad, 0xe7, - 0x96, 0x58, 0xcf, 0xab, 0xf8, 0x72, 0xd6, 0x7a, 0x86, 0xc7, 0xc3, 0xe8, 0x7d, 0x3b, 0xd8, 0xd9, - 0x7d, 0x74, 0x58, 0x66, 0x8f, 0x0f, 0xcb, 0xec, 0xef, 0xc3, 0x32, 0xfb, 0xe6, 0xa8, 0x3c, 0xf3, - 0xf8, 0xa8, 0x3c, 0xf3, 0xe7, 0x51, 0x79, 0xe6, 0xee, 0x86, 0xed, 0x04, 0x1f, 0x77, 0x9b, 0xfa, - 0xbe, 0xdb, 0x8a, 0x05, 0xff, 0x5c, 0x85, 0x0f, 0x7a, 0x1d, 0xee, 0x37, 0x17, 0xc4, 0xff, 0x35, - 0xae, 0xff, 0x17, 0x00, 0x00, 0xff, 0xff, 0x55, 0xaf, 0x69, 0xd0, 0x22, 0x12, 0x00, 0x00, + proto.RegisterType((*QueryParamsRequest)(nil), "sge.legacy.reward.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.legacy.reward.v1beta.QueryParamsResponse") + proto.RegisterType((*QueryPromoterByAddressRequest)(nil), "sge.legacy.reward.v1beta.QueryPromoterByAddressRequest") + proto.RegisterType((*QueryPromoterByAddressResponse)(nil), "sge.legacy.reward.v1beta.QueryPromoterByAddressResponse") + proto.RegisterType((*QueryPromotersRequest)(nil), "sge.legacy.reward.v1beta.QueryPromotersRequest") + proto.RegisterType((*QueryPromotersResponse)(nil), "sge.legacy.reward.v1beta.QueryPromotersResponse") + proto.RegisterType((*QueryCampaignRequest)(nil), "sge.legacy.reward.v1beta.QueryCampaignRequest") + proto.RegisterType((*QueryCampaignResponse)(nil), "sge.legacy.reward.v1beta.QueryCampaignResponse") + proto.RegisterType((*QueryCampaignsRequest)(nil), "sge.legacy.reward.v1beta.QueryCampaignsRequest") + proto.RegisterType((*QueryCampaignsResponse)(nil), "sge.legacy.reward.v1beta.QueryCampaignsResponse") + proto.RegisterType((*QueryRewardRequest)(nil), "sge.legacy.reward.v1beta.QueryRewardRequest") + proto.RegisterType((*QueryRewardResponse)(nil), "sge.legacy.reward.v1beta.QueryRewardResponse") + proto.RegisterType((*QueryRewardsRequest)(nil), "sge.legacy.reward.v1beta.QueryRewardsRequest") + proto.RegisterType((*QueryRewardsResponse)(nil), "sge.legacy.reward.v1beta.QueryRewardsResponse") + proto.RegisterType((*QueryRewardsByAddressRequest)(nil), "sge.legacy.reward.v1beta.QueryRewardsByAddressRequest") + proto.RegisterType((*QueryRewardsByAddressResponse)(nil), "sge.legacy.reward.v1beta.QueryRewardsByAddressResponse") + proto.RegisterType((*QueryRewardsByAddressAndCategoryRequest)(nil), "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryRequest") + proto.RegisterType((*QueryRewardsByAddressAndCategoryResponse)(nil), "sge.legacy.reward.v1beta.QueryRewardsByAddressAndCategoryResponse") + proto.RegisterType((*QueryRewardsByCampaignRequest)(nil), "sge.legacy.reward.v1beta.QueryRewardsByCampaignRequest") + proto.RegisterType((*QueryRewardsByCampaignResponse)(nil), "sge.legacy.reward.v1beta.QueryRewardsByCampaignResponse") +} + +func init() { + proto.RegisterFile("sge/legacy/reward/v1beta/query.proto", fileDescriptor_8cad129c0fe40d34) +} + +var fileDescriptor_8cad129c0fe40d34 = []byte{ + // 1055 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x58, 0x4f, 0x6f, 0x1b, 0x45, + 0x14, 0xcf, 0x24, 0x21, 0x49, 0x5f, 0x0b, 0x6a, 0x1f, 0x01, 0x05, 0x13, 0xdc, 0x64, 0x29, 0x8e, + 0xa9, 0xe2, 0xdd, 0xd6, 0x20, 0x12, 0x7a, 0x80, 0xc6, 0xe1, 0x8f, 0x54, 0x84, 0x54, 0x8c, 0x7a, + 0x41, 0x54, 0xd1, 0xda, 0x3b, 0x5a, 0x56, 0xd4, 0x5e, 0x77, 0x77, 0x4d, 0xb1, 0x22, 0x73, 0xe0, + 0x88, 0x04, 0x02, 0xf5, 0x84, 0x38, 0x71, 0xe2, 0x0b, 0x94, 0x23, 0xaa, 0x84, 0x84, 0xe8, 0xb1, + 0x82, 0x0b, 0x27, 0x84, 0x12, 0xbe, 0x00, 0xdf, 0x00, 0xed, 0xcc, 0x9b, 0x8d, 0xed, 0xcd, 0x66, + 0x36, 0xed, 0x56, 0xea, 0xc9, 0xe3, 0xf1, 0xfb, 0xf3, 0x7b, 0xbf, 0xf7, 0x67, 0x9e, 0x0c, 0xe7, + 0x42, 0x97, 0x5b, 0x37, 0xb8, 0x6b, 0xb7, 0x07, 0x56, 0xc0, 0x6f, 0xd9, 0x81, 0x63, 0x7d, 0x76, + 0xb1, 0xc5, 0x23, 0xdb, 0xba, 0xd9, 0xe7, 0xc1, 0xc0, 0xec, 0x05, 0x7e, 0xe4, 0xe3, 0x52, 0xe8, + 0x72, 0x53, 0x4a, 0x99, 0x52, 0xca, 0x94, 0x52, 0xa5, 0xf3, 0x6d, 0x3f, 0xec, 0xf8, 0xa1, 0xd5, + 0xb2, 0x43, 0x2e, 0x55, 0x48, 0xff, 0xa2, 0xd5, 0xb3, 0x5d, 0xaf, 0x6b, 0x47, 0x9e, 0xdf, 0x95, + 0x56, 0x4a, 0xcf, 0x49, 0xd9, 0x1d, 0xf1, 0xcd, 0x92, 0x5f, 0xe8, 0xa7, 0x45, 0xd7, 0x77, 0x7d, + 0x79, 0x1f, 0x9f, 0xe8, 0x76, 0xd9, 0xf5, 0x7d, 0xf7, 0x06, 0xb7, 0xec, 0x9e, 0x67, 0xd9, 0xdd, + 0xae, 0x1f, 0x09, 0x6b, 0x4a, 0x67, 0x2d, 0x13, 0x7a, 0xdb, 0xee, 0xf4, 0x6c, 0xcf, 0x55, 0x7e, + 0x5f, 0xca, 0x14, 0xec, 0xd9, 0x81, 0xdd, 0xd1, 0xdb, 0xeb, 0x05, 0x7e, 0xc7, 0x8f, 0x78, 0xa0, + 0xb5, 0x47, 0xdc, 0x08, 0x31, 0x63, 0x11, 0xf0, 0x83, 0x98, 0x90, 0xab, 0xc2, 0x49, 0x93, 0xdf, + 0xec, 0xf3, 0x30, 0x32, 0xae, 0xc1, 0xd3, 0x63, 0xb7, 0x61, 0xcf, 0xef, 0x86, 0x1c, 0xdf, 0x80, + 0x39, 0x09, 0x66, 0x89, 0xad, 0xb0, 0xea, 0xc9, 0xfa, 0x8a, 0x99, 0x45, 0xb9, 0x29, 0x35, 0x1b, + 0xb3, 0xf7, 0xfe, 0x3e, 0x3b, 0xd5, 0x24, 0x2d, 0xe3, 0x7d, 0x78, 0x41, 0x9a, 0x25, 0xa8, 0x8d, + 0xc1, 0x96, 0xe3, 0x04, 0x3c, 0x54, 0x7e, 0x71, 0x1d, 0x66, 0x6d, 0xc7, 0x09, 0x84, 0xf9, 0x13, + 0x8d, 0xa5, 0x3f, 0xee, 0xd4, 0x16, 0x29, 0x03, 0x24, 0xf8, 0x61, 0x14, 0x78, 0x5d, 0xb7, 0x29, + 0xa4, 0x8c, 0x2f, 0xa0, 0x9c, 0x65, 0x8e, 0x00, 0x7f, 0x0c, 0x0b, 0x8a, 0x16, 0x82, 0x6c, 0x1c, + 0x01, 0x59, 0x99, 0x59, 0x8e, 0x41, 0x67, 0xfa, 0x4e, 0x2c, 0x1a, 0x3b, 0xf0, 0xcc, 0x98, 0xff, + 0x24, 0x8c, 0x77, 0x00, 0x0e, 0xea, 0x8a, 0x1c, 0x57, 0x4c, 0xb2, 0x16, 0x17, 0xa1, 0x29, 0xeb, + 0x96, 0x8a, 0xd0, 0xbc, 0x6a, 0xbb, 0x9c, 0x74, 0x9b, 0x23, 0x9a, 0xc6, 0x5d, 0x06, 0xcf, 0x4e, + 0x7a, 0x38, 0x34, 0xb2, 0x99, 0x62, 0x23, 0xc3, 0x77, 0xc7, 0x02, 0x98, 0x16, 0x01, 0xac, 0x69, + 0x03, 0x90, 0xd0, 0xc6, 0x22, 0xa8, 0xc2, 0xa2, 0x08, 0x60, 0x9b, 0x8a, 0x5d, 0x31, 0x74, 0x1a, + 0x66, 0xfa, 0x9e, 0x23, 0xf3, 0xdc, 0x8c, 0x8f, 0xc6, 0x75, 0x22, 0xf3, 0x40, 0x92, 0x22, 0x7d, + 0x0b, 0x16, 0x54, 0xab, 0xe8, 0x73, 0xa8, 0xb4, 0xa9, 0xf0, 0x12, 0xcd, 0x24, 0x57, 0x4a, 0xa0, + 0xf0, 0x5c, 0xfd, 0xa4, 0x72, 0x35, 0xe2, 0xe1, 0xd0, 0x08, 0x66, 0x1e, 0x2c, 0x82, 0xe2, 0x72, + 0x52, 0xa1, 0x96, 0x6f, 0x0a, 0xbf, 0xd9, 0x19, 0x51, 0x43, 0x40, 0xc9, 0x1d, 0x0c, 0x01, 0x89, + 0x58, 0x3f, 0x04, 0xa4, 0xa6, 0x1a, 0x02, 0xf2, 0x37, 0xe3, 0xfa, 0x98, 0xd9, 0xc2, 0xf3, 0xf0, + 0x23, 0xa3, 0x92, 0x4b, 0xec, 0x13, 0xee, 0xcb, 0x30, 0x2f, 0x11, 0x84, 0x94, 0x84, 0xbc, 0xc0, + 0x95, 0x5a, 0x71, 0x19, 0xf8, 0x85, 0xc1, 0xf2, 0x28, 0xc6, 0xd4, 0x1c, 0x2c, 0x88, 0x0c, 0xac, + 0xc3, 0xbc, 0x2d, 0x2d, 0x0b, 0xb8, 0x47, 0x8d, 0x54, 0x25, 0x88, 0xab, 0x70, 0x4a, 0xcd, 0x81, + 0x9d, 0xb8, 0x22, 0x66, 0x44, 0x45, 0x9c, 0x54, 0x77, 0xd7, 0x3c, 0xc7, 0xb8, 0xc3, 0x68, 0x90, + 0xa7, 0xf1, 0x13, 0xd9, 0x57, 0x26, 0xc9, 0x3e, 0xaf, 0x25, 0x7b, 0xb0, 0x6d, 0x47, 0xdc, 0xf5, + 0x83, 0xc1, 0x23, 0xa3, 0xfd, 0x9b, 0x69, 0x58, 0x3b, 0x14, 0xf6, 0x56, 0xd7, 0x51, 0xce, 0x1f, + 0x87, 0x0c, 0x88, 0x79, 0x21, 0xe1, 0x08, 0xf6, 0x9f, 0xaa, 0x57, 0x75, 0xec, 0x25, 0xf0, 0x13, + 0xcd, 0x54, 0x1e, 0x67, 0xd3, 0x79, 0xbc, 0xcb, 0xa0, 0xaa, 0x27, 0xe4, 0x71, 0x4e, 0xe9, 0x57, + 0xa9, 0x4a, 0x9c, 0x7c, 0x69, 0x8a, 0x4a, 0xe4, 0x2a, 0x9c, 0x52, 0xa3, 0x58, 0xd0, 0x39, 0x2d, + 0xe9, 0x54, 0x77, 0x31, 0x9d, 0x3f, 0x33, 0x5a, 0x48, 0x0e, 0x01, 0xf3, 0x50, 0x24, 0x8e, 0xbd, + 0x08, 0x85, 0x93, 0x58, 0xdf, 0x7b, 0x12, 0x9e, 0x10, 0xb8, 0xf1, 0x6b, 0x06, 0x73, 0x72, 0x73, + 0xc3, 0xf5, 0x6c, 0x60, 0xe9, 0x85, 0xb1, 0x54, 0xcb, 0x29, 0x2d, 0xbd, 0x1b, 0x95, 0x2f, 0xff, + 0xfc, 0xf7, 0xf6, 0xf4, 0x0a, 0x96, 0xad, 0xd0, 0xe5, 0xb5, 0x2e, 0x8f, 0x6e, 0xf9, 0xc1, 0xa7, + 0xf1, 0x59, 0xad, 0xaa, 0x72, 0x61, 0xc4, 0x5f, 0x19, 0x9c, 0x49, 0x6d, 0x77, 0xb8, 0xa1, 0x73, + 0x96, 0xb1, 0x5e, 0x96, 0x36, 0x8f, 0xaf, 0x48, 0x80, 0x2f, 0x09, 0xc0, 0xaf, 0x62, 0x3d, 0x13, + 0x30, 0xa9, 0xd6, 0x5a, 0x83, 0x1a, 0xf5, 0xb1, 0xb5, 0x1b, 0x1f, 0x86, 0xf8, 0x3d, 0x83, 0x13, + 0xc9, 0x02, 0x87, 0x56, 0x4e, 0x0c, 0x09, 0xe8, 0x0b, 0xf9, 0x15, 0x08, 0xec, 0xcb, 0x02, 0xec, + 0x8b, 0xb8, 0xaa, 0x03, 0x1b, 0xe2, 0x0f, 0x0c, 0x16, 0x54, 0x7d, 0xa1, 0xa9, 0xf1, 0x34, 0xd1, + 0x5a, 0x25, 0x2b, 0xb7, 0x3c, 0x01, 0x33, 0x05, 0xb0, 0x2a, 0x56, 0xb2, 0x80, 0xa9, 0x6e, 0xb2, + 0x76, 0xfb, 0x9e, 0x23, 0x99, 0x4b, 0xd6, 0x29, 0xcc, 0xeb, 0x2e, 0x37, 0x73, 0xa9, 0x4d, 0x4d, + 0xcf, 0x5c, 0x3b, 0x41, 0x73, 0x9b, 0xc1, 0x9c, 0xec, 0x50, 0x6d, 0xab, 0x8c, 0x2d, 0x5a, 0xda, + 0x56, 0x19, 0x5f, 0xb7, 0x8c, 0x75, 0x01, 0xa9, 0x82, 0xe7, 0xb2, 0x20, 0xd1, 0x87, 0x64, 0xec, + 0x3b, 0x06, 0xf3, 0x34, 0x7d, 0x30, 0x9f, 0xa3, 0x84, 0x2d, 0x33, 0xaf, 0x38, 0x01, 0x5b, 0x13, + 0xc0, 0x56, 0xf1, 0xec, 0xd1, 0xc0, 0x42, 0xfc, 0x8d, 0xc1, 0xe9, 0xc9, 0x07, 0x06, 0x5f, 0xcb, + 0xe7, 0x2d, 0xd5, 0xc2, 0x1b, 0xc7, 0xd6, 0x23, 0xb8, 0x97, 0x05, 0xdc, 0x4b, 0xb8, 0xa9, 0x81, + 0x6b, 0xed, 0x8e, 0xbe, 0x9a, 0x43, 0xd9, 0xc4, 0x3c, 0x0c, 0x87, 0xf8, 0x1f, 0x83, 0xe7, 0x8f, + 0x78, 0x28, 0x71, 0xeb, 0x98, 0xd0, 0xd2, 0x5b, 0x47, 0xa9, 0xf1, 0x30, 0x26, 0x28, 0xd0, 0xf7, + 0x44, 0xa0, 0x6f, 0xe3, 0xf6, 0x83, 0x06, 0x6a, 0xed, 0xaa, 0x1d, 0x62, 0x88, 0xbf, 0x33, 0x38, + 0x93, 0x7a, 0xcd, 0x30, 0x77, 0x12, 0x26, 0x27, 0xc6, 0xe6, 0xf1, 0x15, 0x29, 0xaa, 0x37, 0x45, + 0x54, 0xaf, 0xe3, 0x86, 0x2e, 0xaa, 0x83, 0x11, 0x32, 0xfa, 0x5c, 0x0f, 0x1b, 0x57, 0xee, 0xed, + 0x95, 0xd9, 0xfd, 0xbd, 0x32, 0xfb, 0x67, 0xaf, 0xcc, 0xbe, 0xdd, 0x2f, 0x4f, 0xdd, 0xdf, 0x2f, + 0x4f, 0xfd, 0xb5, 0x5f, 0x9e, 0xfa, 0xe8, 0x82, 0xeb, 0x45, 0x9f, 0xf4, 0x5b, 0x66, 0xdb, 0xef, + 0xa4, 0x8c, 0x7f, 0x3e, 0xf1, 0x17, 0x4a, 0x34, 0xe8, 0xf1, 0xb0, 0x35, 0x27, 0xfe, 0x3b, 0x79, + 0xe5, 0xff, 0x00, 0x00, 0x00, 0xff, 0xff, 0x11, 0xdc, 0xef, 0x46, 0x98, 0x12, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1174,7 +1177,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -1183,7 +1186,7 @@ func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts . func (c *queryClient) PromoterByAddress(ctx context.Context, in *QueryPromoterByAddressRequest, opts ...grpc.CallOption) (*QueryPromoterByAddressResponse, error) { out := new(QueryPromoterByAddressResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/PromoterByAddress", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/PromoterByAddress", in, out, opts...) if err != nil { return nil, err } @@ -1192,7 +1195,7 @@ func (c *queryClient) PromoterByAddress(ctx context.Context, in *QueryPromoterBy func (c *queryClient) Promoters(ctx context.Context, in *QueryPromotersRequest, opts ...grpc.CallOption) (*QueryPromotersResponse, error) { out := new(QueryPromotersResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/Promoters", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/Promoters", in, out, opts...) if err != nil { return nil, err } @@ -1201,7 +1204,7 @@ func (c *queryClient) Promoters(ctx context.Context, in *QueryPromotersRequest, func (c *queryClient) Campaign(ctx context.Context, in *QueryCampaignRequest, opts ...grpc.CallOption) (*QueryCampaignResponse, error) { out := new(QueryCampaignResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/Campaign", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/Campaign", in, out, opts...) if err != nil { return nil, err } @@ -1210,7 +1213,7 @@ func (c *queryClient) Campaign(ctx context.Context, in *QueryCampaignRequest, op func (c *queryClient) Campaigns(ctx context.Context, in *QueryCampaignsRequest, opts ...grpc.CallOption) (*QueryCampaignsResponse, error) { out := new(QueryCampaignsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/Campaigns", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/Campaigns", in, out, opts...) if err != nil { return nil, err } @@ -1219,7 +1222,7 @@ func (c *queryClient) Campaigns(ctx context.Context, in *QueryCampaignsRequest, func (c *queryClient) Reward(ctx context.Context, in *QueryRewardRequest, opts ...grpc.CallOption) (*QueryRewardResponse, error) { out := new(QueryRewardResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/Reward", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/Reward", in, out, opts...) if err != nil { return nil, err } @@ -1228,7 +1231,7 @@ func (c *queryClient) Reward(ctx context.Context, in *QueryRewardRequest, opts . func (c *queryClient) Rewards(ctx context.Context, in *QueryRewardsRequest, opts ...grpc.CallOption) (*QueryRewardsResponse, error) { out := new(QueryRewardsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/Rewards", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/Rewards", in, out, opts...) if err != nil { return nil, err } @@ -1237,7 +1240,7 @@ func (c *queryClient) Rewards(ctx context.Context, in *QueryRewardsRequest, opts func (c *queryClient) RewardsByAddress(ctx context.Context, in *QueryRewardsByAddressRequest, opts ...grpc.CallOption) (*QueryRewardsByAddressResponse, error) { out := new(QueryRewardsByAddressResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/RewardsByAddress", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/RewardsByAddress", in, out, opts...) if err != nil { return nil, err } @@ -1246,7 +1249,7 @@ func (c *queryClient) RewardsByAddress(ctx context.Context, in *QueryRewardsByAd func (c *queryClient) RewardsByAddressAndCategory(ctx context.Context, in *QueryRewardsByAddressAndCategoryRequest, opts ...grpc.CallOption) (*QueryRewardsByAddressAndCategoryResponse, error) { out := new(QueryRewardsByAddressAndCategoryResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/RewardsByAddressAndCategory", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/RewardsByAddressAndCategory", in, out, opts...) if err != nil { return nil, err } @@ -1255,7 +1258,7 @@ func (c *queryClient) RewardsByAddressAndCategory(ctx context.Context, in *Query func (c *queryClient) RewardsByCampaign(ctx context.Context, in *QueryRewardsByCampaignRequest, opts ...grpc.CallOption) (*QueryRewardsByCampaignResponse, error) { out := new(QueryRewardsByCampaignResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Query/RewardsByCampaign", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Query/RewardsByCampaign", in, out, opts...) if err != nil { return nil, err } @@ -1336,7 +1339,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/Params", + FullMethod: "/sge.legacy.reward.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -1354,7 +1357,7 @@ func _Query_PromoterByAddress_Handler(srv interface{}, ctx context.Context, dec } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/PromoterByAddress", + FullMethod: "/sge.legacy.reward.v1beta.Query/PromoterByAddress", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PromoterByAddress(ctx, req.(*QueryPromoterByAddressRequest)) @@ -1372,7 +1375,7 @@ func _Query_Promoters_Handler(srv interface{}, ctx context.Context, dec func(int } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/Promoters", + FullMethod: "/sge.legacy.reward.v1beta.Query/Promoters", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Promoters(ctx, req.(*QueryPromotersRequest)) @@ -1390,7 +1393,7 @@ func _Query_Campaign_Handler(srv interface{}, ctx context.Context, dec func(inte } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/Campaign", + FullMethod: "/sge.legacy.reward.v1beta.Query/Campaign", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Campaign(ctx, req.(*QueryCampaignRequest)) @@ -1408,7 +1411,7 @@ func _Query_Campaigns_Handler(srv interface{}, ctx context.Context, dec func(int } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/Campaigns", + FullMethod: "/sge.legacy.reward.v1beta.Query/Campaigns", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Campaigns(ctx, req.(*QueryCampaignsRequest)) @@ -1426,7 +1429,7 @@ func _Query_Reward_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/Reward", + FullMethod: "/sge.legacy.reward.v1beta.Query/Reward", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Reward(ctx, req.(*QueryRewardRequest)) @@ -1444,7 +1447,7 @@ func _Query_Rewards_Handler(srv interface{}, ctx context.Context, dec func(inter } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/Rewards", + FullMethod: "/sge.legacy.reward.v1beta.Query/Rewards", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Rewards(ctx, req.(*QueryRewardsRequest)) @@ -1462,7 +1465,7 @@ func _Query_RewardsByAddress_Handler(srv interface{}, ctx context.Context, dec f } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/RewardsByAddress", + FullMethod: "/sge.legacy.reward.v1beta.Query/RewardsByAddress", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).RewardsByAddress(ctx, req.(*QueryRewardsByAddressRequest)) @@ -1480,7 +1483,7 @@ func _Query_RewardsByAddressAndCategory_Handler(srv interface{}, ctx context.Con } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/RewardsByAddressAndCategory", + FullMethod: "/sge.legacy.reward.v1beta.Query/RewardsByAddressAndCategory", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).RewardsByAddressAndCategory(ctx, req.(*QueryRewardsByAddressAndCategoryRequest)) @@ -1498,7 +1501,7 @@ func _Query_RewardsByCampaign_Handler(srv interface{}, ctx context.Context, dec } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Query/RewardsByCampaign", + FullMethod: "/sge.legacy.reward.v1beta.Query/RewardsByCampaign", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).RewardsByCampaign(ctx, req.(*QueryRewardsByCampaignRequest)) @@ -1506,8 +1509,9 @@ func _Query_RewardsByCampaign_Handler(srv interface{}, ctx context.Context, dec return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.reward.Query", + ServiceName: "sge.legacy.reward.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -1552,7 +1556,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/reward/query.proto", + Metadata: "sge/legacy/reward/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/types/query.pb.gw.go b/x/legacy/reward/types/query.pb.gw.go similarity index 99% rename from x/reward/types/query.pb.gw.go rename to x/legacy/reward/types/query.pb.gw.go index 1f85402d..0b37cf73 100644 --- a/x/reward/types/query.pb.gw.go +++ b/x/legacy/reward/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/reward/query.proto +// source: sge/legacy/reward/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/reward/types/reward.go b/x/legacy/reward/types/reward.go similarity index 94% rename from x/reward/types/reward.go rename to x/legacy/reward/types/reward.go index a07442e6..35f91a78 100644 --- a/x/reward/types/reward.go +++ b/x/legacy/reward/types/reward.go @@ -4,7 +4,7 @@ import ( context "context" "github.com/mrz1836/go-sanitize" - subaccounttypes "github.com/sge-network/sge/x/subaccount/types" + subaccounttypes "github.com/sge-network/sge/x/legacy/subaccount/types" yaml "gopkg.in/yaml.v2" sdkerrors "cosmossdk.io/errors" @@ -58,7 +58,7 @@ func NewRewardFactoryData(receiver Receiver, common RewardPayloadCommon) RewardF } func newRewardAmount(mainAccountAmount, subaccountAmount sdkmath.Int, - mainAccountPercentage, subaccountPercentage sdk.Dec, + mainAccountPercentage, subaccountPercentage sdkmath.LegacyDec, unlockPeriod uint64, ) RewardAmount { return RewardAmount{ @@ -112,7 +112,7 @@ type IRewardFactory interface { // NewReceiver creates receiver object. func NewReceiver(maAddr, saAddr string, maAmount, saAmount sdkmath.Int, - maPercentage, saPercentage sdk.Dec, + maPercentage, saPercentage sdkmath.LegacyDec, unlockPeriod uint64, ) Receiver { return Receiver{ diff --git a/x/reward/types/reward.pb.go b/x/legacy/reward/types/reward.pb.go similarity index 83% rename from x/reward/types/reward.pb.go rename to x/legacy/reward/types/reward.pb.go index ed5c549d..c8cf9b2b 100644 --- a/x/reward/types/reward.pb.go +++ b/x/legacy/reward/types/reward.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/reward.proto +// source: sge/legacy/reward/v1beta/reward.proto package types @@ -7,7 +7,6 @@ import ( cosmossdk_io_math "cosmossdk.io/math" fmt "fmt" _ "github.com/cosmos/cosmos-proto" - github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" @@ -75,7 +74,7 @@ func (x RewardCategory) String() string { } func (RewardCategory) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_31e6858ad0a3d6b8, []int{0} + return fileDescriptor_3db834905484e40a, []int{0} } // RewardType defines supported types of rewards of reward module. @@ -135,7 +134,7 @@ func (x RewardType) String() string { } func (RewardType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_31e6858ad0a3d6b8, []int{1} + return fileDescriptor_3db834905484e40a, []int{1} } // RewardType defines supported types of rewards of reward module. @@ -171,7 +170,7 @@ func (x RewardAmountType) String() string { } func (RewardAmountType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_31e6858ad0a3d6b8, []int{2} + return fileDescriptor_3db834905484e40a, []int{2} } // Reward is the type for transaction made to reward a user @@ -201,7 +200,7 @@ func (m *Reward) Reset() { *m = Reward{} } func (m *Reward) String() string { return proto.CompactTextString(m) } func (*Reward) ProtoMessage() {} func (*Reward) Descriptor() ([]byte, []int) { - return fileDescriptor_31e6858ad0a3d6b8, []int{0} + return fileDescriptor_3db834905484e40a, []int{0} } func (m *Reward) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -288,16 +287,16 @@ type RewardAmount struct { // unlock_period is the period after which the reward is unlocked. UnlockPeriod uint64 `protobuf:"varint,3,opt,name=unlock_period,proto3" json:"unlock_period"` // main_account_percentage transferred to main account address - MainAccountPercentage github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,4,opt,name=main_account_percentage,json=mainAccountPercentage,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"main_account_percentage" yaml:"main_account_percentage"` + MainAccountPercentage cosmossdk_io_math.LegacyDec `protobuf:"bytes,4,opt,name=main_account_percentage,json=mainAccountPercentage,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"main_account_percentage" yaml:"main_account_percentage"` // subaccount_percentage amount transferred to subaccount address - SubaccountPercentage github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,5,opt,name=subaccount_percentage,json=subaccountPercentage,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"subaccount_percentage" yaml:"subaccount_percentage"` + SubaccountPercentage cosmossdk_io_math.LegacyDec `protobuf:"bytes,5,opt,name=subaccount_percentage,json=subaccountPercentage,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"subaccount_percentage" yaml:"subaccount_percentage"` } func (m *RewardAmount) Reset() { *m = RewardAmount{} } func (m *RewardAmount) String() string { return proto.CompactTextString(m) } func (*RewardAmount) ProtoMessage() {} func (*RewardAmount) Descriptor() ([]byte, []int) { - return fileDescriptor_31e6858ad0a3d6b8, []int{1} + return fileDescriptor_3db834905484e40a, []int{1} } func (m *RewardAmount) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -340,14 +339,14 @@ type RewardByCategory struct { // addr is the address of the reward receiver. Addr string `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"` // reward_category is the category of the reward. - RewardCategory RewardCategory `protobuf:"varint,3,opt,name=reward_category,json=rewardCategory,proto3,enum=sgenetwork.sge.reward.RewardCategory" json:"reward_category,omitempty"` + RewardCategory RewardCategory `protobuf:"varint,3,opt,name=reward_category,json=rewardCategory,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"reward_category,omitempty"` } func (m *RewardByCategory) Reset() { *m = RewardByCategory{} } func (m *RewardByCategory) String() string { return proto.CompactTextString(m) } func (*RewardByCategory) ProtoMessage() {} func (*RewardByCategory) Descriptor() ([]byte, []int) { - return fileDescriptor_31e6858ad0a3d6b8, []int{2} + return fileDescriptor_3db834905484e40a, []int{2} } func (m *RewardByCategory) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -409,7 +408,7 @@ func (m *RewardByCampaign) Reset() { *m = RewardByCampaign{} } func (m *RewardByCampaign) String() string { return proto.CompactTextString(m) } func (*RewardByCampaign) ProtoMessage() {} func (*RewardByCampaign) Descriptor() ([]byte, []int) { - return fileDescriptor_31e6858ad0a3d6b8, []int{3} + return fileDescriptor_3db834905484e40a, []int{3} } func (m *RewardByCampaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -453,79 +452,79 @@ func (m *RewardByCampaign) GetCampaignUID() string { } func init() { - proto.RegisterEnum("sgenetwork.sge.reward.RewardCategory", RewardCategory_name, RewardCategory_value) - proto.RegisterEnum("sgenetwork.sge.reward.RewardType", RewardType_name, RewardType_value) - proto.RegisterEnum("sgenetwork.sge.reward.RewardAmountType", RewardAmountType_name, RewardAmountType_value) - proto.RegisterType((*Reward)(nil), "sgenetwork.sge.reward.Reward") - proto.RegisterType((*RewardAmount)(nil), "sgenetwork.sge.reward.RewardAmount") - proto.RegisterType((*RewardByCategory)(nil), "sgenetwork.sge.reward.RewardByCategory") - proto.RegisterType((*RewardByCampaign)(nil), "sgenetwork.sge.reward.RewardByCampaign") + proto.RegisterEnum("sge.legacy.reward.v1beta.RewardCategory", RewardCategory_name, RewardCategory_value) + proto.RegisterEnum("sge.legacy.reward.v1beta.RewardType", RewardType_name, RewardType_value) + proto.RegisterEnum("sge.legacy.reward.v1beta.RewardAmountType", RewardAmountType_name, RewardAmountType_value) + proto.RegisterType((*Reward)(nil), "sge.legacy.reward.v1beta.Reward") + proto.RegisterType((*RewardAmount)(nil), "sge.legacy.reward.v1beta.RewardAmount") + proto.RegisterType((*RewardByCategory)(nil), "sge.legacy.reward.v1beta.RewardByCategory") + proto.RegisterType((*RewardByCampaign)(nil), "sge.legacy.reward.v1beta.RewardByCampaign") } func init() { - proto.RegisterFile("sgenetwork/sge/reward/reward.proto", fileDescriptor_31e6858ad0a3d6b8) -} - -var fileDescriptor_31e6858ad0a3d6b8 = []byte{ - // 918 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0xcf, 0x8f, 0xdb, 0x44, - 0x14, 0x5e, 0x27, 0xd9, 0x5f, 0xaf, 0xdb, 0xc5, 0x3b, 0x6c, 0xda, 0x6c, 0x76, 0x1b, 0x6f, 0x8d, - 0x40, 0x65, 0xc5, 0x3a, 0xd2, 0xc2, 0x05, 0x7a, 0x72, 0x1c, 0x27, 0x58, 0xda, 0x26, 0xd1, 0xc4, - 0x11, 0x94, 0x4b, 0xe4, 0xb5, 0x07, 0x37, 0xca, 0x26, 0x8e, 0x6c, 0x87, 0x92, 0x33, 0x12, 0xe2, - 0xc8, 0x05, 0x89, 0x7f, 0x80, 0x7f, 0x00, 0x71, 0xe5, 0xde, 0x63, 0xc5, 0x09, 0x71, 0xb0, 0x50, - 0xf6, 0xd6, 0x63, 0xff, 0x02, 0xe4, 0x19, 0x27, 0x19, 0xbb, 0x11, 0x5b, 0xb8, 0x24, 0x9e, 0xf7, - 0x7d, 0x6f, 0xde, 0x37, 0xdf, 0xcc, 0x1b, 0x0d, 0xc8, 0x81, 0x4b, 0xc6, 0x24, 0x7c, 0xee, 0xf9, - 0xc3, 0x6a, 0xe0, 0x92, 0xaa, 0x4f, 0x9e, 0x5b, 0xbe, 0x93, 0xfc, 0x29, 0x13, 0xdf, 0x0b, 0x3d, - 0x54, 0x5c, 0x71, 0x94, 0xc0, 0x25, 0x0a, 0x03, 0xcb, 0x87, 0xae, 0xe7, 0x7a, 0x94, 0x51, 0x8d, - 0xbf, 0x18, 0xb9, 0x7c, 0x64, 0x7b, 0xc1, 0xc8, 0x0b, 0xfa, 0x0c, 0x60, 0x03, 0x06, 0xc9, 0x3f, - 0xe7, 0x61, 0x0b, 0xd3, 0x5c, 0x74, 0x0a, 0xf9, 0xe9, 0xc0, 0x29, 0x09, 0xa7, 0xc2, 0xa3, 0xdd, - 0xda, 0xfe, 0x3c, 0x92, 0xf2, 0x3d, 0xa3, 0xfe, 0x2a, 0x92, 0xe2, 0x28, 0x8e, 0x7f, 0xd0, 0x05, - 0x6c, 0xdb, 0x3e, 0xb1, 0x42, 0xcf, 0x2f, 0xe5, 0x28, 0xab, 0xf4, 0xc7, 0x6f, 0xe7, 0x87, 0xc9, - 0x7c, 0xaa, 0xe3, 0xf8, 0x24, 0x08, 0xba, 0xa1, 0x3f, 0x18, 0xbb, 0x78, 0x41, 0x44, 0x9f, 0xc0, - 0x8e, 0x4f, 0x6c, 0x32, 0xf8, 0x86, 0xf8, 0xa5, 0xfc, 0x2d, 0x49, 0x4b, 0x26, 0xd2, 0x60, 0xcf, - 0xb6, 0x46, 0x13, 0x6b, 0xe0, 0x8e, 0xfb, 0xb1, 0xa8, 0x02, 0xcd, 0x94, 0xe6, 0x91, 0x74, 0x47, - 0x4b, 0xe2, 0x4c, 0x5c, 0x8a, 0x86, 0x53, 0x23, 0x74, 0x0d, 0x77, 0x99, 0x2d, 0x7d, 0x6b, 0xe4, - 0x4d, 0xc7, 0x61, 0x69, 0xfb, 0x54, 0x78, 0x74, 0xe7, 0xe2, 0x3d, 0x65, 0xad, 0x77, 0x0a, 0xb3, - 0x41, 0xa5, 0xd4, 0xda, 0xc3, 0x79, 0x24, 0xed, 0xf1, 0x91, 0x57, 0x91, 0x94, 0x9e, 0x0d, 0xa7, - 0x87, 0xe8, 0x31, 0x40, 0xe0, 0x4d, 0x7d, 0x9b, 0x50, 0xc1, 0x3b, 0x54, 0xf0, 0xf1, 0x3c, 0x92, - 0x76, 0xbb, 0x34, 0xca, 0xe4, 0x72, 0x14, 0xcc, 0x7d, 0x23, 0x04, 0x85, 0x11, 0x09, 0xad, 0xd2, - 0x5e, 0x9c, 0x86, 0xe9, 0xb7, 0xfc, 0x7b, 0x01, 0x52, 0x0a, 0xd0, 0x10, 0xde, 0x1d, 0x59, 0x83, - 0x71, 0xdf, 0xb2, 0xed, 0x78, 0xbc, 0x58, 0x15, 0xdb, 0xb0, 0xc7, 0x2f, 0x22, 0x69, 0xe3, 0xaf, - 0x48, 0x2a, 0x32, 0x67, 0x03, 0x67, 0xa8, 0x0c, 0xbc, 0xea, 0xc8, 0x0a, 0x9f, 0x29, 0xc6, 0x38, - 0x7c, 0x1d, 0x49, 0xe5, 0x99, 0x35, 0xba, 0xfe, 0x4c, 0x5e, 0x33, 0x83, 0x8c, 0x0f, 0xe2, 0xa8, - 0xca, 0x82, 0x49, 0xb1, 0xaf, 0xe1, 0x20, 0x98, 0x5e, 0x65, 0x4a, 0xb1, 0x5d, 0xff, 0xf4, 0xb6, - 0x52, 0x25, 0x56, 0xea, 0x8d, 0x7c, 0x19, 0x8b, 0xab, 0x58, 0x52, 0xa7, 0x09, 0x77, 0xa7, 0xe3, - 0x6b, 0xcf, 0x1e, 0xf6, 0x27, 0xc4, 0x1f, 0x78, 0x0e, 0x3d, 0x24, 0x05, 0xe6, 0x7f, 0x8f, 0x02, - 0x1d, 0x1a, 0x8f, 0xfd, 0x4f, 0x11, 0x71, 0x7a, 0x88, 0x7e, 0x10, 0xe0, 0x7e, 0x6a, 0x71, 0x13, - 0xe2, 0xdb, 0x64, 0x1c, 0x5a, 0x2e, 0x49, 0x8e, 0x4f, 0x27, 0xd1, 0xfd, 0x81, 0x3b, 0x08, 0x9f, - 0x4d, 0xaf, 0x14, 0xdb, 0x1b, 0x25, 0xcd, 0x90, 0xfc, 0x9d, 0x07, 0xce, 0xb0, 0x1a, 0xce, 0x26, - 0x24, 0x50, 0xea, 0xc4, 0x7e, 0x1d, 0x49, 0x95, 0x35, 0x9e, 0xad, 0xa6, 0x95, 0x71, 0x91, 0xf3, - 0xad, 0xb3, 0x8c, 0xa3, 0xef, 0x04, 0x28, 0x72, 0x8b, 0xe7, 0x84, 0x6c, 0x52, 0x21, 0xad, 0xff, - 0x2c, 0xe4, 0xe4, 0x0d, 0x47, 0x79, 0x19, 0x87, 0xab, 0xf8, 0x4a, 0x85, 0xfc, 0xab, 0x00, 0x22, - 0x3b, 0x3f, 0xb5, 0x99, 0x66, 0x85, 0xc4, 0xf5, 0xfc, 0xd9, 0x5b, 0x34, 0xf9, 0x47, 0x50, 0xb0, - 0x1c, 0xe7, 0xf6, 0x0e, 0xa7, 0x2c, 0xd4, 0x82, 0x77, 0x92, 0x36, 0xb0, 0x93, 0x12, 0x74, 0x03, - 0xf7, 0x2f, 0xde, 0xff, 0xd7, 0x2e, 0x5b, 0xe8, 0xc1, 0xfb, 0x7e, 0x6a, 0x2c, 0xcf, 0x78, 0xcd, - 0xac, 0x97, 0xdf, 0x42, 0x73, 0xf6, 0xba, 0xc8, 0xfd, 0x8f, 0xeb, 0xe2, 0xec, 0xfb, 0x1c, 0xec, - 0xa7, 0xd5, 0x21, 0x09, 0x8e, 0xb1, 0xfe, 0x85, 0x8a, 0xeb, 0x7d, 0x4d, 0x35, 0xf5, 0x66, 0x1b, - 0x3f, 0xed, 0xf7, 0x5a, 0xdd, 0x8e, 0xae, 0x19, 0x0d, 0x43, 0xaf, 0x8b, 0x1b, 0xa8, 0x0c, 0xf7, - 0xb2, 0x84, 0xae, 0xd1, 0x6c, 0xf5, 0x3a, 0xa2, 0x80, 0x4e, 0xa0, 0x94, 0xc5, 0xb0, 0xde, 0xd0, - 0x31, 0x56, 0x2f, 0xc5, 0x1c, 0x7a, 0x00, 0x47, 0x59, 0x54, 0x6d, 0x34, 0x8c, 0x4b, 0x43, 0x35, - 0x75, 0x31, 0x8f, 0x2a, 0x50, 0xce, 0xc2, 0x35, 0xdd, 0x8c, 0x27, 0xe8, 0xb5, 0xea, 0x62, 0x61, - 0x5d, 0xfa, 0x13, 0xe3, 0x52, 0xef, 0x9a, 0xed, 0x96, 0x2e, 0x6e, 0xa2, 0x53, 0x38, 0x59, 0x97, - 0x5e, 0x37, 0xba, 0x5a, 0xbb, 0xd7, 0x32, 0xc5, 0x2d, 0x74, 0x04, 0xc5, 0x2c, 0xa3, 0x6d, 0x7e, - 0xae, 0x63, 0x71, 0xfb, 0xec, 0x97, 0x1c, 0x00, 0x33, 0xc2, 0x9c, 0x4d, 0x08, 0x3a, 0x86, 0xfb, - 0x09, 0xd3, 0x7c, 0xda, 0xd1, 0x33, 0x06, 0xdc, 0x03, 0xc4, 0x83, 0xcb, 0xc5, 0xaf, 0x9c, 0xa3, - 0xf1, 0xc5, 0xc2, 0x17, 0x84, 0x1c, 0xa7, 0x90, 0x12, 0x96, 0x6b, 0x5f, 0x30, 0xf2, 0xa8, 0x04, - 0x87, 0xeb, 0xa6, 0x10, 0x0b, 0x9c, 0xf6, 0x74, 0xae, 0xb8, 0xc9, 0x6d, 0x08, 0x85, 0x38, 0xcf, - 0xb6, 0xb2, 0x69, 0x2b, 0xbf, 0xb6, 0xb9, 0xbd, 0x5a, 0xa6, 0x2d, 0xbd, 0xda, 0x41, 0x45, 0x38, - 0xe0, 0x51, 0xe6, 0xd3, 0xee, 0xd9, 0x4f, 0xcb, 0x06, 0x63, 0x77, 0x19, 0x75, 0x4b, 0x86, 0x4a, - 0xc2, 0x55, 0x9f, 0xc4, 0xe9, 0xeb, 0x4c, 0x5b, 0x55, 0xe3, 0x39, 0x0d, 0xe3, 0x4b, 0xbd, 0x9e, - 0x3a, 0x37, 0x3c, 0x7a, 0xd9, 0x6e, 0x1a, 0x9a, 0x98, 0x43, 0x0f, 0xe1, 0xc1, 0x1a, 0xb4, 0xa3, - 0x63, 0x4d, 0x6f, 0x99, 0x6a, 0x53, 0x17, 0xf3, 0x35, 0xed, 0xc5, 0xbc, 0x22, 0xbc, 0x9c, 0x57, - 0x84, 0xbf, 0xe7, 0x15, 0xe1, 0xc7, 0x9b, 0xca, 0xc6, 0xcb, 0x9b, 0xca, 0xc6, 0x9f, 0x37, 0x95, - 0x8d, 0xaf, 0x3e, 0xe4, 0x2e, 0x9c, 0xc0, 0x25, 0xe7, 0xfc, 0x2b, 0xe3, 0xdb, 0xc5, 0x3b, 0x83, - 0xde, 0x3b, 0x57, 0x5b, 0xf4, 0x7d, 0xf0, 0xf1, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x6a, 0x5a, - 0x1b, 0x29, 0x8d, 0x08, 0x00, 0x00, + proto.RegisterFile("sge/legacy/reward/v1beta/reward.proto", fileDescriptor_3db834905484e40a) +} + +var fileDescriptor_3db834905484e40a = []byte{ + // 916 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0x3f, 0x6f, 0xdb, 0x46, + 0x1c, 0xd5, 0xbf, 0xf8, 0xcf, 0x2f, 0x8e, 0x4b, 0x5f, 0xad, 0x84, 0x96, 0x1d, 0xd2, 0x21, 0xd0, + 0xc2, 0x30, 0x1a, 0xa9, 0x75, 0xbb, 0xb4, 0x99, 0x28, 0x8a, 0x52, 0x59, 0x28, 0x92, 0x7a, 0xa2, + 0xd0, 0xa6, 0x8b, 0x40, 0x53, 0x57, 0x46, 0xb0, 0x25, 0x0a, 0x24, 0x95, 0x44, 0x43, 0xd7, 0xce, + 0x5d, 0x3a, 0x75, 0xce, 0x37, 0x68, 0xbf, 0x43, 0xc6, 0xa0, 0x53, 0xd1, 0x81, 0x28, 0xe4, 0x2d, + 0x63, 0x3e, 0x41, 0xc1, 0x3b, 0x4a, 0x3a, 0xd2, 0x2a, 0x6c, 0x74, 0x11, 0xee, 0xde, 0xef, 0xfd, + 0xee, 0xbd, 0x7b, 0x77, 0x47, 0x08, 0x3e, 0xf2, 0x1d, 0x52, 0xb9, 0x24, 0x8e, 0x65, 0xcf, 0x2a, + 0x1e, 0x79, 0x69, 0x79, 0x83, 0xca, 0x8b, 0xcf, 0xce, 0x49, 0x60, 0xc5, 0xb3, 0xf2, 0xc4, 0x73, + 0x03, 0x17, 0x89, 0xbe, 0x43, 0xca, 0x8c, 0x56, 0x8e, 0x0b, 0x8c, 0x56, 0x3a, 0xb0, 0x5d, 0x7f, + 0xe4, 0xfa, 0x7d, 0xca, 0xab, 0xb0, 0x09, 0x6b, 0x2a, 0xed, 0x3b, 0xae, 0xe3, 0x32, 0x3c, 0x1a, + 0x31, 0x54, 0xf9, 0x2d, 0x0f, 0x1b, 0x98, 0x2e, 0x81, 0x8e, 0x21, 0x3f, 0x1d, 0x0e, 0xc4, 0xec, + 0x71, 0xf6, 0x64, 0xbb, 0xba, 0x3b, 0x0f, 0xe5, 0x7c, 0xcf, 0xa8, 0xbd, 0x0b, 0xe5, 0x08, 0xc5, + 0xd1, 0x0f, 0x3a, 0x83, 0x4d, 0xdb, 0x23, 0x56, 0xe0, 0x7a, 0x62, 0x8e, 0xb2, 0xc4, 0x3f, 0x7f, + 0x7f, 0xbc, 0x1f, 0xab, 0xa8, 0x83, 0x81, 0x47, 0x7c, 0xbf, 0x1b, 0x78, 0xc3, 0xb1, 0x83, 0x17, + 0x44, 0xf4, 0x05, 0x6c, 0x79, 0xc4, 0x26, 0xc3, 0x17, 0xc4, 0x13, 0xf3, 0x37, 0x34, 0x2d, 0x99, + 0x48, 0x83, 0x1d, 0xdb, 0x1a, 0x4d, 0xac, 0xa1, 0x33, 0xee, 0x47, 0xa6, 0x0a, 0xb4, 0x53, 0x9e, + 0x87, 0xf2, 0x5d, 0x2d, 0xc6, 0x99, 0xb9, 0x04, 0x0d, 0x27, 0x66, 0xc8, 0x85, 0x7b, 0x2c, 0x9d, + 0xbe, 0x35, 0x72, 0xa7, 0xe3, 0x40, 0xdc, 0x3c, 0xce, 0x9e, 0xdc, 0x3d, 0xfb, 0xb8, 0xfc, 0x5f, + 0xf1, 0x95, 0x59, 0x12, 0x2a, 0x65, 0x57, 0x1f, 0xcd, 0x43, 0x79, 0x87, 0x47, 0xde, 0x85, 0x72, + 0x72, 0x41, 0x9c, 0x9c, 0xa2, 0x27, 0x00, 0xbe, 0x3b, 0xf5, 0x6c, 0x42, 0x3d, 0x6f, 0x51, 0xcf, + 0x87, 0xf3, 0x50, 0xde, 0xee, 0x52, 0x94, 0x39, 0xe6, 0x28, 0x98, 0x1b, 0x23, 0x04, 0x85, 0x11, + 0x09, 0x2c, 0x71, 0x27, 0x6a, 0xc3, 0x74, 0xac, 0xbc, 0x2e, 0x40, 0xc2, 0x01, 0xba, 0x80, 0x0f, + 0x47, 0xd6, 0x70, 0xdc, 0xb7, 0x6c, 0x3b, 0x9a, 0x2f, 0x36, 0xc6, 0xce, 0xec, 0xc9, 0x9b, 0x50, + 0xce, 0xfc, 0x1d, 0xca, 0x45, 0x16, 0xae, 0x3f, 0xb8, 0x28, 0x0f, 0xdd, 0xca, 0xc8, 0x0a, 0x9e, + 0x97, 0x8d, 0x71, 0xf0, 0x3e, 0x94, 0x4b, 0x33, 0x6b, 0x74, 0xf9, 0x95, 0xb2, 0x66, 0x05, 0x05, + 0xef, 0x45, 0xa8, 0xca, 0xc0, 0x58, 0xec, 0x47, 0xd8, 0xf3, 0xa7, 0xe7, 0x29, 0x29, 0x76, 0xf0, + 0x5f, 0xde, 0x24, 0x25, 0x32, 0xa9, 0x6b, 0xfd, 0x0a, 0x16, 0x56, 0x58, 0xac, 0xd3, 0x80, 0x7b, + 0xd3, 0xf1, 0xa5, 0x6b, 0x5f, 0xf4, 0x27, 0xc4, 0x1b, 0xba, 0x03, 0x7a, 0x4f, 0x0a, 0x2c, 0xff, + 0x1e, 0x2d, 0x74, 0x28, 0x1e, 0xe5, 0x9f, 0x20, 0xe2, 0xe4, 0x14, 0xfd, 0x04, 0x0f, 0x12, 0x7b, + 0x9b, 0x10, 0xcf, 0x26, 0xe3, 0xc0, 0x72, 0x48, 0x7c, 0x81, 0xf4, 0xd8, 0xf6, 0xe1, 0x75, 0xdb, + 0x4d, 0x7a, 0x1f, 0x6a, 0xc4, 0x7e, 0x1f, 0xca, 0xd2, 0x9a, 0x9c, 0x56, 0x6b, 0x29, 0xb8, 0xc8, + 0x65, 0xd5, 0x59, 0xe2, 0xe8, 0x15, 0x14, 0xb9, 0xfd, 0x72, 0xe2, 0x77, 0xa8, 0xb8, 0x76, 0x3b, + 0xf1, 0xa3, 0x6b, 0xc9, 0xf1, 0xd2, 0xfb, 0x2b, 0x7c, 0xa5, 0xac, 0xfc, 0x91, 0x05, 0x81, 0xdd, + 0x93, 0xea, 0x4c, 0xb3, 0x02, 0xe2, 0xb8, 0xde, 0xec, 0x16, 0xef, 0xf9, 0x13, 0x28, 0x58, 0x83, + 0xc1, 0xcd, 0x8f, 0x99, 0xb2, 0xd0, 0xb7, 0xf0, 0x41, 0x7c, 0xdd, 0xed, 0x58, 0x82, 0x1e, 0xd4, + 0xee, 0xd9, 0xc9, 0x4d, 0x0f, 0x6a, 0x61, 0x09, 0xef, 0x7a, 0x89, 0xb9, 0x32, 0xe3, 0x6d, 0xb3, + 0x97, 0x7b, 0x0b, 0xdb, 0xe9, 0x8f, 0x43, 0xee, 0x7f, 0x7c, 0x1c, 0x4e, 0x7f, 0xce, 0xc1, 0x6e, + 0xd2, 0x1d, 0x92, 0xe1, 0x10, 0xeb, 0xdf, 0xa9, 0xb8, 0xd6, 0xd7, 0x54, 0x53, 0x6f, 0xb4, 0xf1, + 0xb3, 0x7e, 0xaf, 0xd5, 0xed, 0xe8, 0x9a, 0x51, 0x37, 0xf4, 0x9a, 0x90, 0x41, 0x25, 0xb8, 0x9f, + 0x26, 0x74, 0x8d, 0x46, 0xab, 0xd7, 0x11, 0xb2, 0xe8, 0x08, 0xc4, 0x74, 0x0d, 0xeb, 0x75, 0x1d, + 0x63, 0xb5, 0x29, 0xe4, 0xd0, 0x43, 0x38, 0x48, 0x57, 0xd5, 0x7a, 0xdd, 0x68, 0x1a, 0xaa, 0xa9, + 0x0b, 0x79, 0x24, 0x41, 0x29, 0x5d, 0xae, 0xea, 0x66, 0xb4, 0x40, 0xaf, 0x55, 0x13, 0x0a, 0xeb, + 0xda, 0x9f, 0x1a, 0x4d, 0xbd, 0x6b, 0xb6, 0x5b, 0xba, 0x70, 0x07, 0x1d, 0xc3, 0xd1, 0xba, 0xf6, + 0x9a, 0xd1, 0xd5, 0xda, 0xbd, 0x96, 0x29, 0x6c, 0xa0, 0x03, 0x28, 0xa6, 0x19, 0x6d, 0xf3, 0x6b, + 0x1d, 0x0b, 0x9b, 0xa7, 0xaf, 0x73, 0x00, 0x2c, 0x08, 0x73, 0x36, 0x21, 0xe8, 0x10, 0x1e, 0xc4, + 0x4c, 0xf3, 0x59, 0x47, 0x4f, 0x05, 0x70, 0x1f, 0x10, 0x5f, 0x5c, 0x6e, 0x7e, 0x95, 0x1c, 0xc5, + 0x17, 0x1b, 0x5f, 0x10, 0x72, 0x9c, 0x43, 0x4a, 0x58, 0xee, 0x7d, 0xc1, 0xc8, 0x23, 0x11, 0xf6, + 0xd7, 0x2d, 0x21, 0x14, 0x38, 0xef, 0xc9, 0x5e, 0xe1, 0x0e, 0x77, 0x20, 0xb4, 0xc4, 0x65, 0xb6, + 0x91, 0x6e, 0x5b, 0xe5, 0xb5, 0xc9, 0x9d, 0xd5, 0xb2, 0x6d, 0x99, 0xd5, 0x16, 0x2a, 0xc2, 0x1e, + 0x5f, 0x65, 0x39, 0x6d, 0x9f, 0xfe, 0xba, 0x7c, 0x63, 0xec, 0xb3, 0x45, 0xd3, 0x52, 0x40, 0x8a, + 0xb9, 0xea, 0xd3, 0xa8, 0x7d, 0x5d, 0x68, 0x2b, 0x35, 0x9e, 0x53, 0x37, 0xbe, 0xd7, 0x6b, 0x89, + 0x7b, 0xc3, 0x57, 0x9b, 0xed, 0x86, 0xa1, 0x09, 0x39, 0xf4, 0x08, 0x1e, 0xae, 0xa9, 0x76, 0x74, + 0xac, 0xe9, 0x2d, 0x53, 0x6d, 0xe8, 0x42, 0xbe, 0xfa, 0xcd, 0x9b, 0xb9, 0x94, 0x7d, 0x3b, 0x97, + 0xb2, 0xff, 0xcc, 0xa5, 0xec, 0x2f, 0x57, 0x52, 0xe6, 0xed, 0x95, 0x94, 0xf9, 0xeb, 0x4a, 0xca, + 0xfc, 0xf0, 0xa9, 0x33, 0x0c, 0x9e, 0x4f, 0xcf, 0xcb, 0xb6, 0x3b, 0xaa, 0xf8, 0x0e, 0x79, 0x3c, + 0x26, 0xc1, 0x4b, 0xd7, 0xbb, 0x88, 0xc6, 0x95, 0x57, 0xa9, 0xbf, 0x19, 0xc1, 0x6c, 0x42, 0xfc, + 0xf3, 0x0d, 0xfa, 0xa7, 0xe0, 0xf3, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x8a, 0x87, 0x98, 0x66, + 0x88, 0x08, 0x00, 0x00, } func (m *Reward) Marshal() (dAtA []byte, err error) { diff --git a/x/reward/types/reward_bet_bonus.go b/x/legacy/reward/types/reward_bet_bonus.go similarity index 95% rename from x/reward/types/reward_bet_bonus.go rename to x/legacy/reward/types/reward_bet_bonus.go index 8e162686..39a22c6c 100644 --- a/x/reward/types/reward_bet_bonus.go +++ b/x/legacy/reward/types/reward_bet_bonus.go @@ -7,7 +7,7 @@ import ( sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - bettypes "github.com/sge-network/sge/x/bet/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" ) // BetBonusReward is the type for bet bonus rewards calculations @@ -80,10 +80,10 @@ func (sur BetBonusReward) Calculate(goCtx context.Context, ctx sdk.Context, keep return RewardFactoryData{}, sdkerrors.Wrapf(sdkerrtypes.ErrInvalidRequest, "bet should be winner or loser, requested bet result is %s", bet.Result) } - effectiveBetAmount := sdk.NewDecFromInt(bet.Amount) + effectiveBetAmount := sdkmath.LegacyNewDecFromInt(bet.Amount) if campaign.Constraints != nil { if !campaign.Constraints.MaxBetAmount.IsNil() && campaign.Constraints.MaxBetAmount.GT(sdkmath.ZeroInt()) { - effectiveBetAmount = sdk.NewDecFromInt( + effectiveBetAmount = sdkmath.LegacyNewDecFromInt( sdkmath.MinInt(campaign.Constraints.MaxBetAmount, bet.Amount), ) } diff --git a/x/reward/types/reward_signup.go b/x/legacy/reward/types/reward_signup.go similarity index 97% rename from x/reward/types/reward_signup.go rename to x/legacy/reward/types/reward_signup.go index fa19fa08..feea5e35 100644 --- a/x/reward/types/reward_signup.go +++ b/x/legacy/reward/types/reward_signup.go @@ -63,7 +63,7 @@ func (sur SignUpReward) Calculate(goCtx context.Context, ctx sdk.Context, keeper subaccountAddrStr, campaign.RewardAmount.MainAccountAmount, campaign.RewardAmount.SubaccountAmount, - sdk.ZeroDec(), sdk.ZeroDec(), + sdkmath.LegacyZeroDec(), sdkmath.LegacyZeroDec(), campaign.RewardAmount.UnlockPeriod, ), payload.Common, diff --git a/x/reward/types/reward_signup_affiliatee.go b/x/legacy/reward/types/reward_signup_affiliatee.go similarity index 98% rename from x/reward/types/reward_signup_affiliatee.go rename to x/legacy/reward/types/reward_signup_affiliatee.go index f2afa6cf..27c6a9c4 100644 --- a/x/reward/types/reward_signup_affiliatee.go +++ b/x/legacy/reward/types/reward_signup_affiliatee.go @@ -67,7 +67,7 @@ func (sur SignUpAffiliateeReward) Calculate(goCtx context.Context, ctx sdk.Conte subaccountAddrStr, campaign.RewardAmount.MainAccountAmount, campaign.RewardAmount.SubaccountAmount, - sdk.ZeroDec(), sdk.ZeroDec(), + sdkmath.LegacyZeroDec(), sdkmath.LegacyZeroDec(), campaign.RewardAmount.UnlockPeriod, ), payload.Common, diff --git a/x/reward/types/reward_signup_affiliator.go b/x/legacy/reward/types/reward_signup_affiliator.go similarity index 98% rename from x/reward/types/reward_signup_affiliator.go rename to x/legacy/reward/types/reward_signup_affiliator.go index 75a9f542..4e767561 100644 --- a/x/reward/types/reward_signup_affiliator.go +++ b/x/legacy/reward/types/reward_signup_affiliator.go @@ -75,7 +75,7 @@ func (sur SignUpAffiliatorReward) Calculate(goCtx context.Context, ctx sdk.Conte subaccountAddrStr, campaign.RewardAmount.MainAccountAmount, campaign.RewardAmount.SubaccountAmount, - sdk.ZeroDec(), sdk.ZeroDec(), + sdkmath.LegacyZeroDec(), sdkmath.LegacyZeroDec(), campaign.RewardAmount.UnlockPeriod, ), payload.Common, diff --git a/x/reward/types/reward_signup_referee.go b/x/legacy/reward/types/reward_signup_referee.go similarity index 98% rename from x/reward/types/reward_signup_referee.go rename to x/legacy/reward/types/reward_signup_referee.go index ecde0865..b57b3544 100644 --- a/x/reward/types/reward_signup_referee.go +++ b/x/legacy/reward/types/reward_signup_referee.go @@ -67,7 +67,7 @@ func (sur SignUpRefereelReward) Calculate(goCtx context.Context, ctx sdk.Context subaccountAddrStr, campaign.RewardAmount.MainAccountAmount, campaign.RewardAmount.SubaccountAmount, - sdk.ZeroDec(), sdk.ZeroDec(), + sdkmath.LegacyZeroDec(), sdkmath.LegacyZeroDec(), campaign.RewardAmount.UnlockPeriod, ), payload.Common, diff --git a/x/reward/types/reward_signup_referrer.go b/x/legacy/reward/types/reward_signup_referrer.go similarity index 98% rename from x/reward/types/reward_signup_referrer.go rename to x/legacy/reward/types/reward_signup_referrer.go index b1481a21..26c79a01 100644 --- a/x/reward/types/reward_signup_referrer.go +++ b/x/legacy/reward/types/reward_signup_referrer.go @@ -72,7 +72,7 @@ func (sur SignUpReferrerReward) Calculate(goCtx context.Context, ctx sdk.Context subaccountAddrStr, campaign.RewardAmount.MainAccountAmount, campaign.RewardAmount.SubaccountAmount, - sdk.ZeroDec(), sdk.ZeroDec(), + sdkmath.LegacyZeroDec(), sdkmath.LegacyZeroDec(), campaign.RewardAmount.UnlockPeriod, ), payload.Common, diff --git a/x/reward/types/ticket.go b/x/legacy/reward/types/ticket.go similarity index 92% rename from x/reward/types/ticket.go rename to x/legacy/reward/types/ticket.go index a617d1ec..d76d1556 100644 --- a/x/reward/types/ticket.go +++ b/x/legacy/reward/types/ticket.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/bet/types" + "github.com/sge-network/sge/x/legacy/bet/types" ) // Validate validates campaign creation ticket payload. @@ -33,9 +33,9 @@ func (payload *CreateCampaignPayload) Validate(blockTime uint64) error { switch payload.RewardAmountType { case RewardAmountType_REWARD_AMOUNT_TYPE_FIXED: if (!payload.RewardAmount.MainAccountPercentage.IsNil() && - payload.RewardAmount.MainAccountPercentage.GT(sdk.ZeroDec())) || + payload.RewardAmount.MainAccountPercentage.GT(sdkmath.LegacyZeroDec())) || (!payload.RewardAmount.SubaccountPercentage.IsNil() && - payload.RewardAmount.SubaccountPercentage.GT(sdk.ZeroDec())) { + payload.RewardAmount.SubaccountPercentage.GT(sdkmath.LegacyZeroDec())) { return sdkerrors.Wrapf(sdkerrtypes.ErrInvalidRequest, "reward percentage is not allowed for fixed amount campaign") } if (payload.RewardAmount.MainAccountAmount.IsNil() || @@ -52,9 +52,9 @@ func (payload *CreateCampaignPayload) Validate(blockTime uint64) error { return sdkerrors.Wrapf(sdkerrtypes.ErrInvalidRequest, "reward amount is not allowed for percentage campaign") } if (payload.RewardAmount.MainAccountPercentage.IsNil() || - payload.RewardAmount.MainAccountPercentage.LTE(sdk.ZeroDec())) && + payload.RewardAmount.MainAccountPercentage.LTE(sdkmath.LegacyZeroDec())) && (payload.RewardAmount.SubaccountPercentage.IsNil() || - payload.RewardAmount.SubaccountPercentage.LTE(sdk.ZeroDec())) { + payload.RewardAmount.SubaccountPercentage.LTE(sdkmath.LegacyZeroDec())) { return sdkerrors.Wrapf(sdkerrtypes.ErrInvalidRequest, "reward percentage should be set for at least one of main account or subaccount") } default: @@ -64,7 +64,7 @@ func (payload *CreateCampaignPayload) Validate(blockTime uint64) error { if ((!payload.RewardAmount.SubaccountAmount.IsNil() && payload.RewardAmount.SubaccountAmount.GT(sdkmath.ZeroInt())) || (!payload.RewardAmount.SubaccountPercentage.IsNil() && - payload.RewardAmount.SubaccountPercentage.GT(sdk.ZeroDec()))) && + payload.RewardAmount.SubaccountPercentage.GT(sdkmath.LegacyZeroDec()))) && payload.RewardAmount.UnlockPeriod == 0 { return sdkerrors.Wrapf(sdkerrtypes.ErrInvalidRequest, "sub account should have unlock period") } diff --git a/x/reward/types/ticket.pb.go b/x/legacy/reward/types/ticket.pb.go similarity index 89% rename from x/reward/types/ticket.pb.go rename to x/legacy/reward/types/ticket.pb.go index 60db2d79..01351d14 100644 --- a/x/reward/types/ticket.pb.go +++ b/x/legacy/reward/types/ticket.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/ticket.proto +// source: sge/legacy/reward/v1beta/ticket.proto package types @@ -8,7 +8,7 @@ import ( _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" - types "github.com/sge-network/sge/types" + legacy "github.com/sge-network/sge/types/legacy" io "io" math "math" math_bits "math/bits" @@ -35,11 +35,11 @@ type CreateCampaignPayload struct { // end_ts is the end timestamp of the campaign. EndTs uint64 `protobuf:"varint,3,opt,name=end_ts,json=endTs,proto3" json:"end_ts,omitempty"` // category is the category of the campaign. - Category RewardCategory `protobuf:"varint,4,opt,name=category,proto3,enum=sgenetwork.sge.reward.RewardCategory" json:"category,omitempty"` + Category RewardCategory `protobuf:"varint,4,opt,name=category,proto3,enum=sge.legacy.reward.v1beta.RewardCategory" json:"category,omitempty"` // reward_type is the type of reward. - RewardType RewardType `protobuf:"varint,5,opt,name=reward_type,json=rewardType,proto3,enum=sgenetwork.sge.reward.RewardType" json:"reward_type,omitempty"` + RewardType RewardType `protobuf:"varint,5,opt,name=reward_type,json=rewardType,proto3,enum=sge.legacy.reward.v1beta.RewardType" json:"reward_type,omitempty"` // Reward amount - RewardAmountType RewardAmountType `protobuf:"varint,6,opt,name=reward_amount_type,json=rewardAmountType,proto3,enum=sgenetwork.sge.reward.RewardAmountType" json:"reward_amount_type,omitempty"` + RewardAmountType RewardAmountType `protobuf:"varint,6,opt,name=reward_amount_type,json=rewardAmountType,proto3,enum=sge.legacy.reward.v1beta.RewardAmountType" json:"reward_amount_type,omitempty"` // reward_amount is the amount of reward. RewardAmount *RewardAmount `protobuf:"bytes,7,opt,name=reward_amount,json=rewardAmount,proto3" json:"reward_amount,omitempty"` // is_active is the flag to check if the campaign is active or not. @@ -57,7 +57,7 @@ func (m *CreateCampaignPayload) Reset() { *m = CreateCampaignPayload{} } func (m *CreateCampaignPayload) String() string { return proto.CompactTextString(m) } func (*CreateCampaignPayload) ProtoMessage() {} func (*CreateCampaignPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{0} + return fileDescriptor_6c907c7173936d03, []int{0} } func (m *CreateCampaignPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -175,7 +175,7 @@ func (m *UpdateCampaignPayload) Reset() { *m = UpdateCampaignPayload{} } func (m *UpdateCampaignPayload) String() string { return proto.CompactTextString(m) } func (*UpdateCampaignPayload) ProtoMessage() {} func (*UpdateCampaignPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{1} + return fileDescriptor_6c907c7173936d03, []int{1} } func (m *UpdateCampaignPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -229,7 +229,7 @@ func (m *WithdrawFundsPayload) Reset() { *m = WithdrawFundsPayload{} } func (m *WithdrawFundsPayload) String() string { return proto.CompactTextString(m) } func (*WithdrawFundsPayload) ProtoMessage() {} func (*WithdrawFundsPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{2} + return fileDescriptor_6c907c7173936d03, []int{2} } func (m *WithdrawFundsPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -278,14 +278,14 @@ type RewardPayloadCommon struct { // It is a stringified base64 encoded json. Meta string `protobuf:"bytes,3,opt,name=meta,proto3" json:"meta,omitempty"` // kyc_data contains the details of user kyc. - KycData *types.KycDataPayload `protobuf:"bytes,4,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data,omitempty"` + KycData *legacy.KycDataPayload `protobuf:"bytes,4,opt,name=kyc_data,json=kycData,proto3" json:"kyc_data,omitempty"` } func (m *RewardPayloadCommon) Reset() { *m = RewardPayloadCommon{} } func (m *RewardPayloadCommon) String() string { return proto.CompactTextString(m) } func (*RewardPayloadCommon) ProtoMessage() {} func (*RewardPayloadCommon) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{3} + return fileDescriptor_6c907c7173936d03, []int{3} } func (m *RewardPayloadCommon) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -335,7 +335,7 @@ func (m *RewardPayloadCommon) GetMeta() string { return "" } -func (m *RewardPayloadCommon) GetKycData() *types.KycDataPayload { +func (m *RewardPayloadCommon) GetKycData() *legacy.KycDataPayload { if m != nil { return m.KycData } @@ -352,7 +352,7 @@ func (m *GrantSignupRewardPayload) Reset() { *m = GrantSignupRewardPaylo func (m *GrantSignupRewardPayload) String() string { return proto.CompactTextString(m) } func (*GrantSignupRewardPayload) ProtoMessage() {} func (*GrantSignupRewardPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{4} + return fileDescriptor_6c907c7173936d03, []int{4} } func (m *GrantSignupRewardPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -402,7 +402,7 @@ func (m *GrantSignupReferrerRewardPayload) Reset() { *m = GrantSignupRef func (m *GrantSignupReferrerRewardPayload) String() string { return proto.CompactTextString(m) } func (*GrantSignupReferrerRewardPayload) ProtoMessage() {} func (*GrantSignupReferrerRewardPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{5} + return fileDescriptor_6c907c7173936d03, []int{5} } func (m *GrantSignupReferrerRewardPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -459,7 +459,7 @@ func (m *GrantSignupAffiliatorRewardPayload) Reset() { *m = GrantSignupA func (m *GrantSignupAffiliatorRewardPayload) String() string { return proto.CompactTextString(m) } func (*GrantSignupAffiliatorRewardPayload) ProtoMessage() {} func (*GrantSignupAffiliatorRewardPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{6} + return fileDescriptor_6c907c7173936d03, []int{6} } func (m *GrantSignupAffiliatorRewardPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -515,7 +515,7 @@ func (m *GrantBetBonusRewardPayload) Reset() { *m = GrantBetBonusRewardP func (m *GrantBetBonusRewardPayload) String() string { return proto.CompactTextString(m) } func (*GrantBetBonusRewardPayload) ProtoMessage() {} func (*GrantBetBonusRewardPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{7} + return fileDescriptor_6c907c7173936d03, []int{7} } func (m *GrantBetBonusRewardPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -569,7 +569,7 @@ func (m *CreatePromoterPayload) Reset() { *m = CreatePromoterPayload{} } func (m *CreatePromoterPayload) String() string { return proto.CompactTextString(m) } func (*CreatePromoterPayload) ProtoMessage() {} func (*CreatePromoterPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{8} + return fileDescriptor_6c907c7173936d03, []int{8} } func (m *CreatePromoterPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -621,7 +621,7 @@ func (m *SetPromoterConfPayload) Reset() { *m = SetPromoterConfPayload{} func (m *SetPromoterConfPayload) String() string { return proto.CompactTextString(m) } func (*SetPromoterConfPayload) ProtoMessage() {} func (*SetPromoterConfPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_b924af6a809dd84d, []int{9} + return fileDescriptor_6c907c7173936d03, []int{9} } func (m *SetPromoterConfPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -658,75 +658,75 @@ func (m *SetPromoterConfPayload) GetConf() PromoterConf { } func init() { - proto.RegisterType((*CreateCampaignPayload)(nil), "sgenetwork.sge.reward.CreateCampaignPayload") - proto.RegisterType((*UpdateCampaignPayload)(nil), "sgenetwork.sge.reward.UpdateCampaignPayload") - proto.RegisterType((*WithdrawFundsPayload)(nil), "sgenetwork.sge.reward.WithdrawFundsPayload") - proto.RegisterType((*RewardPayloadCommon)(nil), "sgenetwork.sge.reward.RewardPayloadCommon") - proto.RegisterType((*GrantSignupRewardPayload)(nil), "sgenetwork.sge.reward.GrantSignupRewardPayload") - proto.RegisterType((*GrantSignupReferrerRewardPayload)(nil), "sgenetwork.sge.reward.GrantSignupReferrerRewardPayload") - proto.RegisterType((*GrantSignupAffiliatorRewardPayload)(nil), "sgenetwork.sge.reward.GrantSignupAffiliatorRewardPayload") - proto.RegisterType((*GrantBetBonusRewardPayload)(nil), "sgenetwork.sge.reward.GrantBetBonusRewardPayload") - proto.RegisterType((*CreatePromoterPayload)(nil), "sgenetwork.sge.reward.CreatePromoterPayload") - proto.RegisterType((*SetPromoterConfPayload)(nil), "sgenetwork.sge.reward.SetPromoterConfPayload") + proto.RegisterType((*CreateCampaignPayload)(nil), "sge.legacy.reward.v1beta.CreateCampaignPayload") + proto.RegisterType((*UpdateCampaignPayload)(nil), "sge.legacy.reward.v1beta.UpdateCampaignPayload") + proto.RegisterType((*WithdrawFundsPayload)(nil), "sge.legacy.reward.v1beta.WithdrawFundsPayload") + proto.RegisterType((*RewardPayloadCommon)(nil), "sge.legacy.reward.v1beta.RewardPayloadCommon") + proto.RegisterType((*GrantSignupRewardPayload)(nil), "sge.legacy.reward.v1beta.GrantSignupRewardPayload") + proto.RegisterType((*GrantSignupReferrerRewardPayload)(nil), "sge.legacy.reward.v1beta.GrantSignupReferrerRewardPayload") + proto.RegisterType((*GrantSignupAffiliatorRewardPayload)(nil), "sge.legacy.reward.v1beta.GrantSignupAffiliatorRewardPayload") + proto.RegisterType((*GrantBetBonusRewardPayload)(nil), "sge.legacy.reward.v1beta.GrantBetBonusRewardPayload") + proto.RegisterType((*CreatePromoterPayload)(nil), "sge.legacy.reward.v1beta.CreatePromoterPayload") + proto.RegisterType((*SetPromoterConfPayload)(nil), "sge.legacy.reward.v1beta.SetPromoterConfPayload") } func init() { - proto.RegisterFile("sgenetwork/sge/reward/ticket.proto", fileDescriptor_b924af6a809dd84d) -} - -var fileDescriptor_b924af6a809dd84d = []byte{ - // 802 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0x4f, 0x6f, 0xe3, 0x44, - 0x14, 0xcf, 0x6c, 0xb2, 0x89, 0xf3, 0xb2, 0xac, 0xd0, 0xd0, 0x20, 0x6f, 0x57, 0x24, 0xc1, 0x80, - 0x08, 0x48, 0x9b, 0x48, 0x85, 0x03, 0x12, 0x02, 0x29, 0xf6, 0x0a, 0x16, 0xed, 0x1e, 0x56, 0x4e, - 0xab, 0x4a, 0x5c, 0xa2, 0xe9, 0x78, 0xe2, 0x5a, 0xa9, 0x3d, 0xd6, 0xcc, 0xa4, 0xad, 0xbf, 0x05, - 0x37, 0xae, 0x1c, 0xf9, 0x00, 0x7c, 0x03, 0x2e, 0x3d, 0x56, 0x9c, 0x38, 0xa0, 0x08, 0xa5, 0x37, - 0x3e, 0x05, 0xf2, 0xd8, 0x4e, 0x9d, 0x2a, 0xa9, 0xaa, 0xad, 0x7a, 0x89, 0x67, 0xe6, 0xfd, 0xde, - 0xef, 0xfd, 0xde, 0x1f, 0x67, 0x0c, 0x96, 0xf4, 0x59, 0xc4, 0xd4, 0x19, 0x17, 0xb3, 0xa1, 0xf4, - 0xd9, 0x50, 0xb0, 0x33, 0x22, 0xbc, 0xa1, 0x0a, 0xe8, 0x8c, 0xa9, 0x41, 0x2c, 0xb8, 0xe2, 0xb8, - 0x7d, 0x8d, 0x19, 0x48, 0x9f, 0x0d, 0x32, 0xcc, 0xee, 0x8e, 0xcf, 0x7d, 0xae, 0x11, 0xc3, 0x74, - 0x95, 0x81, 0x77, 0x9f, 0x51, 0x2e, 0x43, 0x2e, 0x27, 0x99, 0x21, 0xdb, 0xe4, 0xa6, 0x8f, 0x6e, - 0xc4, 0x52, 0x49, 0xcc, 0x86, 0xb3, 0x84, 0xe6, 0xe6, 0x4f, 0x37, 0x4b, 0xa1, 0x24, 0x8c, 0x49, - 0xe0, 0x47, 0x39, 0x6a, 0x8b, 0xe0, 0xec, 0x71, 0x3b, 0x53, 0x2c, 0x78, 0xc8, 0x15, 0x13, 0x19, - 0xca, 0xfa, 0xb3, 0x06, 0x6d, 0x47, 0x30, 0xa2, 0x98, 0x93, 0x87, 0x78, 0x4b, 0x92, 0x13, 0x4e, - 0x3c, 0xfc, 0x35, 0x18, 0x05, 0xd6, 0x44, 0x3d, 0xd4, 0x6f, 0xda, 0xe6, 0x5f, 0x7f, 0xbc, 0xd8, - 0xc9, 0x93, 0x19, 0x79, 0x9e, 0x60, 0x52, 0x8e, 0x95, 0x08, 0x22, 0xdf, 0x5d, 0x21, 0xf1, 0x33, - 0x30, 0xa4, 0x22, 0x42, 0x4d, 0x94, 0x34, 0x1f, 0xf5, 0x50, 0xbf, 0xe6, 0x36, 0xf4, 0x7e, 0x5f, - 0xe2, 0x36, 0xd4, 0x59, 0xe4, 0xa5, 0x86, 0xaa, 0x36, 0x3c, 0x66, 0x91, 0xb7, 0x2f, 0xf1, 0x08, - 0x0c, 0x4a, 0x14, 0xf3, 0xb9, 0x48, 0xcc, 0x5a, 0x0f, 0xf5, 0x9f, 0xee, 0x7d, 0x36, 0xd8, 0x58, - 0xeb, 0x81, 0xab, 0x1f, 0x4e, 0x0e, 0x76, 0x57, 0x6e, 0xd8, 0x86, 0x56, 0x06, 0x99, 0xa4, 0xd5, - 0x34, 0x1f, 0x6b, 0x96, 0x8f, 0x6f, 0x65, 0xd9, 0x4f, 0x62, 0xe6, 0x82, 0x58, 0xad, 0xf1, 0x01, - 0xe0, 0x9c, 0x83, 0x84, 0x7c, 0x1e, 0xa9, 0x8c, 0xaa, 0xae, 0xa9, 0x3e, 0xbf, 0x95, 0x6a, 0xa4, - 0xf1, 0x9a, 0xf0, 0x7d, 0x71, 0xe3, 0x04, 0xbf, 0x82, 0xf7, 0xd6, 0x68, 0xcd, 0x46, 0x0f, 0xf5, - 0x5b, 0x7b, 0x9f, 0xdc, 0x81, 0xd1, 0x7d, 0x52, 0x66, 0xc3, 0xcf, 0xa1, 0x19, 0xc8, 0x09, 0xa1, - 0x2a, 0x38, 0x65, 0xa6, 0xd1, 0x43, 0x7d, 0xc3, 0x35, 0x02, 0x39, 0xd2, 0x7b, 0x8c, 0xa1, 0x16, - 0x32, 0x45, 0x4c, 0x48, 0x1b, 0xe5, 0xea, 0x75, 0xea, 0x40, 0x49, 0x3c, 0xa1, 0x3a, 0x6c, 0x4b, - 0x97, 0xdc, 0xa0, 0x24, 0x76, 0x34, 0xdb, 0x1b, 0x68, 0x51, 0x1e, 0x49, 0x25, 0x48, 0x10, 0x29, - 0x69, 0x3e, 0xd1, 0xaa, 0xbe, 0xdc, 0xa2, 0xaa, 0x18, 0x0d, 0xe7, 0xda, 0xc3, 0x2d, 0xbb, 0x5b, - 0xaf, 0xa1, 0x7d, 0x10, 0x7b, 0x1b, 0x86, 0xe8, 0xba, 0xe7, 0xa8, 0xdc, 0xf3, 0xb5, 0x5c, 0x1e, - 0xad, 0xe7, 0x62, 0xbd, 0x81, 0x9d, 0xc3, 0x40, 0x1d, 0x7b, 0x82, 0x9c, 0xfd, 0x30, 0x8f, 0x3c, - 0x79, 0xaf, 0x81, 0xb4, 0xfe, 0x41, 0xf0, 0x41, 0x56, 0xd5, 0x9c, 0xc7, 0xe1, 0x61, 0xc8, 0xa3, - 0x94, 0x4d, 0x30, 0xca, 0x82, 0xd3, 0xbb, 0xb0, 0x15, 0x48, 0xfc, 0x2d, 0x80, 0xe4, 0x73, 0x41, - 0xd9, 0x64, 0x1e, 0x78, 0x5a, 0x79, 0xd3, 0x7e, 0xbe, 0x5c, 0x74, 0x9b, 0x63, 0x7d, 0x7a, 0xf0, - 0xd3, 0xcb, 0xff, 0x16, 0xdd, 0x12, 0xc4, 0x2d, 0xad, 0x57, 0x4d, 0xaa, 0x96, 0x9a, 0xf4, 0x3d, - 0x18, 0xb3, 0x84, 0x4e, 0x3c, 0xa2, 0x88, 0x9e, 0xfe, 0x0d, 0xa3, 0x91, 0x0e, 0xe2, 0xe0, 0x75, - 0x42, 0x5f, 0x12, 0x45, 0xf2, 0x1c, 0xdc, 0xc6, 0x2c, 0xdb, 0x5b, 0x1e, 0x98, 0x3f, 0x0a, 0x12, - 0xa9, 0x71, 0xe0, 0x47, 0xf3, 0x78, 0x2d, 0x51, 0xfc, 0x0a, 0xea, 0x54, 0x27, 0xab, 0x85, 0x6e, - 0x6f, 0xef, 0x86, 0xf2, 0xd8, 0xb5, 0x8b, 0x45, 0xb7, 0xe2, 0xe6, 0xfe, 0xd6, 0x6f, 0x08, 0x7a, - 0x6b, 0x61, 0xa6, 0x4c, 0x08, 0x26, 0xb6, 0x85, 0x43, 0xf7, 0x0b, 0x87, 0xf7, 0xa0, 0x21, 0xd2, - 0x10, 0x8c, 0xe5, 0x25, 0xde, 0xde, 0x9a, 0x02, 0x68, 0xfd, 0x8e, 0xc0, 0x2a, 0x49, 0x1c, 0x4d, - 0xa7, 0xc1, 0x49, 0x40, 0x14, 0x7f, 0x30, 0x91, 0xdf, 0x00, 0x90, 0x3c, 0xc8, 0x1d, 0x74, 0x96, - 0xb0, 0xd6, 0xaf, 0x08, 0x76, 0xb5, 0x54, 0x9b, 0x29, 0x9b, 0x47, 0x73, 0xf9, 0x50, 0x12, 0x87, - 0xd0, 0x38, 0x62, 0xaa, 0x34, 0xaa, 0xed, 0xe5, 0xa2, 0x5b, 0xb7, 0x99, 0xca, 0xe6, 0xb4, 0x30, - 0xba, 0xc5, 0xc2, 0x3a, 0x2f, 0x2e, 0x83, 0xb7, 0xf9, 0xeb, 0x53, 0x68, 0xea, 0x41, 0x35, 0x65, - 0xc9, 0x5e, 0x94, 0xa7, 0xcb, 0x45, 0xb7, 0x9a, 0x51, 0xa4, 0xa7, 0x6e, 0xfa, 0x83, 0xbf, 0x83, - 0x1a, 0xe5, 0xd1, 0x34, 0x1f, 0xb5, 0x6d, 0xff, 0x6f, 0x05, 0xaf, 0xc3, 0xa3, 0x69, 0x2e, 0x56, - 0xbb, 0x59, 0x87, 0xf0, 0xe1, 0x98, 0xa9, 0xb2, 0xb9, 0x08, 0x5d, 0x10, 0xa3, 0x77, 0x22, 0xb6, - 0x9d, 0x8b, 0x65, 0x07, 0x5d, 0x2e, 0x3b, 0xe8, 0xdf, 0x65, 0x07, 0xfd, 0x72, 0xd5, 0xa9, 0x5c, - 0x5e, 0x75, 0x2a, 0x7f, 0x5f, 0x75, 0x2a, 0x3f, 0x7f, 0xe1, 0x07, 0xea, 0x78, 0x7e, 0x34, 0xa0, - 0x3c, 0x4c, 0x2f, 0xc8, 0x17, 0xe5, 0xcb, 0xf2, 0x7c, 0xf5, 0x0d, 0x90, 0xc4, 0x4c, 0x1e, 0xd5, - 0xf5, 0x65, 0xf9, 0xd5, 0xff, 0x01, 0x00, 0x00, 0xff, 0xff, 0xb0, 0x15, 0x04, 0xf3, 0x29, 0x08, - 0x00, 0x00, + proto.RegisterFile("sge/legacy/reward/v1beta/ticket.proto", fileDescriptor_6c907c7173936d03) +} + +var fileDescriptor_6c907c7173936d03 = []byte{ + // 813 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x55, 0xcf, 0x6f, 0xe3, 0x44, + 0x14, 0xce, 0x6c, 0xb2, 0x89, 0xf3, 0xb2, 0xac, 0xd0, 0xd0, 0x20, 0x6f, 0x57, 0x4a, 0x2c, 0x8b, + 0x1f, 0x11, 0x52, 0x63, 0x28, 0x1c, 0x90, 0xb8, 0x90, 0xa4, 0x80, 0x20, 0x48, 0xac, 0x9c, 0xae, + 0x40, 0x7b, 0x89, 0x26, 0xe3, 0x89, 0xd7, 0x4a, 0xed, 0xb1, 0x66, 0x26, 0x2d, 0x16, 0xff, 0x04, + 0x67, 0xae, 0x1c, 0xb9, 0xf2, 0x47, 0xec, 0x71, 0xb5, 0x27, 0x4e, 0x01, 0xa5, 0x37, 0xfe, 0x0a, + 0xe4, 0xb1, 0x9d, 0x3a, 0x55, 0xd3, 0x56, 0x54, 0xbd, 0x44, 0x6f, 0x66, 0xbe, 0xf7, 0xbd, 0xef, + 0xcd, 0xfb, 0x26, 0x86, 0xf7, 0xa5, 0xcf, 0x9c, 0x13, 0xe6, 0x13, 0x9a, 0x38, 0x82, 0x9d, 0x11, + 0xe1, 0x39, 0xa7, 0x9f, 0xcc, 0x98, 0x22, 0x8e, 0x0a, 0xe8, 0x82, 0xa9, 0x7e, 0x2c, 0xb8, 0xe2, + 0xd8, 0x94, 0x3e, 0xeb, 0x67, 0xb0, 0x7e, 0x06, 0xeb, 0x67, 0xb0, 0xfd, 0x27, 0x94, 0xcb, 0x90, + 0xcb, 0xa9, 0xc6, 0x39, 0xd9, 0x22, 0x4b, 0xda, 0xdf, 0xf3, 0xb9, 0xcf, 0xb3, 0xfd, 0x34, 0xca, + 0x77, 0x3f, 0xdc, 0x59, 0x91, 0x92, 0x30, 0x26, 0x81, 0x1f, 0xdd, 0x08, 0x8c, 0x05, 0x0f, 0xb9, + 0x62, 0x22, 0x07, 0xee, 0xee, 0x21, 0x97, 0x9a, 0xc1, 0xac, 0x12, 0x4c, 0x25, 0x31, 0x2b, 0x40, + 0x8b, 0x84, 0x66, 0x08, 0xfb, 0x4d, 0x0d, 0xda, 0x23, 0xc1, 0x88, 0x62, 0xa3, 0x5c, 0xca, 0x33, + 0x92, 0x9c, 0x70, 0xe2, 0xe1, 0xcf, 0xc0, 0x28, 0x8a, 0x9a, 0xc8, 0x42, 0xbd, 0xe6, 0xd0, 0x7c, + 0xf3, 0xe7, 0xc1, 0x5e, 0xde, 0xee, 0xc0, 0xf3, 0x04, 0x93, 0x72, 0xa2, 0x44, 0x10, 0xf9, 0xee, + 0x06, 0x89, 0x9f, 0x80, 0x21, 0x15, 0x11, 0x6a, 0xaa, 0xa4, 0xf9, 0xc0, 0x42, 0xbd, 0x9a, 0xdb, + 0xd0, 0xeb, 0x63, 0x89, 0xdb, 0x50, 0x67, 0x91, 0x97, 0x1e, 0x54, 0xf5, 0xc1, 0x43, 0x16, 0x79, + 0xc7, 0x12, 0x1f, 0x81, 0x41, 0x89, 0x62, 0x3e, 0x17, 0x89, 0x59, 0xb3, 0x50, 0xef, 0xf1, 0x61, + 0xaf, 0xbf, 0xeb, 0xea, 0xfb, 0xae, 0x5e, 0x8d, 0x72, 0xbc, 0xbb, 0xc9, 0xc4, 0x5f, 0x41, 0x2b, + 0x43, 0x4e, 0xd3, 0x3e, 0xcd, 0x87, 0x9a, 0xe8, 0xbd, 0x9b, 0x88, 0x8e, 0x93, 0x98, 0xb9, 0x20, + 0x36, 0x31, 0xfe, 0x09, 0x70, 0x4e, 0x43, 0x42, 0xbe, 0x8c, 0x54, 0xc6, 0x56, 0xd7, 0x6c, 0x1f, + 0xdd, 0xc4, 0x36, 0xd0, 0x29, 0x9a, 0xf3, 0x6d, 0x71, 0x69, 0x07, 0x8f, 0xe1, 0xad, 0x2d, 0x66, + 0xb3, 0x61, 0xa1, 0x5e, 0xeb, 0xf0, 0x83, 0xdb, 0x91, 0xba, 0x8f, 0xca, 0x84, 0xf8, 0x29, 0x34, + 0x03, 0x39, 0x25, 0x54, 0x05, 0xa7, 0xcc, 0x34, 0x2c, 0xd4, 0x33, 0x5c, 0x23, 0x90, 0x03, 0xbd, + 0xc6, 0x18, 0x6a, 0x21, 0x53, 0xc4, 0x84, 0x74, 0x68, 0xae, 0x8e, 0xd3, 0x04, 0x4a, 0xe2, 0x29, + 0xd5, 0x95, 0x5b, 0xfa, 0xfa, 0x0d, 0x4a, 0xe2, 0x91, 0x66, 0xfb, 0x01, 0x5a, 0x94, 0x47, 0x52, + 0x09, 0x12, 0x44, 0x4a, 0x9a, 0x8f, 0xb4, 0xb0, 0x83, 0xdd, 0xc2, 0x0a, 0xa7, 0x8c, 0x2e, 0x92, + 0xdc, 0x32, 0x83, 0x3d, 0x86, 0xf6, 0xf3, 0xd8, 0xbb, 0xc2, 0x53, 0x17, 0x16, 0x40, 0x65, 0x0b, + 0x6c, 0xb5, 0xf3, 0x60, 0xbb, 0x1d, 0xfb, 0x7b, 0xd8, 0xfb, 0x31, 0x50, 0x2f, 0x3d, 0x41, 0xce, + 0xbe, 0x5e, 0x46, 0x9e, 0xbc, 0x93, 0x3f, 0xed, 0xbf, 0x11, 0xbc, 0x93, 0x5d, 0x6c, 0xce, 0x33, + 0xe2, 0x61, 0xc8, 0xa3, 0x94, 0x4d, 0x30, 0xca, 0x82, 0xd3, 0xdb, 0xb0, 0x15, 0x48, 0xfc, 0x05, + 0x80, 0xe4, 0x4b, 0x41, 0xd9, 0x74, 0x19, 0x78, 0x5a, 0x79, 0x73, 0xf8, 0x74, 0xbd, 0xea, 0x36, + 0x27, 0x7a, 0xf7, 0xf9, 0xb7, 0x47, 0xff, 0xae, 0xba, 0x25, 0x88, 0x5b, 0x8a, 0x37, 0x73, 0xaa, + 0x96, 0xe6, 0x34, 0x00, 0x63, 0x91, 0xd0, 0xa9, 0x47, 0x14, 0xd1, 0x8f, 0xe1, 0x92, 0x41, 0x52, + 0x37, 0x16, 0x53, 0x18, 0x27, 0xf4, 0x88, 0x28, 0x92, 0xb7, 0xe1, 0x36, 0x16, 0xd9, 0xda, 0xf6, + 0xc1, 0xfc, 0x46, 0x90, 0x48, 0x4d, 0x02, 0x3f, 0x5a, 0xc6, 0x5b, 0xbd, 0xe2, 0x31, 0xd4, 0xa9, + 0xee, 0x57, 0x6b, 0xbd, 0x76, 0xc8, 0x57, 0x5c, 0xd2, 0xb0, 0xf6, 0x6a, 0xd5, 0xad, 0xb8, 0x39, + 0x85, 0xfd, 0x3b, 0x02, 0x6b, 0xab, 0xd2, 0x9c, 0x09, 0xc1, 0xc4, 0xae, 0x8a, 0xe8, 0xce, 0x15, + 0xf1, 0x21, 0x34, 0x44, 0x5a, 0x85, 0xb1, 0xfc, 0xae, 0x77, 0xcf, 0xa8, 0x00, 0xda, 0x7f, 0x20, + 0xb0, 0x4b, 0x2a, 0x07, 0xf3, 0x79, 0x70, 0x12, 0x10, 0xc5, 0xef, 0x53, 0xe7, 0xe7, 0x00, 0x24, + 0xaf, 0x73, 0x0b, 0xa9, 0x25, 0xac, 0xfd, 0x1b, 0x82, 0x7d, 0xad, 0x76, 0xc8, 0xd4, 0x90, 0x47, + 0x4b, 0x79, 0x8f, 0x2a, 0x1d, 0x68, 0xcc, 0x98, 0x2a, 0x39, 0xb7, 0xbd, 0x5e, 0x75, 0xeb, 0x43, + 0xa6, 0x32, 0xdb, 0x16, 0x87, 0x6e, 0x11, 0xd8, 0xbf, 0x14, 0x9f, 0x8a, 0x67, 0xf9, 0x6b, 0x2a, + 0x64, 0x59, 0x50, 0x4d, 0x59, 0xb2, 0x77, 0xf3, 0x78, 0xbd, 0xea, 0x56, 0x33, 0x8a, 0x74, 0xd7, + 0x4d, 0x7f, 0xf0, 0x97, 0x50, 0xa3, 0x3c, 0x9a, 0xe7, 0xb6, 0xbb, 0xe6, 0x4f, 0xaf, 0xa0, 0x1e, + 0xf1, 0x68, 0x9e, 0xeb, 0xd5, 0x99, 0xf6, 0x0b, 0x78, 0x77, 0xc2, 0x54, 0xf9, 0xb8, 0xa8, 0x5e, + 0x70, 0xa3, 0xff, 0xcb, 0x3d, 0xfc, 0xee, 0xd5, 0xba, 0x83, 0x5e, 0xaf, 0x3b, 0xe8, 0x9f, 0x75, + 0x07, 0xfd, 0x7a, 0xde, 0xa9, 0xbc, 0x3e, 0xef, 0x54, 0xfe, 0x3a, 0xef, 0x54, 0x5e, 0x7c, 0xec, + 0x07, 0xea, 0xe5, 0x72, 0xd6, 0xa7, 0x3c, 0x74, 0xa4, 0xcf, 0x0e, 0x22, 0xa6, 0xce, 0xb8, 0x58, + 0xa4, 0xb1, 0xf3, 0xf3, 0xa5, 0x0f, 0x70, 0xfa, 0x38, 0xe5, 0xac, 0xae, 0xbf, 0xab, 0x9f, 0xfe, + 0x17, 0x00, 0x00, 0xff, 0xff, 0xbf, 0xb1, 0x00, 0xd5, 0x66, 0x08, 0x00, 0x00, } func (m *CreateCampaignPayload) Marshal() (dAtA []byte, err error) { @@ -2024,7 +2024,7 @@ func (m *RewardPayloadCommon) Unmarshal(dAtA []byte) error { return io.ErrUnexpectedEOF } if m.KycData == nil { - m.KycData = &types.KycDataPayload{} + m.KycData = &legacy.KycDataPayload{} } if err := m.KycData.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err diff --git a/x/reward/types/ticket_test.go b/x/legacy/reward/types/ticket_test.go similarity index 98% rename from x/reward/types/ticket_test.go rename to x/legacy/reward/types/ticket_test.go index 069a9ff0..6a557413 100644 --- a/x/reward/types/ticket_test.go +++ b/x/legacy/reward/types/ticket_test.go @@ -9,7 +9,7 @@ import ( "github.com/stretchr/testify/require" "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/reward/types" ) func TestCreateCampaignPayloadValidation(t *testing.T) { diff --git a/x/reward/types/tx.pb.go b/x/legacy/reward/types/tx.pb.go similarity index 90% rename from x/reward/types/tx.pb.go rename to x/legacy/reward/types/tx.pb.go index 08e2fe98..643bce75 100644 --- a/x/reward/types/tx.pb.go +++ b/x/legacy/reward/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/reward/tx.proto +// source: sge/legacy/reward/v1beta/tx.proto package types @@ -44,7 +44,7 @@ func (m *MsgCreatePromoter) Reset() { *m = MsgCreatePromoter{} } func (m *MsgCreatePromoter) String() string { return proto.CompactTextString(m) } func (*MsgCreatePromoter) ProtoMessage() {} func (*MsgCreatePromoter) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{0} + return fileDescriptor_89da971360d3fc55, []int{0} } func (m *MsgCreatePromoter) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -95,7 +95,7 @@ func (m *MsgCreatePromoterResponse) Reset() { *m = MsgCreatePromoterResp func (m *MsgCreatePromoterResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreatePromoterResponse) ProtoMessage() {} func (*MsgCreatePromoterResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{1} + return fileDescriptor_89da971360d3fc55, []int{1} } func (m *MsgCreatePromoterResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -138,7 +138,7 @@ func (m *MsgSetPromoterConf) Reset() { *m = MsgSetPromoterConf{} } func (m *MsgSetPromoterConf) String() string { return proto.CompactTextString(m) } func (*MsgSetPromoterConf) ProtoMessage() {} func (*MsgSetPromoterConf) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{2} + return fileDescriptor_89da971360d3fc55, []int{2} } func (m *MsgSetPromoterConf) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -196,7 +196,7 @@ func (m *MsgSetPromoterConfResponse) Reset() { *m = MsgSetPromoterConfRe func (m *MsgSetPromoterConfResponse) String() string { return proto.CompactTextString(m) } func (*MsgSetPromoterConfResponse) ProtoMessage() {} func (*MsgSetPromoterConfResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{3} + return fileDescriptor_89da971360d3fc55, []int{3} } func (m *MsgSetPromoterConfResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -241,7 +241,7 @@ func (m *MsgCreateCampaign) Reset() { *m = MsgCreateCampaign{} } func (m *MsgCreateCampaign) String() string { return proto.CompactTextString(m) } func (*MsgCreateCampaign) ProtoMessage() {} func (*MsgCreateCampaign) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{4} + return fileDescriptor_89da971360d3fc55, []int{4} } func (m *MsgCreateCampaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -299,7 +299,7 @@ func (m *MsgCreateCampaignResponse) Reset() { *m = MsgCreateCampaignResp func (m *MsgCreateCampaignResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreateCampaignResponse) ProtoMessage() {} func (*MsgCreateCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{5} + return fileDescriptor_89da971360d3fc55, []int{5} } func (m *MsgCreateCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -345,7 +345,7 @@ func (m *MsgUpdateCampaign) Reset() { *m = MsgUpdateCampaign{} } func (m *MsgUpdateCampaign) String() string { return proto.CompactTextString(m) } func (*MsgUpdateCampaign) ProtoMessage() {} func (*MsgUpdateCampaign) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{6} + return fileDescriptor_89da971360d3fc55, []int{6} } func (m *MsgUpdateCampaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -403,7 +403,7 @@ func (m *MsgUpdateCampaignResponse) Reset() { *m = MsgUpdateCampaignResp func (m *MsgUpdateCampaignResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateCampaignResponse) ProtoMessage() {} func (*MsgUpdateCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{7} + return fileDescriptor_89da971360d3fc55, []int{7} } func (m *MsgUpdateCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -448,7 +448,7 @@ func (m *MsgGrantReward) Reset() { *m = MsgGrantReward{} } func (m *MsgGrantReward) String() string { return proto.CompactTextString(m) } func (*MsgGrantReward) ProtoMessage() {} func (*MsgGrantReward) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{8} + return fileDescriptor_89da971360d3fc55, []int{8} } func (m *MsgGrantReward) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -513,7 +513,7 @@ func (m *MsgGrantRewardResponse) Reset() { *m = MsgGrantRewardResponse{} func (m *MsgGrantRewardResponse) String() string { return proto.CompactTextString(m) } func (*MsgGrantRewardResponse) ProtoMessage() {} func (*MsgGrantRewardResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{9} + return fileDescriptor_89da971360d3fc55, []int{9} } func (m *MsgGrantRewardResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -558,7 +558,7 @@ func (m *MsgWithdrawFunds) Reset() { *m = MsgWithdrawFunds{} } func (m *MsgWithdrawFunds) String() string { return proto.CompactTextString(m) } func (*MsgWithdrawFunds) ProtoMessage() {} func (*MsgWithdrawFunds) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{10} + return fileDescriptor_89da971360d3fc55, []int{10} } func (m *MsgWithdrawFunds) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -616,7 +616,7 @@ func (m *MsgWithdrawFundsResponse) Reset() { *m = MsgWithdrawFundsRespon func (m *MsgWithdrawFundsResponse) String() string { return proto.CompactTextString(m) } func (*MsgWithdrawFundsResponse) ProtoMessage() {} func (*MsgWithdrawFundsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{11} + return fileDescriptor_89da971360d3fc55, []int{11} } func (m *MsgWithdrawFundsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -658,7 +658,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{12} + return fileDescriptor_89da971360d3fc55, []int{12} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -710,7 +710,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0db1a5dd8b963fa8, []int{13} + return fileDescriptor_89da971360d3fc55, []int{13} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -740,73 +740,74 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgCreatePromoter)(nil), "sgenetwork.sge.reward.MsgCreatePromoter") - proto.RegisterType((*MsgCreatePromoterResponse)(nil), "sgenetwork.sge.reward.MsgCreatePromoterResponse") - proto.RegisterType((*MsgSetPromoterConf)(nil), "sgenetwork.sge.reward.MsgSetPromoterConf") - proto.RegisterType((*MsgSetPromoterConfResponse)(nil), "sgenetwork.sge.reward.MsgSetPromoterConfResponse") - proto.RegisterType((*MsgCreateCampaign)(nil), "sgenetwork.sge.reward.MsgCreateCampaign") - proto.RegisterType((*MsgCreateCampaignResponse)(nil), "sgenetwork.sge.reward.MsgCreateCampaignResponse") - proto.RegisterType((*MsgUpdateCampaign)(nil), "sgenetwork.sge.reward.MsgUpdateCampaign") - proto.RegisterType((*MsgUpdateCampaignResponse)(nil), "sgenetwork.sge.reward.MsgUpdateCampaignResponse") - proto.RegisterType((*MsgGrantReward)(nil), "sgenetwork.sge.reward.MsgGrantReward") - proto.RegisterType((*MsgGrantRewardResponse)(nil), "sgenetwork.sge.reward.MsgGrantRewardResponse") - proto.RegisterType((*MsgWithdrawFunds)(nil), "sgenetwork.sge.reward.MsgWithdrawFunds") - proto.RegisterType((*MsgWithdrawFundsResponse)(nil), "sgenetwork.sge.reward.MsgWithdrawFundsResponse") - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.reward.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.reward.MsgUpdateParamsResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/reward/tx.proto", fileDescriptor_0db1a5dd8b963fa8) } - -var fileDescriptor_0db1a5dd8b963fa8 = []byte{ - // 751 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0x4b, 0x4f, 0xdb, 0x4a, - 0x14, 0xce, 0x90, 0xab, 0x5c, 0x31, 0xe1, 0xf2, 0xb0, 0x78, 0x04, 0xdf, 0x4b, 0xe0, 0xa6, 0x6a, - 0x0b, 0x48, 0xb1, 0x09, 0xa8, 0xad, 0x94, 0x55, 0x9b, 0x48, 0xad, 0xba, 0x88, 0x84, 0x42, 0x51, - 0xa5, 0x6e, 0xd0, 0x10, 0x0f, 0x13, 0x0b, 0xec, 0x71, 0x67, 0xc6, 0x05, 0x76, 0xa8, 0x2b, 0x96, - 0xfd, 0x07, 0xdd, 0x76, 0x49, 0x25, 0xfa, 0x1f, 0x50, 0x57, 0x08, 0xa9, 0x52, 0xd5, 0x05, 0xaa, - 0x60, 0xc1, 0xbe, 0xbf, 0xa0, 0xf2, 0x13, 0xdb, 0x79, 0x16, 0xc1, 0x26, 0xf1, 0xcc, 0xf9, 0xce, - 0x7c, 0xdf, 0x37, 0xe3, 0x73, 0x3c, 0x30, 0xcf, 0x09, 0x36, 0xb1, 0xd8, 0xa5, 0x6c, 0x5b, 0xe5, - 0x04, 0xab, 0x0c, 0xef, 0x22, 0xa6, 0xa9, 0x62, 0x4f, 0xb1, 0x18, 0x15, 0x54, 0x9a, 0xb8, 0x8e, - 0x2b, 0x9c, 0x60, 0xc5, 0x8b, 0xcb, 0x63, 0xc8, 0xd0, 0x4d, 0xaa, 0xba, 0xbf, 0x1e, 0x52, 0x9e, - 0x6a, 0x50, 0x6e, 0x50, 0xae, 0x1a, 0x9c, 0xa8, 0xef, 0x4a, 0xce, 0x9f, 0x1f, 0x98, 0xf6, 0x02, - 0x1b, 0xee, 0x48, 0xf5, 0x06, 0x7e, 0x68, 0x9c, 0x50, 0x42, 0xbd, 0x79, 0xe7, 0xc9, 0x9f, 0x2d, - 0xb4, 0xd7, 0x64, 0x21, 0x86, 0x0c, 0x3f, 0xb3, 0x60, 0xc0, 0xb1, 0x1a, 0x27, 0x55, 0x86, 0x91, - 0xc0, 0xab, 0x8c, 0x1a, 0x54, 0x60, 0x26, 0x2d, 0xc3, 0xbf, 0x1b, 0xce, 0x0c, 0x65, 0x39, 0x30, - 0x07, 0xe6, 0x07, 0x2b, 0xb9, 0xb3, 0xe3, 0xe2, 0xb8, 0xcf, 0xf8, 0x4c, 0xd3, 0x18, 0xe6, 0x7c, - 0x4d, 0x30, 0xdd, 0x24, 0xf5, 0x00, 0x28, 0x4d, 0xc2, 0x8c, 0xd0, 0x1b, 0xdb, 0x58, 0xe4, 0x06, - 0x9c, 0x94, 0xba, 0x3f, 0x2a, 0x0f, 0xbd, 0xbf, 0x3a, 0x5a, 0x0c, 0x50, 0x85, 0x7f, 0xe1, 0x74, - 0x0b, 0x5d, 0x1d, 0x73, 0x8b, 0x9a, 0x1c, 0x17, 0x0e, 0x00, 0x94, 0x6a, 0x9c, 0xac, 0x61, 0x11, - 0x84, 0xaa, 0xd4, 0xdc, 0xba, 0x91, 0x9a, 0x51, 0x98, 0xb6, 0x75, 0xcd, 0x97, 0xe2, 0x3c, 0x46, - 0xf4, 0xa5, 0xbb, 0xe8, 0xfb, 0x0f, 0xca, 0xad, 0x0a, 0x42, 0x81, 0xdf, 0x40, 0x64, 0xb7, 0xaa, - 0xc8, 0xb0, 0x90, 0x4e, 0xcc, 0x5b, 0xd2, 0xf7, 0x0a, 0x66, 0x05, 0x15, 0x68, 0x67, 0x63, 0xcb, - 0x36, 0x35, 0xee, 0x89, 0xac, 0xac, 0x9c, 0x9c, 0xcf, 0xa6, 0x7e, 0x9c, 0xcf, 0x4e, 0x78, 0xab, - 0x71, 0x6d, 0x5b, 0xd1, 0xa9, 0x6a, 0x20, 0xd1, 0x54, 0x5e, 0x9a, 0xe2, 0xd7, 0xf9, 0xac, 0xb4, - 0x8f, 0x8c, 0x9d, 0x72, 0x21, 0x92, 0x59, 0xa8, 0x43, 0x77, 0xf4, 0xdc, 0x19, 0x44, 0x5c, 0xff, - 0xd5, 0xe7, 0xa9, 0x04, 0xb6, 0x92, 0xa6, 0xd7, 0x2d, 0xed, 0x8e, 0x4c, 0x5b, 0xb6, 0x75, 0x43, - 0xd3, 0x61, 0xa6, 0x6b, 0xda, 0xb2, 0xad, 0x3f, 0x37, 0x1d, 0xb7, 0x15, 0x9a, 0xfe, 0x08, 0xe0, - 0x70, 0x8d, 0x93, 0x17, 0x0c, 0x99, 0xa2, 0xee, 0x96, 0xcd, 0x2d, 0x39, 0xfe, 0x1f, 0x0e, 0x35, - 0x7c, 0xb2, 0x0d, 0x27, 0xe4, 0xbd, 0x8c, 0xd9, 0x60, 0x6e, 0x3d, 0xf6, 0xa6, 0x76, 0x93, 0x9f, - 0x83, 0x93, 0x71, 0x81, 0xa1, 0xf6, 0x2f, 0x00, 0x8e, 0xd6, 0x38, 0x79, 0xad, 0x8b, 0xa6, 0xc6, - 0xd0, 0xae, 0xb7, 0x27, 0x77, 0x5a, 0x44, 0xd2, 0x23, 0x98, 0x41, 0x06, 0xb5, 0x4d, 0x5f, 0x72, - 0x65, 0xa6, 0xeb, 0x11, 0xd6, 0x7d, 0x70, 0xc2, 0x91, 0x0c, 0x73, 0x49, 0xd9, 0xa1, 0xa7, 0x23, - 0x00, 0x47, 0xc2, 0xd3, 0x5a, 0x75, 0x1b, 0x98, 0xf4, 0x18, 0x0e, 0x22, 0x5b, 0x34, 0x29, 0xd3, - 0xc5, 0x7e, 0x4f, 0x53, 0xd7, 0x50, 0xe9, 0x29, 0xcc, 0x78, 0x2d, 0xd0, 0x75, 0x96, 0x5d, 0x9e, - 0x51, 0xda, 0xf6, 0x66, 0xc5, 0xa3, 0xa9, 0x0c, 0x3a, 0x5e, 0x3e, 0x5d, 0x1d, 0x2d, 0x82, 0xba, - 0x9f, 0x57, 0xbe, 0x77, 0x76, 0x5c, 0x1c, 0xe3, 0x04, 0x17, 0xfd, 0xac, 0xb9, 0x92, 0xf2, 0x44, - 0x29, 0x39, 0x66, 0xae, 0x69, 0x0a, 0x4b, 0x70, 0x2a, 0xa1, 0x38, 0x70, 0x53, 0x9e, 0x68, 0x9b, - 0xbf, 0xfc, 0x39, 0x03, 0xd3, 0x35, 0x4e, 0x24, 0x01, 0x47, 0x92, 0x3d, 0x70, 0xa1, 0x83, 0xc6, - 0xd6, 0x66, 0x25, 0x97, 0xfa, 0x86, 0x86, 0xbb, 0x9b, 0x3e, 0x1c, 0x00, 0xd2, 0x5b, 0x38, 0x9c, - 0xf8, 0x0c, 0xcc, 0x77, 0x5e, 0x29, 0x8e, 0x94, 0x97, 0xfa, 0x45, 0x76, 0xa0, 0x0c, 0xdb, 0x4a, - 0x4f, 0xca, 0x00, 0xd9, 0x9b, 0xb2, 0xa5, 0xa6, 0x03, 0xca, 0x44, 0x27, 0xeb, 0x42, 0x19, 0x47, - 0x76, 0xa3, 0xec, 0xd0, 0x46, 0x5c, 0x4a, 0x13, 0xfe, 0x13, 0xaf, 0xc5, 0x87, 0x9d, 0xd7, 0x89, - 0x01, 0x65, 0xb5, 0x4f, 0x60, 0x9c, 0xaf, 0x09, 0xb3, 0xd1, 0xbe, 0x75, 0xbf, 0xf3, 0x22, 0x11, - 0x98, 0x5c, 0xec, 0x0b, 0x16, 0x67, 0x3a, 0x00, 0x70, 0x28, 0x56, 0x92, 0x0f, 0x7a, 0xed, 0x90, - 0x87, 0x93, 0x95, 0xfe, 0x70, 0x21, 0x5b, 0xee, 0x6b, 0xbb, 0x82, 0x39, 0x1c, 0x00, 0x95, 0xea, - 0xc9, 0x45, 0x1e, 0x9c, 0x5e, 0xe4, 0xc1, 0xcf, 0x8b, 0x3c, 0xf8, 0x70, 0x99, 0x4f, 0x9d, 0x5e, - 0xe6, 0x53, 0xdf, 0x2f, 0xf3, 0xa9, 0x37, 0x0b, 0x44, 0x17, 0x4d, 0x7b, 0x53, 0x69, 0x50, 0x43, - 0x8d, 0xa4, 0xba, 0x37, 0xa1, 0xbd, 0xf0, 0x7e, 0xb6, 0x6f, 0x61, 0xbe, 0x99, 0x71, 0xef, 0x42, - 0x2b, 0xbf, 0x03, 0x00, 0x00, 0xff, 0xff, 0x6e, 0x63, 0xf7, 0xb4, 0xc5, 0x09, 0x00, 0x00, + proto.RegisterType((*MsgCreatePromoter)(nil), "sge.legacy.reward.v1beta.MsgCreatePromoter") + proto.RegisterType((*MsgCreatePromoterResponse)(nil), "sge.legacy.reward.v1beta.MsgCreatePromoterResponse") + proto.RegisterType((*MsgSetPromoterConf)(nil), "sge.legacy.reward.v1beta.MsgSetPromoterConf") + proto.RegisterType((*MsgSetPromoterConfResponse)(nil), "sge.legacy.reward.v1beta.MsgSetPromoterConfResponse") + proto.RegisterType((*MsgCreateCampaign)(nil), "sge.legacy.reward.v1beta.MsgCreateCampaign") + proto.RegisterType((*MsgCreateCampaignResponse)(nil), "sge.legacy.reward.v1beta.MsgCreateCampaignResponse") + proto.RegisterType((*MsgUpdateCampaign)(nil), "sge.legacy.reward.v1beta.MsgUpdateCampaign") + proto.RegisterType((*MsgUpdateCampaignResponse)(nil), "sge.legacy.reward.v1beta.MsgUpdateCampaignResponse") + proto.RegisterType((*MsgGrantReward)(nil), "sge.legacy.reward.v1beta.MsgGrantReward") + proto.RegisterType((*MsgGrantRewardResponse)(nil), "sge.legacy.reward.v1beta.MsgGrantRewardResponse") + proto.RegisterType((*MsgWithdrawFunds)(nil), "sge.legacy.reward.v1beta.MsgWithdrawFunds") + proto.RegisterType((*MsgWithdrawFundsResponse)(nil), "sge.legacy.reward.v1beta.MsgWithdrawFundsResponse") + proto.RegisterType((*MsgUpdateParams)(nil), "sge.legacy.reward.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.legacy.reward.v1beta.MsgUpdateParamsResponse") +} + +func init() { proto.RegisterFile("sge/legacy/reward/v1beta/tx.proto", fileDescriptor_89da971360d3fc55) } + +var fileDescriptor_89da971360d3fc55 = []byte{ + // 764 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0xcf, 0x4b, 0x1b, 0x4d, + 0x18, 0xce, 0x9a, 0x8f, 0x7c, 0x38, 0xf1, 0xf3, 0xc7, 0xe2, 0x8f, 0xb8, 0x5f, 0x1b, 0x35, 0xa5, + 0x60, 0x6d, 0xdd, 0x35, 0xb1, 0x3f, 0x20, 0xb7, 0x26, 0xd0, 0xd2, 0x42, 0x40, 0x62, 0xa5, 0xd0, + 0x8b, 0x8c, 0xd9, 0x71, 0xb2, 0xe8, 0xee, 0x2c, 0x33, 0x13, 0x63, 0x7a, 0x2a, 0x3d, 0x14, 0x8f, + 0xfd, 0x0f, 0x7a, 0xed, 0x51, 0xa8, 0xfd, 0x1f, 0xa4, 0x27, 0x11, 0x0a, 0xa5, 0x05, 0x29, 0x7a, + 0xf0, 0xde, 0xbf, 0xa0, 0xec, 0xce, 0xee, 0x9a, 0xdd, 0x98, 0xb8, 0x8a, 0x5e, 0x92, 0x99, 0x79, + 0x9f, 0x77, 0x9e, 0xe7, 0x99, 0xd9, 0xf7, 0xdd, 0x05, 0x33, 0x0c, 0x23, 0x6d, 0x13, 0x61, 0x58, + 0x6b, 0x69, 0x14, 0x35, 0x21, 0xd5, 0xb5, 0xad, 0xfc, 0x1a, 0xe2, 0x50, 0xe3, 0xdb, 0xaa, 0x4d, + 0x09, 0x27, 0x72, 0x86, 0x61, 0xa4, 0x0a, 0x88, 0x2a, 0x20, 0xaa, 0x80, 0x28, 0x23, 0xd0, 0x34, + 0x2c, 0xa2, 0xb9, 0xbf, 0x02, 0xac, 0x4c, 0xd4, 0x08, 0x33, 0x09, 0xd3, 0x4c, 0x86, 0xb5, 0xad, + 0xbc, 0xf3, 0xe7, 0x05, 0x26, 0x45, 0x60, 0xd5, 0x9d, 0x69, 0x62, 0xe2, 0x85, 0x46, 0x31, 0xc1, + 0x44, 0xac, 0x3b, 0x23, 0x6f, 0xf5, 0x6e, 0x57, 0x65, 0x36, 0xa4, 0xd0, 0xf4, 0x92, 0x73, 0x26, + 0x18, 0xa9, 0x30, 0x5c, 0xa6, 0x08, 0x72, 0xb4, 0x44, 0x89, 0x49, 0x38, 0xa2, 0x72, 0x01, 0xfc, + 0x5b, 0x73, 0x56, 0x08, 0xcd, 0x48, 0xd3, 0xd2, 0x6c, 0x7f, 0x29, 0x73, 0xb8, 0x37, 0x3f, 0xea, + 0x91, 0x3e, 0xd5, 0x75, 0x8a, 0x18, 0x5b, 0xe6, 0xd4, 0xb0, 0x70, 0xd5, 0x07, 0xca, 0xe3, 0x20, + 0xc5, 0x8d, 0xda, 0x06, 0xe2, 0x99, 0x3e, 0x27, 0xa5, 0xea, 0xcd, 0x8a, 0x03, 0xef, 0x4f, 0x77, + 0xe7, 0x7c, 0x54, 0xee, 0x7f, 0x30, 0xd9, 0x41, 0x57, 0x45, 0xcc, 0x26, 0x16, 0x43, 0xb9, 0x77, + 0x12, 0x90, 0x2b, 0x0c, 0x2f, 0x23, 0xee, 0x87, 0xca, 0xc4, 0x5a, 0xbf, 0x92, 0x9a, 0x61, 0x90, + 0x6c, 0x18, 0xba, 0x27, 0xc5, 0x19, 0xb6, 0xe9, 0x4b, 0xf6, 0xd0, 0x77, 0x0b, 0x28, 0x9d, 0x0a, + 0x02, 0x81, 0xdf, 0xa5, 0xb6, 0xd3, 0x2a, 0x43, 0xd3, 0x86, 0x06, 0xb6, 0xae, 0x49, 0xdf, 0x2b, + 0x90, 0xe6, 0x84, 0xc3, 0xcd, 0xd5, 0xf5, 0x86, 0xa5, 0x33, 0x21, 0xb2, 0xb4, 0xb8, 0x7f, 0x34, + 0x95, 0xf8, 0x79, 0x34, 0x35, 0x26, 0x76, 0x63, 0xfa, 0x86, 0x6a, 0x10, 0xcd, 0x84, 0xbc, 0xae, + 0xbe, 0xb0, 0xf8, 0x9f, 0xa3, 0x29, 0xb9, 0x05, 0xcd, 0xcd, 0x62, 0xae, 0x2d, 0x33, 0x57, 0x05, + 0xee, 0xec, 0x99, 0x33, 0x69, 0x73, 0xfd, 0x4f, 0xcc, 0x5b, 0xf1, 0x6d, 0x45, 0x4d, 0xaf, 0xd8, + 0xfa, 0x0d, 0x99, 0xb6, 0x1b, 0xf6, 0x15, 0x4d, 0x07, 0x99, 0xae, 0x69, 0xbb, 0x61, 0x5f, 0xde, + 0x74, 0xd8, 0x56, 0x60, 0xfa, 0x93, 0x04, 0x06, 0x2b, 0x0c, 0x3f, 0xa7, 0xd0, 0xe2, 0x55, 0xb7, + 0x7a, 0xae, 0xc9, 0xf1, 0x0c, 0x18, 0xa8, 0x79, 0x64, 0xab, 0x4e, 0x48, 0x3c, 0x8c, 0x69, 0x7f, + 0x6d, 0x25, 0xf4, 0xa4, 0xf6, 0x92, 0x9f, 0x01, 0xe3, 0x61, 0x81, 0x81, 0xf6, 0xaf, 0x12, 0x18, + 0xae, 0x30, 0xfc, 0xda, 0xe0, 0x75, 0x9d, 0xc2, 0xa6, 0x38, 0x93, 0x1b, 0x2d, 0x22, 0xf9, 0x11, + 0x48, 0x41, 0x93, 0x34, 0x2c, 0x4f, 0x72, 0xe9, 0x76, 0xcf, 0x2b, 0xac, 0x7a, 0xe0, 0x88, 0x23, + 0x05, 0x64, 0xa2, 0xb2, 0x03, 0x4f, 0x5f, 0x24, 0x30, 0x14, 0xdc, 0xd6, 0x92, 0xdb, 0xc0, 0xe4, + 0xc7, 0xa0, 0x1f, 0x36, 0x78, 0x9d, 0x50, 0x83, 0xb7, 0x2e, 0x34, 0x75, 0x06, 0x95, 0xcb, 0x20, + 0x25, 0x5a, 0xa0, 0xeb, 0x2c, 0x5d, 0x98, 0x56, 0xbb, 0x75, 0x68, 0x55, 0x30, 0x95, 0xfa, 0x1d, + 0x3b, 0x9f, 0x4f, 0x77, 0xe7, 0xa4, 0xaa, 0x97, 0x5a, 0xbc, 0x73, 0xb8, 0x37, 0x3f, 0xc2, 0x30, + 0x9a, 0xb7, 0x10, 0x6f, 0x12, 0xba, 0x31, 0x9d, 0x57, 0x9f, 0xa8, 0x79, 0xc7, 0xcf, 0x19, 0x53, + 0x6e, 0x01, 0x4c, 0x44, 0x44, 0xfb, 0x86, 0x8a, 0x63, 0xe7, 0xe6, 0x17, 0x7e, 0xa5, 0x40, 0xb2, + 0xc2, 0xb0, 0xfc, 0x16, 0x0c, 0x45, 0xdb, 0xe0, 0x83, 0xee, 0x32, 0x3b, 0x5b, 0x96, 0xf2, 0xf0, + 0x32, 0xe8, 0xe0, 0x98, 0x93, 0x3b, 0x7d, 0x92, 0xdc, 0x04, 0x83, 0x91, 0xf7, 0xc1, 0xfd, 0x9e, + 0x9b, 0x85, 0xc1, 0xca, 0xe2, 0x25, 0xc0, 0x5d, 0x88, 0x83, 0x2e, 0x13, 0x87, 0xd8, 0x07, 0xc7, + 0x22, 0xee, 0x28, 0x74, 0x9f, 0x38, 0xd2, 0xde, 0x7a, 0x13, 0x87, 0xc1, 0x17, 0x10, 0x77, 0xe9, + 0x30, 0x2e, 0x31, 0x07, 0xff, 0x85, 0xcb, 0x74, 0xae, 0xe7, 0x56, 0x21, 0xac, 0x52, 0x88, 0x8f, + 0x0d, 0xb3, 0x5a, 0x20, 0xdd, 0xde, 0xd8, 0x66, 0x7b, 0xee, 0xd3, 0x86, 0x54, 0x16, 0xe2, 0x22, + 0xc3, 0x7c, 0x1f, 0x24, 0x30, 0x10, 0xaa, 0xdc, 0x7b, 0x31, 0x0e, 0x4c, 0x40, 0x95, 0x7c, 0x6c, + 0x68, 0xc0, 0x99, 0xf9, 0x76, 0x5e, 0x69, 0xed, 0xf4, 0x49, 0xa5, 0x97, 0xfb, 0xc7, 0x59, 0xe9, + 0xe0, 0x38, 0x2b, 0xfd, 0x3e, 0xce, 0x4a, 0x1f, 0x4f, 0xb2, 0x89, 0x83, 0x93, 0x6c, 0xe2, 0xc7, + 0x49, 0x36, 0xf1, 0x66, 0x01, 0x1b, 0xbc, 0xde, 0x58, 0x53, 0x6b, 0xc4, 0xd4, 0xda, 0x52, 0x9d, + 0xb1, 0xb6, 0x1d, 0xf9, 0x8c, 0xe2, 0x2d, 0x1b, 0xb1, 0xb5, 0x94, 0xfb, 0xfd, 0xb4, 0xf8, 0x37, + 0x00, 0x00, 0xff, 0xff, 0x6d, 0xf5, 0x90, 0x9a, 0x02, 0x0a, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -849,7 +850,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { // Deprecated: Do not use. func (c *msgClient) SetPromoterConf(ctx context.Context, in *MsgSetPromoterConf, opts ...grpc.CallOption) (*MsgSetPromoterConfResponse, error) { out := new(MsgSetPromoterConfResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Msg/SetPromoterConf", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Msg/SetPromoterConf", in, out, opts...) if err != nil { return nil, err } @@ -859,7 +860,7 @@ func (c *msgClient) SetPromoterConf(ctx context.Context, in *MsgSetPromoterConf, // Deprecated: Do not use. func (c *msgClient) CreatePromoter(ctx context.Context, in *MsgCreatePromoter, opts ...grpc.CallOption) (*MsgCreatePromoterResponse, error) { out := new(MsgCreatePromoterResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Msg/CreatePromoter", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Msg/CreatePromoter", in, out, opts...) if err != nil { return nil, err } @@ -869,7 +870,7 @@ func (c *msgClient) CreatePromoter(ctx context.Context, in *MsgCreatePromoter, o // Deprecated: Do not use. func (c *msgClient) CreateCampaign(ctx context.Context, in *MsgCreateCampaign, opts ...grpc.CallOption) (*MsgCreateCampaignResponse, error) { out := new(MsgCreateCampaignResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Msg/CreateCampaign", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Msg/CreateCampaign", in, out, opts...) if err != nil { return nil, err } @@ -879,7 +880,7 @@ func (c *msgClient) CreateCampaign(ctx context.Context, in *MsgCreateCampaign, o // Deprecated: Do not use. func (c *msgClient) UpdateCampaign(ctx context.Context, in *MsgUpdateCampaign, opts ...grpc.CallOption) (*MsgUpdateCampaignResponse, error) { out := new(MsgUpdateCampaignResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Msg/UpdateCampaign", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Msg/UpdateCampaign", in, out, opts...) if err != nil { return nil, err } @@ -889,7 +890,7 @@ func (c *msgClient) UpdateCampaign(ctx context.Context, in *MsgUpdateCampaign, o // Deprecated: Do not use. func (c *msgClient) WithdrawFunds(ctx context.Context, in *MsgWithdrawFunds, opts ...grpc.CallOption) (*MsgWithdrawFundsResponse, error) { out := new(MsgWithdrawFundsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Msg/WithdrawFunds", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Msg/WithdrawFunds", in, out, opts...) if err != nil { return nil, err } @@ -899,7 +900,7 @@ func (c *msgClient) WithdrawFunds(ctx context.Context, in *MsgWithdrawFunds, opt // Deprecated: Do not use. func (c *msgClient) GrantReward(ctx context.Context, in *MsgGrantReward, opts ...grpc.CallOption) (*MsgGrantRewardResponse, error) { out := new(MsgGrantRewardResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Msg/GrantReward", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Msg/GrantReward", in, out, opts...) if err != nil { return nil, err } @@ -909,7 +910,7 @@ func (c *msgClient) GrantReward(ctx context.Context, in *MsgGrantReward, opts .. // Deprecated: Do not use. func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.reward.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.reward.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -975,7 +976,7 @@ func _Msg_SetPromoterConf_Handler(srv interface{}, ctx context.Context, dec func } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Msg/SetPromoterConf", + FullMethod: "/sge.legacy.reward.v1beta.Msg/SetPromoterConf", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).SetPromoterConf(ctx, req.(*MsgSetPromoterConf)) @@ -993,7 +994,7 @@ func _Msg_CreatePromoter_Handler(srv interface{}, ctx context.Context, dec func( } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Msg/CreatePromoter", + FullMethod: "/sge.legacy.reward.v1beta.Msg/CreatePromoter", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).CreatePromoter(ctx, req.(*MsgCreatePromoter)) @@ -1011,7 +1012,7 @@ func _Msg_CreateCampaign_Handler(srv interface{}, ctx context.Context, dec func( } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Msg/CreateCampaign", + FullMethod: "/sge.legacy.reward.v1beta.Msg/CreateCampaign", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).CreateCampaign(ctx, req.(*MsgCreateCampaign)) @@ -1029,7 +1030,7 @@ func _Msg_UpdateCampaign_Handler(srv interface{}, ctx context.Context, dec func( } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Msg/UpdateCampaign", + FullMethod: "/sge.legacy.reward.v1beta.Msg/UpdateCampaign", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateCampaign(ctx, req.(*MsgUpdateCampaign)) @@ -1047,7 +1048,7 @@ func _Msg_WithdrawFunds_Handler(srv interface{}, ctx context.Context, dec func(i } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Msg/WithdrawFunds", + FullMethod: "/sge.legacy.reward.v1beta.Msg/WithdrawFunds", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).WithdrawFunds(ctx, req.(*MsgWithdrawFunds)) @@ -1065,7 +1066,7 @@ func _Msg_GrantReward_Handler(srv interface{}, ctx context.Context, dec func(int } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Msg/GrantReward", + FullMethod: "/sge.legacy.reward.v1beta.Msg/GrantReward", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).GrantReward(ctx, req.(*MsgGrantReward)) @@ -1083,7 +1084,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.reward.Msg/UpdateParams", + FullMethod: "/sge.legacy.reward.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -1091,8 +1092,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.reward.Msg", + ServiceName: "sge.legacy.reward.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -1125,7 +1127,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/reward/tx.proto", + Metadata: "sge/legacy/reward/v1beta/tx.proto", } func (m *MsgCreatePromoter) Marshal() (dAtA []byte, err error) { diff --git a/x/subaccount/client/cli/query.go b/x/legacy/subaccount/client/cli/query.go similarity index 96% rename from x/subaccount/client/cli/query.go rename to x/legacy/subaccount/client/cli/query.go index ff7c36d3..2016cf5a 100644 --- a/x/subaccount/client/cli/query.go +++ b/x/legacy/subaccount/client/cli/query.go @@ -10,7 +10,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // GetQueryCmd returns the cli query commands for this module diff --git a/x/reward/client/cli/query_params.go b/x/legacy/subaccount/client/cli/query_params.go similarity index 92% rename from x/reward/client/cli/query_params.go rename to x/legacy/subaccount/client/cli/query_params.go index 2aa5f8d8..16240d3d 100644 --- a/x/reward/client/cli/query_params.go +++ b/x/legacy/subaccount/client/cli/query_params.go @@ -8,7 +8,7 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) func CmdQueryParams() *cobra.Command { diff --git a/x/subaccount/client/cli/tx.go b/x/legacy/subaccount/client/cli/tx.go similarity index 98% rename from x/subaccount/client/cli/tx.go rename to x/legacy/subaccount/client/cli/tx.go index dbecabd0..11e0d04a 100644 --- a/x/subaccount/client/cli/tx.go +++ b/x/legacy/subaccount/client/cli/tx.go @@ -15,8 +15,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - housetypes "github.com/sge-network/sge/x/house/types" - "github.com/sge-network/sge/x/subaccount/types" + housetypes "github.com/sge-network/sge/x/legacy/house/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // GetTxCmd returns the transaction commands for this module diff --git a/x/subaccount/genesis.go b/x/legacy/subaccount/genesis.go similarity index 88% rename from x/subaccount/genesis.go rename to x/legacy/subaccount/genesis.go index 067c5db8..cef1fd87 100644 --- a/x/subaccount/genesis.go +++ b/x/legacy/subaccount/genesis.go @@ -3,8 +3,8 @@ package subaccount import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/subaccount/keeper" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/keeper" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // InitGenesis initializes the module's state from a provided genesis diff --git a/x/subaccount/keeper/balance.go b/x/legacy/subaccount/keeper/balance.go similarity index 98% rename from x/subaccount/keeper/balance.go rename to x/legacy/subaccount/keeper/balance.go index 2d4c738a..8b3036c1 100644 --- a/x/subaccount/keeper/balance.go +++ b/x/legacy/subaccount/keeper/balance.go @@ -3,13 +3,13 @@ package keeper import ( sdkerrors "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" "github.com/sge-network/sge/app/params" "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // SetLockedBalances saves the locked balances of an account. diff --git a/x/subaccount/keeper/hooks.go b/x/legacy/subaccount/keeper/hooks.go similarity index 97% rename from x/subaccount/keeper/hooks.go rename to x/legacy/subaccount/keeper/hooks.go index 01f83e8a..b6870106 100644 --- a/x/subaccount/keeper/hooks.go +++ b/x/legacy/subaccount/keeper/hooks.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/app/params" - orderbooktypes "github.com/sge-network/sge/x/orderbook/types" + orderbooktypes "github.com/sge-network/sge/x/legacy/orderbook/types" ) // Hooks wrapper struct for slashing keeper diff --git a/x/subaccount/keeper/keeper.go b/x/legacy/subaccount/keeper/keeper.go similarity index 90% rename from x/subaccount/keeper/keeper.go rename to x/legacy/subaccount/keeper/keeper.go index c1b69ce2..6776a35e 100644 --- a/x/subaccount/keeper/keeper.go +++ b/x/legacy/subaccount/keeper/keeper.go @@ -1,12 +1,12 @@ package keeper import ( + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - bettypes "github.com/sge-network/sge/x/bet/types" - "github.com/sge-network/sge/x/subaccount/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) type Keeper struct { diff --git a/x/subaccount/keeper/msg_server.go b/x/legacy/subaccount/keeper/msg_server.go similarity index 84% rename from x/subaccount/keeper/msg_server.go rename to x/legacy/subaccount/keeper/msg_server.go index 5625c960..f3cbe596 100644 --- a/x/subaccount/keeper/msg_server.go +++ b/x/legacy/subaccount/keeper/msg_server.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) type msgServer struct { diff --git a/x/subaccount/keeper/msg_server_balance.go b/x/legacy/subaccount/keeper/msg_server_balance.go similarity index 95% rename from x/subaccount/keeper/msg_server_balance.go rename to x/legacy/subaccount/keeper/msg_server_balance.go index 5057d8d3..3afccf29 100644 --- a/x/subaccount/keeper/msg_server_balance.go +++ b/x/legacy/subaccount/keeper/msg_server_balance.go @@ -5,7 +5,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // TopUp increases the balance of sub account according to the input data. diff --git a/x/subaccount/keeper/msg_server_bet.go b/x/legacy/subaccount/keeper/msg_server_bet.go similarity index 91% rename from x/subaccount/keeper/msg_server_bet.go rename to x/legacy/subaccount/keeper/msg_server_bet.go index a5f2f449..2e8d946f 100644 --- a/x/subaccount/keeper/msg_server_bet.go +++ b/x/legacy/subaccount/keeper/msg_server_bet.go @@ -11,8 +11,8 @@ import ( sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" "github.com/sge-network/sge/app/params" - bettypes "github.com/sge-network/sge/x/bet/types" - "github.com/sge-network/sge/x/subaccount/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) func (k msgServer) Wager(goCtx context.Context, msg *types.MsgWager) (*types.MsgWagerResponse, error) { @@ -30,7 +30,7 @@ func (k msgServer) Wager(goCtx context.Context, msg *types.MsgWager) (*types.Msg } payload := &types.SubAccWagerTicketPayload{} - err := k.Keeper.ovmKeeper.VerifyTicketUnmarshal(sdk.WrapSDKContext(ctx), msg.Ticket, &payload) + err := k.Keeper.ovmKeeper.VerifyTicketUnmarshal(ctx, msg.Ticket, &payload) if err != nil { return nil, sdkerrors.Wrapf(types.ErrInTicketVerification, "%s", err) } diff --git a/x/subaccount/keeper/msg_server_house.go b/x/legacy/subaccount/keeper/msg_server_house.go similarity index 96% rename from x/subaccount/keeper/msg_server_house.go rename to x/legacy/subaccount/keeper/msg_server_house.go index c667d562..84d9f006 100644 --- a/x/subaccount/keeper/msg_server_house.go +++ b/x/legacy/subaccount/keeper/msg_server_house.go @@ -7,8 +7,8 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - housetypes "github.com/sge-network/sge/x/house/types" - "github.com/sge-network/sge/x/subaccount/types" + housetypes "github.com/sge-network/sge/x/legacy/house/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) func (k msgServer) HouseDeposit(goCtx context.Context, msg *types.MsgHouseDeposit) (*types.MsgHouseDepositResponse, error) { diff --git a/x/legacy/subaccount/keeper/msg_server_params.go b/x/legacy/subaccount/keeper/msg_server_params.go new file mode 100644 index 00000000..debaf7fc --- /dev/null +++ b/x/legacy/subaccount/keeper/msg_server_params.go @@ -0,0 +1,27 @@ +package keeper + +import ( + "context" + + sdkerrors "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + + "github.com/sge-network/sge/x/legacy/subaccount/types" +) + +func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { + ctx := sdk.UnwrapSDKContext(goCtx) + + if k.GetAuthority() != req.Authority { + return nil, sdkerrors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.GetAuthority(), req.Authority) + } + + if err := req.Params.Validate(); err != nil { + return nil, err + } + + k.SetParams(ctx, req.Params) + + return &types.MsgUpdateParamsResponse{}, nil +} diff --git a/x/subaccount/keeper/msg_server_subaccount.go b/x/legacy/subaccount/keeper/msg_server_subaccount.go similarity index 92% rename from x/subaccount/keeper/msg_server_subaccount.go rename to x/legacy/subaccount/keeper/msg_server_subaccount.go index 3c033651..7d7a471f 100644 --- a/x/subaccount/keeper/msg_server_subaccount.go +++ b/x/legacy/subaccount/keeper/msg_server_subaccount.go @@ -6,7 +6,7 @@ import ( sdkerrors "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // Create creates a subaccount according to the input message data. diff --git a/x/subaccount/keeper/params.go b/x/legacy/subaccount/keeper/params.go similarity index 92% rename from x/subaccount/keeper/params.go rename to x/legacy/subaccount/keeper/params.go index f1329519..41d39281 100644 --- a/x/subaccount/keeper/params.go +++ b/x/legacy/subaccount/keeper/params.go @@ -3,7 +3,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // SetParams set the params diff --git a/x/reward/keeper/query_params.go b/x/legacy/subaccount/keeper/query_params.go similarity index 89% rename from x/reward/keeper/query_params.go rename to x/legacy/subaccount/keeper/query_params.go index 00aacab5..aaf9fe8a 100644 --- a/x/reward/keeper/query_params.go +++ b/x/legacy/subaccount/keeper/query_params.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/x/reward/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) func (k Keeper) Params(goCtx context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { diff --git a/x/subaccount/keeper/query_server.go b/x/legacy/subaccount/keeper/query_server.go similarity index 96% rename from x/subaccount/keeper/query_server.go rename to x/legacy/subaccount/keeper/query_server.go index 4138545f..1acd596b 100644 --- a/x/subaccount/keeper/query_server.go +++ b/x/legacy/subaccount/keeper/query_server.go @@ -6,7 +6,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) func NewQueryServer(keeper Keeper) types.QueryServer { diff --git a/x/subaccount/keeper/subaccount.go b/x/legacy/subaccount/keeper/subaccount.go similarity index 96% rename from x/subaccount/keeper/subaccount.go rename to x/legacy/subaccount/keeper/subaccount.go index 0df03653..5c009d5b 100644 --- a/x/subaccount/keeper/subaccount.go +++ b/x/legacy/subaccount/keeper/subaccount.go @@ -3,11 +3,12 @@ package keeper import ( sdkerrors "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" + storetypes "cosmossdk.io/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cast" "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // Peek returns the next value without advancing the subaccount ID. @@ -64,7 +65,7 @@ func (k Keeper) IsSubaccount(ctx sdk.Context, subAccAddr sdk.AccAddress) bool { func (k Keeper) IterateSubaccounts(ctx sdk.Context, cb func(subAccountAddress, subaccountOwner sdk.AccAddress) (stop bool)) { store := ctx.KVStore(k.storeKey) - iterator := sdk.KVStorePrefixIterator(store, types.SubaccountOwnerReversePrefix) + iterator := storetypes.KVStorePrefixIterator(store, types.SubaccountOwnerReversePrefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { diff --git a/x/subaccount/module.go b/x/legacy/subaccount/module.go similarity index 89% rename from x/subaccount/module.go rename to x/legacy/subaccount/module.go index e53597a8..efac3a06 100644 --- a/x/subaccount/module.go +++ b/x/legacy/subaccount/module.go @@ -18,9 +18,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/subaccount/client/cli" - "github.com/sge-network/sge/x/subaccount/keeper" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/client/cli" + "github.com/sge-network/sge/x/legacy/subaccount/keeper" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) var ( @@ -100,13 +100,19 @@ type AppModule struct { } // NewAppModule creates new app module object -func NewAppModule(k keeper.Keeper) AppModule { - return AppModule{ +func NewAppModule(k keeper.Keeper) *AppModule { + return &AppModule{ AppModuleBasic: AppModuleBasic{}, keeper: k, } } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} + +// IsOnePerModuleType is a marker function just indicates that this is a one-per-module type. +func (am AppModule) IsOnePerModuleType() {} + // Name returns the module's name. func (am AppModule) Name() string { return am.AppModuleBasic.Name() } @@ -152,10 +158,10 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock executes all ABCI BeginBlock logic respective to the module. -func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} +func (AppModule) BeginBlock(_ sdk.Context) {} // EndBlock executes all ABCI EndBlock logic respective to the module. It // returns no validator updates. -func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { +func (am AppModule) EndBlock(_ sdk.Context) []abci.ValidatorUpdate { return []abci.ValidatorUpdate{} } diff --git a/x/subaccount/simulation/decoder.go b/x/legacy/subaccount/simulation/decoder.go similarity index 96% rename from x/subaccount/simulation/decoder.go rename to x/legacy/subaccount/simulation/decoder.go index d7cf0297..8739caf3 100644 --- a/x/subaccount/simulation/decoder.go +++ b/x/legacy/subaccount/simulation/decoder.go @@ -8,7 +8,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // NewDecodeStore returns a decoder function closure that unmarshal the KVPair's diff --git a/x/subaccount/simulation/errors.go b/x/legacy/subaccount/simulation/errors.go similarity index 100% rename from x/subaccount/simulation/errors.go rename to x/legacy/subaccount/simulation/errors.go diff --git a/x/subaccount/simulation/genesis.go b/x/legacy/subaccount/simulation/genesis.go similarity index 87% rename from x/subaccount/simulation/genesis.go rename to x/legacy/subaccount/simulation/genesis.go index ef92c0d1..6e8bd92a 100644 --- a/x/subaccount/simulation/genesis.go +++ b/x/legacy/subaccount/simulation/genesis.go @@ -12,7 +12,7 @@ import ( sdkmath "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // Simulation parameter constants @@ -35,13 +35,13 @@ func GenMinDeposit(r *rand.Rand) sdkmath.Int { func RandomizedGenState(simState *module.SimulationState) { var houseParticipationFee sdkmath.LegacyDec simState.AppParams.GetOrGenerate( - simState.Cdc, HouseParticipationFee, &houseParticipationFee, simState.Rand, + HouseParticipationFee, &houseParticipationFee, simState.Rand, func(r *rand.Rand) { houseParticipationFee = GenHouseParticipationFee(r) }, ) var minDeposit sdkmath.Int simState.AppParams.GetOrGenerate( - simState.Cdc, MinDeposit, &minDeposit, simState.Rand, + MinDeposit, &minDeposit, simState.Rand, func(r *rand.Rand) { minDeposit = GenMinDeposit(r) }, ) diff --git a/x/subaccount/simulation/proposals.go b/x/legacy/subaccount/simulation/proposals.go similarity index 95% rename from x/subaccount/simulation/proposals.go rename to x/legacy/subaccount/simulation/proposals.go index c6265cb2..2ee8e0f4 100644 --- a/x/subaccount/simulation/proposals.go +++ b/x/legacy/subaccount/simulation/proposals.go @@ -8,7 +8,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) // Simulation operation weights constants diff --git a/x/ovm/simulation/simap.go b/x/legacy/subaccount/simulation/simap.go similarity index 100% rename from x/ovm/simulation/simap.go rename to x/legacy/subaccount/simulation/simap.go diff --git a/x/subaccount/types/accsummary.go b/x/legacy/subaccount/types/accsummary.go similarity index 100% rename from x/subaccount/types/accsummary.go rename to x/legacy/subaccount/types/accsummary.go diff --git a/x/subaccount/types/address.go b/x/legacy/subaccount/types/address.go similarity index 100% rename from x/subaccount/types/address.go rename to x/legacy/subaccount/types/address.go diff --git a/x/subaccount/types/balance.pb.go b/x/legacy/subaccount/types/balance.pb.go similarity index 83% rename from x/subaccount/types/balance.pb.go rename to x/legacy/subaccount/types/balance.pb.go index 10a213e3..1abca942 100644 --- a/x/subaccount/types/balance.pb.go +++ b/x/legacy/subaccount/types/balance.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/subaccount/balance.proto +// source: sge/legacy/subaccount/v1beta/balance.proto package types @@ -53,7 +53,7 @@ func (x LockedBalanceStatus) String() string { } func (LockedBalanceStatus) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_90f20af016bfbfef, []int{0} + return fileDescriptor_f7183f94d19bb6da, []int{0} } // AccountSummary defines the balance of a subaccount. @@ -76,7 +76,7 @@ func (m *AccountSummary) Reset() { *m = AccountSummary{} } func (m *AccountSummary) String() string { return proto.CompactTextString(m) } func (*AccountSummary) ProtoMessage() {} func (*AccountSummary) Descriptor() ([]byte, []int) { - return fileDescriptor_90f20af016bfbfef, []int{0} + return fileDescriptor_f7183f94d19bb6da, []int{0} } func (m *AccountSummary) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -115,7 +115,7 @@ func (m *LockedBalance) Reset() { *m = LockedBalance{} } func (m *LockedBalance) String() string { return proto.CompactTextString(m) } func (*LockedBalance) ProtoMessage() {} func (*LockedBalance) Descriptor() ([]byte, []int) { - return fileDescriptor_90f20af016bfbfef, []int{1} + return fileDescriptor_f7183f94d19bb6da, []int{1} } func (m *LockedBalance) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -152,43 +152,44 @@ func (m *LockedBalance) GetUnlockTS() uint64 { } func init() { - proto.RegisterEnum("sgenetwork.sge.subaccount.LockedBalanceStatus", LockedBalanceStatus_name, LockedBalanceStatus_value) - proto.RegisterType((*AccountSummary)(nil), "sgenetwork.sge.subaccount.AccountSummary") - proto.RegisterType((*LockedBalance)(nil), "sgenetwork.sge.subaccount.LockedBalance") + proto.RegisterEnum("sge.legacy.subaccount.v1beta.LockedBalanceStatus", LockedBalanceStatus_name, LockedBalanceStatus_value) + proto.RegisterType((*AccountSummary)(nil), "sge.legacy.subaccount.v1beta.AccountSummary") + proto.RegisterType((*LockedBalance)(nil), "sge.legacy.subaccount.v1beta.LockedBalance") } func init() { - proto.RegisterFile("sgenetwork/sge/subaccount/balance.proto", fileDescriptor_90f20af016bfbfef) -} - -var fileDescriptor_90f20af016bfbfef = []byte{ - // 410 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x92, 0xcd, 0xca, 0xd3, 0x40, - 0x14, 0x86, 0x93, 0x5a, 0x8a, 0x9d, 0xfa, 0x13, 0x46, 0x05, 0x2b, 0x9a, 0xd4, 0x82, 0x28, 0x42, - 0x93, 0x85, 0x88, 0x3b, 0x31, 0x69, 0xa3, 0x2d, 0x96, 0x2a, 0x4d, 0xbb, 0x71, 0x13, 0x26, 0xc9, - 0x90, 0x86, 0x34, 0x99, 0x90, 0x99, 0x50, 0xbb, 0x12, 0xbc, 0x02, 0xaf, 0xc2, 0x6b, 0xe9, 0xb2, - 0x4b, 0x71, 0x11, 0x24, 0xdd, 0x79, 0x15, 0x92, 0x9f, 0x36, 0x15, 0x14, 0xfa, 0xed, 0x86, 0x33, - 0xcf, 0xfb, 0x70, 0x38, 0xbc, 0xe0, 0x29, 0x75, 0x71, 0x88, 0xd9, 0x86, 0xc4, 0xbe, 0x42, 0x5d, - 0xac, 0xd0, 0xc4, 0x42, 0xb6, 0x4d, 0x92, 0x90, 0x29, 0x16, 0x5a, 0xa3, 0xd0, 0xc6, 0x72, 0x14, - 0x13, 0x46, 0x60, 0xb7, 0x06, 0x65, 0xea, 0x62, 0xb9, 0x06, 0x1f, 0xdc, 0x75, 0x89, 0x4b, 0x0a, - 0x4a, 0xc9, 0x5f, 0x65, 0xa0, 0xff, 0xbd, 0x01, 0x6e, 0xa9, 0x25, 0x61, 0x24, 0x41, 0x80, 0xe2, - 0x2d, 0x1c, 0x03, 0xc1, 0xc1, 0x11, 0xa1, 0x1e, 0xc3, 0x8e, 0x89, 0x82, 0xfc, 0xeb, 0x3e, 0xdf, - 0xe3, 0x9f, 0xb5, 0xb5, 0x47, 0xbb, 0x54, 0xe2, 0x7e, 0xa6, 0xd2, 0x3d, 0x9b, 0xd0, 0x80, 0x50, - 0xea, 0xf8, 0xb2, 0x47, 0x94, 0x00, 0xb1, 0x95, 0x3c, 0x09, 0xd9, 0xfc, 0xf6, 0x29, 0xa6, 0x16, - 0x29, 0xf8, 0x06, 0xdc, 0xa0, 0x11, 0x0e, 0xd9, 0xd1, 0xd2, 0xb8, 0xc4, 0xd2, 0x29, 0x22, 0x95, - 0x61, 0x0c, 0x84, 0x8d, 0xc7, 0x56, 0x4e, 0x8c, 0x36, 0xe1, 0xd1, 0x72, 0xed, 0xa2, 0x5d, 0x4e, - 0xb1, 0xca, 0xf4, 0x1a, 0x74, 0xd6, 0x84, 0x9e, 0x56, 0x69, 0x5e, 0x22, 0x01, 0x79, 0xa2, 0xcc, - 0xf7, 0xbf, 0x80, 0x9b, 0x53, 0x62, 0xfb, 0xd8, 0xd1, 0xca, 0x83, 0xc3, 0x57, 0xa0, 0x9d, 0x84, - 0x6b, 0x62, 0xfb, 0x26, 0xa3, 0xc5, 0x7d, 0x9a, 0x5a, 0x37, 0x4b, 0xa5, 0xeb, 0xcb, 0x62, 0xb8, - 0x30, 0x7e, 0xa7, 0x52, 0x0d, 0xcc, 0xeb, 0x27, 0x7c, 0x09, 0x5a, 0x57, 0xb9, 0x47, 0x05, 0x3f, - 0xff, 0xca, 0x83, 0x3b, 0x7f, 0x6d, 0x60, 0x30, 0xc4, 0x12, 0x0a, 0x9f, 0x80, 0xc7, 0xd3, 0x0f, - 0xc3, 0xf7, 0xfa, 0xc8, 0xd4, 0xd4, 0xa9, 0x3a, 0x1b, 0xea, 0xa6, 0xb1, 0x50, 0x17, 0x4b, 0xc3, - 0x5c, 0xce, 0x8c, 0x8f, 0xfa, 0x70, 0xf2, 0x76, 0xa2, 0x8f, 0x04, 0x0e, 0xf6, 0xc0, 0xc3, 0x7f, - 0x63, 0xe5, 0x54, 0xe0, 0x61, 0x1f, 0x88, 0xff, 0x13, 0x55, 0x4c, 0x43, 0x7b, 0xb7, 0xcb, 0x44, - 0x7e, 0x9f, 0x89, 0xfc, 0xaf, 0x4c, 0xe4, 0xbf, 0x1d, 0x44, 0x6e, 0x7f, 0x10, 0xb9, 0x1f, 0x07, - 0x91, 0xfb, 0x34, 0x70, 0x3d, 0xb6, 0x4a, 0x2c, 0xd9, 0x26, 0x41, 0x5e, 0xd1, 0xc1, 0x79, 0x5d, - 0x3f, 0x9f, 0x17, 0x96, 0x6d, 0x23, 0x4c, 0xad, 0x56, 0x51, 0xbf, 0x17, 0x7f, 0x02, 0x00, 0x00, - 0xff, 0xff, 0x56, 0x5e, 0x83, 0x83, 0xda, 0x02, 0x00, 0x00, + proto.RegisterFile("sge/legacy/subaccount/v1beta/balance.proto", fileDescriptor_f7183f94d19bb6da) +} + +var fileDescriptor_f7183f94d19bb6da = []byte{ + // 422 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x92, 0x4d, 0x8b, 0xd3, 0x40, + 0x18, 0xc7, 0x93, 0xba, 0x2c, 0xee, 0xac, 0x2f, 0x61, 0x54, 0x50, 0x59, 0x93, 0xb5, 0x20, 0xc8, + 0x82, 0x19, 0x44, 0xc5, 0x9b, 0x98, 0x74, 0x23, 0x2d, 0x96, 0x2a, 0x4d, 0x7b, 0xf1, 0x12, 0x26, + 0x93, 0x21, 0x0d, 0x79, 0x99, 0x90, 0x99, 0x58, 0x7b, 0x12, 0xfc, 0x04, 0x7e, 0x0a, 0x3f, 0x4b, + 0x8f, 0x3d, 0x8a, 0x87, 0x20, 0xe9, 0xcd, 0x4f, 0x21, 0x79, 0x69, 0x8b, 0x50, 0xa1, 0x7b, 0x7b, + 0x98, 0xf9, 0xfd, 0x7f, 0x3c, 0xfc, 0x79, 0xc0, 0x05, 0xf7, 0x29, 0x8a, 0xa8, 0x8f, 0xc9, 0x02, + 0xf1, 0xdc, 0xc5, 0x84, 0xb0, 0x3c, 0x11, 0xe8, 0xf3, 0x73, 0x97, 0x0a, 0x8c, 0x5c, 0x1c, 0xe1, + 0x84, 0x50, 0x3d, 0xcd, 0x98, 0x60, 0xf0, 0x8c, 0xfb, 0x54, 0x6f, 0x58, 0x7d, 0xc7, 0xea, 0x0d, + 0xfb, 0xf0, 0xae, 0xcf, 0x7c, 0x56, 0x83, 0xa8, 0x9a, 0x9a, 0x4c, 0xf7, 0x47, 0x07, 0xdc, 0x32, + 0x1a, 0xd0, 0xce, 0xe3, 0x18, 0x67, 0x0b, 0xd8, 0x07, 0x8a, 0x47, 0x53, 0xc6, 0x03, 0x41, 0x3d, + 0x07, 0xc7, 0xd5, 0xd7, 0x7d, 0xf9, 0x5c, 0x7e, 0x7a, 0x62, 0x3e, 0x5a, 0x16, 0x9a, 0xf4, 0xab, + 0xd0, 0xee, 0x11, 0xc6, 0x63, 0xc6, 0xb9, 0x17, 0xea, 0x01, 0x43, 0x31, 0x16, 0x33, 0x7d, 0x90, + 0x88, 0xf1, 0xed, 0x6d, 0xcc, 0xa8, 0x53, 0xf0, 0x2d, 0xb8, 0xc1, 0x53, 0x9a, 0x88, 0x8d, 0xa5, + 0x73, 0x88, 0xe5, 0xb4, 0x8e, 0xb4, 0x86, 0x3e, 0x50, 0xe6, 0x81, 0x98, 0x79, 0x19, 0x9e, 0x27, + 0x1b, 0xcb, 0xb5, 0x83, 0x76, 0xd9, 0xc6, 0x5a, 0xd3, 0x1b, 0x70, 0x1a, 0x31, 0xbe, 0x5d, 0xe5, + 0xe8, 0x10, 0x09, 0xa8, 0x12, 0x4d, 0xbe, 0xfb, 0x15, 0xdc, 0x1c, 0x32, 0x12, 0x52, 0xcf, 0x6c, + 0x3a, 0x87, 0xaf, 0xc1, 0x49, 0x9e, 0x44, 0x8c, 0x84, 0x8e, 0xe0, 0x75, 0x3f, 0x47, 0xe6, 0x83, + 0xb2, 0xd0, 0xae, 0x4f, 0xeb, 0xc7, 0x89, 0xfd, 0xa7, 0xd0, 0x76, 0xc0, 0x78, 0x37, 0xc2, 0x57, + 0xe0, 0xf8, 0x2a, 0x7d, 0xb4, 0xf0, 0xc5, 0x37, 0x19, 0xdc, 0xf9, 0x67, 0x03, 0x5b, 0x60, 0x91, + 0x73, 0xf8, 0x04, 0x3c, 0x1e, 0x7e, 0xe8, 0xbd, 0xb7, 0x2e, 0x1d, 0xd3, 0x18, 0x1a, 0xa3, 0x9e, + 0xe5, 0xd8, 0x13, 0x63, 0x32, 0xb5, 0x9d, 0xe9, 0xc8, 0xfe, 0x68, 0xf5, 0x06, 0xef, 0x06, 0xd6, + 0xa5, 0x22, 0xc1, 0x73, 0x70, 0xb6, 0x1f, 0x6b, 0x5e, 0x15, 0x19, 0x76, 0x81, 0xfa, 0x3f, 0x51, + 0xcb, 0x74, 0xcc, 0xd1, 0xb2, 0x54, 0xe5, 0x55, 0xa9, 0xca, 0xbf, 0x4b, 0x55, 0xfe, 0xbe, 0x56, + 0xa5, 0xd5, 0x5a, 0x95, 0x7e, 0xae, 0x55, 0xe9, 0xd3, 0x4b, 0x3f, 0x10, 0xb3, 0xdc, 0xd5, 0x09, + 0x8b, 0x11, 0xf7, 0xe9, 0xb3, 0x84, 0x8a, 0x39, 0xcb, 0xc2, 0x6a, 0x46, 0x5f, 0xf6, 0x5c, 0xb0, + 0x58, 0xa4, 0x94, 0xbb, 0xc7, 0xf5, 0x15, 0xbe, 0xf8, 0x1b, 0x00, 0x00, 0xff, 0xff, 0xf1, 0xd7, + 0xf1, 0x93, 0xe7, 0x02, 0x00, 0x00, } func (m *AccountSummary) Marshal() (dAtA []byte, err error) { diff --git a/x/subaccount/types/balance_test.go b/x/legacy/subaccount/types/balance_test.go similarity index 94% rename from x/subaccount/types/balance_test.go rename to x/legacy/subaccount/types/balance_test.go index 3cb0101d..425dc738 100644 --- a/x/subaccount/types/balance_test.go +++ b/x/legacy/subaccount/types/balance_test.go @@ -9,7 +9,7 @@ import ( sdkmath "cosmossdk.io/math" - "github.com/sge-network/sge/x/subaccount/types" + "github.com/sge-network/sge/x/legacy/subaccount/types" ) func TestLockedBalanceValidate(t *testing.T) { diff --git a/x/subaccount/types/codec.go b/x/legacy/subaccount/types/codec.go similarity index 100% rename from x/subaccount/types/codec.go rename to x/legacy/subaccount/types/codec.go diff --git a/x/subaccount/types/errors.go b/x/legacy/subaccount/types/errors.go similarity index 100% rename from x/subaccount/types/errors.go rename to x/legacy/subaccount/types/errors.go diff --git a/x/subaccount/types/events.go b/x/legacy/subaccount/types/events.go similarity index 100% rename from x/subaccount/types/events.go rename to x/legacy/subaccount/types/events.go diff --git a/x/subaccount/types/expected_keepers.go b/x/legacy/subaccount/types/expected_keepers.go similarity index 79% rename from x/subaccount/types/expected_keepers.go rename to x/legacy/subaccount/types/expected_keepers.go index c9492706..a430798c 100644 --- a/x/subaccount/types/expected_keepers.go +++ b/x/legacy/subaccount/types/expected_keepers.go @@ -5,10 +5,9 @@ import ( sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - bettypes "github.com/sge-network/sge/x/bet/types" - housetypes "github.com/sge-network/sge/x/house/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" + housetypes "github.com/sge-network/sge/x/legacy/house/types" ) // BetKeeper defines the expected interface needed to retrieve or set bets. @@ -19,14 +18,14 @@ type BetKeeper interface { // AccountKeeper defines the expected account keeper used for simulations (noalias) type AccountKeeper interface { - NewAccountWithAddress(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI - SetAccount(ctx sdk.Context, acc authtypes.AccountI) + NewAccountWithAddress(ctx context.Context, addr sdk.AccAddress) sdk.AccountI + SetAccount(ctx context.Context, acc sdk.AccountI) } // BankKeeper defines the expected interface needed to retrieve account balances. type BankKeeper interface { - SendCoins(ctx sdk.Context, fromAddr, toAddr sdk.AccAddress, amt sdk.Coins) error - GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin + SendCoins(ctx context.Context, fromAddr, toAddr sdk.AccAddress, amt sdk.Coins) error + GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin } // HouseKeeper defines the expected interface needed to deposit or withdraw. diff --git a/x/subaccount/types/genesis.go b/x/legacy/subaccount/types/genesis.go similarity index 100% rename from x/subaccount/types/genesis.go rename to x/legacy/subaccount/types/genesis.go diff --git a/x/subaccount/types/genesis.pb.go b/x/legacy/subaccount/types/genesis.pb.go similarity index 85% rename from x/subaccount/types/genesis.pb.go rename to x/legacy/subaccount/types/genesis.pb.go index 76a9ef6a..39ed185c 100644 --- a/x/subaccount/types/genesis.pb.go +++ b/x/legacy/subaccount/types/genesis.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/subaccount/genesis.proto +// source: sge/legacy/subaccount/v1beta/genesis.proto package types @@ -37,7 +37,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_4e56b8808b8d551c, []int{0} + return fileDescriptor_7267e0a27eb93584, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -104,7 +104,7 @@ func (m *GenesisSubaccount) Reset() { *m = GenesisSubaccount{} } func (m *GenesisSubaccount) String() string { return proto.CompactTextString(m) } func (*GenesisSubaccount) ProtoMessage() {} func (*GenesisSubaccount) Descriptor() ([]byte, []int) { - return fileDescriptor_4e56b8808b8d551c, []int{1} + return fileDescriptor_7267e0a27eb93584, []int{1} } func (m *GenesisSubaccount) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -162,41 +162,42 @@ func (m *GenesisSubaccount) GetLockedBalances() []LockedBalance { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.subaccount.GenesisState") - proto.RegisterType((*GenesisSubaccount)(nil), "sgenetwork.sge.subaccount.GenesisSubaccount") + proto.RegisterType((*GenesisState)(nil), "sge.legacy.subaccount.v1beta.GenesisState") + proto.RegisterType((*GenesisSubaccount)(nil), "sge.legacy.subaccount.v1beta.GenesisSubaccount") } func init() { - proto.RegisterFile("sgenetwork/sge/subaccount/genesis.proto", fileDescriptor_4e56b8808b8d551c) -} - -var fileDescriptor_4e56b8808b8d551c = []byte{ - // 391 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0xc1, 0x6a, 0xea, 0x40, - 0x14, 0x86, 0x13, 0xf5, 0x2a, 0x77, 0xf4, 0xde, 0xcb, 0x1d, 0x5c, 0x44, 0x17, 0xa9, 0xb5, 0xd0, - 0xa6, 0x50, 0x13, 0xb0, 0x0f, 0x50, 0xcc, 0x46, 0x84, 0x2e, 0x8a, 0x16, 0x0a, 0xdd, 0xc8, 0x24, - 0x19, 0xd2, 0xa0, 0xc9, 0x48, 0x66, 0x82, 0xf5, 0x2d, 0xba, 0xef, 0x6b, 0xf4, 0x21, 0xa4, 0x2b, - 0xe9, 0xaa, 0xab, 0x52, 0xf4, 0x45, 0x8a, 0x33, 0x93, 0x26, 0x50, 0xcc, 0x2a, 0x99, 0x73, 0xbe, - 0xff, 0x9c, 0xff, 0x1c, 0x0e, 0x38, 0xa3, 0x3e, 0x8e, 0x30, 0x5b, 0x92, 0x78, 0x66, 0x51, 0x1f, - 0x5b, 0x34, 0x71, 0x90, 0xeb, 0x92, 0x24, 0x62, 0xd6, 0x3e, 0x41, 0x03, 0x6a, 0x2e, 0x62, 0xc2, - 0x08, 0x6c, 0x65, 0xa0, 0x49, 0x7d, 0x6c, 0x66, 0x60, 0xbb, 0xe9, 0x13, 0x9f, 0x70, 0xca, 0xda, - 0xff, 0x09, 0x41, 0xbb, 0xe5, 0x12, 0x1a, 0x12, 0x3a, 0x15, 0x09, 0xf1, 0x90, 0xa9, 0xd3, 0xc3, - 0x4d, 0x17, 0x28, 0x46, 0x61, 0xca, 0x15, 0x98, 0x73, 0xd0, 0x1c, 0x45, 0x2e, 0x16, 0x60, 0xf7, - 0x55, 0x05, 0x8d, 0xa1, 0xb0, 0x3b, 0x61, 0x88, 0x61, 0x78, 0x05, 0xaa, 0xa2, 0x92, 0xa6, 0x76, - 0x54, 0xa3, 0xde, 0x3f, 0x36, 0x0f, 0xda, 0x37, 0x6f, 0x38, 0x68, 0x57, 0xd6, 0x1f, 0x47, 0xca, - 0x58, 0xca, 0xe0, 0x09, 0xf8, 0x93, 0x21, 0xd3, 0xc0, 0xd3, 0x4a, 0x1d, 0xd5, 0xa8, 0x8c, 0x1b, - 0x59, 0x70, 0xe4, 0xc1, 0x5b, 0x50, 0xcf, 0xde, 0x54, 0x2b, 0x77, 0xca, 0x46, 0xbd, 0x7f, 0x51, - 0xd0, 0x2a, 0xf5, 0xf8, 0x1d, 0x91, 0x5d, 0xf3, 0x65, 0xba, 0xcf, 0x25, 0xf0, 0xff, 0x07, 0x08, - 0xfb, 0xa0, 0x86, 0x3c, 0x2f, 0xc6, 0x54, 0x8c, 0xf4, 0xdb, 0xd6, 0xde, 0x5e, 0x7a, 0x4d, 0xb9, - 0xd6, 0x81, 0xc8, 0x4c, 0x58, 0x1c, 0x44, 0xfe, 0x38, 0x05, 0xa1, 0x09, 0x7e, 0x91, 0x65, 0x84, - 0x63, 0x6e, 0xbe, 0x48, 0x21, 0x30, 0x38, 0x02, 0x35, 0xb9, 0x57, 0xad, 0xcc, 0xd7, 0x76, 0x5e, - 0x30, 0xcb, 0x40, 0x7c, 0x27, 0x49, 0x18, 0xa2, 0x78, 0x25, 0x07, 0x49, 0xf5, 0xf0, 0x0e, 0xfc, - 0x9b, 0x13, 0x77, 0x86, 0xbd, 0xa9, 0x8c, 0x50, 0xad, 0xc2, 0xd7, 0x63, 0x14, 0x94, 0xbc, 0xe6, - 0x0a, 0x5b, 0x08, 0x64, 0xc5, 0xbf, 0xf3, 0x7c, 0x90, 0xda, 0xc3, 0xf5, 0x56, 0x57, 0x37, 0x5b, - 0x5d, 0xfd, 0xdc, 0xea, 0xea, 0xd3, 0x4e, 0x57, 0x36, 0x3b, 0x5d, 0x79, 0xdf, 0xe9, 0xca, 0x7d, - 0xcf, 0x0f, 0xd8, 0x43, 0xe2, 0x98, 0x2e, 0x09, 0xf7, 0xd7, 0xd2, 0xcb, 0x5f, 0xce, 0x63, 0xfe, - 0x76, 0xd8, 0x6a, 0x81, 0xa9, 0x53, 0xe5, 0xa7, 0x73, 0xf9, 0x15, 0x00, 0x00, 0xff, 0xff, 0xdf, - 0x5a, 0xa9, 0x97, 0x02, 0x03, 0x00, 0x00, + proto.RegisterFile("sge/legacy/subaccount/v1beta/genesis.proto", fileDescriptor_7267e0a27eb93584) +} + +var fileDescriptor_7267e0a27eb93584 = []byte{ + // 401 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0xcf, 0x6e, 0xda, 0x30, + 0x1c, 0xc7, 0x13, 0x60, 0xa0, 0x19, 0xb6, 0x69, 0x16, 0x87, 0x0c, 0x4d, 0x19, 0x62, 0x3b, 0xb0, + 0xad, 0xd8, 0x2a, 0xed, 0x0b, 0x90, 0x4b, 0x55, 0x09, 0x55, 0x15, 0x1c, 0x2a, 0x71, 0x41, 0x4e, + 0x62, 0xb9, 0x11, 0x49, 0x8c, 0x62, 0xa7, 0x94, 0xb7, 0xe8, 0x2b, 0xf4, 0x1d, 0xfa, 0x10, 0x1c, + 0x51, 0x4f, 0x3d, 0x55, 0x15, 0xbc, 0x48, 0x45, 0x6c, 0x1a, 0xa4, 0x56, 0xb9, 0xf9, 0xf7, 0xf5, + 0xe7, 0xfb, 0xfb, 0x67, 0x83, 0x7f, 0x82, 0x51, 0x1c, 0x52, 0x46, 0xbc, 0x25, 0x16, 0xa9, 0x4b, + 0x3c, 0x8f, 0xa7, 0xb1, 0xc4, 0x37, 0xc7, 0x2e, 0x95, 0x04, 0x33, 0x1a, 0x53, 0x11, 0x08, 0x34, + 0x4f, 0xb8, 0xe4, 0xf0, 0xa7, 0x60, 0x14, 0x29, 0x16, 0xe5, 0x2c, 0x52, 0x6c, 0xeb, 0x87, 0xc7, + 0x45, 0xc4, 0xc5, 0x34, 0x63, 0xb1, 0x0a, 0x94, 0xb1, 0xd5, 0x64, 0x9c, 0x71, 0xa5, 0xef, 0x4e, + 0x5a, 0x2d, 0x2e, 0xed, 0x92, 0x90, 0xc4, 0x1e, 0xd5, 0xec, 0xdf, 0x42, 0x76, 0x4e, 0x12, 0x12, + 0xe9, 0x62, 0x9d, 0xb5, 0x09, 0x1a, 0x67, 0xaa, 0xef, 0xb1, 0x24, 0x92, 0x42, 0x07, 0x54, 0x15, + 0x60, 0x99, 0x6d, 0xb3, 0x5b, 0xef, 0xff, 0x41, 0x45, 0x73, 0xa0, 0xcb, 0x8c, 0x75, 0x2a, 0xab, + 0xe7, 0x5f, 0xc6, 0x48, 0x3b, 0xe1, 0x6f, 0xf0, 0x25, 0x27, 0xa7, 0x81, 0x6f, 0x95, 0xda, 0x66, + 0xb7, 0x32, 0x6a, 0xe4, 0xe2, 0xb9, 0x0f, 0xaf, 0x40, 0x3d, 0x8f, 0x85, 0x55, 0x6e, 0x97, 0xbb, + 0xf5, 0x3e, 0x2e, 0xae, 0xb6, 0xef, 0xf4, 0xed, 0x42, 0x17, 0x3e, 0xcc, 0xd4, 0xb9, 0x2f, 0x81, + 0xef, 0xef, 0x40, 0xd8, 0x07, 0x35, 0xe2, 0xfb, 0x09, 0x15, 0x6a, 0xb0, 0xcf, 0x8e, 0xf5, 0xf8, + 0xd0, 0x6b, 0xea, 0xc5, 0x0f, 0xd4, 0xcd, 0x58, 0x26, 0x41, 0xcc, 0x46, 0x7b, 0x10, 0x22, 0xf0, + 0x89, 0x2f, 0x62, 0x9a, 0x64, 0xfd, 0x17, 0x39, 0x14, 0x06, 0x87, 0xa0, 0xa6, 0x1f, 0xc2, 0x2a, + 0x67, 0xcb, 0x3b, 0x2a, 0x1e, 0x67, 0xa0, 0xc2, 0x71, 0x1a, 0x45, 0x24, 0x59, 0xea, 0x59, 0xf6, + 0x29, 0xe0, 0x04, 0x7c, 0x0b, 0xb9, 0x37, 0xa3, 0xfe, 0x54, 0x2b, 0xc2, 0xaa, 0x64, 0x4b, 0xfa, + 0x5f, 0x9c, 0x75, 0x98, 0x99, 0x1c, 0xe5, 0xd1, 0x49, 0xbf, 0x86, 0x87, 0xa2, 0x70, 0x2e, 0x56, + 0x1b, 0xdb, 0x5c, 0x6f, 0x6c, 0xf3, 0x65, 0x63, 0x9b, 0x77, 0x5b, 0xdb, 0x58, 0x6f, 0x6d, 0xe3, + 0x69, 0x6b, 0x1b, 0x93, 0x53, 0x16, 0xc8, 0xeb, 0xd4, 0x45, 0x1e, 0x8f, 0xb0, 0x60, 0xb4, 0x17, + 0x53, 0xb9, 0xe0, 0xc9, 0x6c, 0x77, 0xc6, 0xb7, 0x1f, 0x7c, 0x2a, 0xb9, 0x9c, 0x53, 0xe1, 0x56, + 0xb3, 0xdf, 0x74, 0xf2, 0x1a, 0x00, 0x00, 0xff, 0xff, 0x28, 0x4d, 0x07, 0xcc, 0x21, 0x03, 0x00, + 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/subaccount/types/keys.go b/x/legacy/subaccount/types/keys.go similarity index 100% rename from x/subaccount/types/keys.go rename to x/legacy/subaccount/types/keys.go diff --git a/x/subaccount/types/messages_balance.go b/x/legacy/subaccount/types/messages_balance.go similarity index 100% rename from x/subaccount/types/messages_balance.go rename to x/legacy/subaccount/types/messages_balance.go diff --git a/x/subaccount/types/messages_bet.go b/x/legacy/subaccount/types/messages_bet.go similarity index 96% rename from x/subaccount/types/messages_bet.go rename to x/legacy/subaccount/types/messages_bet.go index 3a767c72..9fc179b8 100644 --- a/x/subaccount/types/messages_bet.go +++ b/x/legacy/subaccount/types/messages_bet.go @@ -5,7 +5,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/errors" "github.com/sge-network/sge/utils" - bettypes "github.com/sge-network/sge/x/bet/types" + bettypes "github.com/sge-network/sge/x/legacy/bet/types" ) const ( diff --git a/x/subaccount/types/messages_house.go b/x/legacy/subaccount/types/messages_house.go similarity index 100% rename from x/subaccount/types/messages_house.go rename to x/legacy/subaccount/types/messages_house.go diff --git a/x/subaccount/types/messages_params.go b/x/legacy/subaccount/types/messages_params.go similarity index 100% rename from x/subaccount/types/messages_params.go rename to x/legacy/subaccount/types/messages_params.go diff --git a/x/subaccount/types/messages_subaccount.go b/x/legacy/subaccount/types/messages_subaccount.go similarity index 100% rename from x/subaccount/types/messages_subaccount.go rename to x/legacy/subaccount/types/messages_subaccount.go diff --git a/x/subaccount/types/params.go b/x/legacy/subaccount/types/params.go similarity index 100% rename from x/subaccount/types/params.go rename to x/legacy/subaccount/types/params.go diff --git a/x/subaccount/types/params.pb.go b/x/legacy/subaccount/types/params.pb.go similarity index 80% rename from x/subaccount/types/params.pb.go rename to x/legacy/subaccount/types/params.pb.go index 23ce6cda..b81cae1f 100644 --- a/x/subaccount/types/params.pb.go +++ b/x/legacy/subaccount/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/subaccount/params.proto +// source: sge/legacy/subaccount/v1beta/params.proto package types @@ -34,7 +34,7 @@ type Params struct { func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_3de2ae61e0617cc7, []int{0} + return fileDescriptor_b683dd80c38cb183, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -78,29 +78,30 @@ func (m *Params) GetDepositEnabled() bool { } func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.subaccount.Params") + proto.RegisterType((*Params)(nil), "sge.legacy.subaccount.v1beta.Params") } func init() { - proto.RegisterFile("sgenetwork/sge/subaccount/params.proto", fileDescriptor_3de2ae61e0617cc7) + proto.RegisterFile("sge/legacy/subaccount/v1beta/params.proto", fileDescriptor_b683dd80c38cb183) } -var fileDescriptor_3de2ae61e0617cc7 = []byte{ - // 211 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2b, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0x2f, 0x2e, 0x4d, 0x4a, 0x4c, - 0x4e, 0xce, 0x2f, 0xcd, 0x2b, 0xd1, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, - 0x2f, 0xc9, 0x17, 0x92, 0x44, 0xa8, 0xd3, 0x2b, 0x4e, 0x4f, 0xd5, 0x43, 0xa8, 0x93, 0x12, 0x49, - 0xcf, 0x4f, 0xcf, 0x07, 0xab, 0xd2, 0x07, 0xb1, 0x20, 0x1a, 0x94, 0x62, 0xb8, 0xd8, 0x02, 0xc0, - 0x06, 0x08, 0x29, 0x73, 0xf1, 0x96, 0x27, 0xa6, 0xa7, 0x16, 0xc5, 0xa7, 0xe6, 0x25, 0x26, 0xe5, - 0xa4, 0xa6, 0x48, 0x30, 0x2a, 0x30, 0x6a, 0x70, 0x04, 0xf1, 0x80, 0x05, 0x5d, 0x21, 0x62, 0x42, - 0xea, 0x5c, 0xfc, 0x29, 0xa9, 0x05, 0xf9, 0xc5, 0x99, 0x25, 0x70, 0x65, 0x4c, 0x60, 0x65, 0x7c, - 0x50, 0x61, 0xa8, 0x42, 0x2b, 0x96, 0x19, 0x0b, 0xe4, 0x19, 0x9c, 0xdc, 0x4f, 0x3c, 0x92, 0x63, - 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, - 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x37, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, - 0x3f, 0x17, 0xe4, 0x21, 0x5d, 0x64, 0xcf, 0x55, 0x20, 0x7b, 0xaf, 0xa4, 0xb2, 0x20, 0xb5, 0x38, - 0x89, 0x0d, 0xec, 0x5a, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x2b, 0x2f, 0xdd, 0x9e, 0x08, - 0x01, 0x00, 0x00, +var fileDescriptor_b683dd80c38cb183 = []byte{ + // 226 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2c, 0x4e, 0x4f, 0xd5, + 0xcf, 0x49, 0x4d, 0x4f, 0x4c, 0xae, 0xd4, 0x2f, 0x2e, 0x4d, 0x4a, 0x4c, 0x4e, 0xce, 0x2f, 0xcd, + 0x2b, 0xd1, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, + 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x92, 0x29, 0x4e, 0x4f, 0xd5, 0x83, 0x28, 0xd5, 0x43, 0x28, + 0xd5, 0x83, 0x28, 0x95, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd4, 0x07, 0xb1, 0x20, 0x7a, + 0x94, 0x62, 0xb8, 0xd8, 0x02, 0xc0, 0x66, 0x08, 0x29, 0x73, 0xf1, 0x96, 0x27, 0xa6, 0xa7, 0x16, + 0xc5, 0xa7, 0xe6, 0x25, 0x26, 0xe5, 0xa4, 0xa6, 0x48, 0x30, 0x2a, 0x30, 0x6a, 0x70, 0x04, 0xf1, + 0x80, 0x05, 0x5d, 0x21, 0x62, 0x42, 0xea, 0x5c, 0xfc, 0x29, 0xa9, 0x05, 0xf9, 0xc5, 0x99, 0x25, + 0x70, 0x65, 0x4c, 0x60, 0x65, 0x7c, 0x50, 0x61, 0xa8, 0x42, 0x2b, 0x96, 0x19, 0x0b, 0xe4, 0x19, + 0x9c, 0xfc, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, + 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0xca, 0x24, 0x3d, 0xb3, + 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0xbf, 0x38, 0x3d, 0x55, 0x37, 0x2f, 0xb5, 0xa4, + 0x3c, 0xbf, 0x28, 0x1b, 0xc4, 0xd6, 0xaf, 0xc0, 0xe2, 0xdf, 0x92, 0xca, 0x82, 0xd4, 0xe2, 0x24, + 0x36, 0xb0, 0xa3, 0x8d, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0xf3, 0x68, 0x6f, 0x9e, 0x15, 0x01, + 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/subaccount/types/query.pb.go b/x/legacy/subaccount/types/query.pb.go similarity index 85% rename from x/subaccount/types/query.pb.go rename to x/legacy/subaccount/types/query.pb.go index ee108615..83375830 100644 --- a/x/subaccount/types/query.pb.go +++ b/x/legacy/subaccount/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/subaccount/query.proto +// source: sge/legacy/subaccount/v1beta/query.proto package types @@ -39,7 +39,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_8c7f71115b08f83f, []int{0} + return fileDescriptor_630ad87ee8983ecc, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -77,7 +77,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_8c7f71115b08f83f, []int{1} + return fileDescriptor_630ad87ee8983ecc, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -122,7 +122,7 @@ func (m *QuerySubaccountRequest) Reset() { *m = QuerySubaccountRequest{} func (m *QuerySubaccountRequest) String() string { return proto.CompactTextString(m) } func (*QuerySubaccountRequest) ProtoMessage() {} func (*QuerySubaccountRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_8c7f71115b08f83f, []int{2} + return fileDescriptor_630ad87ee8983ecc, []int{2} } func (m *QuerySubaccountRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -171,7 +171,7 @@ func (m *QuerySubaccountResponse) Reset() { *m = QuerySubaccountResponse func (m *QuerySubaccountResponse) String() string { return proto.CompactTextString(m) } func (*QuerySubaccountResponse) ProtoMessage() {} func (*QuerySubaccountResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_8c7f71115b08f83f, []int{3} + return fileDescriptor_630ad87ee8983ecc, []int{3} } func (m *QuerySubaccountResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -229,51 +229,52 @@ func (m *QuerySubaccountResponse) GetUnlockedBalance() []LockedBalance { } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.subaccount.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.subaccount.QueryParamsResponse") - proto.RegisterType((*QuerySubaccountRequest)(nil), "sgenetwork.sge.subaccount.QuerySubaccountRequest") - proto.RegisterType((*QuerySubaccountResponse)(nil), "sgenetwork.sge.subaccount.QuerySubaccountResponse") + proto.RegisterType((*QueryParamsRequest)(nil), "sge.legacy.subaccount.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.legacy.subaccount.v1beta.QueryParamsResponse") + proto.RegisterType((*QuerySubaccountRequest)(nil), "sge.legacy.subaccount.v1beta.QuerySubaccountRequest") + proto.RegisterType((*QuerySubaccountResponse)(nil), "sge.legacy.subaccount.v1beta.QuerySubaccountResponse") } func init() { - proto.RegisterFile("sgenetwork/sge/subaccount/query.proto", fileDescriptor_8c7f71115b08f83f) + proto.RegisterFile("sge/legacy/subaccount/v1beta/query.proto", fileDescriptor_630ad87ee8983ecc) } -var fileDescriptor_8c7f71115b08f83f = []byte{ - // 529 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0xcb, 0x6e, 0xd3, 0x40, - 0x14, 0x8d, 0x93, 0x36, 0x15, 0x53, 0xf1, 0xd0, 0x10, 0x8a, 0x1b, 0xa8, 0x5b, 0x2c, 0x28, 0x41, - 0x22, 0xb6, 0x30, 0x1f, 0x80, 0x9a, 0x0d, 0xaa, 0xc4, 0x02, 0x12, 0x15, 0x09, 0x36, 0xd1, 0xd8, - 0x1e, 0x39, 0x56, 0xec, 0x19, 0xd7, 0x33, 0x56, 0x88, 0x10, 0x1b, 0x36, 0x6c, 0x91, 0xf8, 0x02, - 0x3e, 0x80, 0x1d, 0xfc, 0x43, 0x97, 0x15, 0x6c, 0x10, 0x8b, 0x0a, 0x25, 0x7c, 0x08, 0xca, 0xcc, - 0xb8, 0x71, 0xd2, 0x26, 0x3c, 0x56, 0x33, 0x73, 0xef, 0x39, 0xe7, 0x3e, 0xe6, 0x5e, 0x70, 0x87, - 0x05, 0x98, 0x60, 0x3e, 0xa0, 0x69, 0xdf, 0x66, 0x01, 0xb6, 0x59, 0xe6, 0x22, 0xcf, 0xa3, 0x19, - 0xe1, 0xf6, 0x61, 0x86, 0xd3, 0xa1, 0x95, 0xa4, 0x94, 0x53, 0xb8, 0x39, 0x85, 0x59, 0x2c, 0xc0, - 0xd6, 0x14, 0x56, 0xaf, 0x05, 0x34, 0xa0, 0x02, 0x65, 0x4f, 0x6e, 0x92, 0x50, 0xdf, 0xf4, 0x28, - 0x8b, 0x29, 0xeb, 0x4a, 0x87, 0x7c, 0x28, 0xd7, 0xcd, 0x80, 0xd2, 0x20, 0xc2, 0x36, 0x4a, 0x42, - 0x1b, 0x11, 0x42, 0x39, 0xe2, 0x21, 0x25, 0xb9, 0xf7, 0xee, 0xe2, 0x84, 0x5c, 0x14, 0x21, 0xe2, - 0x61, 0x05, 0xdc, 0x5d, 0x0c, 0x4c, 0x50, 0x8a, 0x62, 0x25, 0x68, 0xd6, 0x00, 0x7c, 0x36, 0xa9, - 0xe4, 0xa9, 0x30, 0xb6, 0xf1, 0x61, 0x86, 0x19, 0x37, 0x9f, 0x83, 0xab, 0x33, 0x56, 0x96, 0x50, - 0xc2, 0x30, 0x7c, 0x04, 0xaa, 0x92, 0xac, 0x6b, 0x3b, 0x5a, 0x63, 0xdd, 0xb9, 0x65, 0x2d, 0x2c, - 0xdc, 0x92, 0xd4, 0xd6, 0xca, 0xd1, 0xc9, 0x76, 0xa9, 0xad, 0x68, 0xa6, 0x03, 0x36, 0x84, 0x6e, - 0xe7, 0x14, 0xa7, 0x22, 0x42, 0x1d, 0xac, 0x21, 0xdf, 0x4f, 0x31, 0x93, 0xda, 0x17, 0xda, 0xf9, - 0xd3, 0xfc, 0x54, 0x01, 0xd7, 0xcf, 0x90, 0x54, 0x42, 0xce, 0x1c, 0xab, 0xa5, 0x7f, 0xfd, 0xdc, - 0xac, 0xa9, 0x7e, 0xee, 0x49, 0x4f, 0x87, 0xa7, 0x21, 0x09, 0x4e, 0xf5, 0xe0, 0x3e, 0x58, 0x53, - 0xad, 0xd2, 0xcb, 0xa2, 0x8a, 0x7b, 0x4b, 0xaa, 0xd8, 0x93, 0x67, 0x27, 0x8b, 0x63, 0x94, 0x0e, - 0x55, 0x35, 0x39, 0x1f, 0x1e, 0x80, 0x4b, 0x11, 0xf5, 0xfa, 0xd8, 0xef, 0xe6, 0x8a, 0x95, 0x9d, - 0x4a, 0x63, 0xdd, 0x69, 0x2c, 0x51, 0x7c, 0x22, 0x08, 0x2d, 0x89, 0x57, 0x82, 0x17, 0xa3, 0xa2, - 0x11, 0xbe, 0x00, 0x57, 0x32, 0x32, 0x27, 0xbc, 0xf2, 0x5f, 0xc2, 0x97, 0x73, 0x9d, 0x5c, 0x1a, - 0x81, 0xad, 0x41, 0xc8, 0x7b, 0x7e, 0x8a, 0x06, 0xc8, 0x8d, 0x70, 0xf7, 0x4c, 0x9c, 0x55, 0xd1, - 0xc6, 0xad, 0x09, 0xfb, 0xc7, 0xc9, 0xf6, 0x35, 0xd9, 0x4a, 0xe6, 0xf7, 0xad, 0x90, 0xda, 0x31, - 0xe2, 0x3d, 0x6b, 0x9f, 0xf0, 0xf6, 0x8d, 0xa2, 0xc6, 0xc1, 0x6c, 0x08, 0xe7, 0x4b, 0x19, 0xac, - 0x8a, 0xff, 0x82, 0x1f, 0x35, 0x00, 0xa6, 0x9f, 0x06, 0x1f, 0x2c, 0x49, 0xfe, 0xfc, 0xa9, 0xa8, - 0x3b, 0xff, 0x42, 0x91, 0x33, 0x61, 0xde, 0x7f, 0xfb, 0xed, 0xd7, 0x87, 0xf2, 0x2e, 0xbc, 0x3d, - 0x3f, 0xf7, 0x85, 0xeb, 0x6b, 0x35, 0x0c, 0x6f, 0xe0, 0x3b, 0x0d, 0x54, 0xe5, 0xa8, 0xc2, 0xe6, - 0x9f, 0x82, 0xcd, 0xec, 0x48, 0xdd, 0xfa, 0x5b, 0xb8, 0xca, 0xcb, 0x10, 0x79, 0xe9, 0x70, 0xe3, - 0xfc, 0x7d, 0x6c, 0x3d, 0x3e, 0x1a, 0x19, 0xda, 0xf1, 0xc8, 0xd0, 0x7e, 0x8e, 0x0c, 0xed, 0xfd, - 0xd8, 0x28, 0x1d, 0x8f, 0x8d, 0xd2, 0xf7, 0xb1, 0x51, 0x7a, 0xd9, 0x0c, 0x42, 0xde, 0xcb, 0x5c, - 0xcb, 0xa3, 0xf1, 0x84, 0xdb, 0x2c, 0xee, 0xf5, 0xab, 0xa2, 0x12, 0x1f, 0x26, 0x98, 0xb9, 0x55, - 0xb1, 0xd9, 0x0f, 0x7f, 0x07, 0x00, 0x00, 0xff, 0xff, 0x4e, 0x35, 0x9d, 0xb9, 0xbd, 0x04, 0x00, +var fileDescriptor_630ad87ee8983ecc = []byte{ + // 545 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x93, 0xc1, 0x6e, 0xd3, 0x4c, + 0x10, 0xc7, 0xe3, 0xa4, 0x4d, 0xf5, 0x6d, 0xf5, 0x01, 0x5a, 0x42, 0x09, 0xa1, 0x75, 0x2b, 0xab, + 0x42, 0x01, 0x5a, 0x9b, 0x9a, 0xf2, 0x00, 0xf5, 0x0d, 0xa9, 0x42, 0x90, 0x08, 0x09, 0x10, 0x52, + 0xb4, 0xb6, 0x57, 0x8e, 0x15, 0x7b, 0xd7, 0xf5, 0xae, 0x09, 0x11, 0xe2, 0xc2, 0x1d, 0x09, 0x89, + 0x87, 0xe0, 0x05, 0x10, 0x77, 0x6e, 0x3d, 0x56, 0x70, 0x41, 0x1c, 0x2a, 0x94, 0xf0, 0x20, 0xc8, + 0xbb, 0xeb, 0x36, 0x49, 0x2b, 0x8b, 0x72, 0xf3, 0x8e, 0xff, 0xff, 0xdf, 0xce, 0xcc, 0xce, 0x80, + 0x36, 0x0b, 0xb0, 0x15, 0xe1, 0x00, 0x79, 0x23, 0x8b, 0x65, 0x2e, 0xf2, 0x3c, 0x9a, 0x11, 0x6e, + 0xbd, 0xda, 0x71, 0x31, 0x47, 0xd6, 0x41, 0x86, 0xd3, 0x91, 0x99, 0xa4, 0x94, 0x53, 0xb8, 0xca, + 0x02, 0x6c, 0x4a, 0xa5, 0x79, 0xaa, 0x34, 0xa5, 0xb2, 0x75, 0xc3, 0xa3, 0x2c, 0xa6, 0xac, 0x27, + 0xb4, 0x96, 0x3c, 0x48, 0x63, 0xab, 0x11, 0xd0, 0x80, 0xca, 0x78, 0xfe, 0xa5, 0xa2, 0xab, 0x01, + 0xa5, 0x41, 0x84, 0x2d, 0x94, 0x84, 0x16, 0x22, 0x84, 0x72, 0xc4, 0x43, 0x4a, 0x0a, 0xcf, 0x9d, + 0xd2, 0xb4, 0x5c, 0x14, 0x21, 0xe2, 0x61, 0xa5, 0xbd, 0x5d, 0xaa, 0x4d, 0x50, 0x8a, 0x62, 0x85, + 0x35, 0x1a, 0x00, 0x3e, 0xc9, 0x4b, 0x7a, 0x2c, 0x82, 0x1d, 0x7c, 0x90, 0x61, 0xc6, 0x8d, 0xe7, + 0xe0, 0xea, 0x4c, 0x94, 0x25, 0x94, 0x30, 0x0c, 0x1d, 0x50, 0x97, 0xe6, 0xa6, 0xb6, 0xa1, 0xb5, + 0x97, 0xed, 0x4d, 0xb3, 0xac, 0x03, 0xa6, 0x74, 0x3b, 0x0b, 0x87, 0xc7, 0xeb, 0x95, 0x8e, 0x72, + 0x1a, 0x36, 0x58, 0x11, 0xe8, 0xee, 0x89, 0x5c, 0x5d, 0x0a, 0x9b, 0x60, 0x09, 0xf9, 0x7e, 0x8a, + 0x99, 0xc4, 0xff, 0xd7, 0x29, 0x8e, 0xc6, 0x97, 0x1a, 0xb8, 0x7e, 0xc6, 0xa4, 0x72, 0xb2, 0xe7, + 0x5c, 0x4e, 0xf3, 0xdb, 0xe7, 0xed, 0x86, 0x6a, 0xf7, 0x9e, 0xfc, 0xd3, 0xe5, 0x69, 0x48, 0x82, + 0x13, 0x1e, 0xdc, 0x07, 0x4b, 0xaa, 0x61, 0xcd, 0xaa, 0x28, 0x64, 0xab, 0xbc, 0x90, 0x3d, 0x79, + 0xec, 0x66, 0x71, 0x8c, 0xd2, 0x91, 0x2a, 0xa8, 0x40, 0xc0, 0x67, 0xe0, 0x52, 0x44, 0xbd, 0x01, + 0xf6, 0x7b, 0x05, 0xb4, 0xb6, 0x51, 0x6b, 0x2f, 0xdb, 0x77, 0xcb, 0xa1, 0xfb, 0xc2, 0xe3, 0x48, + 0x8b, 0x62, 0xfe, 0x1f, 0x4d, 0x07, 0xe1, 0x4b, 0x70, 0x25, 0x23, 0x73, 0xec, 0x85, 0x7f, 0x65, + 0x5f, 0x2e, 0x50, 0x05, 0x1d, 0x81, 0xb5, 0x61, 0xc8, 0xfb, 0x7e, 0x8a, 0x86, 0xc8, 0x8d, 0x70, + 0xef, 0xcc, 0x55, 0x8b, 0xa2, 0x9f, 0x6b, 0xb9, 0xfb, 0xe7, 0xf1, 0xfa, 0x35, 0xd9, 0x53, 0xe6, + 0x0f, 0xcc, 0x90, 0x5a, 0x31, 0xe2, 0x7d, 0xf3, 0x21, 0xe1, 0x9d, 0x9b, 0xd3, 0x8c, 0xa7, 0xb3, + 0x57, 0xd8, 0x5f, 0xab, 0x60, 0x51, 0x3c, 0x1c, 0xfc, 0xa4, 0x01, 0x70, 0xfa, 0x7a, 0x70, 0xb7, + 0x3c, 0xff, 0xf3, 0x27, 0xa4, 0xf5, 0xe0, 0x82, 0x2e, 0x39, 0x22, 0xc6, 0xd6, 0xbb, 0xef, 0xbf, + 0x3f, 0x56, 0x6f, 0xc1, 0x4d, 0x2b, 0xdf, 0x8b, 0xa9, 0x85, 0x98, 0xfa, 0x7c, 0xa3, 0x66, 0xe3, + 0x2d, 0x7c, 0xaf, 0x81, 0xba, 0x9c, 0x5c, 0x78, 0xef, 0x2f, 0xee, 0x9b, 0x59, 0x9c, 0xd6, 0xce, + 0x05, 0x1c, 0x2a, 0x3b, 0x5d, 0x64, 0xd7, 0x84, 0x2b, 0xf3, 0xd9, 0xc9, 0x85, 0x71, 0x1e, 0x1d, + 0x8e, 0x75, 0xed, 0x68, 0xac, 0x6b, 0xbf, 0xc6, 0xba, 0xf6, 0x61, 0xa2, 0x57, 0x8e, 0x26, 0x7a, + 0xe5, 0xc7, 0x44, 0xaf, 0xbc, 0xd8, 0x0d, 0x42, 0xde, 0xcf, 0x5c, 0xd3, 0xa3, 0x71, 0xee, 0xdd, + 0x26, 0x98, 0x0f, 0x69, 0x3a, 0x10, 0x9c, 0xd7, 0xe7, 0xec, 0x3f, 0x1f, 0x25, 0x98, 0xb9, 0x75, + 0xb1, 0xf8, 0xf7, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0xaa, 0xc1, 0xe3, 0x08, 0xe8, 0x04, 0x00, 0x00, } @@ -305,7 +306,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Subaccount(ctx context.Context, in *QuerySubaccountRequest, opts ...grpc.CallOption) (*QuerySubaccountResponse, error) { out := new(QuerySubaccountResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Query/Subaccount", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Query/Subaccount", in, out, opts...) if err != nil { return nil, err } @@ -314,7 +315,7 @@ func (c *queryClient) Subaccount(ctx context.Context, in *QuerySubaccountRequest func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -354,7 +355,7 @@ func _Query_Subaccount_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Query/Subaccount", + FullMethod: "/sge.legacy.subaccount.v1beta.Query/Subaccount", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Subaccount(ctx, req.(*QuerySubaccountRequest)) @@ -372,7 +373,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Query/Params", + FullMethod: "/sge.legacy.subaccount.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -380,8 +381,9 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.subaccount.Query", + ServiceName: "sge.legacy.subaccount.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -394,7 +396,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/subaccount/query.proto", + Metadata: "sge/legacy/subaccount/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/subaccount/types/query.pb.gw.go b/x/legacy/subaccount/types/query.pb.gw.go similarity index 99% rename from x/subaccount/types/query.pb.gw.go rename to x/legacy/subaccount/types/query.pb.gw.go index bee0dcb3..a547ad9f 100644 --- a/x/subaccount/types/query.pb.gw.go +++ b/x/legacy/subaccount/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/subaccount/query.proto +// source: sge/legacy/subaccount/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/subaccount/types/ticket.go b/x/legacy/subaccount/types/ticket.go similarity index 100% rename from x/subaccount/types/ticket.go rename to x/legacy/subaccount/types/ticket.go diff --git a/x/subaccount/types/ticket.pb.go b/x/legacy/subaccount/types/ticket.pb.go similarity index 80% rename from x/subaccount/types/ticket.pb.go rename to x/legacy/subaccount/types/ticket.pb.go index 227e4b29..31d84aa2 100644 --- a/x/subaccount/types/ticket.pb.go +++ b/x/legacy/subaccount/types/ticket.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/subaccount/ticket.proto +// source: sge/legacy/subaccount/v1beta/ticket.proto package types @@ -8,7 +8,7 @@ import ( fmt "fmt" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" - types "github.com/sge-network/sge/x/bet/types" + types "github.com/sge-network/sge/x/legacy/bet/types" io "io" math "math" math_bits "math/bits" @@ -39,7 +39,7 @@ func (m *SubAccWagerTicketPayload) Reset() { *m = SubAccWagerTicketPaylo func (m *SubAccWagerTicketPayload) String() string { return proto.CompactTextString(m) } func (*SubAccWagerTicketPayload) ProtoMessage() {} func (*SubAccWagerTicketPayload) Descriptor() ([]byte, []int) { - return fileDescriptor_fc46a49a6077510c, []int{0} + return fileDescriptor_9554d18f59a927ff, []int{0} } func (m *SubAccWagerTicketPayload) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -76,34 +76,35 @@ func (m *SubAccWagerTicketPayload) GetMsg() *types.MsgWager { } func init() { - proto.RegisterType((*SubAccWagerTicketPayload)(nil), "sgenetwork.sge.subaccount.SubAccWagerTicketPayload") + proto.RegisterType((*SubAccWagerTicketPayload)(nil), "sge.legacy.subaccount.v1beta.SubAccWagerTicketPayload") } func init() { - proto.RegisterFile("sgenetwork/sge/subaccount/ticket.proto", fileDescriptor_fc46a49a6077510c) + proto.RegisterFile("sge/legacy/subaccount/v1beta/ticket.proto", fileDescriptor_9554d18f59a927ff) } -var fileDescriptor_fc46a49a6077510c = []byte{ - // 301 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x91, 0x41, 0x4b, 0xf3, 0x30, - 0x18, 0xc7, 0x9b, 0x77, 0xf0, 0x82, 0xf5, 0x56, 0x37, 0xa8, 0x53, 0xb3, 0xe1, 0x41, 0x76, 0x59, - 0x02, 0xfa, 0x09, 0x36, 0x04, 0xf1, 0x20, 0xea, 0x14, 0x04, 0x2f, 0x23, 0x49, 0x43, 0x56, 0x6a, - 0x9a, 0xd1, 0x3c, 0xc5, 0xed, 0x5b, 0xf8, 0xb1, 0x76, 0xdc, 0x51, 0x3c, 0x0c, 0x69, 0xef, 0x7e, - 0x06, 0x69, 0x2a, 0x6c, 0xf6, 0xe4, 0x2d, 0x90, 0xff, 0xef, 0xf7, 0x24, 0xff, 0xc7, 0x3f, 0xb3, - 0x4a, 0xa6, 0x12, 0x5e, 0x4d, 0x96, 0x50, 0xab, 0x24, 0xb5, 0x39, 0x67, 0x42, 0x98, 0x3c, 0x05, - 0x0a, 0xb1, 0x48, 0x24, 0x90, 0x79, 0x66, 0xc0, 0x04, 0x87, 0xdb, 0x1c, 0xb1, 0x4a, 0x92, 0x6d, - 0xae, 0xdb, 0x56, 0x46, 0x19, 0x97, 0xa2, 0xd5, 0xa9, 0x06, 0xba, 0x47, 0x0d, 0x31, 0x97, 0x40, - 0x61, 0x51, 0x5f, 0x9e, 0x7e, 0x21, 0x3f, 0x7c, 0xc8, 0xf9, 0x48, 0x88, 0x27, 0xa6, 0x64, 0xf6, - 0xe8, 0x26, 0xdd, 0xb1, 0xe5, 0x8b, 0x61, 0x51, 0x40, 0xfc, 0x96, 0xb6, 0x2a, 0x44, 0x7d, 0x34, - 0xd8, 0x3f, 0x3f, 0x26, 0x8d, 0xc1, 0x5c, 0x02, 0xb9, 0xb1, 0xca, 0x71, 0x93, 0x2a, 0x18, 0xdc, - 0xfb, 0x1d, 0xcd, 0xe2, 0x94, 0x09, 0x31, 0x8d, 0x64, 0x94, 0x0b, 0x98, 0x32, 0x5d, 0x3d, 0x2c, - 0xfc, 0xd7, 0x47, 0x83, 0xbd, 0xf1, 0xc9, 0x6a, 0xd3, 0xf3, 0x3e, 0x36, 0xbd, 0x8e, 0x30, 0x56, - 0x1b, 0x6b, 0xa3, 0x84, 0xc4, 0x86, 0x6a, 0x06, 0x33, 0x72, 0x9d, 0xc2, 0xe4, 0xe0, 0x87, 0xbd, - 0x74, 0xe8, 0xc8, 0x91, 0xc1, 0xad, 0xdf, 0xae, 0x3f, 0xd8, 0x30, 0xb6, 0xfe, 0x62, 0x0c, 0x6a, - 0x74, 0x57, 0x38, 0xbe, 0x5a, 0x15, 0x18, 0xad, 0x0b, 0x8c, 0x3e, 0x0b, 0x8c, 0xde, 0x4a, 0xec, - 0xad, 0x4b, 0xec, 0xbd, 0x97, 0xd8, 0x7b, 0x1e, 0xaa, 0x18, 0x66, 0x39, 0x27, 0xc2, 0xe8, 0xaa, - 0xa7, 0xe1, 0x6e, 0x67, 0x8b, 0x5f, 0xeb, 0x58, 0xce, 0xa5, 0xe5, 0xff, 0x5d, 0x81, 0x17, 0xdf, - 0x01, 0x00, 0x00, 0xff, 0xff, 0x6f, 0xd1, 0x78, 0x2d, 0xb8, 0x01, 0x00, 0x00, +var fileDescriptor_9554d18f59a927ff = []byte{ + // 314 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x91, 0xcd, 0x4a, 0x33, 0x31, + 0x14, 0x86, 0x27, 0x5f, 0xe1, 0x03, 0xc7, 0xdd, 0xd8, 0x42, 0x29, 0x9a, 0x16, 0x57, 0x75, 0x61, + 0x42, 0xd5, 0x1b, 0x68, 0x71, 0xe3, 0xc2, 0xbf, 0x2a, 0x08, 0x6e, 0x4a, 0x92, 0x39, 0xa4, 0x43, + 0x9b, 0x49, 0x69, 0x32, 0xda, 0xde, 0x85, 0x97, 0xd5, 0x65, 0x97, 0xe2, 0xa2, 0xc8, 0xcc, 0x15, + 0x78, 0x07, 0x32, 0x89, 0xd2, 0x41, 0x5c, 0xb8, 0x3b, 0x90, 0xf7, 0x79, 0xde, 0x24, 0x27, 0x3c, + 0x32, 0x12, 0xe8, 0x14, 0x24, 0x13, 0x4b, 0x6a, 0x32, 0xce, 0x84, 0xd0, 0x59, 0x6a, 0xe9, 0x53, + 0x8f, 0x83, 0x65, 0xd4, 0x26, 0x62, 0x02, 0x96, 0xcc, 0xe6, 0xda, 0xea, 0x68, 0xdf, 0x48, 0x20, + 0x3e, 0x4a, 0xb6, 0x51, 0xe2, 0xa3, 0xad, 0xba, 0xd4, 0x52, 0xbb, 0x20, 0x2d, 0x27, 0xcf, 0xb4, + 0x70, 0x45, 0xcf, 0x61, 0xeb, 0x5d, 0xf8, 0xf3, 0xc3, 0x0f, 0x14, 0x36, 0xef, 0x32, 0xde, 0x17, + 0xe2, 0x81, 0x49, 0x98, 0xdf, 0xbb, 0xbe, 0x1b, 0xb6, 0x9c, 0x6a, 0x16, 0x47, 0xbd, 0xb0, 0xa6, + 0x8c, 0x6c, 0xa2, 0x0e, 0xea, 0xee, 0x9e, 0xb4, 0x49, 0xa5, 0x9e, 0xc3, 0x77, 0x2f, 0xb9, 0x34, + 0xd2, 0xa1, 0xc3, 0x32, 0x1b, 0xdd, 0x86, 0x0d, 0xc5, 0x92, 0x94, 0x09, 0x31, 0x8a, 0x21, 0xce, + 0x84, 0x1d, 0x31, 0x55, 0xde, 0xb2, 0xf9, 0xaf, 0x83, 0xba, 0x3b, 0x83, 0x83, 0xd5, 0xa6, 0x1d, + 0xbc, 0x6d, 0xda, 0x0d, 0xa1, 0x8d, 0xd2, 0xc6, 0xc4, 0x13, 0x92, 0x68, 0xaa, 0x98, 0x1d, 0x93, + 0x8b, 0xd4, 0x0e, 0xf7, 0xbe, 0xd8, 0x73, 0x87, 0xf6, 0x1d, 0x19, 0x5d, 0x87, 0x75, 0xff, 0xda, + 0x1f, 0xc6, 0xda, 0x5f, 0x8c, 0x91, 0x47, 0xab, 0xc2, 0xc1, 0xd5, 0x2a, 0xc7, 0x68, 0x9d, 0x63, + 0xf4, 0x9e, 0x63, 0xf4, 0x52, 0xe0, 0x60, 0x5d, 0xe0, 0xe0, 0xb5, 0xc0, 0xc1, 0xe3, 0x99, 0x4c, + 0xec, 0x38, 0xe3, 0x44, 0x68, 0x45, 0x8d, 0x84, 0xe3, 0x14, 0xec, 0xb3, 0x9e, 0x4f, 0xca, 0x99, + 0x2e, 0x7e, 0xd9, 0x92, 0x5d, 0xce, 0xc0, 0xf0, 0xff, 0xee, 0x2b, 0x4f, 0x3f, 0x03, 0x00, 0x00, + 0xff, 0xff, 0x76, 0x60, 0x32, 0xc9, 0xcb, 0x01, 0x00, 0x00, } func (m *SubAccWagerTicketPayload) Marshal() (dAtA []byte, err error) { diff --git a/x/subaccount/types/tx.pb.go b/x/legacy/subaccount/types/tx.pb.go similarity index 89% rename from x/subaccount/types/tx.pb.go rename to x/legacy/subaccount/types/tx.pb.go index 043662c9..5bbd4135 100644 --- a/x/subaccount/types/tx.pb.go +++ b/x/legacy/subaccount/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/subaccount/tx.proto +// source: sge/legacy/subaccount/v1beta/tx.proto package types @@ -12,8 +12,8 @@ import ( _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" - types "github.com/sge-network/sge/x/bet/types" - types1 "github.com/sge-network/sge/x/house/types" + types "github.com/sge-network/sge/x/legacy/bet/types" + types1 "github.com/sge-network/sge/x/legacy/house/types" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" @@ -48,7 +48,7 @@ func (m *MsgCreate) Reset() { *m = MsgCreate{} } func (m *MsgCreate) String() string { return proto.CompactTextString(m) } func (*MsgCreate) ProtoMessage() {} func (*MsgCreate) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{0} + return fileDescriptor_515b75d22188f78f, []int{0} } func (m *MsgCreate) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -106,7 +106,7 @@ func (m *MsgCreateResponse) Reset() { *m = MsgCreateResponse{} } func (m *MsgCreateResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreateResponse) ProtoMessage() {} func (*MsgCreateResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{1} + return fileDescriptor_515b75d22188f78f, []int{1} } func (m *MsgCreateResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -151,7 +151,7 @@ func (m *MsgTopUp) Reset() { *m = MsgTopUp{} } func (m *MsgTopUp) String() string { return proto.CompactTextString(m) } func (*MsgTopUp) ProtoMessage() {} func (*MsgTopUp) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{2} + return fileDescriptor_515b75d22188f78f, []int{2} } func (m *MsgTopUp) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -209,7 +209,7 @@ func (m *MsgTopUpResponse) Reset() { *m = MsgTopUpResponse{} } func (m *MsgTopUpResponse) String() string { return proto.CompactTextString(m) } func (*MsgTopUpResponse) ProtoMessage() {} func (*MsgTopUpResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{3} + return fileDescriptor_515b75d22188f78f, []int{3} } func (m *MsgTopUpResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -249,7 +249,7 @@ func (m *MsgWithdrawUnlockedBalances) Reset() { *m = MsgWithdrawUnlocked func (m *MsgWithdrawUnlockedBalances) String() string { return proto.CompactTextString(m) } func (*MsgWithdrawUnlockedBalances) ProtoMessage() {} func (*MsgWithdrawUnlockedBalances) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{4} + return fileDescriptor_515b75d22188f78f, []int{4} } func (m *MsgWithdrawUnlockedBalances) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -294,7 +294,7 @@ func (m *MsgWithdrawUnlockedBalancesResponse) Reset() { *m = MsgWithdraw func (m *MsgWithdrawUnlockedBalancesResponse) String() string { return proto.CompactTextString(m) } func (*MsgWithdrawUnlockedBalancesResponse) ProtoMessage() {} func (*MsgWithdrawUnlockedBalancesResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{5} + return fileDescriptor_515b75d22188f78f, []int{5} } func (m *MsgWithdrawUnlockedBalancesResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -336,7 +336,7 @@ func (m *MsgWager) Reset() { *m = MsgWager{} } func (m *MsgWager) String() string { return proto.CompactTextString(m) } func (*MsgWager) ProtoMessage() {} func (*MsgWager) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{6} + return fileDescriptor_515b75d22188f78f, []int{6} } func (m *MsgWager) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -389,7 +389,7 @@ func (m *MsgWagerResponse) Reset() { *m = MsgWagerResponse{} } func (m *MsgWagerResponse) String() string { return proto.CompactTextString(m) } func (*MsgWagerResponse) ProtoMessage() {} func (*MsgWagerResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{7} + return fileDescriptor_515b75d22188f78f, []int{7} } func (m *MsgWagerResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -435,7 +435,7 @@ func (m *MsgHouseDeposit) Reset() { *m = MsgHouseDeposit{} } func (m *MsgHouseDeposit) String() string { return proto.CompactTextString(m) } func (*MsgHouseDeposit) ProtoMessage() {} func (*MsgHouseDeposit) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{8} + return fileDescriptor_515b75d22188f78f, []int{8} } func (m *MsgHouseDeposit) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -481,7 +481,7 @@ func (m *MsgHouseDepositResponse) Reset() { *m = MsgHouseDepositResponse func (m *MsgHouseDepositResponse) String() string { return proto.CompactTextString(m) } func (*MsgHouseDepositResponse) ProtoMessage() {} func (*MsgHouseDepositResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{9} + return fileDescriptor_515b75d22188f78f, []int{9} } func (m *MsgHouseDepositResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -527,7 +527,7 @@ func (m *MsgHouseWithdraw) Reset() { *m = MsgHouseWithdraw{} } func (m *MsgHouseWithdraw) String() string { return proto.CompactTextString(m) } func (*MsgHouseWithdraw) ProtoMessage() {} func (*MsgHouseWithdraw) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{10} + return fileDescriptor_515b75d22188f78f, []int{10} } func (m *MsgHouseWithdraw) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -573,7 +573,7 @@ func (m *MsgHouseWithdrawResponse) Reset() { *m = MsgHouseWithdrawRespon func (m *MsgHouseWithdrawResponse) String() string { return proto.CompactTextString(m) } func (*MsgHouseWithdrawResponse) ProtoMessage() {} func (*MsgHouseWithdrawResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{11} + return fileDescriptor_515b75d22188f78f, []int{11} } func (m *MsgHouseWithdrawResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -622,7 +622,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{12} + return fileDescriptor_515b75d22188f78f, []int{12} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -674,7 +674,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_4f026744c489fe19, []int{13} + return fileDescriptor_515b75d22188f78f, []int{13} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -704,78 +704,79 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgCreate)(nil), "sgenetwork.sge.subaccount.MsgCreate") - proto.RegisterType((*MsgCreateResponse)(nil), "sgenetwork.sge.subaccount.MsgCreateResponse") - proto.RegisterType((*MsgTopUp)(nil), "sgenetwork.sge.subaccount.MsgTopUp") - proto.RegisterType((*MsgTopUpResponse)(nil), "sgenetwork.sge.subaccount.MsgTopUpResponse") - proto.RegisterType((*MsgWithdrawUnlockedBalances)(nil), "sgenetwork.sge.subaccount.MsgWithdrawUnlockedBalances") - proto.RegisterType((*MsgWithdrawUnlockedBalancesResponse)(nil), "sgenetwork.sge.subaccount.MsgWithdrawUnlockedBalancesResponse") - proto.RegisterType((*MsgWager)(nil), "sgenetwork.sge.subaccount.MsgWager") - proto.RegisterType((*MsgWagerResponse)(nil), "sgenetwork.sge.subaccount.MsgWagerResponse") - proto.RegisterType((*MsgHouseDeposit)(nil), "sgenetwork.sge.subaccount.MsgHouseDeposit") - proto.RegisterType((*MsgHouseDepositResponse)(nil), "sgenetwork.sge.subaccount.MsgHouseDepositResponse") - proto.RegisterType((*MsgHouseWithdraw)(nil), "sgenetwork.sge.subaccount.MsgHouseWithdraw") - proto.RegisterType((*MsgHouseWithdrawResponse)(nil), "sgenetwork.sge.subaccount.MsgHouseWithdrawResponse") - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.subaccount.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.subaccount.MsgUpdateParamsResponse") + proto.RegisterType((*MsgCreate)(nil), "sge.legacy.subaccount.v1beta.MsgCreate") + proto.RegisterType((*MsgCreateResponse)(nil), "sge.legacy.subaccount.v1beta.MsgCreateResponse") + proto.RegisterType((*MsgTopUp)(nil), "sge.legacy.subaccount.v1beta.MsgTopUp") + proto.RegisterType((*MsgTopUpResponse)(nil), "sge.legacy.subaccount.v1beta.MsgTopUpResponse") + proto.RegisterType((*MsgWithdrawUnlockedBalances)(nil), "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalances") + proto.RegisterType((*MsgWithdrawUnlockedBalancesResponse)(nil), "sge.legacy.subaccount.v1beta.MsgWithdrawUnlockedBalancesResponse") + proto.RegisterType((*MsgWager)(nil), "sge.legacy.subaccount.v1beta.MsgWager") + proto.RegisterType((*MsgWagerResponse)(nil), "sge.legacy.subaccount.v1beta.MsgWagerResponse") + proto.RegisterType((*MsgHouseDeposit)(nil), "sge.legacy.subaccount.v1beta.MsgHouseDeposit") + proto.RegisterType((*MsgHouseDepositResponse)(nil), "sge.legacy.subaccount.v1beta.MsgHouseDepositResponse") + proto.RegisterType((*MsgHouseWithdraw)(nil), "sge.legacy.subaccount.v1beta.MsgHouseWithdraw") + proto.RegisterType((*MsgHouseWithdrawResponse)(nil), "sge.legacy.subaccount.v1beta.MsgHouseWithdrawResponse") + proto.RegisterType((*MsgUpdateParams)(nil), "sge.legacy.subaccount.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.legacy.subaccount.v1beta.MsgUpdateParamsResponse") } func init() { - proto.RegisterFile("sgenetwork/sge/subaccount/tx.proto", fileDescriptor_4f026744c489fe19) -} - -var fileDescriptor_4f026744c489fe19 = []byte{ - // 792 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0x4d, 0x4f, 0xdb, 0x4a, - 0x14, 0x8d, 0xc9, 0x23, 0x90, 0x81, 0xf7, 0x78, 0xf8, 0xf1, 0x4a, 0x30, 0x6a, 0x9a, 0x1a, 0xda, - 0xa6, 0xd0, 0xd8, 0x25, 0x48, 0x54, 0x62, 0x51, 0xb5, 0x29, 0x88, 0x2e, 0x1a, 0xa9, 0x4a, 0x41, - 0x48, 0x5d, 0x34, 0x72, 0x9c, 0xd1, 0x24, 0x82, 0x78, 0x2c, 0xcf, 0x84, 0x8f, 0x6d, 0x57, 0x2c, - 0xbb, 0xeb, 0x5f, 0xe8, 0x92, 0x05, 0xab, 0xfe, 0x02, 0xd4, 0x15, 0x62, 0x51, 0xb5, 0x9b, 0xaa, - 0x82, 0x05, 0x7f, 0xa3, 0xf2, 0xcc, 0xd8, 0x89, 0x9d, 0x0f, 0xa7, 0x59, 0x74, 0x93, 0xd8, 0xbe, - 0xe7, 0x9e, 0x7b, 0xce, 0xb5, 0xef, 0xd5, 0x00, 0x95, 0x20, 0x68, 0x41, 0x7a, 0x88, 0x9d, 0x3d, - 0x9d, 0x20, 0xa8, 0x93, 0x66, 0xc5, 0x30, 0x4d, 0xdc, 0xb4, 0xa8, 0x4e, 0x8f, 0x34, 0xdb, 0xc1, - 0x14, 0xcb, 0x73, 0x2d, 0x8c, 0x46, 0x10, 0xd4, 0x5a, 0x18, 0x65, 0xda, 0x68, 0xd4, 0x2d, 0xac, - 0xb3, 0x5f, 0x8e, 0x56, 0x66, 0x4d, 0x4c, 0x1a, 0x98, 0xe8, 0x0d, 0x82, 0xf4, 0x83, 0x15, 0xf7, - 0x4f, 0x04, 0xe6, 0x78, 0xa0, 0xcc, 0xee, 0x74, 0x7e, 0x23, 0x42, 0x33, 0x08, 0x23, 0xcc, 0x9f, - 0xbb, 0x57, 0xe2, 0xe9, 0x7c, 0x48, 0x5b, 0x05, 0xb6, 0x44, 0x29, 0xb7, 0x43, 0xc1, 0x1a, 0x6e, - 0x12, 0xd8, 0x0a, 0x3f, 0xe8, 0xed, 0xab, 0x62, 0xec, 0x1b, 0x96, 0x09, 0x05, 0xf0, 0x7e, 0x6f, - 0xa0, 0x6d, 0x38, 0x46, 0x43, 0x48, 0x54, 0xbf, 0x4a, 0x20, 0x59, 0x24, 0xe8, 0x85, 0x03, 0x0d, - 0x0a, 0xe5, 0x3c, 0x18, 0x33, 0xdd, 0x2b, 0xec, 0xa4, 0xa4, 0x8c, 0x94, 0x4d, 0x16, 0x52, 0x97, - 0x67, 0xb9, 0x19, 0xe1, 0xe9, 0x79, 0xb5, 0xea, 0x40, 0x42, 0xde, 0x50, 0xa7, 0x6e, 0xa1, 0x92, - 0x07, 0x94, 0x35, 0x30, 0x8a, 0x0f, 0x2d, 0xe8, 0xa4, 0x46, 0x22, 0x32, 0x38, 0x4c, 0xde, 0x05, - 0x53, 0xfb, 0xd8, 0xdc, 0x83, 0xd5, 0xb2, 0x50, 0x4c, 0x52, 0xf1, 0x4c, 0x3c, 0x3b, 0x91, 0xcf, - 0x6a, 0x3d, 0x5f, 0x88, 0xf6, 0x8a, 0x65, 0x14, 0x78, 0x42, 0xe1, 0xaf, 0xf3, 0x1f, 0x77, 0x62, - 0xa5, 0x7f, 0xf6, 0xdb, 0x1f, 0x92, 0xf5, 0xc9, 0xf7, 0x37, 0xa7, 0x4b, 0x9e, 0x2c, 0xf5, 0x3f, - 0x30, 0xed, 0xfb, 0x2a, 0x41, 0x62, 0x63, 0x8b, 0x40, 0xf5, 0xbb, 0x04, 0xc6, 0x8b, 0x04, 0x6d, - 0x63, 0x7b, 0xc7, 0x1e, 0xca, 0x6c, 0x1e, 0x8c, 0x19, 0x3c, 0x12, 0x69, 0xd7, 0x03, 0xfe, 0x29, - 0xc3, 0x32, 0xf8, 0xd7, 0xb3, 0xe6, 0xfb, 0x2d, 0x83, 0xf9, 0x22, 0x41, 0xbb, 0x75, 0x5a, 0xab, - 0x3a, 0xc6, 0xe1, 0x8e, 0x15, 0x24, 0x18, 0xa6, 0x03, 0xa1, 0xa2, 0xf7, 0xc0, 0x42, 0x9f, 0x02, - 0xbe, 0x8e, 0x2a, 0x6b, 0xfb, 0xae, 0x81, 0xa0, 0x33, 0x54, 0xdb, 0x6f, 0x81, 0x04, 0xad, 0x9b, - 0x7b, 0x90, 0xf2, 0xae, 0x97, 0xc4, 0x5d, 0x48, 0xcc, 0x36, 0xeb, 0x00, 0xab, 0xe2, 0x55, 0x96, - 0x9f, 0x81, 0x71, 0x47, 0x5c, 0xb3, 0x72, 0x13, 0xf9, 0xc5, 0x70, 0xd7, 0x2b, 0x90, 0x6a, 0xe1, - 0xbc, 0x92, 0x9f, 0xa5, 0x6e, 0x82, 0xa9, 0x22, 0x41, 0x2f, 0xdd, 0x39, 0xdc, 0x80, 0x36, 0x26, - 0x75, 0x2a, 0xe7, 0x41, 0xbc, 0x41, 0x90, 0xe0, 0xcb, 0x84, 0xf9, 0xd8, 0xc8, 0xba, 0x8c, 0x02, - 0x5e, 0x72, 0xc1, 0x6a, 0x19, 0xcc, 0x86, 0x68, 0x7c, 0x8d, 0x1b, 0x1d, 0x1a, 0xb3, 0x91, 0x9c, - 0x9d, 0x3a, 0xb7, 0x98, 0x7b, 0x56, 0xc0, 0x7b, 0x1f, 0xf2, 0x6a, 0xbb, 0xd0, 0xbb, 0x3d, 0x49, - 0x3d, 0x3c, 0x57, 0x6a, 0x80, 0x54, 0x98, 0xc8, 0x97, 0xba, 0xd9, 0x21, 0xf5, 0x61, 0x34, 0x6b, - 0xa7, 0xd6, 0x33, 0x89, 0x35, 0x75, 0xc7, 0xae, 0x1a, 0x14, 0xbe, 0x66, 0xfb, 0x48, 0x5e, 0x03, - 0x49, 0xa3, 0x49, 0x6b, 0xd8, 0xa9, 0xd3, 0xe3, 0xc8, 0x2f, 0xa3, 0x05, 0x95, 0x37, 0x40, 0x82, - 0x6f, 0x34, 0xf6, 0x6d, 0x74, 0xb1, 0xd9, 0x36, 0x55, 0xbc, 0x54, 0x21, 0xe9, 0x8e, 0xd3, 0xa7, - 0x9b, 0xd3, 0x25, 0xa9, 0x24, 0x72, 0xd7, 0x17, 0x2e, 0xcf, 0x72, 0xd3, 0x04, 0xc1, 0x9c, 0xc8, - 0xcc, 0xac, 0x68, 0x4f, 0xb4, 0x15, 0xf7, 0xf3, 0x6a, 0x95, 0x52, 0x1f, 0xb3, 0x77, 0xd8, 0xae, - 0xda, 0xf3, 0xb6, 0xfe, 0x7f, 0xd7, 0xfc, 0xfc, 0xe7, 0x04, 0x88, 0x17, 0x09, 0x92, 0x0d, 0x90, - 0x10, 0x2b, 0x76, 0xb1, 0x8f, 0x3c, 0x7f, 0x61, 0x29, 0x8f, 0x06, 0x41, 0xf9, 0xe3, 0x15, 0x3f, - 0x19, 0x91, 0xe4, 0x77, 0x60, 0x94, 0xef, 0xb5, 0x85, 0xfe, 0xb9, 0x0c, 0xa4, 0x2c, 0x0f, 0x00, - 0x0a, 0xf2, 0x7f, 0x94, 0x40, 0xaa, 0xe7, 0x26, 0x59, 0xeb, 0x4f, 0xd7, 0x2b, 0x4f, 0x79, 0x3a, - 0x5c, 0x5e, 0x87, 0x73, 0xbe, 0x5a, 0x22, 0x9c, 0x33, 0x50, 0x94, 0xf3, 0xc0, 0x1a, 0xe0, 0xfc, - 0x04, 0x4c, 0x06, 0xc6, 0x7f, 0xa9, 0x3f, 0x43, 0x3b, 0x56, 0xc9, 0x0f, 0x8e, 0x0d, 0x16, 0x3d, - 0x00, 0x7f, 0x07, 0x67, 0x79, 0x79, 0x00, 0x26, 0x0f, 0xac, 0xac, 0xfe, 0x06, 0x38, 0x58, 0xf7, - 0x44, 0x02, 0x93, 0x81, 0xb9, 0x8c, 0x70, 0xdb, 0x8e, 0x8d, 0x72, 0xdb, 0x6d, 0x72, 0xd4, 0xd4, - 0x97, 0x6e, 0x93, 0x73, 0x32, 0x22, 0x15, 0xb6, 0xce, 0xaf, 0xd2, 0xd2, 0xc5, 0x55, 0x5a, 0xfa, - 0x79, 0x95, 0x96, 0x3e, 0x5c, 0xa7, 0x63, 0x17, 0xd7, 0xe9, 0xd8, 0xb7, 0xeb, 0x74, 0xec, 0x6d, - 0x0e, 0xd5, 0x69, 0xad, 0x59, 0xd1, 0x4c, 0xdc, 0xd0, 0xdb, 0x52, 0xd9, 0x49, 0xe7, 0x28, 0x70, - 0xd8, 0x3b, 0xb6, 0x21, 0xa9, 0x24, 0xd8, 0x59, 0x67, 0xf5, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, - 0x56, 0xbd, 0x4e, 0x9a, 0x16, 0x0a, 0x00, 0x00, + proto.RegisterFile("sge/legacy/subaccount/v1beta/tx.proto", fileDescriptor_515b75d22188f78f) +} + +var fileDescriptor_515b75d22188f78f = []byte{ + // 805 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0xcf, 0x4f, 0xdb, 0x48, + 0x14, 0x8e, 0xc9, 0x12, 0xc8, 0xc0, 0x2e, 0x8b, 0x97, 0x5d, 0xb2, 0xde, 0x55, 0x1a, 0x85, 0x52, + 0x28, 0x34, 0x76, 0x93, 0x16, 0xaa, 0x72, 0x23, 0x54, 0x02, 0x55, 0x4d, 0x55, 0xa5, 0x45, 0x48, + 0x5c, 0x90, 0x7f, 0x8c, 0x26, 0x11, 0x89, 0xc7, 0xf2, 0x4c, 0x80, 0x48, 0x3d, 0xf5, 0xc4, 0xa9, + 0xea, 0x3f, 0xd0, 0x7b, 0x8f, 0x1c, 0x90, 0xfa, 0x2f, 0xa0, 0x9e, 0x10, 0xa7, 0x56, 0xaa, 0xaa, + 0x0a, 0x2a, 0xf1, 0x6f, 0x54, 0x9e, 0xb1, 0x8d, 0x1d, 0x87, 0x38, 0xe4, 0xd0, 0x4b, 0x32, 0xf6, + 0x7c, 0xdf, 0x7b, 0xdf, 0xfb, 0x66, 0xde, 0x93, 0xc1, 0x2c, 0x41, 0x50, 0x69, 0x40, 0xa4, 0xea, + 0x6d, 0x85, 0xb4, 0x34, 0x55, 0xd7, 0x71, 0xcb, 0xa4, 0xca, 0x5e, 0x51, 0x83, 0x54, 0x55, 0xe8, + 0x81, 0x6c, 0xd9, 0x98, 0x62, 0xf1, 0x7f, 0x82, 0xa0, 0xcc, 0x61, 0xf2, 0x15, 0x4c, 0xe6, 0x30, + 0x69, 0x52, 0x6d, 0xd6, 0x4d, 0xac, 0xb0, 0x5f, 0x4e, 0x90, 0xa6, 0x75, 0x4c, 0x9a, 0x98, 0x28, + 0x4d, 0x82, 0x94, 0xbd, 0xa2, 0xf3, 0xe7, 0x6e, 0xfc, 0xcb, 0x37, 0x76, 0xd8, 0x93, 0xc2, 0x1f, + 0xdc, 0xad, 0x29, 0x84, 0x11, 0xe6, 0xef, 0x9d, 0x95, 0xfb, 0x36, 0x1b, 0x50, 0xa8, 0xc1, 0x88, + 0x34, 0x29, 0x17, 0xd8, 0xaf, 0xe1, 0x16, 0x81, 0x11, 0xc4, 0x42, 0xcf, 0x1a, 0x35, 0xb5, 0xa1, + 0x9a, 0x3a, 0x74, 0xb1, 0x77, 0x7b, 0x62, 0x2d, 0xd5, 0x56, 0x9b, 0xae, 0xdc, 0xfc, 0x17, 0x01, + 0xa4, 0x2b, 0x04, 0xad, 0xd9, 0x50, 0xa5, 0x50, 0x2c, 0x81, 0x11, 0xdd, 0x59, 0x61, 0x3b, 0x23, + 0xe4, 0x84, 0xf9, 0x74, 0x39, 0x73, 0x76, 0x5c, 0x98, 0x72, 0xeb, 0x5b, 0x35, 0x0c, 0x1b, 0x12, + 0xf2, 0x92, 0xda, 0x75, 0x13, 0x55, 0x3d, 0xa0, 0x28, 0x83, 0x61, 0xbc, 0x6f, 0x42, 0x3b, 0x33, + 0x14, 0xc3, 0xe0, 0x30, 0x71, 0x1b, 0x4c, 0x34, 0xb0, 0xbe, 0x0b, 0x8d, 0x1d, 0x57, 0x34, 0xc9, + 0x24, 0x73, 0xc9, 0xf9, 0xb1, 0xd2, 0xa2, 0xdc, 0xeb, 0x7c, 0xe4, 0x67, 0x8c, 0x54, 0xe6, 0x9c, + 0xf2, 0x6f, 0x27, 0xdf, 0x6e, 0x25, 0xaa, 0x7f, 0x34, 0x82, 0x2f, 0xc9, 0xca, 0xf8, 0x9b, 0xcb, + 0xa3, 0x05, 0x4f, 0x59, 0xfe, 0x2f, 0x30, 0xe9, 0x97, 0x56, 0x85, 0xc4, 0xc2, 0x26, 0x81, 0xf9, + 0xaf, 0x02, 0x18, 0xad, 0x10, 0xf4, 0x0a, 0x5b, 0x9b, 0xd6, 0x40, 0xf5, 0x96, 0xc0, 0x88, 0xca, + 0x77, 0x62, 0x2b, 0xf6, 0x80, 0xbf, 0xb0, 0x66, 0x11, 0xfc, 0xe9, 0x55, 0xe7, 0x97, 0xbc, 0x03, + 0xfe, 0xab, 0x10, 0xb4, 0x55, 0xa7, 0x35, 0xc3, 0x56, 0xf7, 0x37, 0xcd, 0x70, 0x80, 0x41, 0x4c, + 0xe8, 0x48, 0x3a, 0x0b, 0x66, 0x7a, 0x24, 0xf0, 0x75, 0x18, 0xcc, 0xf9, 0x2d, 0x15, 0x41, 0x7b, + 0x20, 0xe7, 0xff, 0x01, 0x29, 0x5a, 0xd7, 0x77, 0x21, 0xe5, 0xc6, 0x57, 0xdd, 0xa7, 0x0e, 0x31, + 0x5b, 0xcc, 0x01, 0x96, 0xc5, 0xcb, 0x2c, 0xae, 0x81, 0x51, 0xdb, 0x5d, 0xb3, 0x74, 0x63, 0xa5, + 0xb9, 0xa0, 0xf1, 0x1a, 0xf4, 0x1d, 0xef, 0xa4, 0x56, 0x7d, 0x62, 0x7e, 0x03, 0x4c, 0x54, 0x08, + 0xda, 0x70, 0xba, 0xf3, 0x09, 0xb4, 0x30, 0xa9, 0x53, 0x71, 0x09, 0x24, 0x9b, 0x04, 0xb9, 0x21, + 0x67, 0x82, 0x21, 0x59, 0x13, 0x07, 0x82, 0xba, 0x8c, 0xaa, 0x83, 0xcf, 0x6b, 0x60, 0xba, 0x23, + 0x92, 0xaf, 0x74, 0x3d, 0xa2, 0x74, 0xb1, 0x9f, 0xb0, 0x51, 0xb5, 0x4f, 0x99, 0x0d, 0x2c, 0x87, + 0x77, 0x30, 0xe2, 0x72, 0x50, 0xee, 0xed, 0x5e, 0x71, 0x3d, 0x0a, 0xd7, 0x6b, 0x80, 0x4c, 0x67, + 0x2c, 0x5f, 0xf0, 0x46, 0x44, 0xf0, 0xbd, 0xbe, 0x02, 0x47, 0x15, 0x7f, 0x14, 0x98, 0xc1, 0x9b, + 0x96, 0xa1, 0x52, 0xf8, 0x82, 0x0d, 0x29, 0x71, 0x19, 0xa4, 0xd5, 0x16, 0xad, 0x61, 0xbb, 0x4e, + 0xdb, 0xb1, 0x17, 0xe5, 0x0a, 0x2a, 0xae, 0x83, 0x14, 0x1f, 0x73, 0xec, 0xaa, 0x74, 0x14, 0x1b, + 0xed, 0x33, 0x9e, 0xad, 0x9c, 0x76, 0x1a, 0xec, 0xc3, 0xe5, 0xd1, 0x82, 0x50, 0x75, 0xe9, 0x2b, + 0x33, 0x67, 0xc7, 0x85, 0x49, 0x82, 0x60, 0xc1, 0x84, 0x74, 0x1f, 0xdb, 0xbb, 0xb9, 0xa2, 0xfc, + 0x48, 0x2e, 0x3a, 0x17, 0xee, 0x2a, 0x5b, 0xfe, 0x3e, 0x3b, 0xcf, 0xa0, 0x70, 0xaf, 0xbc, 0x95, + 0xbf, 0xbb, 0xf2, 0x4b, 0x3f, 0x52, 0x20, 0x59, 0x21, 0x48, 0x44, 0x20, 0xe5, 0x8e, 0xde, 0xb9, + 0xde, 0x0a, 0xfd, 0x41, 0x26, 0x29, 0x7d, 0x02, 0xfd, 0xb6, 0x4b, 0x1e, 0x0e, 0x09, 0xa2, 0x01, + 0x86, 0xf9, 0xc8, 0xbb, 0x13, 0x4b, 0x67, 0x38, 0x49, 0xee, 0x0f, 0x17, 0xce, 0xf2, 0x5e, 0x00, + 0x99, 0x6b, 0xe7, 0xcc, 0xe3, 0xd8, 0x88, 0xd7, 0x51, 0xa5, 0xd5, 0x81, 0xa9, 0x11, 0x17, 0xf8, + 0xf8, 0x89, 0x77, 0x81, 0xe1, 0xfa, 0x70, 0x21, 0x34, 0x2d, 0x78, 0x96, 0x36, 0x18, 0x0f, 0x4d, + 0x89, 0x42, 0x6c, 0x90, 0x20, 0x5c, 0x5a, 0xba, 0x11, 0x3c, 0x9c, 0xfa, 0x35, 0xf8, 0x3d, 0xdc, + 0xf2, 0x72, 0x7f, 0xc1, 0x3c, 0xbc, 0xb4, 0x7c, 0x33, 0x7c, 0x38, 0xfb, 0x5b, 0x01, 0x8c, 0x87, + 0xda, 0x37, 0xbe, 0xf2, 0x20, 0xbc, 0x8f, 0xca, 0xbb, 0xf5, 0x58, 0x3e, 0xf3, 0xa9, 0x5b, 0x8f, + 0x1d, 0x0e, 0x09, 0xe5, 0xe7, 0x27, 0xe7, 0x59, 0xe1, 0xf4, 0x3c, 0x2b, 0x7c, 0x3f, 0xcf, 0x0a, + 0xef, 0x2e, 0xb2, 0x89, 0xd3, 0x8b, 0x6c, 0xe2, 0xf3, 0x45, 0x36, 0xb1, 0xfd, 0x10, 0xd5, 0x69, + 0xad, 0xa5, 0xc9, 0x3a, 0x6e, 0x2a, 0x01, 0xaa, 0xb3, 0x56, 0x0e, 0xba, 0x7c, 0x3b, 0xd1, 0xb6, + 0x05, 0x89, 0x96, 0x62, 0x1f, 0x4d, 0x0f, 0x7e, 0x06, 0x00, 0x00, 0xff, 0xff, 0x8d, 0x46, 0x44, + 0x2f, 0x71, 0x0a, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -820,7 +821,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { // Deprecated: Do not use. func (c *msgClient) Create(ctx context.Context, in *MsgCreate, opts ...grpc.CallOption) (*MsgCreateResponse, error) { out := new(MsgCreateResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Msg/Create", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Msg/Create", in, out, opts...) if err != nil { return nil, err } @@ -830,7 +831,7 @@ func (c *msgClient) Create(ctx context.Context, in *MsgCreate, opts ...grpc.Call // Deprecated: Do not use. func (c *msgClient) TopUp(ctx context.Context, in *MsgTopUp, opts ...grpc.CallOption) (*MsgTopUpResponse, error) { out := new(MsgTopUpResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Msg/TopUp", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Msg/TopUp", in, out, opts...) if err != nil { return nil, err } @@ -840,7 +841,7 @@ func (c *msgClient) TopUp(ctx context.Context, in *MsgTopUp, opts ...grpc.CallOp // Deprecated: Do not use. func (c *msgClient) WithdrawUnlockedBalances(ctx context.Context, in *MsgWithdrawUnlockedBalances, opts ...grpc.CallOption) (*MsgWithdrawUnlockedBalancesResponse, error) { out := new(MsgWithdrawUnlockedBalancesResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Msg/WithdrawUnlockedBalances", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Msg/WithdrawUnlockedBalances", in, out, opts...) if err != nil { return nil, err } @@ -850,7 +851,7 @@ func (c *msgClient) WithdrawUnlockedBalances(ctx context.Context, in *MsgWithdra // Deprecated: Do not use. func (c *msgClient) Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOption) (*MsgWagerResponse, error) { out := new(MsgWagerResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Msg/Wager", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Msg/Wager", in, out, opts...) if err != nil { return nil, err } @@ -860,7 +861,7 @@ func (c *msgClient) Wager(ctx context.Context, in *MsgWager, opts ...grpc.CallOp // Deprecated: Do not use. func (c *msgClient) HouseDeposit(ctx context.Context, in *MsgHouseDeposit, opts ...grpc.CallOption) (*MsgHouseDepositResponse, error) { out := new(MsgHouseDepositResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Msg/HouseDeposit", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Msg/HouseDeposit", in, out, opts...) if err != nil { return nil, err } @@ -870,7 +871,7 @@ func (c *msgClient) HouseDeposit(ctx context.Context, in *MsgHouseDeposit, opts // Deprecated: Do not use. func (c *msgClient) HouseWithdraw(ctx context.Context, in *MsgHouseWithdraw, opts ...grpc.CallOption) (*MsgHouseWithdrawResponse, error) { out := new(MsgHouseWithdrawResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Msg/HouseWithdraw", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Msg/HouseWithdraw", in, out, opts...) if err != nil { return nil, err } @@ -880,7 +881,7 @@ func (c *msgClient) HouseWithdraw(ctx context.Context, in *MsgHouseWithdraw, opt // Deprecated: Do not use. func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.subaccount.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.legacy.subaccount.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -948,7 +949,7 @@ func _Msg_Create_Handler(srv interface{}, ctx context.Context, dec func(interfac } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Msg/Create", + FullMethod: "/sge.legacy.subaccount.v1beta.Msg/Create", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Create(ctx, req.(*MsgCreate)) @@ -966,7 +967,7 @@ func _Msg_TopUp_Handler(srv interface{}, ctx context.Context, dec func(interface } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Msg/TopUp", + FullMethod: "/sge.legacy.subaccount.v1beta.Msg/TopUp", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).TopUp(ctx, req.(*MsgTopUp)) @@ -984,7 +985,7 @@ func _Msg_WithdrawUnlockedBalances_Handler(srv interface{}, ctx context.Context, } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Msg/WithdrawUnlockedBalances", + FullMethod: "/sge.legacy.subaccount.v1beta.Msg/WithdrawUnlockedBalances", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).WithdrawUnlockedBalances(ctx, req.(*MsgWithdrawUnlockedBalances)) @@ -1002,7 +1003,7 @@ func _Msg_Wager_Handler(srv interface{}, ctx context.Context, dec func(interface } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Msg/Wager", + FullMethod: "/sge.legacy.subaccount.v1beta.Msg/Wager", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Wager(ctx, req.(*MsgWager)) @@ -1020,7 +1021,7 @@ func _Msg_HouseDeposit_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Msg/HouseDeposit", + FullMethod: "/sge.legacy.subaccount.v1beta.Msg/HouseDeposit", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).HouseDeposit(ctx, req.(*MsgHouseDeposit)) @@ -1038,7 +1039,7 @@ func _Msg_HouseWithdraw_Handler(srv interface{}, ctx context.Context, dec func(i } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Msg/HouseWithdraw", + FullMethod: "/sge.legacy.subaccount.v1beta.Msg/HouseWithdraw", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).HouseWithdraw(ctx, req.(*MsgHouseWithdraw)) @@ -1056,7 +1057,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.subaccount.Msg/UpdateParams", + FullMethod: "/sge.legacy.subaccount.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -1064,8 +1065,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.subaccount.Msg", + ServiceName: "sge.legacy.subaccount.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -1098,7 +1100,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/subaccount/tx.proto", + Metadata: "sge/legacy/subaccount/v1beta/tx.proto", } func (m *MsgCreate) Marshal() (dAtA []byte, err error) { diff --git a/x/market/client/cli/query_market_test.go b/x/market/client/cli/query_market_test.go deleted file mode 100644 index 2b453546..00000000 --- a/x/market/client/cli/query_market_test.go +++ /dev/null @@ -1,95 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - tmcli "github.com/cometbft/cometbft/libs/cli" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/market/client/cli" - "github.com/sge-network/sge/x/market/types" -) - -func networkWithMarketObjects(t *testing.T, n int) (*network.Network, []types.Market) { - t.Helper() - cfg := network.DefaultConfig() - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - market := types.Market{ - UID: cast.ToString(i), - WinnerOddsUIDs: []string{}, - } - nullify.Fill(&market) - state.MarketList = append(state.MarketList, market) - } - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - return network.New(t, cfg), state.MarketList -} - -func TestQueryMarketCLI(t *testing.T) { - net, objs := networkWithMarketObjects(t, 5) - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - - t.Run("ShowMarket", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - for _, tc := range []struct { - desc string - idUID string - - args []string - err error - obj types.Market - }{ - { - desc: "found", - idUID: objs[0].UID, - - args: common, - obj: objs[0], - }, - { - desc: "not found", - idUID: cast.ToString(100000), - - args: common, - err: status.Error(codes.NotFound, "not found"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.idUID, - } - args = append(args, tc.args...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdGetMarket(), args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.ErrorIs(t, stat.Err(), tc.err) - } else { - require.NoError(t, err) - var resp types.QueryMarketResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NotNil(t, resp.Market) - require.Equal(t, - nullify.Fill(&tc.obj), - nullify.Fill(&resp.Market), - ) - } - }) - } - }) -} diff --git a/x/market/client/cli/query_params_test.go b/x/market/client/cli/query_params_test.go deleted file mode 100644 index a3f331e5..00000000 --- a/x/market/client/cli/query_params_test.go +++ /dev/null @@ -1,53 +0,0 @@ -package cli_test - -import ( - "encoding/json" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/market/client/cli" - "github.com/sge-network/sge/x/market/types" -) - -func TestQueryParams(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdQueryParams(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - var params types.QueryParamsResponse - err = json.Unmarshal(res.Bytes(), ¶ms) - require.NoError(t, err) - - defaultParams := types.DefaultParams() - require.Equal(t, types.QueryParamsResponse{ - Params: defaultParams, - }, params) - }) - } -} diff --git a/x/market/client/cli/query_test.go b/x/market/client/cli/query_test.go deleted file mode 100644 index 65b3074b..00000000 --- a/x/market/client/cli/query_test.go +++ /dev/null @@ -1,48 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/market/client/cli" -) - -func TestGetQueryCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetQueryCmd(""), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True( - t, - strings.HasPrefix(string(res.Bytes()), "Querying commands for the market module"), - ) - }) - } -} diff --git a/x/market/client/cli/tx_test.go b/x/market/client/cli/tx_test.go deleted file mode 100644 index 5381358c..00000000 --- a/x/market/client/cli/tx_test.go +++ /dev/null @@ -1,45 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - "github.com/sge-network/sge/testutil/network" - - "github.com/sge-network/sge/x/market/client/cli" -) - -func TestGetTxCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetTxCmd(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True(t, strings.HasPrefix(string(res.Bytes()), "market transactions subcommands")) - }) - } -} diff --git a/x/market/genesis_test.go b/x/market/genesis_test.go deleted file mode 100644 index 52dd23a0..00000000 --- a/x/market/genesis_test.go +++ /dev/null @@ -1,39 +0,0 @@ -package market_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - market "github.com/sge-network/sge/x/market" - "github.com/sge-network/sge/x/market/types" -) - -func TestGenesis(t *testing.T) { - genesisState := types.GenesisState{ - Params: types.DefaultParams(), - - MarketList: []types.Market{ - { - UID: "0", - }, - { - UID: "1", - }, - }, - } - - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - market.InitGenesis(ctx, *tApp.MarketKeeper, genesisState) - got := market.ExportGenesis(ctx, *tApp.MarketKeeper) - require.NotNil(t, got) - - nullify.Fill(&genesisState) - nullify.Fill(got) - - require.ElementsMatch(t, genesisState.MarketList, got.MarketList) -} diff --git a/x/market/handler.go b/x/market/handler.go deleted file mode 100644 index 0e5139e5..00000000 --- a/x/market/handler.go +++ /dev/null @@ -1,41 +0,0 @@ -package market - -import ( - "fmt" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/x/market/keeper" - "github.com/sge-network/sge/x/market/types" -) - -// NewHandler ... -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - _ = ctx - - switch msg := msg.(type) { - case *types.MsgAdd: - res, err := msgServer.Add(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgResolve: - res, err := msgServer.Resolve(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdate: - res, err := msgServer.Update(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdateParams: - res, err := msgServer.UpdateParams(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrtypes.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/market/keeper/grpc_query_market_test.go b/x/market/keeper/grpc_query_market_test.go deleted file mode 100644 index c7e2cbfb..00000000 --- a/x/market/keeper/grpc_query_market_test.go +++ /dev/null @@ -1,67 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/market/types" -) - -func TestMarketQuerySingle(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNMarket(k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryMarketRequest - response *types.QueryMarketResponse - err error - }{ - { - desc: "First", - request: &types.QueryMarketRequest{ - Uid: msgs[0].UID, - }, - response: &types.QueryMarketResponse{Market: msgs[0]}, - }, - { - desc: "Second", - request: &types.QueryMarketRequest{ - Uid: msgs[1].UID, - }, - response: &types.QueryMarketResponse{Market: msgs[1]}, - }, - { - desc: "KeyNotFound", - request: &types.QueryMarketRequest{ - Uid: cast.ToString(100000), - }, - err: status.Error(codes.NotFound, "not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.Market(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} diff --git a/x/market/keeper/grpc_query_params_test.go b/x/market/keeper/grpc_query_params_test.go deleted file mode 100644 index 5d8ec98a..00000000 --- a/x/market/keeper/grpc_query_params_test.go +++ /dev/null @@ -1,33 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/market/types" -) - -func TestParamsQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - t.Run("Success", func(t *testing.T) { - response, err := k.Params(wctx, &types.QueryParamsRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryParamsResponse{Params: params}, response) - }) - - t.Run("Failed", func(t *testing.T) { - response, err := k.Params(wctx, nil) - require.Equal(t, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), err) - require.Nil(t, response) - }) -} diff --git a/x/market/keeper/keeper_test.go b/x/market/keeper/keeper_test.go deleted file mode 100644 index 9e41d9a8..00000000 --- a/x/market/keeper/keeper_test.go +++ /dev/null @@ -1,33 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/market/keeper" -) - -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp, tApp.MarketKeeper, ctx.WithBlockTime(time.Now()) -} - -func setupKeeper(t testing.TB) (*keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp.MarketKeeper, ctx -} - -func createJwtTicket(claim jwt.MapClaims) (string, error) { - token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, claim) - return token.SignedString(simapp.TestOVMPrivateKeys[0]) -} diff --git a/x/market/keeper/market_test.go b/x/market/keeper/market_test.go deleted file mode 100644 index d1163208..00000000 --- a/x/market/keeper/market_test.go +++ /dev/null @@ -1,117 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/market/keeper" - "github.com/sge-network/sge/x/market/types" -) - -func createNMarket(keeper *keeper.Keeper, ctx sdk.Context, n int) []types.Market { - items := make([]types.Market, n) - for i := range items { - items[i].UID = cast.ToString(i) - - keeper.SetMarket(ctx, items[i]) - } - return items -} - -func TestMarketGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNMarket(k, ctx, 10) - _, found := k.GetMarket(ctx, - "NotExistUid", - ) - require.False(t, found) - - for _, item := range items { - rst, found := k.GetMarket(ctx, - item.UID, - ) - require.True(t, found) - require.EqualValues(t, item, rst) - } -} - -func TestGetMarket(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNMarket(k, ctx, 10) - - rst, found := k.GetMarket(ctx, "NotExistUid") - require.False(t, found) - require.Equal(t, rst.UID, "") - - for _, item := range items { - rst, found := k.GetMarket(ctx, - item.UID, - ) - require.True(t, found) - require.Equal(t, - nullify.Fill(item), - nullify.Fill(rst), - ) - } -} - -func TestMarketGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNMarket(k, ctx, 10) - - markets, err := k.GetMarkets(ctx) - require.NoError(t, err) - - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(markets), - ) -} - -func TestResolveMarkets(t *testing.T) { - t.Run("Success", func(t *testing.T) { - k, ctx := setupKeeper(t) - - item := types.Market{ - UID: "uid", - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - } - k.SetMarket(ctx, item) - - resMarketsIn := types.MarketResolutionTicketPayload{ - UID: item.UID, - ResolutionTS: 123456, - WinnerOddsUIDs: []string{"oddsUID1", "oddsUID2"}, - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - } - k.Resolve(ctx, item, &resMarketsIn) - val, found := k.GetMarket(ctx, item.UID) - require.True(t, found) - require.Equal(t, resMarketsIn.ResolutionTS, val.ResolutionTS) - require.Equal(t, resMarketsIn.WinnerOddsUIDs, val.WinnerOddsUIDs) - require.Equal(t, resMarketsIn.Status, val.Status) - }) -} - -func TestMarketExist(t *testing.T) { - t.Run("NotFound", func(t *testing.T) { - k, ctx := setupKeeper(t) - found := k.MarketExists(ctx, "notExistMarketUID") - require.False(t, found) - }) - - t.Run("Found", func(t *testing.T) { - k, ctx := setupKeeper(t) - item := types.Market{ - UID: "uid", - } - k.SetMarket(ctx, item) - found := k.MarketExists(ctx, item.UID) - require.True(t, found) - }) -} diff --git a/x/market/keeper/msg_server_market_resolve_test.go b/x/market/keeper/msg_server_market_resolve_test.go deleted file mode 100644 index cc776b78..00000000 --- a/x/market/keeper/msg_server_market_resolve_test.go +++ /dev/null @@ -1,205 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/market/types" -) - -func TestMsgServerResolve(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - type args struct { - msg *types.MsgResolve - } - - u1 := uuid.NewString() - k.SetMarket(ctx, types.Market{ - UID: u1, - Creator: sample.AccAddress(), - }) - - tests := []struct { - name string - args args - want *types.MsgResolveResponse - wantErr error - }{ - { - name: "test the empty or invalid format ticket", - args: args{ - msg: types.NewMsgResolve(sample.AccAddress(), ""), - }, - want: nil, - wantErr: types.ErrInTicketVerification, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - got, err := msgk.Resolve(wctx, tt.args.msg) - require.ErrorIs(t, err, tt.wantErr) - require.EqualValues(t, got, tt.want) - }) - } -} - -func TestMsgServerResolveMarketResponse(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - u1, u2, u3 := uuid.NewString(), uuid.NewString(), uuid.NewString() - k.SetMarket(ctx, types.Market{ - UID: u1, - Creator: sample.AccAddress(), - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - }) - k.SetMarket(ctx, types.Market{ - UID: u3, - Creator: sample.AccAddress(), - Status: types.MarketStatus_MARKET_STATUS_CANCELED, - }) - - t.Run("invalid uid for the market", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": "invalid uid", - "status": types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - "resolution_ts": uint64(time.Now().Unix()), - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Resolve( - wctx, - types.NewMsgResolve(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrInTicketPayloadValidation) - assert.Nil(t, response) - }) - - t.Run("non existing market", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u2, - "status": types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - "resolution_ts": uint64(time.Now().Unix()), - "winner_odds_uids": []string{uuid.NewString()}, - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Resolve( - wctx, - types.NewMsgResolve(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrMarketNotFound) - assert.Nil(t, response) - }) - - t.Run("non active market resolution", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u3, - "status": types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - "resolution_ts": uint64(time.Now().Unix()), - "winner_odds_uids": []string{uuid.NewString()}, - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Resolve( - wctx, - types.NewMsgResolve(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrMarketResolutionNotAllowed) - assert.Nil(t, response) - }) - - t.Run("invalid winner odds uid", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u1, - "status": types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - "resolution_ts": uint64(time.Now().Unix()), - "winner_odds_uids": []string{"invalidWId"}, - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Resolve( - wctx, - types.NewMsgResolve(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrInTicketPayloadValidation) - assert.Nil(t, response) - }) - - t.Run("lots of winner odds uid", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u1, - "status": types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - "resolution_ts": uint64(time.Now().Unix()), - "winner_odds_uids": []string{uuid.NewString(), uuid.NewString()}, - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Resolve( - wctx, - types.NewMsgResolve(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrInTicketPayloadValidation) - assert.Nil(t, response) - }) - - t.Run("canceled or aborted with winner id", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u1, - "status": types.MarketStatus_MARKET_STATUS_CANCELED, - "resolution_ts": uint64(time.Now().Unix()), - "winner_odds_uids": []string{uuid.NewString()}, - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Resolve( - wctx, - types.NewMsgResolve(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrInTicketPayloadValidation) - assert.Nil(t, response) - }) - - t.Run("invalid winner odds uid, not contained in the parent", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u1, - "status": types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - "resolution_ts": uint64(time.Now().Unix()), - "winner_odds_uids": []string{uuid.NewString()}, - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Resolve( - wctx, - types.NewMsgResolve(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrInvalidWinnerOdds) - assert.Nil(t, response) - }) -} diff --git a/x/market/keeper/msg_server_market_test.go b/x/market/keeper/msg_server_market_test.go deleted file mode 100644 index fe12ace0..00000000 --- a/x/market/keeper/msg_server_market_test.go +++ /dev/null @@ -1,189 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/market/types" -) - -func TestMsgServerAdd(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - type args struct { - msg *types.MsgAdd - } - - u1 := uuid.NewString() - k.SetMarket(ctx, types.Market{ - UID: u1, - Creator: sample.AccAddress(), - }) - - tests := []struct { - name string - args args - want *types.MsgAddResponse - wantErr error - }{ - { - name: "test the empty or invalid format ticket", - args: args{ - msg: types.NewMsgAdd(sample.AccAddress(), ""), - }, - want: nil, - wantErr: types.ErrInTicketVerification, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - got, err := msgk.Add(wctx, tt.args.msg) - require.ErrorIs(t, err, tt.wantErr) - require.EqualValues(t, got, tt.want) - }) - } -} - -func TestMsgServerAddMarketResponse(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - u1 := uuid.NewString() - k.SetMarket(ctx, types.Market{ - UID: u1, - Creator: sample.AccAddress(), - }) - - t.Run("Error in ticket fields validation", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": "invalid uid", - "start_ts": uint64(time.Now().Add(time.Minute).Unix()), - "end_ts": uint64(time.Now().Add(time.Minute * 5).Unix()), - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Add( - wctx, - types.NewMsgAdd(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrInTicketPayloadValidation) - assert.Nil(t, response) - }) - - t.Run("pre existing uid", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u1, - "start_ts": uint64(time.Now().Add(time.Minute).Unix()), - "end_ts": uint64(time.Now().Add(time.Minute * 5).Unix()), - "odds": []types.Odds{ - {UID: uuid.NewString(), Meta: "odds 1"}, - {UID: uuid.NewString(), Meta: "odds 2"}, - }, - "exp": 9999999999, - "iat": 1111111111, - "meta": "Winner of x:y", - "status": types.MarketStatus_MARKET_STATUS_ACTIVE, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Add( - wctx, - types.NewMsgAdd(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrMarketAlreadyExist) - assert.Nil(t, response) - }) -} - -func TestMsgServerUpdate(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - type args struct { - msg *types.MsgUpdate - } - - u1 := uuid.NewString() - k.SetMarket(ctx, types.Market{ - UID: u1, - Creator: sample.AccAddress(), - }) - - tests := []struct { - name string - args args - want *types.MsgUpdateResponse - wantErr error - }{ - { - name: "test the empty or invalid format ticket", - args: args{ - msg: types.NewMsgUpdate(sample.AccAddress(), ""), - }, - want: nil, - wantErr: types.ErrInTicketVerification, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - got, err := msgk.Update(wctx, tt.args.msg) - require.ErrorIs(t, err, tt.wantErr) - require.EqualValues(t, got, tt.want) - }) - } -} - -func TestMsgServerUpdateMarketResponse(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - u1, u2, u3 := uuid.NewString(), uuid.NewString(), uuid.NewString() - k.SetMarket(ctx, types.Market{ - UID: u1, - Creator: sample.AccAddress(), - }) - k.SetMarket(ctx, types.Market{ - UID: u2, - Creator: sample.AccAddress(), - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - - t.Run("invalid Market id", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "UID": u3, - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Update( - wctx, - types.NewMsgUpdate(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrMarketNotFound) - assert.Nil(t, response) - }) - t.Run("updating an declared market", func(t *testing.T) { - validEmptyTicketClaims := jwt.MapClaims{ - "uid": u2, - "start_ts": uint64(time.Now().UnixNano()), - "end_ts": uint64(time.Now().Add(time.Hour).UnixNano()), - "exp": 9999999999, - "iat": 1111111111, - } - validEmptyTicket, err := createJwtTicket(validEmptyTicketClaims) - require.NoError(t, err) - - response, err := msgk.Update( - wctx, - types.NewMsgUpdate(sample.AccAddress(), validEmptyTicket), - ) - assert.ErrorIs(t, err, types.ErrMarketCanNotBeAltered) - assert.Nil(t, response) - }) -} diff --git a/x/market/keeper/msg_server_test.go b/x/market/keeper/msg_server_test.go deleted file mode 100644 index fc2cebd7..00000000 --- a/x/market/keeper/msg_server_test.go +++ /dev/null @@ -1,26 +0,0 @@ -package keeper_test - -import ( - "context" - "testing" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/market/keeper" - "github.com/sge-network/sge/x/market/types" -) - -func setupMsgServerAndKeeper( - t testing.TB, -) (*keeper.KeeperTest, types.MsgServer, sdk.Context, context.Context) { - _, k, msgk, ctx, wctx := setupMsgServerAndApp(t) - return k, msgk, ctx, wctx -} - -func setupMsgServerAndApp( - t testing.TB, -) (*simapp.TestApp, *keeper.KeeperTest, types.MsgServer, sdk.Context, context.Context) { - tApp, k, ctx := setupKeeperAndApp(t) - return tApp, k, keeper.NewMsgServerImpl(*k), ctx, sdk.WrapSDKContext(ctx) -} diff --git a/x/market/keeper/params_test.go b/x/market/keeper/params_test.go deleted file mode 100644 index 9cb8e512..00000000 --- a/x/market/keeper/params_test.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/market/types" -) - -func TestGetParams(t *testing.T) { - k, ctx := setupKeeper(t) - params := types.DefaultParams() - - k.SetParams(ctx, params) - - require.EqualValues(t, params, k.GetParams(ctx)) -} diff --git a/x/market/simulation/decoder_test.go b/x/market/simulation/decoder_test.go deleted file mode 100644 index 0211aeb3..00000000 --- a/x/market/simulation/decoder_test.go +++ /dev/null @@ -1,71 +0,0 @@ -package simulation_test - -import ( - "fmt" - "testing" - "time" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - "github.com/cosmos/cosmos-sdk/types/kv" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/market/simulation" - "github.com/sge-network/sge/x/market/types" -) - -func TestDecodeStore(t *testing.T) { - cdc := app.MakeEncodingConfig().Marshaler - dec := simulation.NewDecodeStore(cdc) - - uID := uuid.NewString() - market := types.NewMarket( - uID, - sample.AccAddress(), - cast.ToUint64(time.Now().UTC()), - cast.ToUint64(time.Now().Add(1*time.Hour).UTC().String()), - []*types.Odds{ - { - UID: uuid.NewString(), - Meta: "custom odds", - }, - }, - "custom metadata", - uID, - types.MarketStatus_MARKET_STATUS_ACTIVE, - ) - - stats := types.MarketStats{ - ResolvedUnsettled: []string{market.UID}, - } - - kvPairs := kv.Pairs{ - Pairs: []kv.Pair{ - {Key: types.MarketKeyPrefix, Value: cdc.MustMarshal(&market)}, - {Key: types.MarketStatsKey, Value: cdc.MustMarshal(&stats)}, - {Key: []byte{0x99}, Value: []byte{0x99}}, - }, - } - tests := []struct { - name string - expectedLog string - }{ - {"market", fmt.Sprintf("%v\n%v", market, market)}, - {"market_stats", fmt.Sprintf("%v\n%v", stats, stats)}, - {"other", ""}, - } - - for i, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - switch i { - case len(tests) - 1: - require.Panics(t, func() { dec(kvPairs.Pairs[i], kvPairs.Pairs[i]) }, tt.name) - default: - require.Equal(t, tt.expectedLog, dec(kvPairs.Pairs[i], kvPairs.Pairs[i]), tt.name) - } - }) - } -} diff --git a/x/market/simulation/genesis_test.go b/x/market/simulation/genesis_test.go deleted file mode 100644 index 1841c6a7..00000000 --- a/x/market/simulation/genesis_test.go +++ /dev/null @@ -1,74 +0,0 @@ -package simulation_test - -import ( - "encoding/json" - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/codec" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/types/module" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - - "github.com/sge-network/sge/x/market/simulation" - "github.com/sge-network/sge/x/market/types" -) - -// TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. -// Abnormal scenarios are not tested here. -func TestRandomizedGenState(_ *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - simState := module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - NumBonded: 3, - Accounts: simtypes.RandomAccounts(r, 3), - InitialStake: sdkmath.NewInt(1000), - GenState: make(map[string]json.RawMessage), - } - - simulation.RandomizedGenState(&simState) - - var marketGenesis types.GenesisState - simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &marketGenesis) -} - -// TestRandomizedGenState tests abnormal scenarios of applying RandomizedGenState. -func TestRandomizedGenState1(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - // all these tests will panic - tests := []struct { - simState module.SimulationState - panicMsg string - }{ - { // panic => reason: incomplete initialization of the simState - module.SimulationState{}, "invalid memory address or nil pointer dereference"}, - { // panic => reason: incomplete initialization of the simState - module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - }, "assignment to entry in nil map"}, - } - - for _, tt := range tests { - simTest := tt.simState - require.Panicsf(t, func() { simulation.RandomizedGenState(&simTest) }, tt.panicMsg) - } -} diff --git a/x/market/simulation/params_test.go b/x/market/simulation/params_test.go deleted file mode 100644 index 86032a4b..00000000 --- a/x/market/simulation/params_test.go +++ /dev/null @@ -1,32 +0,0 @@ -package simulation_test - -import ( - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/market/simulation" -) - -func TestParamChangest(t *testing.T) { - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - expected := []struct { - composedKey string - key string - subspace string - }{} - - paramChanges := simulation.ParamChanges(r) - require.Len(t, paramChanges, 0) - - for i, p := range paramChanges { - require.Equal(t, expected[i].composedKey, p.ComposedKey()) - require.Equal(t, expected[i].key, p.Key()) - require.Equal(t, expected[i].subspace, p.Subspace()) - } -} diff --git a/x/market/simulation/proposals_test.go b/x/market/simulation/proposals_test.go deleted file mode 100644 index 7c57131d..00000000 --- a/x/market/simulation/proposals_test.go +++ /dev/null @@ -1,43 +0,0 @@ -package simulation_test - -import ( - "fmt" - "math/rand" - "testing" - - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/address" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/market/simulation" - "github.com/sge-network/sge/x/market/types" -) - -func TestProposalMsgs(t *testing.T) { - // initialize parameters - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - ctx := sdk.NewContext(nil, tmproto.Header{}, true, nil) - accounts := simtypes.RandomAccounts(r, 3) - - // execute ProposalMsgs function - weightedProposalMsgs := simulation.ProposalMsgs() - require.Equal(t, len(weightedProposalMsgs), 1) - - w0 := weightedProposalMsgs[0] - - // tests w0 interface: - require.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) - require.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) - - msg := w0.MsgSimulatorFn()(r, ctx, accounts) - msgUpdateParams, ok := msg.(*types.MsgUpdateParams) - require.True(t, ok) - - fmt.Println(msgUpdateParams) - require.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) -} diff --git a/x/market/types/message_market_resolve_test.go b/x/market/types/message_market_resolve_test.go deleted file mode 100644 index cdce12fa..00000000 --- a/x/market/types/message_market_resolve_test.go +++ /dev/null @@ -1,67 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/market/types" -) - -func TestMsgResolveValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgResolve - err error - }{ - { - name: "invalid creator", - msg: types.MsgResolve{ - Creator: "invalid_address", - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "valid", - msg: types.MsgResolve{ - Creator: sample.AccAddress(), - Ticket: "Ticket", - }, - }, - { - name: "no ticket", - msg: types.MsgResolve{ - Creator: sample.AccAddress(), - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestNewResolve(t *testing.T) { - t.Run("valid", func(t *testing.T) { - expected := &types.MsgResolve{ - Creator: uuid.NewString(), - Ticket: "Ticket", - } - res := types.NewMsgResolve( - expected.Creator, - expected.Ticket, - ) - require.Equal(t, expected, res) - }) -} diff --git a/x/market/types/message_market_test.go b/x/market/types/message_market_test.go deleted file mode 100644 index f62a0dc5..00000000 --- a/x/market/types/message_market_test.go +++ /dev/null @@ -1,121 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/market/types" -) - -func TestMsgAddValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgAdd - err error - }{ - { - name: "invalid creator", - msg: types.MsgAdd{ - Creator: "invalid_address", - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "valid", - msg: types.MsgAdd{ - Creator: sample.AccAddress(), - Ticket: "Ticket", - }, - }, - { - name: "no ticket", - msg: types.MsgAdd{ - Creator: sample.AccAddress(), - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestNewAdd(t *testing.T) { - t.Run("valid", func(t *testing.T) { - expected := &types.MsgAdd{ - Creator: uuid.NewString(), - Ticket: "Ticket", - } - res := types.NewMsgAdd( - expected.Creator, - expected.Ticket, - ) - require.Equal(t, expected, res) - }) -} - -func TestMsgUpdateValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgUpdate - err error - }{ - { - name: "invalid creator", - msg: types.MsgUpdate{ - Creator: "invalid_address", - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "valid", - msg: types.MsgUpdate{ - Creator: sample.AccAddress(), - Ticket: "Ticket", - }, - }, - { - name: "no ticket", - msg: types.MsgUpdate{ - Creator: sample.AccAddress(), - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestNewUpdate(t *testing.T) { - t.Run("valid", func(t *testing.T) { - expected := &types.MsgUpdate{ - Creator: uuid.NewString(), - Ticket: "Ticket", - } - res := types.NewMsgUpdate( - expected.Creator, - expected.Ticket, - ) - require.Equal(t, expected, res) - }) -} diff --git a/x/market/types/ticket_test.go b/x/market/types/ticket_test.go deleted file mode 100644 index 58fb68e3..00000000 --- a/x/market/types/ticket_test.go +++ /dev/null @@ -1,339 +0,0 @@ -package types_test - -import ( - "testing" - "time" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/market/types" -) - -func TestAddMarketTicketPayloadValidation(t *testing.T) { - _, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - ctx = ctx.WithBlockTime(time.Now()) - - sampleUID := uuid.NewString() - - tests := []struct { - name string - payload types.MarketAddTicketPayload - err error - }{ - { - name: "valid", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: uuid.NewString(), Meta: "odds 1"}, - {UID: uuid.NewString(), Meta: "odds 2"}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "sample market", - }, - }, - { - name: "invalid end time", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Unix()), - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid status", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Status: types.MarketStatus_MARKET_STATUS_UNSPECIFIED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid uuid", - payload: types.MarketAddTicketPayload{ - UID: "invalid uuid", - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid odds count", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: uuid.NewString(), Meta: "odds 1"}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "empty meta", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: uuid.NewString(), Meta: "odds 1"}, - {UID: uuid.NewString(), Meta: "odds 2"}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "large meta", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: uuid.NewString(), Meta: "odds 1"}, - {UID: uuid.NewString(), Meta: "odds 2"}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: simapp.RandomString(types.MaxAllowedCharactersForMeta + 1), - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid odds meta", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: uuid.NewString(), Meta: ""}, - {UID: uuid.NewString(), Meta: "odds 2"}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "sample market", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid odds long meta", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: uuid.NewString(), Meta: simapp.RandomString(types.MaxAllowedCharactersForMeta + 1)}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "sample market", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid odds uuid", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: "invalid uuid", Meta: "odds 1"}, - {UID: uuid.NewString(), Meta: "odds 2"}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "sample market", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "duplicate odds uuid", - payload: types.MarketAddTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Odds: []*types.Odds{ - {UID: sampleUID, Meta: "odds 1"}, - {UID: sampleUID, Meta: "odds 2"}, - }, - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - Meta: "sample market", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.payload.Validate(ctx) - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestUpdateMarketTicketPayloadValidation(t *testing.T) { - _, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - ctx = ctx.WithBlockTime(time.Now()) - - tests := []struct { - name string - payload types.MarketUpdateTicketPayload - err error - }{ - { - name: "valid", - payload: types.MarketUpdateTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Status: types.MarketStatus_MARKET_STATUS_ACTIVE, - }, - }, - { - name: "invalid end time", - payload: types.MarketUpdateTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Unix()), - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid status", - payload: types.MarketUpdateTicketPayload{ - UID: uuid.NewString(), - StartTS: cast.ToUint64(ctx.BlockTime().Unix()), - EndTS: cast.ToUint64(ctx.BlockTime().Add(5 * time.Minute).Unix()), - Status: types.MarketStatus_MARKET_STATUS_UNSPECIFIED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.payload.Validate(ctx) - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestResolveMarketTicketPayloadValidation(t *testing.T) { - _, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - ctx = ctx.WithBlockTime(time.Now()) - - tests := []struct { - name string - payload types.MarketResolutionTicketPayload - err error - }{ - { - name: "valid", - payload: types.MarketResolutionTicketPayload{ - UID: uuid.NewString(), - ResolutionTS: cast.ToUint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - WinnerOddsUIDs: []string{uuid.NewString()}, - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - }, - { - name: "invaid status", - payload: types.MarketResolutionTicketPayload{ - UID: uuid.NewString(), - ResolutionTS: cast.ToUint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - Status: types.MarketStatus_MARKET_STATUS_UNSPECIFIED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "winner set when result not declared", - payload: types.MarketResolutionTicketPayload{ - UID: uuid.NewString(), - ResolutionTS: cast.ToUint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - WinnerOddsUIDs: []string{uuid.NewString()}, - Status: types.MarketStatus_MARKET_STATUS_UNSPECIFIED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "excessive winner odds", - payload: types.MarketResolutionTicketPayload{ - UID: uuid.NewString(), - ResolutionTS: cast.ToUint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - WinnerOddsUIDs: []string{uuid.NewString(), uuid.NewString()}, - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "no resolution time set", - payload: types.MarketResolutionTicketPayload{ - UID: uuid.NewString(), - WinnerOddsUIDs: []string{uuid.NewString()}, - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid uuid", - payload: types.MarketResolutionTicketPayload{ - UID: "invalid uuid", - ResolutionTS: cast.ToUint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - WinnerOddsUIDs: []string{uuid.NewString()}, - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "result declared no winner odds", - payload: types.MarketResolutionTicketPayload{ - UID: uuid.NewString(), - ResolutionTS: cast.ToUint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - WinnerOddsUIDs: []string{}, - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - name: "invalid odds uuid", - payload: types.MarketResolutionTicketPayload{ - UID: uuid.NewString(), - ResolutionTS: cast.ToUint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - WinnerOddsUIDs: []string{"invalid uuid"}, - Status: types.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.payload.Validate() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/mint/abci.go b/x/mint/abci.go index 7ff22cc8..c5cdbf11 100644 --- a/x/mint/abci.go +++ b/x/mint/abci.go @@ -1,6 +1,7 @@ package mint import ( + "context" "time" "github.com/spf13/cast" @@ -17,15 +18,23 @@ import ( var gaugeKeys = []string{"minted_tokens"} // BeginBlocker mints new tokens for the previous block. -func BeginBlocker(ctx sdk.Context, k keeper.Keeper) { +func BeginBlocker(ctx context.Context, k keeper.Keeper) error { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyBeginBlocker) - // fetch stored minter - minter := k.GetMinter(ctx) - + // fetch stored minter & params + minter, err := k.Minter.Get(ctx) + if err != nil { + return err + } // fetch stored params - params := k.GetParams(ctx) - currentBlock := ctx.BlockHeight() + params, err := k.Params.Get(ctx) + if err != nil { + return err + } + + sdkCtx := sdk.UnwrapSDKContext(ctx) + + currentBlock := sdkCtx.BlockHeight() // detect current phase according to current block currentPhase, currentPhaseStep := minter.CurrentPhase(params, currentBlock) @@ -49,31 +58,37 @@ func BeginBlocker(ctx sdk.Context, k keeper.Keeper) { ) // store minter - k.SetMinter(ctx, minter) + err = k.Minter.Set(ctx, minter) + if err != nil { + return err + } } // if the inflation rate is zero, means that we have no minting, so the rest of the code should not be called if minter.Inflation.Equal(sdkmath.LegacyZeroDec()) { - return + return nil } // mint coins, update supply mintedCoin, truncatedTokens := minter.BlockProvisions(params, currentPhaseStep) mintedCoins := sdk.NewCoins(mintedCoin) - err := k.MintCoins(ctx, mintedCoins) + err = k.MintCoins(ctx, mintedCoins) if err != nil { - panic(err) + return err } // set truncated value in this block to be added to provision calculation in the next block minter.TruncatedTokens = truncatedTokens - k.SetMinter(ctx, minter) + err = k.Minter.Set(ctx, minter) + if err != nil { + return err + } // send the minted coins to the fee collector account err = k.AddCollectedFees(ctx, mintedCoins) if err != nil { - panic(err) + return err } if mintedCoin.Amount.IsInt64() { @@ -83,7 +98,7 @@ func BeginBlocker(ctx sdk.Context, k keeper.Keeper) { gaugeKeys...) } - ctx.EventManager().EmitEvent( + sdkCtx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeMint, sdk.NewAttribute(types.AttributeKeyInflation, minter.Inflation.String()), @@ -91,4 +106,6 @@ func BeginBlocker(ctx sdk.Context, k keeper.Keeper) { sdk.NewAttribute(sdk.AttributeKeyAmount, mintedCoin.Amount.String()), ), ) + + return nil } diff --git a/x/mint/autocli.go b/x/mint/autocli.go new file mode 100644 index 00000000..7cac5810 --- /dev/null +++ b/x/mint/autocli.go @@ -0,0 +1,50 @@ +package mint + +import ( + autocliv1 "cosmossdk.io/api/cosmos/autocli/v1" + mintv1beta1 "github.com/sge-network/sge/api/sge/mint/v1beta" +) + +func (am AppModule) AutoCLIOptions() *autocliv1.ModuleOptions { + return &autocliv1.ModuleOptions{ + Query: &autocliv1.ServiceCommandDescriptor{ + Service: mintv1beta1.Query_ServiceDesc.ServiceName, + RpcCommandOptions: []*autocliv1.RpcCommandOptions{ + { + RpcMethod: "Params", + Use: "params", + Short: "Query the current minting parameters", + }, + { + RpcMethod: "Inflation", + Use: "inflation", + Short: "Query the current minting inflation value", + }, + { + RpcMethod: "PhaseProvisions", + Use: "phase-provisions", + Short: "Query the current minting phase provisions value", + }, + { + RpcMethod: "EndPhaseStatus", + Use: "endphase-status", + Short: "Query the current status of end phase", + }, + { + RpcMethod: "PhaseStep", + Use: "phase-step", + Short: "Query the current minting phase step", + }, + }, + }, + Tx: &autocliv1.ServiceCommandDescriptor{ + Service: mintv1beta1.Msg_ServiceDesc.ServiceName, + RpcCommandOptions: []*autocliv1.RpcCommandOptions{ + { + RpcMethod: "UpdateParams", + Skip: true, // skipped because authority gated + }, + }, + }, + } +} diff --git a/x/mint/client/cli/query.go b/x/mint/client/cli/query.go deleted file mode 100644 index 2d16dba1..00000000 --- a/x/mint/client/cli/query.go +++ /dev/null @@ -1,36 +0,0 @@ -package cli - -import ( - "fmt" - - "github.com/spf13/cobra" - - "github.com/cosmos/cosmos-sdk/client" - - "github.com/sge-network/sge/x/mint/types" -) - -// GetQueryCmd returns the cli query commands for this module -func GetQueryCmd(_ string) *cobra.Command { - // Group mint queries under a subcommand - cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf( - "Querying commands for the %s module", - types.ModuleName, - ), - DisableFlagParsing: true, - SuggestionsMinimumDistance: 2, - RunE: client.ValidateCmd, - } - - cmd.AddCommand( - GetCmdQueryParams(), - GetCmdQueryInflation(), - GetCmdQueryPhaseStep(), - GetCmdQueryPhaseProvisions(), - GetCmdQueryEndPhaseStatus(), - ) - - return cmd -} diff --git a/x/mint/client/cli/query_minter.go b/x/mint/client/cli/query_minter.go deleted file mode 100644 index 0a47ce50..00000000 --- a/x/mint/client/cli/query_minter.go +++ /dev/null @@ -1,127 +0,0 @@ -package cli - -import ( - "fmt" - - "github.com/spf13/cobra" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/sge-network/sge/x/mint/types" -) - -// GetCmdQueryInflation implements a command to return the current minting -// inflation value. -func GetCmdQueryInflation() *cobra.Command { - cmd := &cobra.Command{ - Use: "inflation", - Short: "Query the current minting inflation value", - Args: cobra.NoArgs, - RunE: func(cmd *cobra.Command, _ []string) error { - clientCtx, err := client.GetClientQueryContext(cmd) - if err != nil { - return err - } - queryClient := types.NewQueryClient(clientCtx) - - params := &types.QueryInflationRequest{} - res, err := queryClient.Inflation(cmd.Context(), params) - if err != nil { - return err - } - - return clientCtx.PrintString(fmt.Sprintf("%d\n", res.Inflation)) - }, - } - - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} - -// GetCmdQueryPhaseStep implements a command to return the current minting -// inflation value. -func GetCmdQueryPhaseStep() *cobra.Command { - cmd := &cobra.Command{ - Use: "phase-step", - Short: "Query the current minting phase step", - Args: cobra.NoArgs, - RunE: func(cmd *cobra.Command, _ []string) error { - clientCtx, err := client.GetClientQueryContext(cmd) - if err != nil { - return err - } - queryClient := types.NewQueryClient(clientCtx) - - params := &types.QueryPhaseStepRequest{} - res, err := queryClient.PhaseStep(cmd.Context(), params) - if err != nil { - return err - } - - return clientCtx.PrintString(fmt.Sprintf("%d\n", res.PhaseStep)) - }, - } - - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} - -// GetCmdQueryPhaseProvisions implements a command to return the current minting -// phase provisions value. -func GetCmdQueryPhaseProvisions() *cobra.Command { - cmd := &cobra.Command{ - Use: "phase-provisions", - Short: "Query the current minting phase provisions value", - Args: cobra.NoArgs, - RunE: func(cmd *cobra.Command, _ []string) error { - clientCtx, err := client.GetClientQueryContext(cmd) - if err != nil { - return err - } - queryClient := types.NewQueryClient(clientCtx) - - params := &types.QueryPhaseProvisionsRequest{} - res, err := queryClient.PhaseProvisions(cmd.Context(), params) - if err != nil { - return err - } - - return clientCtx.PrintString(fmt.Sprintf("%d\n", res.PhaseProvisions)) - }, - } - - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} - -// GetCmdQueryEndPhaseStatus implements a command to return the current minting -// end phase status value. -func GetCmdQueryEndPhaseStatus() *cobra.Command { - cmd := &cobra.Command{ - Use: "endphase-status", - Short: "Query the current status of end phase", - Args: cobra.NoArgs, - RunE: func(cmd *cobra.Command, _ []string) error { - clientCtx, err := client.GetClientQueryContext(cmd) - if err != nil { - return err - } - queryClient := types.NewQueryClient(clientCtx) - - params := &types.QueryEndPhaseStatusRequest{} - res, err := queryClient.EndPhaseStatus(cmd.Context(), params) - if err != nil { - return err - } - - return clientCtx.PrintString(fmt.Sprintf("%t\n", res.IsInEndPhase)) - }, - } - - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} diff --git a/x/mint/client/cli/query_minter_test.go b/x/mint/client/cli/query_minter_test.go deleted file mode 100644 index cdf8866c..00000000 --- a/x/mint/client/cli/query_minter_test.go +++ /dev/null @@ -1,175 +0,0 @@ -package cli_test - -import ( - "errors" - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/mint/client/cli" - "github.com/sge-network/sge/x/mint/types" -) - -func TestQueryInflation(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - { - desc: "invalid", - args: []string{"wrongArg"}, - err: errors.New("unknown command \"wrongArg\" for \"inflation\""), - }, - { - desc: "invalid height", - args: []string{"--height=1000"}, - err: errors.New("rpc error: code = Unknown desc = cannot query with height in the future; please provide a valid height: invalid height"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := append([]string(nil), tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryInflation(), args) - if tc.err != nil { - require.EqualError(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - inflation := strings.Replace(string(res.Bytes()), "\n", "", 1) - require.Equal(t, types.DefaultParams().Phases[0].Inflation.String(), inflation) - } - }) - } -} - -func TestQueryPhaseStep(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - { - desc: "invalid", - args: []string{"wrongArg"}, - err: errors.New("unknown command \"wrongArg\" for \"phase-step\""), - }, - { - desc: "invalid height", - args: []string{"--height=1000"}, - err: errors.New("rpc error: code = Unknown desc = cannot query with height in the future; please provide a valid height: invalid height"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := append([]string(nil), tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryPhaseStep(), args) - if tc.err != nil { - require.EqualError(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - phaseStep := strings.Replace(string(res.Bytes()), "\n", "", 1) - require.Equal(t, "1", phaseStep) - } - }) - } -} - -func TestQueryPhaseProvision(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - { - desc: "invalid", - args: []string{"wrongArg"}, - err: errors.New("unknown command \"wrongArg\" for \"phase-provisions\""), - }, - { - desc: "invalid height", - args: []string{"--height=1000"}, - err: errors.New("rpc error: code = Unknown desc = cannot query with height in the future; please provide a valid height: invalid height"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := append([]string(nil), tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryPhaseProvisions(), args) - if tc.err != nil { - require.EqualError(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - phaseProvision := strings.Replace(string(res.Bytes()), "\n", "", 1) - require.Equal(t, "57446808.510638297750000000", phaseProvision) - } - }) - } -} - -func TestQueryEndPhaseStatus(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - { - desc: "invalid", - args: []string{"wrongArg"}, - err: errors.New("unknown command \"wrongArg\" for \"endphase-status\""), - }, - { - desc: "invalid height", - args: []string{"--height=1000"}, - err: errors.New("rpc error: code = Unknown desc = cannot query with height in the future; please provide a valid height: invalid height"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := append([]string(nil), tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryEndPhaseStatus(), args) - if tc.err != nil { - require.EqualError(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - phaseProvision := strings.Replace(string(res.Bytes()), "\n", "", 1) - require.Equal(t, "false", phaseProvision) - } - }) - } -} diff --git a/x/mint/client/cli/query_params.go b/x/mint/client/cli/query_params.go deleted file mode 100644 index 42c5d96d..00000000 --- a/x/mint/client/cli/query_params.go +++ /dev/null @@ -1,37 +0,0 @@ -package cli - -import ( - "context" - - "github.com/spf13/cobra" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - - "github.com/sge-network/sge/x/mint/types" -) - -// GetCmdQueryParams returns the cmd function of params -func GetCmdQueryParams() *cobra.Command { - cmd := &cobra.Command{ - Use: "params", - Short: "shows the parameters of the module", - Args: cobra.NoArgs, - RunE: func(cmd *cobra.Command, _ []string) error { - clientCtx := client.GetClientContextFromCmd(cmd) - - queryClient := types.NewQueryClient(clientCtx) - - res, err := queryClient.Params(context.Background(), &types.QueryParamsRequest{}) - if err != nil { - return err - } - - return clientCtx.PrintProto(res) - }, - } - - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} diff --git a/x/mint/client/cli/query_params_test.go b/x/mint/client/cli/query_params_test.go deleted file mode 100644 index 3b485c63..00000000 --- a/x/mint/client/cli/query_params_test.go +++ /dev/null @@ -1,61 +0,0 @@ -package cli_test - -import ( - "encoding/json" - "fmt" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/mint/client/cli" - "github.com/sge-network/sge/x/mint/types" -) - -func TestQueryParams(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryParams(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - var params types.QueryParamsResponse - err = json.Unmarshal(res.Bytes(), ¶ms) - fmt.Println(params) - // command-line response, wraps the primitive numbers in double quotes, so it is not unmarshall-able. - require.EqualError( - t, - err, - "json: cannot unmarshal string into Go struct field Params.params.blocks_per_year of type int64", - ) - - defaultParams := types.DefaultParams() - defaultParams.BlocksPerYear = 0 - require.Equal(t, types.QueryParamsResponse{ - Params: defaultParams, - }, params) - }) - } -} diff --git a/x/mint/client/cli/query_test.go b/x/mint/client/cli/query_test.go deleted file mode 100644 index b01ce291..00000000 --- a/x/mint/client/cli/query_test.go +++ /dev/null @@ -1,48 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/mint/client/cli" -) - -func TestGetQueryCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetQueryCmd(""), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True( - t, - strings.HasPrefix(string(res.Bytes()), "Querying commands for the mint module"), - ) - }) - } -} diff --git a/x/mint/exported/exported.go b/x/mint/exported/exported.go new file mode 100644 index 00000000..000114e6 --- /dev/null +++ b/x/mint/exported/exported.go @@ -0,0 +1,18 @@ +package exported + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" +) + +type ( + ParamSet = paramtypes.ParamSet + + // Subspace defines an interface that implements the legacy x/params Subspace + // type. + // + // NOTE: This is used solely for migration of x/params managed parameters. + Subspace interface { + GetParamSet(ctx sdk.Context, ps ParamSet) + } +) diff --git a/x/mint/genesis.go b/x/mint/genesis.go deleted file mode 100644 index f4a67dba..00000000 --- a/x/mint/genesis.go +++ /dev/null @@ -1,24 +0,0 @@ -package mint - -import ( - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/mint/keeper" - "github.com/sge-network/sge/x/mint/types" -) - -// InitGenesis initializes the module's state from a provided genesis -// state. -func InitGenesis(ctx sdk.Context, k keeper.Keeper, genState types.GenesisState) { - k.SetMinter(ctx, genState.Minter) - k.SetParams(ctx, genState.Params) -} - -// ExportGenesis returns the module's exported genesis. -func ExportGenesis(ctx sdk.Context, k keeper.Keeper) *types.GenesisState { - genesis := types.DefaultGenesis() - genesis.Params = k.GetParams(ctx) - genesis.Minter = k.GetMinter(ctx) - - return genesis -} diff --git a/x/mint/genesis_test.go b/x/mint/genesis_test.go deleted file mode 100644 index 2e0b292d..00000000 --- a/x/mint/genesis_test.go +++ /dev/null @@ -1,28 +0,0 @@ -package mint_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/mint" - "github.com/sge-network/sge/x/mint/types" -) - -func TestGenesis(t *testing.T) { - genesisState := types.GenesisState{ - Params: types.DefaultParams(), - } - - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - mint.InitGenesis(ctx, tApp.MintKeeper, genesisState) - got := mint.ExportGenesis(ctx, tApp.MintKeeper) - require.NotNil(t, got) - - nullify.Fill(&genesisState) - nullify.Fill(got) -} diff --git a/x/mint/keeper/genesis.go b/x/mint/keeper/genesis.go new file mode 100644 index 00000000..829102c1 --- /dev/null +++ b/x/mint/keeper/genesis.go @@ -0,0 +1,34 @@ +package keeper + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/sge-network/sge/x/mint/types" +) + +// InitGenesis new mint genesis +func (k Keeper) InitGenesis(ctx sdk.Context, ak types.AccountKeeper, data *types.GenesisState) { + if err := k.Minter.Set(ctx, data.Minter); err != nil { + panic(err) + } + + if err := k.Params.Set(ctx, data.Params); err != nil { + panic(err) + } + + ak.GetModuleAccount(ctx, types.ModuleName) +} + +// ExportGenesis returns a GenesisState for a given context and keeper. +func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState { + minter, err := k.Minter.Get(ctx) + if err != nil { + panic(err) + } + + params, err := k.Params.Get(ctx) + if err != nil { + panic(err) + } + + return types.NewGenesisState(minter, params) +} diff --git a/x/mint/keeper/grpc_query.go b/x/mint/keeper/grpc_query.go index 74caac50..98ead670 100644 --- a/x/mint/keeper/grpc_query.go +++ b/x/mint/keeper/grpc_query.go @@ -1,7 +1,73 @@ package keeper import ( + "context" + "github.com/sge-network/sge/x/mint/types" ) -var _ types.QueryServer = Keeper{} +var _ types.QueryServer = queryServer{} + +func NewQueryServerImpl(k Keeper) types.QueryServer { + return queryServer{k} +} + +type queryServer struct { + k Keeper +} + +// Params returns the params of the module +func (q queryServer) Params(ctx context.Context, _ *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { + params, err := q.k.Params.Get(ctx) + if err != nil { + return nil, err + } + + return &types.QueryParamsResponse{Params: params}, nil +} + +// Inflation returns current inflation. +func (q queryServer) Inflation(ctx context.Context, _ *types.QueryInflationRequest) (*types.QueryInflationResponse, error) { + minter, err := q.k.Minter.Get(ctx) + if err != nil { + return nil, err + } + + return &types.QueryInflationResponse{Inflation: minter.Inflation}, nil +} + +// PhaseStep returns phase step. +func (q queryServer) PhaseStep(ctx context.Context, _ *types.QueryPhaseStepRequest) (*types.QueryPhaseStepResponse, error) { + minter, err := q.k.Minter.Get(ctx) + if err != nil { + return nil, err + } + + return &types.QueryPhaseStepResponse{PhaseStep: minter.PhaseStep}, nil +} + +// PhaseProvisions returns current phase provision. +func (q queryServer) PhaseProvisions(ctx context.Context, _ *types.QueryPhaseProvisionsRequest) (*types.QueryPhaseProvisionsResponse, error) { + minter, err := q.k.Minter.Get(ctx) + if err != nil { + return nil, err + } + return &types.QueryPhaseProvisionsResponse{PhaseProvisions: minter.PhaseProvisions}, nil +} + +// EndPhaseStatus returns end phase status. +func (q queryServer) EndPhaseStatus(ctx context.Context, _ *types.QueryEndPhaseStatusRequest) (*types.QueryEndPhaseStatusResponse, error) { + minter, err := q.k.Minter.Get(ctx) + if err != nil { + return nil, err + } + + params, err := q.k.Params.Get(ctx) + if err != nil { + return nil, err + } + + return &types.QueryEndPhaseStatusResponse{ + IsInEndPhase: params.IsEndPhaseByStep(int(minter.PhaseStep)), + }, nil +} diff --git a/x/mint/keeper/grpc_query_minter.go b/x/mint/keeper/grpc_query_minter.go deleted file mode 100644 index 47242ad7..00000000 --- a/x/mint/keeper/grpc_query_minter.go +++ /dev/null @@ -1,56 +0,0 @@ -package keeper - -import ( - "context" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/mint/types" -) - -// Inflation returns current inflation. -func (k Keeper) Inflation( - c context.Context, - _ *types.QueryInflationRequest, -) (*types.QueryInflationResponse, error) { - ctx := sdk.UnwrapSDKContext(c) - minter := k.GetMinter(ctx) - - return &types.QueryInflationResponse{Inflation: minter.Inflation}, nil -} - -// PhaseStep returns phase step. -func (k Keeper) PhaseStep( - c context.Context, - _ *types.QueryPhaseStepRequest, -) (*types.QueryPhaseStepResponse, error) { - ctx := sdk.UnwrapSDKContext(c) - minter := k.GetMinter(ctx) - - return &types.QueryPhaseStepResponse{PhaseStep: minter.PhaseStep}, nil -} - -// PhaseProvisions returns current phase provision. -func (k Keeper) PhaseProvisions( - c context.Context, - _ *types.QueryPhaseProvisionsRequest, -) (*types.QueryPhaseProvisionsResponse, error) { - ctx := sdk.UnwrapSDKContext(c) - minter := k.GetMinter(ctx) - - return &types.QueryPhaseProvisionsResponse{PhaseProvisions: minter.PhaseProvisions}, nil -} - -// EndPhaseStatus returns end phase status. -func (k Keeper) EndPhaseStatus( - c context.Context, - _ *types.QueryEndPhaseStatusRequest, -) (*types.QueryEndPhaseStatusResponse, error) { - ctx := sdk.UnwrapSDKContext(c) - minter := k.GetMinter(ctx) - params := k.GetParams(ctx) - - return &types.QueryEndPhaseStatusResponse{ - IsInEndPhase: params.IsEndPhaseByStep(int(minter.PhaseStep)), - }, nil -} diff --git a/x/mint/keeper/grpc_query_minter_test.go b/x/mint/keeper/grpc_query_minter_test.go deleted file mode 100644 index 25a0d04c..00000000 --- a/x/mint/keeper/grpc_query_minter_test.go +++ /dev/null @@ -1,38 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/mint/types" -) - -func TestMinterQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - inflation, err := k.Inflation(wctx, &types.QueryInflationRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryInflationResponse{Inflation: k.GetMinter(ctx).Inflation}, inflation) - - phaseStep, err := k.PhaseStep(wctx, &types.QueryPhaseStepRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryPhaseStepResponse{PhaseStep: k.GetMinter(ctx).PhaseStep}, phaseStep) - - phaseProvisions, err := k.PhaseProvisions(wctx, &types.QueryPhaseProvisionsRequest{}) - require.NoError(t, err) - require.Equal( - t, - &types.QueryPhaseProvisionsResponse{PhaseProvisions: k.GetMinter(ctx).PhaseProvisions}, - phaseProvisions, - ) - - endPhaseStatus, err := k.EndPhaseStatus(wctx, &types.QueryEndPhaseStatusRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryEndPhaseStatusResponse{IsInEndPhase: false}, endPhaseStatus) -} diff --git a/x/mint/keeper/grpc_query_params.go b/x/mint/keeper/grpc_query_params.go deleted file mode 100644 index 055454e9..00000000 --- a/x/mint/keeper/grpc_query_params.go +++ /dev/null @@ -1,26 +0,0 @@ -package keeper - -import ( - "context" - - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/x/mint/types" -) - -// Params returns the params of the module -func (k Keeper) Params( - c context.Context, - req *types.QueryParamsRequest, -) (*types.QueryParamsResponse, error) { - if req == nil { - return nil, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest) - } - ctx := sdk.UnwrapSDKContext(c) - - return &types.QueryParamsResponse{Params: k.GetParams(ctx)}, nil -} diff --git a/x/mint/keeper/grpc_query_params_test.go b/x/mint/keeper/grpc_query_params_test.go deleted file mode 100644 index 069352c3..00000000 --- a/x/mint/keeper/grpc_query_params_test.go +++ /dev/null @@ -1,32 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/mint/types" -) - -func TestParamsQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - response, err := k.Params(wctx, &types.QueryParamsRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryParamsResponse{Params: params}, response) -} - -func TestParamsInvalidQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - _, err := k.Params(wctx, nil) - require.Error(t, err) -} diff --git a/x/mint/keeper/grpc_query_test.go b/x/mint/keeper/grpc_query_test.go new file mode 100644 index 00000000..758181e9 --- /dev/null +++ b/x/mint/keeper/grpc_query_test.go @@ -0,0 +1,87 @@ +package keeper_test + +import ( + gocontext "context" + "testing" + + storetypes "cosmossdk.io/store/types" + "github.com/cosmos/cosmos-sdk/baseapp" + "github.com/cosmos/cosmos-sdk/runtime" + "github.com/cosmos/cosmos-sdk/testutil" + sdk "github.com/cosmos/cosmos-sdk/types" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/golang/mock/gomock" + "github.com/stretchr/testify/suite" + + "github.com/sge-network/sge/x/mint" + "github.com/sge-network/sge/x/mint/keeper" + minttestutil "github.com/sge-network/sge/x/mint/testutil" + "github.com/sge-network/sge/x/mint/types" +) + +type MintTestSuite struct { + suite.Suite + + ctx sdk.Context + queryClient types.QueryClient + mintKeeper keeper.Keeper +} + +func (suite *MintTestSuite) SetupTest() { + encCfg := moduletestutil.MakeTestEncodingConfig(mint.AppModuleBasic{}) + key := storetypes.NewKVStoreKey(types.StoreKey) + storeService := runtime.NewKVStoreService(key) + testCtx := testutil.DefaultContextWithDB(suite.T(), key, storetypes.NewTransientStoreKey("transient_test")) + suite.ctx = testCtx.Ctx + + // gomock initializations + ctrl := gomock.NewController(suite.T()) + accountKeeper := minttestutil.NewMockAccountKeeper(ctrl) + bankKeeper := minttestutil.NewMockBankKeeper(ctrl) + stakingKeeper := minttestutil.NewMockStakingKeeper(ctrl) + + accountKeeper.EXPECT().GetModuleAddress("mint").Return(sdk.AccAddress{}) + + suite.mintKeeper = keeper.NewKeeper( + encCfg.Codec, + storeService, + stakingKeeper, + accountKeeper, + bankKeeper, + authtypes.FeeCollectorName, + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + ) + + err := suite.mintKeeper.Params.Set(suite.ctx, types.DefaultParams()) + suite.Require().NoError(err) + suite.Require().NoError(suite.mintKeeper.Minter.Set(suite.ctx, types.DefaultInitialMinter())) + + queryHelper := baseapp.NewQueryServerTestHelper(testCtx.Ctx, encCfg.InterfaceRegistry) + types.RegisterQueryServer(queryHelper, keeper.NewQueryServerImpl(suite.mintKeeper)) + + suite.queryClient = types.NewQueryClient(queryHelper) +} + +func (suite *MintTestSuite) TestGRPCParams() { + params, err := suite.queryClient.Params(gocontext.Background(), &types.QueryParamsRequest{}) + suite.Require().NoError(err) + kparams, err := suite.mintKeeper.Params.Get(suite.ctx) + suite.Require().NoError(err) + suite.Require().Equal(params.Params, kparams) + + inflation, err := suite.queryClient.Inflation(gocontext.Background(), &types.QueryInflationRequest{}) + suite.Require().NoError(err) + minter, err := suite.mintKeeper.Minter.Get(suite.ctx) + suite.Require().NoError(err) + suite.Require().Equal(inflation.Inflation, minter.Inflation) + + annualProvisions, err := suite.queryClient.PhaseProvisions(gocontext.Background(), &types.QueryPhaseProvisionsRequest{}) + suite.Require().NoError(err) + suite.Require().Equal(annualProvisions.PhaseProvisions, minter.PhaseProvisions) +} + +func TestMintTestSuite(t *testing.T) { + suite.Run(t, new(MintTestSuite)) +} diff --git a/x/mint/keeper/keeper.go b/x/mint/keeper/keeper.go index f650f851..8d45be22 100644 --- a/x/mint/keeper/keeper.go +++ b/x/mint/keeper/keeper.go @@ -1,13 +1,16 @@ package keeper import ( + "context" "fmt" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/collections" + storetypes "cosmossdk.io/core/store" + "cosmossdk.io/log" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" "github.com/sge-network/sge/consts" "github.com/sge-network/sge/x/mint/types" @@ -16,54 +19,96 @@ import ( // Keeper is the type for module properties type Keeper struct { cdc codec.BinaryCodec - storeKey storetypes.StoreKey - paramstore paramtypes.Subspace + storeService storetypes.KVStoreService stakingKeeper types.StakingKeeper bankKeeper types.BankKeeper feeCollectorName string // the address capable of executing a MsgUpdateParams message. Typically, this // should be the x/gov module account. authority string -} -// ExpectedKeepers contains expected keepers parameter needed by NewKeeper -type ExpectedKeepers struct { - StakingKeeper types.StakingKeeper - BankKeeper types.BankKeeper + Schema collections.Schema + Params collections.Item[types.Params] + Minter collections.Item[types.Minter] } // NewKeeper creates new keeper object func NewKeeper( cdc codec.BinaryCodec, - storeKey storetypes.StoreKey, - ps paramtypes.Subspace, + storeService storetypes.KVStoreService, + sk types.StakingKeeper, ak types.AccountKeeper, - expectedKeepers ExpectedKeepers, + bk types.BankKeeper, feeCollectorName string, authority string, -) *Keeper { +) Keeper { // ensure mint module account is set if addr := ak.GetModuleAddress(types.ModuleName); addr == nil { panic(fmt.Sprintf(consts.ErrModuleAccountHasNotBeenSet, types.ModuleName)) } - // set KeyTable if it has not already been set - if !ps.HasKeyTable() { - ps = ps.WithKeyTable(types.ParamKeyTable()) - } - - return &Keeper{ + sb := collections.NewSchemaBuilder(storeService) + k := Keeper{ cdc: cdc, - storeKey: storeKey, - paramstore: ps, - stakingKeeper: expectedKeepers.StakingKeeper, - bankKeeper: expectedKeepers.BankKeeper, + storeService: storeService, + stakingKeeper: sk, + bankKeeper: bk, feeCollectorName: feeCollectorName, authority: authority, + Params: collections.NewItem(sb, types.ParamsKey, "params", codec.CollValue[types.Params](cdc)), + Minter: collections.NewItem(sb, types.MinterKey, "minter", codec.CollValue[types.Minter](cdc)), + } + + schema, err := sb.Build() + if err != nil { + panic(err) + } + k.Schema = schema + return k +} + +// GetAuthority returns the x/mint module's authority. +func (k Keeper) GetAuthority() string { + return k.authority +} + +// Logger returns a module-specific logger. +func (k Keeper) Logger(ctx context.Context) log.Logger { + sdkCtx := sdk.UnwrapSDKContext(ctx) + return sdkCtx.Logger().With("module", "x/"+types.ModuleName) +} + +// StakingTokenSupply implements an alias call to the underlying staking keeper's +// to be used in BeginBlocker. +func (k Keeper) StakingTokenSupply(ctx context.Context) (sdkmath.Int, error) { + return k.stakingKeeper.StakingTokenSupply(ctx) +} + +// TokenSupply implements an alias call to the underlying bank keeper's +// to be used in BeginBlocker. +func (k Keeper) TokenSupply(ctx context.Context, denom string) sdkmath.Int { + return k.bankKeeper.GetSupply(ctx, denom).Amount +} + +// BondedRatio implements an alias call to the underlying staking keeper's +// to be used in BeginBlocker. +func (k Keeper) BondedRatio(ctx context.Context) (sdkmath.LegacyDec, error) { + return k.stakingKeeper.BondedRatio(ctx) +} + +// MintCoins implements an alias call to the underlying supply keeper's +// to be used in BeginBlocker. +func (k Keeper) MintCoins(ctx context.Context, newCoins sdk.Coins) error { + if newCoins.Empty() { + // skip as no coins need to be minted + return nil } + + return k.bankKeeper.MintCoins(ctx, types.ModuleName, newCoins) } -// Logger returns the logger of the keeper -func (Keeper) Logger(ctx sdk.Context) log.Logger { - return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) +// AddCollectedFees implements an alias call to the underlying supply keeper's +// to be used in BeginBlocker. +func (k Keeper) AddCollectedFees(ctx context.Context, fees sdk.Coins) error { + return k.bankKeeper.SendCoinsFromModuleToModule(ctx, types.ModuleName, k.feeCollectorName, fees) } diff --git a/x/mint/keeper/keeper_test.go b/x/mint/keeper/keeper_test.go index d84c69c2..019a8342 100644 --- a/x/mint/keeper/keeper_test.go +++ b/x/mint/keeper/keeper_test.go @@ -3,31 +3,93 @@ package keeper_test import ( "testing" - "github.com/stretchr/testify/require" + "cosmossdk.io/math" + storetypes "cosmossdk.io/store/types" + "github.com/cosmos/cosmos-sdk/runtime" + "github.com/cosmos/cosmos-sdk/testutil" sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/golang/mock/gomock" + "github.com/sge-network/sge/x/mint" "github.com/sge-network/sge/x/mint/keeper" + minttestutil "github.com/sge-network/sge/x/mint/testutil" + "github.com/sge-network/sge/x/mint/types" + "github.com/stretchr/testify/suite" ) -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) +type IntegrationTestSuite struct { + suite.Suite + + mintKeeper keeper.Keeper + ctx sdk.Context + msgServer types.MsgServer + stakingKeeper *minttestutil.MockStakingKeeper + bankKeeper *minttestutil.MockBankKeeper +} - return tApp, &tApp.MintKeeper, ctx +func TestKeeperTestSuite(t *testing.T) { + suite.Run(t, new(IntegrationTestSuite)) } -func setupKeeper(t testing.TB) (*keeper.KeeperTest, sdk.Context) { - _, k, ctx := setupKeeperAndApp(t) +func (s *IntegrationTestSuite) SetupTest() { + encCfg := moduletestutil.MakeTestEncodingConfig(mint.AppModuleBasic{}) + key := storetypes.NewKVStoreKey(types.StoreKey) + storeService := runtime.NewKVStoreService(key) + testCtx := testutil.DefaultContextWithDB(s.T(), key, storetypes.NewTransientStoreKey("transient_test")) + s.ctx = testCtx.Ctx + + // gomock initializations + ctrl := gomock.NewController(s.T()) + accountKeeper := minttestutil.NewMockAccountKeeper(ctrl) + bankKeeper := minttestutil.NewMockBankKeeper(ctrl) + stakingKeeper := minttestutil.NewMockStakingKeeper(ctrl) + + accountKeeper.EXPECT().GetModuleAddress(types.ModuleName).Return(sdk.AccAddress{}) - return k, ctx + s.mintKeeper = keeper.NewKeeper( + encCfg.Codec, + storeService, + stakingKeeper, + accountKeeper, + bankKeeper, + authtypes.FeeCollectorName, + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + ) + s.stakingKeeper = stakingKeeper + s.bankKeeper = bankKeeper + + s.Require().Equal(testCtx.Ctx.Logger().With("module", "x/"+types.ModuleName), + s.mintKeeper.Logger(testCtx.Ctx)) + + err := s.mintKeeper.Params.Set(s.ctx, types.DefaultParams()) + s.Require().NoError(err) + s.Require().NoError(s.mintKeeper.Minter.Set(s.ctx, types.DefaultInitialMinter())) + + s.msgServer = keeper.NewMsgServerImpl(s.mintKeeper) } -func TestLogger(t *testing.T) { - k, ctx := setupKeeper(t) - logger := k.Logger(ctx) - require.NotNil(t, logger) +func (s *IntegrationTestSuite) TestAliasFunctions() { + stakingTokenSupply := math.NewIntFromUint64(100000000000) + s.stakingKeeper.EXPECT().StakingTokenSupply(s.ctx).Return(stakingTokenSupply, nil) + tokenSupply, err := s.mintKeeper.StakingTokenSupply(s.ctx) + s.Require().NoError(err) + s.Require().Equal(tokenSupply, stakingTokenSupply) + + bondedRatio := math.LegacyNewDecWithPrec(15, 2) + s.stakingKeeper.EXPECT().BondedRatio(s.ctx).Return(bondedRatio, nil) + ratio, err := s.mintKeeper.BondedRatio(s.ctx) + s.Require().NoError(err) + s.Require().Equal(ratio, bondedRatio) + + coins := sdk.NewCoins(sdk.NewCoin("stake", math.NewInt(1000000))) + s.bankKeeper.EXPECT().MintCoins(s.ctx, types.ModuleName, coins).Return(nil) + s.Require().Equal(s.mintKeeper.MintCoins(s.ctx, sdk.NewCoins()), nil) + s.Require().Nil(s.mintKeeper.MintCoins(s.ctx, coins)) - logger.Debug("test log") + fees := sdk.NewCoins(sdk.NewCoin("stake", math.NewInt(1000))) + s.bankKeeper.EXPECT().SendCoinsFromModuleToModule(s.ctx, types.ModuleName, authtypes.FeeCollectorName, fees).Return(nil) + s.Require().Nil(s.mintKeeper.AddCollectedFees(s.ctx, fees)) } diff --git a/x/mint/keeper/migrator.go b/x/mint/keeper/migrator.go new file mode 100644 index 00000000..88552fa5 --- /dev/null +++ b/x/mint/keeper/migrator.go @@ -0,0 +1,29 @@ +package keeper + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/sge-network/sge/x/mint/exported" + v2 "github.com/sge-network/sge/x/mint/migrations/v2" +) + +// Migrator is a struct for handling in-place state migrations. +type Migrator struct { + keeper Keeper + legacySubspace exported.Subspace +} + +// NewMigrator returns Migrator instance for the state migration. +func NewMigrator(k Keeper, ss exported.Subspace) Migrator { + return Migrator{ + keeper: k, + legacySubspace: ss, + } +} + +// Migrate1to2 migrates the x/mint module state from the consensus version 1 to +// version 2. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/mint +// module state. +func (m Migrator) Migrate1to2(ctx sdk.Context) error { + return v2.Migrate(ctx, m.keeper.storeService.OpenKVStore(ctx), m.legacySubspace, m.keeper.cdc) +} diff --git a/x/mint/keeper/minter.go b/x/mint/keeper/minter.go deleted file mode 100644 index a5e24f1b..00000000 --- a/x/mint/keeper/minter.go +++ /dev/null @@ -1,62 +0,0 @@ -package keeper - -import ( - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/mint/types" -) - -// GetMinter returns the minter -func (k Keeper) GetMinter(ctx sdk.Context) (minter types.Minter) { - store := ctx.KVStore(k.storeKey) - b := store.Get(types.MinterKey) - if b == nil { - panic(types.ErrTextNilMinter) - } - - k.cdc.MustUnmarshal(b, &minter) - return -} - -// SetMinter sets the minter -func (k Keeper) SetMinter(ctx sdk.Context, minter types.Minter) { - store := ctx.KVStore(k.storeKey) - b := k.cdc.MustMarshal(&minter) - store.Set(types.MinterKey, b) -} - -// StakingTokenSupply implements an alias call to the underlying staking keeper's -// to be used in BeginBlocker. -func (k Keeper) StakingTokenSupply(ctx sdk.Context) sdkmath.Int { - return k.stakingKeeper.StakingTokenSupply(ctx) -} - -// TokenSupply implements an alias call to the underlying bank keeper's -// to be used in BeginBlocker. -func (k Keeper) TokenSupply(ctx sdk.Context, denom string) sdkmath.Int { - return k.bankKeeper.GetSupply(ctx, denom).Amount -} - -// BondedRatio implements an alias call to the underlying staking keeper's -// to be used in BeginBlocker. -func (k Keeper) BondedRatio(ctx sdk.Context) sdkmath.LegacyDec { - return k.stakingKeeper.BondedRatio(ctx) -} - -// MintCoins implements an alias call to the underlying supply keeper's -// to be used in BeginBlocker. -func (k Keeper) MintCoins(ctx sdk.Context, newCoins sdk.Coins) error { - if newCoins.Empty() { - // skip as no coins need to be minted - return nil - } - - return k.bankKeeper.MintCoins(ctx, types.ModuleName, newCoins) -} - -// AddCollectedFees implements an alias call to the underlying supply keeper's -// to be used in BeginBlocker. -func (k Keeper) AddCollectedFees(ctx sdk.Context, fees sdk.Coins) error { - return k.bankKeeper.SendCoinsFromModuleToModule(ctx, types.ModuleName, k.feeCollectorName, fees) -} diff --git a/x/mint/keeper/minter_test.go b/x/mint/keeper/minter_test.go deleted file mode 100644 index bf6808df..00000000 --- a/x/mint/keeper/minter_test.go +++ /dev/null @@ -1,42 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/app/params" -) - -func TestTokenSupply(t *testing.T) { - k, ctx := setupKeeper(t) - tokenSupply := k.TokenSupply(ctx, params.DefaultBondDenom) - require.Equal(t, int64(10020000000), tokenSupply.Int64()) -} - -func TestStakingTokenSupply(t *testing.T) { - k, ctx := setupKeeper(t) - tokenSupply := k.StakingTokenSupply(ctx) - require.Equal(t, int64(10020000000), tokenSupply.Int64()) -} - -func TestBondedRatio(t *testing.T) { - k, ctx := setupKeeper(t) - bondedRatio := k.BondedRatio(ctx) - expectedBondedRatio, _ := sdkmath.LegacyNewDecFromStr("0.000998003992015968") - require.Equal(t, expectedBondedRatio, bondedRatio) -} - -func TestMintCoins(t *testing.T) { - k, ctx := setupKeeper(t) - mintAmount := int64(100) - err := k.MintCoins(ctx, sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(mintAmount)))) - require.NoError(t, err) - - totalSupply := k.TokenSupply(ctx, params.DefaultBondDenom) - totalSupply = totalSupply.Add(sdkmath.NewInt(mintAmount)) - require.Equal(t, int64(10020000200), totalSupply.Int64()) -} diff --git a/x/mint/keeper/msg_server.go b/x/mint/keeper/msg_server.go index a18ae394..ea33f960 100644 --- a/x/mint/keeper/msg_server.go +++ b/x/mint/keeper/msg_server.go @@ -1,17 +1,42 @@ package keeper import ( + "context" + + "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/sge-network/sge/x/mint/types" ) +var _ types.MsgServer = msgServer{} + +// msgServer is a wrapper of Keeper. type msgServer struct { Keeper } -// NewMsgServerImpl returns an implementation of the MsgServer interface -// for the provided Keeper. -func NewMsgServerImpl(keeper Keeper) types.MsgServer { - return &msgServer{Keeper: keeper} +// NewMsgServerImpl returns an implementation of the x/mint MsgServer interface. +func NewMsgServerImpl(k Keeper) types.MsgServer { + return &msgServer{ + Keeper: k, + } } -var _ types.MsgServer = msgServer{} +// UpdateParams updates the params. +func (ms msgServer) UpdateParams(goCtx context.Context, msg *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { + ctx := sdk.UnwrapSDKContext(goCtx) + + if ms.authority != msg.Authority { + return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", ms.authority, msg.Authority) + } + + if err := msg.Params.Validate(); err != nil { + return nil, err + } + + if err := ms.Params.Set(ctx, msg.Params); err != nil { + return nil, err + } + return &types.MsgUpdateParamsResponse{}, nil +} diff --git a/x/mint/keeper/msg_server_params.go b/x/mint/keeper/msg_server_params.go deleted file mode 100644 index c4c7770d..00000000 --- a/x/mint/keeper/msg_server_params.go +++ /dev/null @@ -1,28 +0,0 @@ -package keeper - -import ( - "context" - - "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - - "github.com/sge-network/sge/x/mint/types" -) - -// UpdateParams updates the params. -func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { - ctx := sdk.UnwrapSDKContext(goCtx) - - if k.authority != req.Authority { - return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.authority, req.Authority) - } - - if err := req.Params.Validate(); err != nil { - return nil, err - } - - k.SetParams(ctx, req.Params) - - return &types.MsgUpdateParamsResponse{}, nil -} diff --git a/x/mint/keeper/msg_server_test.go b/x/mint/keeper/msg_server_test.go new file mode 100644 index 00000000..745b4f21 --- /dev/null +++ b/x/mint/keeper/msg_server_test.go @@ -0,0 +1,67 @@ +package keeper_test + +import ( + sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" + + "github.com/sge-network/sge/x/mint/types" +) + +func (s *IntegrationTestSuite) TestUpdateParams() { + testCases := []struct { + name string + request *types.MsgUpdateParams + expectErr bool + }{ + { + name: "set invalid authority (not an address)", + request: &types.MsgUpdateParams{ + Authority: "foo", + }, + expectErr: true, + }, + { + name: "set invalid authority (not defined authority)", + request: &types.MsgUpdateParams{ + Authority: "cosmos139f7kncmglres2nf3h4hc4tade85ekfr8sulz5", + }, + expectErr: true, + }, + { + name: "set invalid params", + request: &types.MsgUpdateParams{ + Authority: s.mintKeeper.GetAuthority(), + Params: types.Params{ + MintDenom: sdk.DefaultBondDenom, + ExcludeAmount: sdkmath.ZeroInt(), + BlocksPerYear: uint64(60 * 60 * 8766 / 5), + }, + }, + expectErr: true, + }, + { + name: "set full valid params", + request: &types.MsgUpdateParams{ + Authority: s.mintKeeper.GetAuthority(), + Params: types.Params{ + MintDenom: sdk.DefaultBondDenom, + ExcludeAmount: sdkmath.ZeroInt(), + Phases: []types.Phase{{Inflation: sdkmath.LegacyZeroDec(), YearCoefficient: sdkmath.LegacyOneDec()}}, + BlocksPerYear: uint64(60 * 60 * 8766 / 5), + }, + }, + expectErr: false, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + _, err := s.msgServer.UpdateParams(s.ctx, tc.request) + if tc.expectErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + } + }) + } +} diff --git a/x/mint/keeper/params.go b/x/mint/keeper/params.go deleted file mode 100644 index adad8aa4..00000000 --- a/x/mint/keeper/params.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper - -import ( - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/mint/types" -) - -// GetParams get all parameters as types.Params -func (k Keeper) GetParams(ctx sdk.Context) (params types.Params) { - k.paramstore.GetParamSet(ctx, ¶ms) - return params -} - -// SetParams set the params -func (k Keeper) SetParams(ctx sdk.Context, params types.Params) { - k.paramstore.SetParamSet(ctx, ¶ms) -} diff --git a/x/mint/keeper/params_test.go b/x/mint/keeper/params_test.go deleted file mode 100644 index 9d0d05bb..00000000 --- a/x/mint/keeper/params_test.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/mint/types" -) - -func TestGetParams(t *testing.T) { - k, ctx := setupKeeper(t) - params := types.DefaultParams() - - k.SetParams(ctx, params) - - require.EqualValues(t, params, k.GetParams(ctx)) -} diff --git a/x/mint/migrations/v2/migrate.go b/x/mint/migrations/v2/migrate.go new file mode 100644 index 00000000..a7476de3 --- /dev/null +++ b/x/mint/migrations/v2/migrate.go @@ -0,0 +1,37 @@ +package v2 + +import ( + storetypes "cosmossdk.io/core/store" + + "github.com/cosmos/cosmos-sdk/codec" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/sge-network/sge/x/mint/exported" + "github.com/sge-network/sge/x/mint/types" +) + +const ( + ModuleName = "mint" +) + +var ParamsKey = []byte{0x01} + +// Migrate migrates the x/mint module state from the consensus version 1 to +// version 2. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/mint +// module state. +func Migrate( + ctx sdk.Context, + store storetypes.KVStore, + legacySubspace exported.Subspace, + cdc codec.BinaryCodec, +) error { + var currParams types.Params + legacySubspace.GetParamSet(ctx, &currParams) + + if err := currParams.Validate(); err != nil { + return err + } + + bz := cdc.MustMarshal(&currParams) + return store.Set(ParamsKey, bz) +} diff --git a/x/mint/migrations/v2/migrator_test.go b/x/mint/migrations/v2/migrator_test.go new file mode 100644 index 00000000..7dfe06c6 --- /dev/null +++ b/x/mint/migrations/v2/migrator_test.go @@ -0,0 +1,51 @@ +package v2_test + +import ( + "testing" + + "github.com/sge-network/sge/x/mint" + "github.com/sge-network/sge/x/mint/exported" + "github.com/sge-network/sge/x/mint/types" + "github.com/stretchr/testify/require" + + storetypes "cosmossdk.io/store/types" + + "github.com/cosmos/cosmos-sdk/runtime" + "github.com/cosmos/cosmos-sdk/testutil" + sdk "github.com/cosmos/cosmos-sdk/types" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" + v2 "github.com/sge-network/sge/x/mint/migrations/v2" +) + +type mockSubspace struct { + ps types.Params +} + +func newMockSubspace(ps types.Params) mockSubspace { + return mockSubspace{ps: ps} +} + +func (ms mockSubspace) GetParamSet(_ sdk.Context, ps exported.ParamSet) { + //nolint + *ps.(*types.Params) = ms.ps +} + +func TestMigrate(t *testing.T) { + encCfg := moduletestutil.MakeTestEncodingConfig(mint.AppModuleBasic{}) + cdc := encCfg.Codec + + storeKey := storetypes.NewKVStoreKey(v2.ModuleName) + tKey := storetypes.NewTransientStoreKey("transient_test") + ctx := testutil.DefaultContext(storeKey, tKey) + kvStoreService := runtime.NewKVStoreService(storeKey) + store := kvStoreService.OpenKVStore(ctx) + + legacySubspace := newMockSubspace(types.DefaultParams()) + require.NoError(t, v2.Migrate(ctx, store, legacySubspace, cdc)) + + var res types.Params + bz, err := store.Get(v2.ParamsKey) + require.NoError(t, err) + require.NoError(t, cdc.Unmarshal(bz, &res)) + require.Equal(t, legacySubspace.ps, res) +} diff --git a/x/mint/module.go b/x/mint/module.go index d9047936..7957e6d0 100644 --- a/x/mint/module.go +++ b/x/mint/module.go @@ -4,27 +4,41 @@ import ( "context" "encoding/json" "fmt" + "testing" - "github.com/gorilla/mux" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" + "cosmossdk.io/core/appmodule" + "cosmossdk.io/core/store" + "cosmossdk.io/depinject" - abci "github.com/cometbft/cometbft/abci/types" + "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" + simtypes "github.com/cosmos/cosmos-sdk/types/simulation" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/sge-network/sge/x/mint/client/cli" + mintmodulev1 "github.com/sge-network/sge/api/sge/mint/module/v1" + "github.com/sge-network/sge/x/mint/exported" "github.com/sge-network/sge/x/mint/keeper" + mintsimulation "github.com/sge-network/sge/x/mint/simulation" "github.com/sge-network/sge/x/mint/types" ) +// ConsensusVersion defines the current x/mint module consensus version. +const ConsensusVersion = 2 + var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} + _ module.AppModuleBasic = AppModule{} + _ module.AppModuleSimulation = AppModule{} + _ module.HasGenesis = AppModule{} + _ module.HasServices = AppModule{} + + _ appmodule.AppModule = AppModule{} + _ appmodule.HasBeginBlocker = AppModule{} ) // ---------------------------------------------------------------------------- @@ -44,37 +58,29 @@ func NewAppModuleBasic(cdc codec.BinaryCodec) AppModuleBasic { // Name returns the module's name. func (AppModuleBasic) Name() string { return types.ModuleName } -// RegisterLegacyAminoCodec registers the lagacy amino codec for the app module basic +// RegisterLegacyAminoCodec registers the mint module's types on the given LegacyAmino codec. func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } // RegisterInterfaces registers the module's interface types -func (AppModuleBasic) RegisterInterfaces(reg cdctypes.InterfaceRegistry) { - types.RegisterInterfaces(reg) +func (b AppModuleBasic) RegisterInterfaces(r cdctypes.InterfaceRegistry) { + types.RegisterInterfaces(r) } -// DefaultGenesis returns the module's default genesis state. +// DefaultGenesis returns default genesis state as raw bytes for the mint +// module. func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { - return cdc.MustMarshalJSON(types.DefaultGenesis()) + return cdc.MustMarshalJSON(types.DefaultGenesisState()) } // ValidateGenesis performs genesis state validation for the module. -func (AppModuleBasic) ValidateGenesis( - cdc codec.JSONCodec, - _ client.TxEncodingConfig, - bz json.RawMessage, -) error { +func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, _ client.TxEncodingConfig, bz json.RawMessage) error { var genState types.GenesisState if err := cdc.UnmarshalJSON(bz, &genState); err != nil { return fmt.Errorf(ErrTextGenesisUnmarshalFailed, types.ModuleName, err) } - return genState.Validate() -} - -// RegisterRESTRoutes registers the module's REST service handlers. -func (AppModuleBasic) RegisterRESTRoutes(_ client.Context, _ *mux.Router) { - // left empty because the rest api is going to be deprecated + return types.ValidateGenesis(genState) } // RegisterGRPCGatewayRoutes registers the gRPC Gateway routes for the module. @@ -84,15 +90,6 @@ func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *r } } -// GetTxCmd returns the module's root tx command. -func (AppModuleBasic) GetTxCmd() *cobra.Command { - // transactions deprecated in favor of v2 - return nil -} - -// GetQueryCmd returns the module's root query command. -func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd(types.StoreKey) } - // ---------------------------------------------------------------------------- // AppModule // ---------------------------------------------------------------------------- @@ -103,7 +100,9 @@ type AppModule struct { keeper keeper.Keeper accountKeeper types.AccountKeeper - bankKeeper types.BankKeeper + + // legacySubspace is used solely for migration of x/params managed parameters + legacySubspace exported.Subspace } // NewAppModule creates new app module object @@ -111,66 +110,141 @@ func NewAppModule( cdc codec.Codec, keeper keeper.Keeper, accountKeeper types.AccountKeeper, - bankKeeper types.BankKeeper, + ss exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, accountKeeper: accountKeeper, - bankKeeper: bankKeeper, + legacySubspace: ss, } } -// Name returns the module's name. -func (am AppModule) Name() string { return am.AppModuleBasic.Name() } +// IsOnePerModuleType implements the depinject.OnePerModuleType interface. +func (am AppModule) IsOnePerModuleType() {} -// QuerierRoute returns the module's query routing key. -func (AppModule) QuerierRoute() string { return types.QuerierRoute } +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} // RegisterServices registers a GRPC query service to respond to the // module-specific GRPC queries. func (am AppModule) RegisterServices(cfg module.Configurator) { - types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) - types.RegisterQueryServer(cfg.QueryServer(), am.keeper) -} + // transactions deprecated in favor of v2 + if testing.Testing() { + types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) + } + types.RegisterQueryServer(cfg.QueryServer(), keeper.NewQueryServerImpl(am.keeper)) + + m := keeper.NewMigrator(am.keeper, am.legacySubspace) -// RegisterInvariants registers the module's invariants. -func (AppModule) RegisterInvariants(_ sdk.InvariantRegistry) { - // left empty because we don't have any invariants in this module + if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { + panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) + } } // InitGenesis performs the module's genesis initialization It returns // no validator updates. -func (am AppModule) InitGenesis( - ctx sdk.Context, - cdc codec.JSONCodec, - gs json.RawMessage, -) []abci.ValidatorUpdate { +func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, gs json.RawMessage) { var genState types.GenesisState // Initialize global index to index in genesis state cdc.MustUnmarshalJSON(gs, &genState) - InitGenesis(ctx, am.keeper, genState) - - return []abci.ValidatorUpdate{} + am.keeper.InitGenesis(ctx, am.accountKeeper, &genState) } // ExportGenesis returns the module's exported genesis state as raw JSON bytes. func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { - genState := ExportGenesis(ctx, am.keeper) + genState := am.keeper.ExportGenesis(ctx) return cdc.MustMarshalJSON(genState) } // ConsensusVersion implements ConsensusVersion. -func (AppModule) ConsensusVersion() uint64 { return 1 } +func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } + +// BeginBlock returns the begin blocker for the mint module. +func (am AppModule) BeginBlock(ctx context.Context) error { + return BeginBlocker(ctx, am.keeper) +} + +// AppModuleSimulation functions + +// GenerateGenesisState creates a randomized GenState of the mint module. +func (AppModule) GenerateGenesisState(simState *module.SimulationState) { + mintsimulation.RandomizedGenState(simState) +} + +// ProposalMsgs returns msgs used for governance proposals for simulations. +func (AppModule) ProposalMsgs(_ module.SimulationState) []simtypes.WeightedProposalMsg { + return mintsimulation.ProposalMsgs() +} + +// RegisterStoreDecoder registers a decoder for mint module's types. +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { + sdr[types.StoreKey] = simtypes.NewStoreDecoderFuncFromCollectionsSchema(am.keeper.Schema) +} + +// WeightedOperations doesn't return any mint module operation. +func (AppModule) WeightedOperations(_ module.SimulationState) []simtypes.WeightedOperation { + return nil +} + +// +// App Wiring Setup +// -// BeginBlock executes all ABCI BeginBlock logic respective to the module. -func (am AppModule) BeginBlock(ctx sdk.Context, _ abci.RequestBeginBlock) { - BeginBlocker(ctx, am.keeper) +func init() { + appmodule.Register(&mintmodulev1.Module{}, + appmodule.Provide(ProvideModule), + ) } -// EndBlock executes all ABCI EndBlock logic respective to the module. It -// returns no validator updates. -func (AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { - return []abci.ValidatorUpdate{} +type ModuleInputs struct { + depinject.In + + ModuleKey depinject.OwnModuleKey + Config *mintmodulev1.Module + StoreService store.KVStoreService + Cdc codec.Codec + + // LegacySubspace is used solely for migration of x/params managed parameters + LegacySubspace exported.Subspace `optional:"true"` + + AccountKeeper types.AccountKeeper + BankKeeper types.BankKeeper + StakingKeeper types.StakingKeeper +} + +type ModuleOutputs struct { + depinject.Out + + MintKeeper keeper.Keeper + Module appmodule.AppModule +} + +func ProvideModule(in ModuleInputs) ModuleOutputs { + feeCollectorName := in.Config.FeeCollectorName + if feeCollectorName == "" { + feeCollectorName = authtypes.FeeCollectorName + } + + // default to governance authority if not provided + authority := authtypes.NewModuleAddress(govtypes.ModuleName) + if in.Config.Authority != "" { + authority = authtypes.NewModuleAddressOrBech32Address(in.Config.Authority) + } + + k := keeper.NewKeeper( + in.Cdc, + in.StoreService, + in.StakingKeeper, + in.AccountKeeper, + in.BankKeeper, + feeCollectorName, + authority.String(), + ) + + // when no inflation calculation function is provided it will use the default types.DefaultInflationCalculationFn + m := NewAppModule(in.Cdc, k, in.AccountKeeper, in.LegacySubspace) + + return ModuleOutputs{MintKeeper: k, Module: m} } diff --git a/x/mint/module_simulation.go b/x/mint/module_simulation.go deleted file mode 100644 index c45b1963..00000000 --- a/x/mint/module_simulation.go +++ /dev/null @@ -1,47 +0,0 @@ -package mint - -import ( - //#nosec - - "github.com/cosmos/cosmos-sdk/baseapp" - simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/module" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/cosmos/cosmos-sdk/x/simulation" - - "github.com/sge-network/sge/testutil/sample" - mintsimulation "github.com/sge-network/sge/x/mint/simulation" - "github.com/sge-network/sge/x/mint/types" -) - -// avoid unused import issue -var ( - _ = sample.AccAddress - _ = mintsimulation.FindAccount - _ = simtestutil.StakePerAccount - _ = simulation.MsgEntryKind - _ = baseapp.Paramspace -) - -// GenerateGenesisState creates a randomized GenState of the module -func (AppModule) GenerateGenesisState(simState *module.SimulationState) { - mintsimulation.RandomizedGenState(simState) -} - -// ProposalContents doesn't return any content functions for governance proposals -func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalMsg { - return nil -} - -// RegisterStoreDecoder registers a decoder -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { - sdr[types.StoreKey] = mintsimulation.NewDecodeStore(am.cdc) -} - -// WeightedOperations returns the all the gov module operations with their respective weights. -func (AppModule) WeightedOperations(_ module.SimulationState) []simtypes.WeightedOperation { - operations := make([]simtypes.WeightedOperation, 0) - - return operations -} diff --git a/x/mint/module_test.go b/x/mint/module_test.go deleted file mode 100644 index 3d9d7ec2..00000000 --- a/x/mint/module_test.go +++ /dev/null @@ -1,20 +0,0 @@ -package mint_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/mint/types" -) - -func TestItCreatesModuleAccountOnInitBlock(t *testing.T) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - acc := tApp.AccountKeeper.GetAccount(ctx, authtypes.NewModuleAddress(types.ModuleName)) - require.NotNil(t, acc) -} diff --git a/x/mint/simulation/decoder.go b/x/mint/simulation/decoder.go deleted file mode 100644 index 185bcc47..00000000 --- a/x/mint/simulation/decoder.go +++ /dev/null @@ -1,27 +0,0 @@ -package simulation - -import ( - "bytes" - "fmt" - - "github.com/cosmos/cosmos-sdk/codec" - "github.com/cosmos/cosmos-sdk/types/kv" - - "github.com/sge-network/sge/x/mint/types" -) - -// NewDecodeStore returns a decoder function closure that unmarshal the KVPair's -// Value to the corresponding mint type. -func NewDecodeStore(cdc codec.BinaryCodec) func(kvA, kvB kv.Pair) string { - return func(kvA, kvB kv.Pair) string { - switch { - case bytes.Equal(kvA.Key, types.MinterKey): - var minterA, minterB types.Minter - cdc.MustUnmarshal(kvA.Value, &minterA) - cdc.MustUnmarshal(kvB.Value, &minterB) - return fmt.Sprintf("%v\n%v", minterA, minterB) - default: - panic(fmt.Sprintf(ErrTextInvalidMintKey, kvA.Key)) - } - } -} diff --git a/x/mint/simulation/decoder_test.go b/x/mint/simulation/decoder_test.go deleted file mode 100644 index 0cf16243..00000000 --- a/x/mint/simulation/decoder_test.go +++ /dev/null @@ -1,47 +0,0 @@ -package simulation_test - -import ( - "fmt" - "testing" - - sdkmath "cosmossdk.io/math" - "github.com/stretchr/testify/require" - - "github.com/cosmos/cosmos-sdk/types/kv" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/x/mint/simulation" - "github.com/sge-network/sge/x/mint/types" -) - -func TestDecodeStore(t *testing.T) { - cdc := app.MakeEncodingConfig().Marshaler - dec := simulation.NewDecodeStore(cdc) - - minter := types.NewMinter(sdkmath.LegacyOneDec(), sdkmath.LegacyNewDec(15), 1, sdkmath.LegacyNewDec(0)) - - kvPairs := kv.Pairs{ - Pairs: []kv.Pair{ - {Key: types.MinterKey, Value: cdc.MustMarshal(&minter)}, - {Key: []byte{0x99}, Value: []byte{0x99}}, - }, - } - tests := []struct { - name string - expectedLog string - }{ - {"Minter", fmt.Sprintf("%v\n%v", minter, minter)}, - {"other", ""}, - } - - for i, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - switch i { - case len(tests) - 1: - require.Panics(t, func() { dec(kvPairs.Pairs[i], kvPairs.Pairs[i]) }, tt.name) - default: - require.Equal(t, tt.expectedLog, dec(kvPairs.Pairs[i], kvPairs.Pairs[i]), tt.name) - } - }) - } -} diff --git a/x/mint/simulation/errors.go b/x/mint/simulation/errors.go deleted file mode 100644 index c34df5d5..00000000 --- a/x/mint/simulation/errors.go +++ /dev/null @@ -1,5 +0,0 @@ -package simulation - -const ( - ErrTextInvalidMintKey = "invalid mint key %X" -) diff --git a/x/mint/simulation/genesis.go b/x/mint/simulation/genesis.go index cb4cf51d..8445c68b 100644 --- a/x/mint/simulation/genesis.go +++ b/x/mint/simulation/genesis.go @@ -9,6 +9,7 @@ import ( sdkmath "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/types/module" + "github.com/spf13/cast" "github.com/sge-network/sge/app/params" "github.com/sge-network/sge/x/mint/types" @@ -26,7 +27,7 @@ func GenInflation(r *rand.Rand) sdkmath.LegacyDec { // GenBlocksPerYear randomized BlocksPerYear func GenBlocksPerYear(_ *rand.Rand) sdkmath.LegacyDec { - return sdkmath.LegacyNewDec(types.BlocksPerYear) + return sdkmath.LegacyMustNewDecFromStr(cast.ToString(types.BlocksPerYear)) } // RandomizedGenState generates a random GenesisState for mint @@ -34,7 +35,7 @@ func RandomizedGenState(simState *module.SimulationState) { // minter var inflation sdkmath.LegacyDec simState.AppParams.GetOrGenerate( - simState.Cdc, Inflation, &inflation, simState.Rand, + Inflation, &inflation, simState.Rand, func(r *rand.Rand) { inflation = GenInflation(r) }, ) diff --git a/x/mint/simulation/genesis_test.go b/x/mint/simulation/genesis_test.go index 5cb12aa9..34144dcf 100644 --- a/x/mint/simulation/genesis_test.go +++ b/x/mint/simulation/genesis_test.go @@ -21,7 +21,7 @@ import ( var params = types.Params{ MintDenom: "usge", BlocksPerYear: 100, - Phases: types.DefaultGenesis().Params.Phases, + Phases: types.DefaultGenesisState().Params.Phases, } // TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. @@ -49,7 +49,7 @@ func TestRandomizedGenState(t *testing.T) { var mintGenesis types.GenesisState simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &mintGenesis) - require.Equal(t, int64(6311520), mintGenesis.Params.BlocksPerYear) + require.Equal(t, uint64(6311520), mintGenesis.Params.BlocksPerYear) require.Equal(t, "usge", mintGenesis.Params.MintDenom) bp, _ := mintGenesis.Minter.BlockProvisions(mintGenesis.Params, 1) require.Equal(t, "0usge", bp.String()) diff --git a/x/mint/simulation/params.go b/x/mint/simulation/params.go deleted file mode 100644 index a06ba0f5..00000000 --- a/x/mint/simulation/params.go +++ /dev/null @@ -1,30 +0,0 @@ -package simulation - -// DONTCOVER - -import ( - "fmt" - //#nosec - "math/rand" - - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/cosmos/cosmos-sdk/x/simulation" - - "github.com/sge-network/sge/x/mint/types" -) - -const ( - keyBlocksPerYear = "BlocksPerYear" -) - -// ParamChanges defines the parameters that can be modified by param change proposals -// on the simulation -func ParamChanges(_ *rand.Rand) []simtypes.LegacyParamChange { - return []simtypes.LegacyParamChange{ - simulation.NewSimLegacyParamChange(types.ModuleName, keyBlocksPerYear, - func(r *rand.Rand) string { - return fmt.Sprintf("\"%s\"", GenBlocksPerYear(r)) - }, - ), - } -} diff --git a/x/mint/simulation/params_test.go b/x/mint/simulation/params_test.go deleted file mode 100644 index d57ae07b..00000000 --- a/x/mint/simulation/params_test.go +++ /dev/null @@ -1,36 +0,0 @@ -package simulation_test - -import ( - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/mint/simulation" -) - -func TestParamChanges(t *testing.T) { - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - expected := []struct { - composedKey string - key string - simValue string - subspace string - }{ - {"mint/BlocksPerYear", "BlocksPerYear", "\"6311520.000000000000000000\"", "mint"}, - } - - paramChanges := simulation.ParamChanges(r) - require.Len(t, paramChanges, 1) - - for i, p := range paramChanges { - require.Equal(t, expected[i].composedKey, p.ComposedKey()) - require.Equal(t, expected[i].key, p.Key()) - require.Equal(t, expected[i].simValue, p.SimValue()(r)) - require.Equal(t, expected[i].subspace, p.Subspace()) - } -} diff --git a/x/mint/simulation/proposals.go b/x/mint/simulation/proposals.go new file mode 100644 index 00000000..94c9ab04 --- /dev/null +++ b/x/mint/simulation/proposals.go @@ -0,0 +1,49 @@ +package simulation + +import ( + "math/rand" + + sdkmath "cosmossdk.io/math" + + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/address" + simtypes "github.com/cosmos/cosmos-sdk/types/simulation" + "github.com/cosmos/cosmos-sdk/x/simulation" + "github.com/sge-network/sge/x/mint/types" + "github.com/spf13/cast" +) + +// Simulation operation weights constants +const ( + DefaultWeightMsgUpdateParams int = 100 + + //nolint:gosec + OpWeightMsgUpdateParams = "op_weight_msg_update_params" +) + +// ProposalMsgs defines the module weighted proposals' contents +func ProposalMsgs() []simtypes.WeightedProposalMsg { + return []simtypes.WeightedProposalMsg{ + simulation.NewWeightedProposalMsg( + OpWeightMsgUpdateParams, + DefaultWeightMsgUpdateParams, + SimulateMsgUpdateParams, + ), + } +} + +// SimulateMsgUpdateParams returns a random MsgUpdateParams +func SimulateMsgUpdateParams(r *rand.Rand, _ sdk.Context, _ []simtypes.Account) sdk.Msg { + // use the default gov module account address as authority + var authority sdk.AccAddress = address.Module("gov") + + params := types.DefaultParams() + params.BlocksPerYear = cast.ToUint64(simtypes.RandIntBetween(r, 1, 1000000)) + params.ExcludeAmount = sdkmath.NewInt(cast.ToInt64(simtypes.RandIntBetween(r, 1, 100))) + params.MintDenom = simtypes.RandStringOfLength(r, 10) + + return &types.MsgUpdateParams{ + Authority: authority.String(), + Params: params, + } +} diff --git a/x/mint/simulation/proposals_test.go b/x/mint/simulation/proposals_test.go new file mode 100644 index 00000000..d03ff125 --- /dev/null +++ b/x/mint/simulation/proposals_test.go @@ -0,0 +1,41 @@ +package simulation_test + +import ( + "math/rand" + "testing" + + cmtproto "github.com/cometbft/cometbft/proto/tendermint/types" + "gotest.tools/v3/assert" + + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/address" + simtypes "github.com/cosmos/cosmos-sdk/types/simulation" + "github.com/sge-network/sge/x/mint/simulation" + "github.com/sge-network/sge/x/mint/types" +) + +func TestProposalMsgs(t *testing.T) { + // initialize parameters + s := rand.NewSource(1) + r := rand.New(s) + + ctx := sdk.NewContext(nil, cmtproto.Header{}, true, nil) + accounts := simtypes.RandomAccounts(r, 3) + + // execute ProposalMsgs function + weightedProposalMsgs := simulation.ProposalMsgs() + assert.Assert(t, len(weightedProposalMsgs) == 1) + + w0 := weightedProposalMsgs[0] + + // tests w0 interface: + assert.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) + assert.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) + + msg := w0.MsgSimulatorFn()(r, ctx, accounts) + msgUpdateParams, ok := msg.(*types.MsgUpdateParams) + assert.Assert(t, ok) + + assert.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) + assert.Equal(t, uint64(122877), msgUpdateParams.Params.BlocksPerYear) +} diff --git a/x/mint/testutil/app_config.go b/x/mint/testutil/app_config.go new file mode 100644 index 00000000..4f385518 --- /dev/null +++ b/x/mint/testutil/app_config.go @@ -0,0 +1,24 @@ +package testutil + +import ( + "github.com/cosmos/cosmos-sdk/testutil/configurator" + _ "github.com/cosmos/cosmos-sdk/x/auth" // import as blank for app wiring + _ "github.com/cosmos/cosmos-sdk/x/auth/tx/config" // import as blank for app wiring + _ "github.com/cosmos/cosmos-sdk/x/bank" // import as blank for app wiring + _ "github.com/cosmos/cosmos-sdk/x/consensus" // import as blank for app wiring + _ "github.com/cosmos/cosmos-sdk/x/genutil" // import as blank for app wiring + _ "github.com/cosmos/cosmos-sdk/x/mint" // import as blank for app wiring + _ "github.com/cosmos/cosmos-sdk/x/params" // import as blank for app wiring + _ "github.com/cosmos/cosmos-sdk/x/staking" // import as blank for app wiring +) + +var AppConfig = configurator.NewAppConfig( + configurator.AuthModule(), + configurator.BankModule(), + configurator.StakingModule(), + configurator.TxModule(), + configurator.ConsensusModule(), + configurator.ParamsModule(), + configurator.GenutilModule(), + configurator.MintModule(), +) diff --git a/x/mint/testutil/expected_keepers_mocks.go b/x/mint/testutil/expected_keepers_mocks.go new file mode 100644 index 00000000..db6474b9 --- /dev/null +++ b/x/mint/testutil/expected_keepers_mocks.go @@ -0,0 +1,197 @@ +// Code generated by MockGen. DO NOT EDIT. +// Source: x/mint/types/expected_keepers.go + +// Package testutil is a generated GoMock package. +package testutil + +import ( + context "context" + reflect "reflect" + + math "cosmossdk.io/math" + types "github.com/cosmos/cosmos-sdk/types" + gomock "github.com/golang/mock/gomock" +) + +// MockStakingKeeper is a mock of StakingKeeper interface. +type MockStakingKeeper struct { + ctrl *gomock.Controller + recorder *MockStakingKeeperMockRecorder +} + +// MockStakingKeeperMockRecorder is the mock recorder for MockStakingKeeper. +type MockStakingKeeperMockRecorder struct { + mock *MockStakingKeeper +} + +// NewMockStakingKeeper creates a new mock instance. +func NewMockStakingKeeper(ctrl *gomock.Controller) *MockStakingKeeper { + mock := &MockStakingKeeper{ctrl: ctrl} + mock.recorder = &MockStakingKeeperMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockStakingKeeper) EXPECT() *MockStakingKeeperMockRecorder { + return m.recorder +} + +// BondedRatio mocks base method. +func (m *MockStakingKeeper) BondedRatio(ctx context.Context) (math.LegacyDec, error) { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "BondedRatio", ctx) + ret0, _ := ret[0].(math.LegacyDec) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// BondedRatio indicates an expected call of BondedRatio. +func (mr *MockStakingKeeperMockRecorder) BondedRatio(ctx interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BondedRatio", reflect.TypeOf((*MockStakingKeeper)(nil).BondedRatio), ctx) +} + +// StakingTokenSupply mocks base method. +func (m *MockStakingKeeper) StakingTokenSupply(ctx context.Context) (math.Int, error) { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "StakingTokenSupply", ctx) + ret0, _ := ret[0].(math.Int) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// StakingTokenSupply indicates an expected call of StakingTokenSupply. +func (mr *MockStakingKeeperMockRecorder) StakingTokenSupply(ctx interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StakingTokenSupply", reflect.TypeOf((*MockStakingKeeper)(nil).StakingTokenSupply), ctx) +} + +// MockAccountKeeper is a mock of AccountKeeper interface. +type MockAccountKeeper struct { + ctrl *gomock.Controller + recorder *MockAccountKeeperMockRecorder +} + +// MockAccountKeeperMockRecorder is the mock recorder for MockAccountKeeper. +type MockAccountKeeperMockRecorder struct { + mock *MockAccountKeeper +} + +// NewMockAccountKeeper creates a new mock instance. +func NewMockAccountKeeper(ctrl *gomock.Controller) *MockAccountKeeper { + mock := &MockAccountKeeper{ctrl: ctrl} + mock.recorder = &MockAccountKeeperMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockAccountKeeper) EXPECT() *MockAccountKeeperMockRecorder { + return m.recorder +} + +// GetModuleAccount mocks base method. +func (m *MockAccountKeeper) GetModuleAccount(ctx context.Context, moduleName string) types.ModuleAccountI { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "GetModuleAccount", ctx, moduleName) + ret0, _ := ret[0].(types.ModuleAccountI) + return ret0 +} + +// GetModuleAccount indicates an expected call of GetModuleAccount. +func (mr *MockAccountKeeperMockRecorder) GetModuleAccount(ctx, moduleName interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetModuleAccount", reflect.TypeOf((*MockAccountKeeper)(nil).GetModuleAccount), ctx, moduleName) +} + +// GetModuleAddress mocks base method. +func (m *MockAccountKeeper) GetModuleAddress(name string) types.AccAddress { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "GetModuleAddress", name) + ret0, _ := ret[0].(types.AccAddress) + return ret0 +} + +// GetModuleAddress indicates an expected call of GetModuleAddress. +func (mr *MockAccountKeeperMockRecorder) GetModuleAddress(name interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetModuleAddress", reflect.TypeOf((*MockAccountKeeper)(nil).GetModuleAddress), name) +} + +// MockBankKeeper is a mock of BankKeeper interface. +type MockBankKeeper struct { + ctrl *gomock.Controller + recorder *MockBankKeeperMockRecorder +} + +// MockBankKeeperMockRecorder is the mock recorder for MockBankKeeper. +type MockBankKeeperMockRecorder struct { + mock *MockBankKeeper +} + +// NewMockBankKeeper creates a new mock instance. +func NewMockBankKeeper(ctrl *gomock.Controller) *MockBankKeeper { + mock := &MockBankKeeper{ctrl: ctrl} + mock.recorder = &MockBankKeeperMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockBankKeeper) EXPECT() *MockBankKeeperMockRecorder { + return m.recorder +} + +// GetSupply mocks base method. +func (m *MockBankKeeper) GetSupply(ctx context.Context, denom string) types.Coin { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "GetSupply", ctx, denom) + ret0, _ := ret[0].(types.Coin) + return ret0 +} + +// GetSupply indicates an expected call of GetSupply. +func (mr *MockBankKeeperMockRecorder) GetSupply(ctx, denom interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetSupply", reflect.TypeOf((*MockBankKeeper)(nil).GetSupply), ctx, denom) +} + +// MintCoins mocks base method. +func (m *MockBankKeeper) MintCoins(ctx context.Context, name string, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "MintCoins", ctx, name, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// MintCoins indicates an expected call of MintCoins. +func (mr *MockBankKeeperMockRecorder) MintCoins(ctx, name, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "MintCoins", reflect.TypeOf((*MockBankKeeper)(nil).MintCoins), ctx, name, amt) +} + +// SendCoinsFromModuleToAccount mocks base method. +func (m *MockBankKeeper) SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr types.AccAddress, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SendCoinsFromModuleToAccount", ctx, senderModule, recipientAddr, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// SendCoinsFromModuleToAccount indicates an expected call of SendCoinsFromModuleToAccount. +func (mr *MockBankKeeperMockRecorder) SendCoinsFromModuleToAccount(ctx, senderModule, recipientAddr, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoinsFromModuleToAccount", reflect.TypeOf((*MockBankKeeper)(nil).SendCoinsFromModuleToAccount), ctx, senderModule, recipientAddr, amt) +} + +// SendCoinsFromModuleToModule mocks base method. +func (m *MockBankKeeper) SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SendCoinsFromModuleToModule", ctx, senderModule, recipientModule, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// SendCoinsFromModuleToModule indicates an expected call of SendCoinsFromModuleToModule. +func (mr *MockBankKeeperMockRecorder) SendCoinsFromModuleToModule(ctx, senderModule, recipientModule, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoinsFromModuleToModule", reflect.TypeOf((*MockBankKeeper)(nil).SendCoinsFromModuleToModule), ctx, senderModule, recipientModule, amt) +} diff --git a/x/mint/types/codec.go b/x/mint/types/codec.go index c1dcfe68..0145f37e 100644 --- a/x/mint/types/codec.go +++ b/x/mint/types/codec.go @@ -2,6 +2,7 @@ package types import ( "github.com/cosmos/cosmos-sdk/codec" + "github.com/cosmos/cosmos-sdk/codec/legacy" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" @@ -9,24 +10,17 @@ import ( // RegisterLegacyAminoCodec registers the necessary x/mint interfaces and concrete types // on the provided LegacyAmino codec. These types are used for Amino JSON serialization. -func RegisterLegacyAminoCodec(_ *codec.LegacyAmino) { - // left empty because no message is available in this module +func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { + cdc.RegisterConcrete(Params{}, "cosmos-sdk/x/mint/Params", nil) + legacy.RegisterAminoMsg(cdc, &MsgUpdateParams{}, "cosmos-sdk/x/mint/MsgUpdateParams") } // RegisterInterfaces registers the module interface types func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { - msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) -} + registry.RegisterImplementations( + (*sdk.Msg)(nil), + &MsgUpdateParams{}, + ) -var ( - // amino is the legacy amino codec - amino = codec.NewLegacyAmino() - // ModuleCdc is the codec of the module - ModuleCdc = codec.NewAminoCodec(amino) -) - -func init() { - RegisterLegacyAminoCodec(amino) - // cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } diff --git a/x/mint/types/expected_keepers.go b/x/mint/types/expected_keepers.go index dbd4f9c5..3656694a 100644 --- a/x/mint/types/expected_keepers.go +++ b/x/mint/types/expected_keepers.go @@ -1,35 +1,38 @@ package types import ( + context "context" + sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" ) // StakingKeeper defines the expected staking keeper type StakingKeeper interface { - StakingTokenSupply(ctx sdk.Context) sdkmath.Int - BondedRatio(ctx sdk.Context) sdkmath.LegacyDec + StakingTokenSupply(ctx context.Context) (sdkmath.Int, error) + BondedRatio(ctx context.Context) (sdkmath.LegacyDec, error) } // AccountKeeper defines the contract required for account APIs. type AccountKeeper interface { GetModuleAddress(name string) sdk.AccAddress + GetModuleAccount(ctx context.Context, moduleName string) sdk.ModuleAccountI } // BankKeeper defines the contract needed to be fulfilled for banking and supply // dependencies. type BankKeeper interface { - GetSupply(ctx sdk.Context, denom string) sdk.Coin + GetSupply(ctx context.Context, denom string) sdk.Coin SendCoinsFromModuleToAccount( - ctx sdk.Context, + ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins, ) error SendCoinsFromModuleToModule( - ctx sdk.Context, + ctx context.Context, senderModule, recipientModule string, amt sdk.Coins, ) error - MintCoins(ctx sdk.Context, name string, amt sdk.Coins) error + MintCoins(ctx context.Context, name string, amt sdk.Coins) error } diff --git a/x/mint/types/genesis.go b/x/mint/types/genesis.go index 55e60724..c9e09eb2 100644 --- a/x/mint/types/genesis.go +++ b/x/mint/types/genesis.go @@ -11,19 +11,20 @@ func NewGenesisState(minter Minter, params Params) *GenesisState { } } -// DefaultGenesis returns the default genesis state -func DefaultGenesis() *GenesisState { +// DefaultGenesisState creates a default GenesisState object +func DefaultGenesisState() *GenesisState { return &GenesisState{ Minter: DefaultInitialMinter(), Params: DefaultParams(), } } -// Validate performs basic genesis state validation returning an error upon any -// failure. -func (gs GenesisState) Validate() error { - if err := gs.Params.Validate(); err != nil { +// ValidateGenesis validates the provided genesis state to ensure the +// expected invariants holds. +func ValidateGenesis(data GenesisState) error { + if err := data.Params.Validate(); err != nil { return err } - return ValidateMinter(gs.Minter) + + return ValidateMinter(data.Minter) } diff --git a/x/mint/types/genesis.pb.go b/x/mint/types/genesis.pb.go index b9548291..1e717a1a 100644 --- a/x/mint/types/genesis.pb.go +++ b/x/mint/types/genesis.pb.go @@ -1,10 +1,11 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/mint/genesis.proto +// source: sge/mint/v1beta/genesis.proto package types import ( fmt "fmt" + _ "github.com/cosmos/cosmos-sdk/types/tx/amino" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" @@ -35,7 +36,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_77c6a42e62252e0d, []int{0} + return fileDescriptor_c17803b013ca6da7, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -79,27 +80,28 @@ func (m *GenesisState) GetParams() Params { } func init() { - proto.RegisterType((*GenesisState)(nil), "sgenetwork.sge.mint.GenesisState") + proto.RegisterType((*GenesisState)(nil), "sge.mint.v1beta.GenesisState") } -func init() { proto.RegisterFile("sgenetwork/sge/mint/genesis.proto", fileDescriptor_77c6a42e62252e0d) } +func init() { proto.RegisterFile("sge/mint/v1beta/genesis.proto", fileDescriptor_c17803b013ca6da7) } -var fileDescriptor_77c6a42e62252e0d = []byte{ - // 217 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0xcd, 0xcc, 0x2b, 0xd1, - 0x07, 0x09, 0x15, 0x67, 0x16, 0xeb, 0x15, 0x14, 0xe5, 0x97, 0xe4, 0x0b, 0x09, 0x23, 0x94, 0xe8, - 0x15, 0xa7, 0xa7, 0xea, 0x81, 0x94, 0x48, 0x89, 0xa4, 0xe7, 0xa7, 0xe7, 0x83, 0xe5, 0xf5, 0x41, - 0x2c, 0x88, 0x52, 0x29, 0x05, 0x6c, 0xa6, 0x15, 0x24, 0x16, 0x25, 0xe6, 0x16, 0xe3, 0x53, 0x01, - 0x22, 0x52, 0x8b, 0x20, 0x2a, 0x94, 0x5a, 0x18, 0xb9, 0x78, 0xdc, 0x21, 0x0e, 0x08, 0x2e, 0x49, - 0x2c, 0x49, 0x15, 0xb2, 0xe4, 0x62, 0x83, 0x28, 0x90, 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x36, 0x92, - 0xd6, 0xc3, 0xe2, 0x20, 0x3d, 0x5f, 0xb0, 0x12, 0x27, 0x96, 0x13, 0xf7, 0xe4, 0x19, 0x82, 0xa0, - 0x1a, 0x40, 0x5a, 0x21, 0xb6, 0x4b, 0x30, 0xe1, 0xd1, 0x1a, 0x00, 0x56, 0x02, 0xd3, 0x0a, 0xd1, - 0xe0, 0xe4, 0x78, 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x4e, - 0x78, 0x2c, 0xc7, 0x70, 0xe1, 0xb1, 0x1c, 0xc3, 0x8d, 0xc7, 0x72, 0x0c, 0x51, 0xea, 0xe9, 0x99, - 0x25, 0x19, 0xa5, 0x49, 0x7a, 0xc9, 0xf9, 0xb9, 0x20, 0x2f, 0xe8, 0x22, 0x7b, 0xa7, 0x02, 0xe2, - 0xa1, 0x92, 0xca, 0x82, 0xd4, 0xe2, 0x24, 0x36, 0xb0, 0x87, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, - 0xff, 0x94, 0x31, 0x50, 0x21, 0x64, 0x01, 0x00, 0x00, +var fileDescriptor_c17803b013ca6da7 = []byte{ + // 238 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2d, 0x4e, 0x4f, 0xd5, + 0xcf, 0xcd, 0xcc, 0x2b, 0xd1, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, + 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x2f, 0x4e, 0x4f, 0xd5, 0x03, + 0x49, 0xeb, 0x41, 0xa4, 0xa5, 0x04, 0x13, 0x73, 0x33, 0xf3, 0xf2, 0xf5, 0xc1, 0x24, 0x44, 0x8d, + 0x94, 0x48, 0x7a, 0x7e, 0x7a, 0x3e, 0x98, 0xa9, 0x0f, 0x62, 0x41, 0x45, 0x65, 0xd0, 0x0d, 0x06, + 0xb1, 0x53, 0x8b, 0x70, 0xc9, 0x16, 0x24, 0x16, 0x25, 0xe6, 0x42, 0x6d, 0x55, 0x6a, 0x63, 0xe4, + 0xe2, 0x71, 0x87, 0xb8, 0x23, 0xb8, 0x24, 0xb1, 0x24, 0x55, 0xc8, 0x8a, 0x8b, 0x0d, 0xa2, 0x5d, + 0x82, 0x51, 0x81, 0x51, 0x83, 0xdb, 0x48, 0x5c, 0x0f, 0xcd, 0x5d, 0x7a, 0xbe, 0x60, 0x69, 0x27, + 0xce, 0x13, 0xf7, 0xe4, 0x19, 0x56, 0x3c, 0xdf, 0xa0, 0xc5, 0x18, 0x04, 0xd5, 0x01, 0xd2, 0x0b, + 0x31, 0x5c, 0x82, 0x09, 0x87, 0xde, 0x00, 0xb0, 0x34, 0x8a, 0x5e, 0x88, 0x0e, 0x27, 0xc7, 0x13, + 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, + 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0x52, 0x4f, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, + 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x2f, 0x4e, 0x4f, 0xd5, 0xcd, 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, + 0x06, 0xb1, 0xf5, 0x2b, 0x20, 0x3e, 0x2b, 0xa9, 0x2c, 0x48, 0x2d, 0x4e, 0x62, 0x03, 0x7b, 0xc9, + 0x18, 0x10, 0x00, 0x00, 0xff, 0xff, 0x6a, 0x7e, 0x4c, 0xb2, 0x69, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/mint/types/genesis_test.go b/x/mint/types/genesis_test.go index 03059cba..67cd6eb4 100644 --- a/x/mint/types/genesis_test.go +++ b/x/mint/types/genesis_test.go @@ -11,9 +11,9 @@ import ( ) func TestNewGenesisState(t *testing.T) { - defaultGs := types.DefaultGenesis() + defaultGs := types.DefaultGenesisState() gs := types.NewGenesisState(defaultGs.Minter, defaultGs.Params) - require.NoError(t, gs.Validate()) + require.NoError(t, types.ValidateGenesis(*gs)) } func TestGenesisStateValidate(t *testing.T) { @@ -24,7 +24,7 @@ func TestGenesisStateValidate(t *testing.T) { }{ { desc: "default is valid", - genState: types.DefaultGenesis(), + genState: types.DefaultGenesisState(), valid: true, }, { @@ -157,7 +157,7 @@ func TestGenesisStateValidate(t *testing.T) { }, } { t.Run(tc.desc, func(t *testing.T) { - err := tc.genState.Validate() + err := types.ValidateGenesis(*tc.genState) if tc.valid { require.NoError(t, err) } else { diff --git a/x/mint/types/keys.go b/x/mint/types/keys.go index 3cbbc4bd..f8266f81 100644 --- a/x/mint/types/keys.go +++ b/x/mint/types/keys.go @@ -1,5 +1,13 @@ package types +// keys +var ( + // MinterKey is the key to use for the keeper store. + MinterKey = []byte{0x00} + // ParamsKey is the key to use for the keeper store. + ParamsKey = []byte{0x01} +) + // module constants const ( // ModuleName defines the module name @@ -7,13 +15,4 @@ const ( // StoreKey defines the primary module store key StoreKey = ModuleName - - // QuerierRoute defines the module's query routing key - QuerierRoute = ModuleName -) - -// keys -var ( - // MinterKey is the key to use for the keeper store. - MinterKey = []byte{0x00} ) diff --git a/x/mint/types/minter.pb.go b/x/mint/types/minter.pb.go index a4ce36f7..c378b5a6 100644 --- a/x/mint/types/minter.pb.go +++ b/x/mint/types/minter.pb.go @@ -1,11 +1,12 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/mint/minter.proto +// source: sge/mint/v1beta/minter.proto package types import ( cosmossdk_io_math "cosmossdk.io/math" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" @@ -41,7 +42,7 @@ func (m *Minter) Reset() { *m = Minter{} } func (m *Minter) String() string { return proto.CompactTextString(m) } func (*Minter) ProtoMessage() {} func (*Minter) Descriptor() ([]byte, []int) { - return fileDescriptor_a969bd1a18aad64f, []int{0} + return fileDescriptor_94c904bea9e19bc3, []int{0} } func (m *Minter) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -78,33 +79,34 @@ func (m *Minter) GetPhaseStep() int32 { } func init() { - proto.RegisterType((*Minter)(nil), "sgenetwork.sge.mint.Minter") + proto.RegisterType((*Minter)(nil), "sge.mint.v1beta.Minter") } -func init() { proto.RegisterFile("sgenetwork/sge/mint/minter.proto", fileDescriptor_a969bd1a18aad64f) } +func init() { proto.RegisterFile("sge/mint/v1beta/minter.proto", fileDescriptor_94c904bea9e19bc3) } -var fileDescriptor_a969bd1a18aad64f = []byte{ - // 307 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x28, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0xcd, 0xcc, 0x2b, 0x01, - 0x13, 0xa9, 0x45, 0x7a, 0x05, 0x45, 0xf9, 0x25, 0xf9, 0x42, 0xc2, 0x08, 0x15, 0x7a, 0xc5, 0xe9, - 0xa9, 0x7a, 0x20, 0x49, 0x29, 0x91, 0xf4, 0xfc, 0xf4, 0x7c, 0xb0, 0xbc, 0x3e, 0x88, 0x05, 0x51, - 0xaa, 0xb4, 0x94, 0x89, 0x8b, 0xcd, 0x17, 0xac, 0x57, 0xc8, 0x91, 0x8b, 0x33, 0x33, 0x2f, 0x2d, - 0x27, 0xb1, 0x24, 0x33, 0x3f, 0x4f, 0x82, 0x51, 0x81, 0x51, 0x83, 0xd3, 0x49, 0xf9, 0xc4, 0x3d, - 0x79, 0x86, 0x5b, 0xf7, 0xe4, 0xa5, 0x93, 0xf3, 0x8b, 0x73, 0xf3, 0x8b, 0x8b, 0x53, 0xb2, 0xf5, - 0x32, 0xf3, 0xf5, 0x73, 0x13, 0x4b, 0x32, 0xf4, 0x7c, 0x52, 0xd3, 0x13, 0x93, 0x2b, 0x5d, 0x52, - 0x93, 0x83, 0x10, 0xba, 0x84, 0x64, 0xb9, 0xb8, 0x0a, 0x32, 0x12, 0x8b, 0x53, 0xe3, 0x8b, 0x4b, - 0x52, 0x0b, 0x24, 0x98, 0x14, 0x18, 0x35, 0x58, 0x83, 0x38, 0xc1, 0x22, 0xc1, 0x25, 0xa9, 0x05, - 0x42, 0x99, 0x5c, 0x02, 0x10, 0xe9, 0x82, 0xa2, 0xfc, 0xb2, 0xcc, 0xe2, 0xcc, 0xfc, 0xbc, 0x62, - 0x09, 0x66, 0xb0, 0x45, 0x76, 0x44, 0x58, 0xf4, 0xe9, 0x9e, 0xbc, 0x78, 0x65, 0x62, 0x6e, 0x8e, - 0x95, 0x12, 0xba, 0x21, 0x4a, 0x41, 0xfc, 0x60, 0xa1, 0x00, 0xb8, 0x88, 0x90, 0x1f, 0x97, 0x40, - 0x49, 0x51, 0x69, 0x5e, 0x72, 0x62, 0x49, 0x6a, 0x4a, 0x7c, 0x49, 0x7e, 0x76, 0x6a, 0x5e, 0xb1, - 0x04, 0x0b, 0xf1, 0x7e, 0xe2, 0x87, 0x6b, 0x0e, 0x01, 0xeb, 0x75, 0x72, 0x3c, 0xf1, 0x48, 0x8e, - 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, - 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xf5, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, - 0xfc, 0x5c, 0x50, 0x74, 0xe8, 0x22, 0x47, 0x4d, 0x05, 0x24, 0x72, 0x4a, 0x2a, 0x0b, 0x52, 0x8b, - 0x93, 0xd8, 0xc0, 0x21, 0x6e, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x93, 0xe9, 0x58, 0x3d, 0xc0, - 0x01, 0x00, 0x00, +var fileDescriptor_94c904bea9e19bc3 = []byte{ + // 333 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x91, 0xb1, 0x4e, 0x2a, 0x41, + 0x14, 0x86, 0x77, 0xb9, 0xf7, 0x92, 0x30, 0x0d, 0x64, 0x73, 0x93, 0xbb, 0x17, 0x75, 0x21, 0x34, + 0xd2, 0xb0, 0x1b, 0x62, 0x67, 0x27, 0xa1, 0xc4, 0x68, 0xd0, 0xca, 0x98, 0x90, 0x61, 0x39, 0x0e, + 0x13, 0xd8, 0x39, 0x9b, 0x9d, 0x03, 0xc8, 0x5b, 0xf8, 0x30, 0x3e, 0x04, 0x9d, 0xc4, 0xca, 0x58, + 0x10, 0x03, 0x6f, 0xe0, 0x13, 0x18, 0x66, 0x0c, 0x26, 0x54, 0xc6, 0xee, 0x9f, 0xff, 0x3f, 0xf9, + 0xfe, 0x39, 0x39, 0xec, 0x50, 0x0b, 0x88, 0x12, 0xa9, 0x28, 0x9a, 0x36, 0xfb, 0x40, 0xdc, 0x68, + 0xc8, 0xc2, 0x34, 0x43, 0x42, 0xaf, 0xa8, 0x05, 0x84, 0x5b, 0x27, 0xb4, 0x69, 0xf9, 0x7f, 0x8c, + 0x3a, 0x41, 0xdd, 0x33, 0x71, 0x64, 0x1f, 0x76, 0xb6, 0xfc, 0x57, 0xa0, 0x40, 0xeb, 0x6f, 0x95, + 0x75, 0x6b, 0x4f, 0x39, 0x96, 0x3f, 0x37, 0x48, 0xef, 0x82, 0x15, 0xa4, 0xba, 0x1b, 0x73, 0x92, + 0xa8, 0x7c, 0xb7, 0xea, 0xd6, 0x0b, 0xad, 0xe6, 0x62, 0x55, 0x71, 0x5e, 0x57, 0x95, 0x03, 0x4b, + 0xd2, 0x83, 0x51, 0x28, 0x31, 0x4a, 0x38, 0x0d, 0xc3, 0x0e, 0x08, 0x1e, 0xcf, 0xdb, 0x10, 0x3f, + 0x3f, 0x36, 0xd8, 0x67, 0x51, 0x1b, 0xe2, 0xee, 0x17, 0xc3, 0x3b, 0x62, 0x2c, 0x1d, 0x72, 0x0d, + 0x3d, 0x4d, 0x90, 0xfa, 0xb9, 0xaa, 0x5b, 0xff, 0xd3, 0x2d, 0x18, 0xe7, 0x8a, 0x20, 0xf5, 0x66, + 0xac, 0x64, 0xe3, 0x34, 0xc3, 0xa9, 0xd4, 0x12, 0x95, 0xf6, 0x7f, 0x99, 0xda, 0xce, 0x37, 0x6a, + 0xdf, 0x57, 0x95, 0x7f, 0x73, 0x9e, 0x8c, 0x4f, 0x6b, 0xfb, 0x90, 0xda, 0xde, 0x8f, 0x8a, 0x66, + 0xe0, 0x72, 0x97, 0x7b, 0xb7, 0xac, 0x44, 0xd9, 0x44, 0xc5, 0x9c, 0x60, 0xd0, 0x23, 0x1c, 0x81, + 0xd2, 0xfe, 0xef, 0x9f, 0xee, 0x5b, 0xdc, 0xa1, 0xae, 0x0d, 0xa9, 0x75, 0xb6, 0x58, 0x07, 0xee, + 0x72, 0x1d, 0xb8, 0x6f, 0xeb, 0xc0, 0x7d, 0xd8, 0x04, 0xce, 0x72, 0x13, 0x38, 0x2f, 0x9b, 0xc0, + 0xb9, 0x39, 0x16, 0x92, 0x86, 0x93, 0x7e, 0x18, 0x63, 0x12, 0x69, 0x01, 0x0d, 0x05, 0x34, 0xc3, + 0x6c, 0xb4, 0xd5, 0xd1, 0xbd, 0x3d, 0x32, 0xcd, 0x53, 0xd0, 0xfd, 0xbc, 0xb9, 0xcd, 0xc9, 0x47, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x58, 0xc3, 0x26, 0x17, 0xfd, 0x01, 0x00, 0x00, } func (m *Minter) Marshal() (dAtA []byte, err error) { diff --git a/x/mint/types/minter_test.go b/x/mint/types/minter_test.go index 228332c9..c64ad56c 100644 --- a/x/mint/types/minter_test.go +++ b/x/mint/types/minter_test.go @@ -64,10 +64,10 @@ func TestNextPhase(t *testing.T) { minter := types.DefaultInitialMinter() params := types.DefaultParams() - blocksPerYear := int64(100) + blocksPerYear := uint64(100) tests := []struct { currentBlock, currentPhase int64 - blocksYear int64 + blocksYear uint64 expPhase int }{ {1, 0, blocksPerYear, 1}, @@ -231,7 +231,7 @@ func TestBlockProvisions(t *testing.T) { minter := types.DefaultInitialMinter() params := types.DefaultParams() - blocksPerYear := int64(51480) + blocksPerYear := uint64(51480) totalSupply := sdkmath.NewIntFromUint64(1150000000000000) params.ExcludeAmount = sdkmath.NewInt(445000000000025) tests := []struct { diff --git a/x/mint/types/msgs.go b/x/mint/types/msgs.go deleted file mode 100644 index 0e66bc57..00000000 --- a/x/mint/types/msgs.go +++ /dev/null @@ -1,32 +0,0 @@ -package types - -import ( - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" -) - -var _ sdk.Msg = &MsgUpdateParams{} - -// GetSignBytes implements the LegacyMsg interface. -func (m MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) -} - -// GetSigners returns the expected signers for a MsgUpdateParams message. -func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { - addr, _ := sdk.AccAddressFromBech32(m.Authority) - return []sdk.AccAddress{addr} -} - -// ValidateBasic does a sanity check on the provided data. -func (m *MsgUpdateParams) ValidateBasic() error { - if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { - return sdkerrors.Wrap(err, "invalid authority address") - } - - if err := m.Params.Validate(); err != nil { - return err - } - - return nil -} diff --git a/x/mint/types/params.go b/x/mint/types/params.go index 3d84211b..bb896785 100644 --- a/x/mint/types/params.go +++ b/x/mint/types/params.go @@ -11,6 +11,7 @@ import ( sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + "github.com/spf13/cast" "github.com/sge-network/sge/app/params" ) @@ -37,19 +38,7 @@ const ( yearHours = 8766 // 8766 is coming from 365.25×24h YearSeconds = 60 * 60 * yearHours expectedBlockTime = 5 // in seconds - BlocksPerYear = int64(YearSeconds / expectedBlockTime) -) - -// parameter store keys -var ( - // KeyMintDenom is the mint denom param key - keyMintDenom = []byte("MintDenom") - // KeyBlocksPerYear is the blocks per year param key - keyBlocksPerYear = []byte("BlocksPerYear") - // KeyPhases is the inflation phases param key - keyPhases = []byte("Phases") - // KeyExcludeAmount is the excluded amount from inflation calculation param key - keyExcludeAmount = []byte("ExcludeAmount") + BlocksPerYear = uint64(YearSeconds / expectedBlockTime) ) var ( @@ -101,13 +90,8 @@ var ( } ) -// ParamKeyTable the param key table for launch module -func ParamKeyTable() paramtypes.KeyTable { - return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) -} - // NewParams creates a new Params instance -func NewParams(mintDenom string, blocksPerYear int64, excludeAmount sdkmath.Int, phases []Phase) Params { +func NewParams(mintDenom string, blocksPerYear uint64, excludeAmount sdkmath.Int, phases []Phase) Params { return Params{ MintDenom: mintDenom, BlocksPerYear: blocksPerYear, @@ -126,16 +110,6 @@ func DefaultParams() Params { } } -// ParamSetPairs get the params.ParamSet -func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { - return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(keyMintDenom, &p.MintDenom, validateMintDenom), - paramtypes.NewParamSetPair(keyBlocksPerYear, &p.BlocksPerYear, validateBlocksPerYear), - paramtypes.NewParamSetPair(keyPhases, &p.Phases, validatePhases), - paramtypes.NewParamSetPair(keyExcludeAmount, &p.ExcludeAmount, validateExcludeAmount), - } -} - // Validate validates the set of params func (p Params) Validate() error { if err := validateMintDenom(p.MintDenom); err != nil { @@ -222,7 +196,7 @@ func (p Params) getPhaseBlocks(phaseStep int) sdkmath.LegacyDec { // current block = 50 // so the changing point of the phase is in block number 50.5 which is not applicable // the 0.5 provisions will be calculated in the BlockProvisions method of Minter - phaseBlocks := yearCoefficient.Mul(sdkmath.LegacyNewDec(p.BlocksPerYear)).TruncateDec() + phaseBlocks := yearCoefficient.Mul(sdkmath.LegacyMustNewDecFromStr(cast.ToString(p.BlocksPerYear))).TruncateDec() return phaseBlocks } @@ -253,7 +227,7 @@ func validateExcludeAmount(i interface{}) error { } func validateBlocksPerYear(i interface{}) error { - v, ok := i.(int64) + v, ok := i.(uint64) if !ok { return fmt.Errorf(ErrTextInvalidParamType, i) } diff --git a/x/mint/types/params.pb.go b/x/mint/types/params.pb.go index 0d20ebfb..96f764a7 100644 --- a/x/mint/types/params.pb.go +++ b/x/mint/types/params.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/mint/params.proto +// source: sge/mint/v1beta/params.proto package types @@ -29,7 +29,7 @@ type Params struct { // mint_denom is the type of coin to mint. MintDenom string `protobuf:"bytes,1,opt,name=mint_denom,json=mintDenom,proto3" json:"mint_denom,omitempty"` // blocks_per_year is expected blocks per year. - BlocksPerYear int64 `protobuf:"varint,2,opt,name=blocks_per_year,json=blocksPerYear,proto3" json:"blocks_per_year,omitempty" yaml:"blocks_per_year"` + BlocksPerYear uint64 `protobuf:"varint,2,opt,name=blocks_per_year,json=blocksPerYear,proto3" json:"blocks_per_year,omitempty" yaml:"blocks_per_year"` // phases contains phases of inflation. Phases []Phase `protobuf:"bytes,3,rep,name=phases,proto3" json:"phases" yaml:"phases"` // exclude_amount is the excluded amount form being calculated in inflation. @@ -39,7 +39,7 @@ type Params struct { func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_1a26370164e410ff, []int{0} + return fileDescriptor_2a08e4df58e642f1, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -75,7 +75,7 @@ func (m *Params) GetMintDenom() string { return "" } -func (m *Params) GetBlocksPerYear() int64 { +func (m *Params) GetBlocksPerYear() uint64 { if m != nil { return m.BlocksPerYear } @@ -90,35 +90,35 @@ func (m *Params) GetPhases() []Phase { } func init() { - proto.RegisterType((*Params)(nil), "sgenetwork.sge.mint.Params") + proto.RegisterType((*Params)(nil), "sge.mint.v1beta.Params") } -func init() { proto.RegisterFile("sgenetwork/sge/mint/params.proto", fileDescriptor_1a26370164e410ff) } +func init() { proto.RegisterFile("sge/mint/v1beta/params.proto", fileDescriptor_2a08e4df58e642f1) } -var fileDescriptor_1a26370164e410ff = []byte{ - // 346 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x90, 0xcf, 0x6a, 0xf2, 0x40, - 0x14, 0xc5, 0x13, 0x15, 0xc1, 0x7c, 0xf8, 0x15, 0xd2, 0x5a, 0x42, 0xa0, 0x99, 0x90, 0x4d, 0xdd, - 0x74, 0x02, 0x2d, 0x74, 0xe1, 0xce, 0xd0, 0x8d, 0x3b, 0xc9, 0xae, 0x85, 0x12, 0xc6, 0x78, 0x89, - 0xa2, 0x93, 0x09, 0x33, 0x23, 0xd5, 0xb7, 0xe8, 0xb2, 0xd0, 0x4d, 0x1f, 0xc7, 0xa5, 0xcb, 0xd2, - 0x45, 0x28, 0xfa, 0x06, 0x3e, 0x41, 0x99, 0x8c, 0xd0, 0x3f, 0xb8, 0x9b, 0x39, 0xf7, 0x77, 0xce, - 0xcc, 0x3d, 0x96, 0x2f, 0x32, 0xc8, 0x41, 0x3e, 0x31, 0x3e, 0x0b, 0x45, 0x06, 0x21, 0x9d, 0xe6, - 0x32, 0x2c, 0x08, 0x27, 0x54, 0xe0, 0x82, 0x33, 0xc9, 0xec, 0xd3, 0x6f, 0x02, 0x8b, 0x0c, 0xb0, - 0x22, 0xdc, 0xb3, 0x8c, 0x65, 0xac, 0x9a, 0x87, 0xea, 0xa4, 0x51, 0x17, 0x1d, 0x0d, 0x9b, 0x10, - 0x01, 0x1a, 0x08, 0x5e, 0x6b, 0x56, 0x73, 0x58, 0x85, 0xdb, 0x17, 0x96, 0xa5, 0xc6, 0xc9, 0x18, - 0x72, 0x46, 0x1d, 0xd3, 0x37, 0xbb, 0xad, 0xb8, 0xa5, 0x94, 0x3b, 0x25, 0xd8, 0x91, 0x75, 0x32, - 0x9a, 0xb3, 0x74, 0x26, 0x92, 0x02, 0x78, 0xb2, 0x02, 0xc2, 0x9d, 0x9a, 0x6f, 0x76, 0xeb, 0x91, - 0xbb, 0x2f, 0xd1, 0xf9, 0x8a, 0xd0, 0x79, 0x2f, 0xf8, 0x03, 0x04, 0x71, 0x5b, 0x2b, 0x43, 0xe0, - 0xf7, 0x40, 0xb8, 0x3d, 0xb0, 0x9a, 0xd5, 0xe3, 0xc2, 0xa9, 0xfb, 0xf5, 0xee, 0xbf, 0x6b, 0x17, - 0x1f, 0x59, 0x05, 0x0f, 0x15, 0x12, 0x75, 0xd6, 0x25, 0x32, 0xf6, 0x25, 0x6a, 0xeb, 0x68, 0xed, - 0x0b, 0xe2, 0x43, 0x80, 0xfd, 0x68, 0xfd, 0x87, 0x65, 0x3a, 0x5f, 0x8c, 0x21, 0x21, 0x94, 0x2d, - 0x72, 0xe9, 0x34, 0xd4, 0x8f, 0xa3, 0x5b, 0x65, 0xfb, 0x28, 0x51, 0x27, 0x65, 0x82, 0x32, 0x21, - 0xc6, 0x33, 0x3c, 0x65, 0x21, 0x25, 0x72, 0x82, 0x07, 0xb9, 0xdc, 0x97, 0xa8, 0xa3, 0xf3, 0x7e, - 0x9b, 0x83, 0xb8, 0x7d, 0x10, 0xfa, 0xd5, 0xbd, 0xd7, 0x78, 0x79, 0x43, 0x46, 0xd4, 0x5f, 0x6f, - 0x3d, 0x73, 0xb3, 0xf5, 0xcc, 0xcf, 0xad, 0x67, 0x3e, 0xef, 0x3c, 0x63, 0xb3, 0xf3, 0x8c, 0xf7, - 0x9d, 0x67, 0x3c, 0x5c, 0x66, 0x53, 0x39, 0x59, 0x8c, 0x70, 0xca, 0xa8, 0x2a, 0xf6, 0xea, 0x67, - 0xc9, 0x4b, 0x5d, 0xb3, 0x5c, 0x15, 0x20, 0x46, 0xcd, 0xaa, 0xe7, 0x9b, 0xaf, 0x00, 0x00, 0x00, - 0xff, 0xff, 0x97, 0x32, 0xf7, 0x23, 0xd7, 0x01, 0x00, 0x00, +var fileDescriptor_2a08e4df58e642f1 = []byte{ + // 349 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x64, 0x90, 0xb1, 0x6e, 0xea, 0x30, + 0x18, 0x85, 0x13, 0x40, 0x48, 0xe4, 0x8a, 0x8b, 0x14, 0x5d, 0x50, 0xc4, 0x6d, 0x13, 0x94, 0xa5, + 0x2c, 0xb5, 0xd5, 0x56, 0xea, 0xc0, 0x46, 0xd4, 0x0e, 0xdd, 0x50, 0xb6, 0x56, 0xaa, 0x22, 0x27, + 0xfc, 0x0a, 0x08, 0x1c, 0x47, 0xb6, 0x69, 0xe1, 0x2d, 0xba, 0xb5, 0x63, 0x1f, 0x87, 0x91, 0xb1, + 0xea, 0x10, 0x55, 0xf0, 0x06, 0x3c, 0x41, 0xe5, 0x98, 0xa5, 0x74, 0xfb, 0x7d, 0xbe, 0x73, 0x8e, + 0xed, 0xdf, 0x3a, 0x11, 0x29, 0x60, 0x3a, 0xcd, 0x24, 0x7e, 0xba, 0x88, 0x41, 0x12, 0x9c, 0x13, + 0x4e, 0xa8, 0x40, 0x39, 0x67, 0x92, 0xd9, 0x2d, 0x91, 0x02, 0x52, 0x14, 0x69, 0xda, 0xfd, 0x97, + 0xb2, 0x94, 0x95, 0x0c, 0xab, 0x49, 0xdb, 0xba, 0xff, 0x7f, 0x95, 0x4c, 0x88, 0x00, 0x0d, 0xfd, + 0xd7, 0x8a, 0x55, 0x1f, 0x95, 0xa5, 0xf6, 0xa9, 0x65, 0x29, 0x57, 0x34, 0x86, 0x8c, 0x51, 0xc7, + 0xec, 0x99, 0xfd, 0x46, 0xd8, 0x50, 0xca, 0x8d, 0x12, 0xec, 0xc0, 0x6a, 0xc5, 0x73, 0x96, 0xcc, + 0x44, 0x94, 0x03, 0x8f, 0x56, 0x40, 0xb8, 0x53, 0xe9, 0x99, 0xfd, 0x5a, 0xd0, 0xdd, 0x17, 0x5e, + 0x67, 0x45, 0xe8, 0x7c, 0xe0, 0x1f, 0x19, 0xfc, 0xb0, 0xa9, 0x95, 0x11, 0xf0, 0x7b, 0x20, 0xdc, + 0xbe, 0xb5, 0xea, 0xe5, 0xe5, 0xc2, 0xa9, 0xf6, 0xaa, 0xfd, 0x3f, 0x97, 0x1d, 0x74, 0xf4, 0x05, + 0x34, 0x52, 0x38, 0x68, 0xaf, 0x0b, 0xcf, 0xd8, 0x17, 0x5e, 0x53, 0xd7, 0xea, 0x8c, 0x1f, 0x1e, + 0xc2, 0xf6, 0xa3, 0xf5, 0x17, 0x96, 0xc9, 0x7c, 0x31, 0x86, 0x88, 0x50, 0xb6, 0xc8, 0xa4, 0x53, + 0x53, 0xaf, 0x0d, 0xae, 0x55, 0xec, 0xb3, 0xf0, 0xda, 0x09, 0x13, 0x94, 0x09, 0x31, 0x9e, 0xa1, + 0x29, 0xc3, 0x94, 0xc8, 0x09, 0xba, 0xcb, 0xe4, 0xbe, 0xf0, 0xda, 0xba, 0xef, 0x67, 0xd8, 0x0f, + 0x9b, 0x07, 0x61, 0x58, 0x9e, 0x07, 0xb5, 0xb7, 0x77, 0xcf, 0x08, 0x86, 0xeb, 0xad, 0x6b, 0x6e, + 0xb6, 0xae, 0xf9, 0xb5, 0x75, 0xcd, 0x97, 0x9d, 0x6b, 0x6c, 0x76, 0xae, 0xf1, 0xb1, 0x73, 0x8d, + 0x87, 0xb3, 0x74, 0x2a, 0x27, 0x8b, 0x18, 0x25, 0x8c, 0x62, 0x91, 0xc2, 0x79, 0x06, 0xf2, 0x99, + 0xf1, 0x99, 0x9a, 0xf1, 0x52, 0x6f, 0x5a, 0xae, 0x72, 0x10, 0x71, 0xbd, 0xdc, 0xf1, 0xd5, 0x77, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xae, 0x85, 0x92, 0x4d, 0xc7, 0x01, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { @@ -296,7 +296,7 @@ func (m *Params) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.BlocksPerYear |= int64(b&0x7F) << shift + m.BlocksPerYear |= uint64(b&0x7F) << shift if b < 0x80 { break } diff --git a/x/mint/types/params_legacy.go b/x/mint/types/params_legacy.go new file mode 100644 index 00000000..21044b39 --- /dev/null +++ b/x/mint/types/params_legacy.go @@ -0,0 +1,30 @@ +package types + +import paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + +// parameter store keys +var ( + // KeyMintDenom is the mint denom param key + keyMintDenom = []byte("MintDenom") + // KeyBlocksPerYear is the blocks per year param key + keyBlocksPerYear = []byte("BlocksPerYear") + // KeyPhases is the inflation phases param key + keyPhases = []byte("Phases") + // KeyExcludeAmount is the excluded amount from inflation calculation param key + keyExcludeAmount = []byte("ExcludeAmount") +) + +// ParamKeyTable the param key table for launch module +func ParamKeyTable() paramtypes.KeyTable { + return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) +} + +// ParamSetPairs get the params.ParamSet +func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { + return paramtypes.ParamSetPairs{ + paramtypes.NewParamSetPair(keyMintDenom, &p.MintDenom, validateMintDenom), + paramtypes.NewParamSetPair(keyBlocksPerYear, &p.BlocksPerYear, validateBlocksPerYear), + paramtypes.NewParamSetPair(keyPhases, &p.Phases, validatePhases), + paramtypes.NewParamSetPair(keyExcludeAmount, &p.ExcludeAmount, validateExcludeAmount), + } +} diff --git a/x/mint/types/phase.pb.go b/x/mint/types/phase.pb.go index 132544c4..e18a2b75 100644 --- a/x/mint/types/phase.pb.go +++ b/x/mint/types/phase.pb.go @@ -1,11 +1,12 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/mint/phase.proto +// source: sge/mint/v1beta/phase.proto package types import ( cosmossdk_io_math "cosmossdk.io/math" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" @@ -35,7 +36,7 @@ type Phase struct { func (m *Phase) Reset() { *m = Phase{} } func (*Phase) ProtoMessage() {} func (*Phase) Descriptor() ([]byte, []int) { - return fileDescriptor_a4ef2371d48b7ae6, []int{0} + return fileDescriptor_6b9b9e76a231acf4, []int{0} } func (m *Phase) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -65,30 +66,32 @@ func (m *Phase) XXX_DiscardUnknown() { var xxx_messageInfo_Phase proto.InternalMessageInfo func init() { - proto.RegisterType((*Phase)(nil), "sgenetwork.sge.mint.Phase") + proto.RegisterType((*Phase)(nil), "sge.mint.v1beta.Phase") } -func init() { proto.RegisterFile("sgenetwork/sge/mint/phase.proto", fileDescriptor_a4ef2371d48b7ae6) } +func init() { proto.RegisterFile("sge/mint/v1beta/phase.proto", fileDescriptor_6b9b9e76a231acf4) } -var fileDescriptor_a4ef2371d48b7ae6 = []byte{ - // 268 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2f, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0xcd, 0xcc, 0x2b, 0xd1, - 0x2f, 0xc8, 0x48, 0x2c, 0x4e, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x46, 0x28, 0xd0, - 0x2b, 0x4e, 0x4f, 0xd5, 0x03, 0x29, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xcb, 0xeb, 0x83, - 0x58, 0x10, 0xa5, 0x4a, 0xe7, 0x19, 0xb9, 0x58, 0x03, 0x40, 0x5a, 0x85, 0x42, 0xb9, 0x38, 0x33, - 0xf3, 0xd2, 0x72, 0x12, 0x4b, 0x32, 0xf3, 0xf3, 0x24, 0x18, 0x15, 0x18, 0x35, 0x38, 0x9d, 0xcc, - 0x4f, 0xdc, 0x93, 0x67, 0xb8, 0x75, 0x4f, 0x5e, 0x3a, 0x39, 0xbf, 0x38, 0x37, 0xbf, 0xb8, 0x38, - 0x25, 0x5b, 0x2f, 0x33, 0x5f, 0x3f, 0x37, 0xb1, 0x24, 0x43, 0xcf, 0x27, 0x35, 0x3d, 0x31, 0xb9, - 0xd2, 0x25, 0x35, 0xf9, 0xd3, 0x3d, 0x79, 0x81, 0xca, 0xc4, 0xdc, 0x1c, 0x2b, 0x25, 0xb8, 0x6e, - 0xa5, 0x20, 0x84, 0x49, 0x42, 0x99, 0x5c, 0x02, 0x95, 0xa9, 0x89, 0x45, 0xf1, 0xc9, 0xf9, 0xa9, - 0x69, 0x69, 0x99, 0xc9, 0x99, 0xa9, 0x79, 0x25, 0x12, 0x4c, 0x60, 0xd3, 0xed, 0x88, 0x33, 0x5d, - 0x1c, 0x62, 0x3a, 0xba, 0x21, 0x4a, 0x41, 0xfc, 0x20, 0x21, 0x67, 0x84, 0x88, 0x15, 0xcb, 0x8c, - 0x05, 0xf2, 0x0c, 0x4e, 0x8e, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, - 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, - 0x9e, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0x0b, 0x0a, 0x37, 0x5d, 0xe4, 0x30, - 0xac, 0x80, 0x84, 0x62, 0x49, 0x65, 0x41, 0x6a, 0x71, 0x12, 0x1b, 0x38, 0x6c, 0x8c, 0x01, 0x01, - 0x00, 0x00, 0xff, 0xff, 0x9e, 0x0e, 0xbc, 0xcd, 0x69, 0x01, 0x00, 0x00, +var fileDescriptor_6b9b9e76a231acf4 = []byte{ + // 293 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2e, 0x4e, 0x4f, 0xd5, + 0xcf, 0xcd, 0xcc, 0x2b, 0xd1, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0xc8, 0x48, 0x2c, + 0x4e, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x2f, 0x4e, 0x4f, 0xd5, 0x03, 0x49, 0xea, + 0x41, 0x24, 0xa5, 0x24, 0x93, 0xf3, 0x8b, 0x73, 0xf3, 0x8b, 0xe3, 0xc1, 0xd2, 0xfa, 0x10, 0x0e, + 0x44, 0xad, 0x94, 0x48, 0x7a, 0x7e, 0x7a, 0x3e, 0x44, 0x1c, 0xc4, 0x82, 0x88, 0x2a, 0xbd, 0x66, + 0xe4, 0x62, 0x0d, 0x00, 0x99, 0x28, 0x94, 0xcc, 0xc5, 0x99, 0x99, 0x97, 0x96, 0x93, 0x58, 0x92, + 0x99, 0x9f, 0x27, 0xc1, 0xa8, 0xc0, 0xa8, 0xc1, 0xe9, 0xe4, 0x7a, 0xe2, 0x9e, 0x3c, 0xc3, 0xad, + 0x7b, 0xf2, 0xd2, 0x10, 0x83, 0x8a, 0x53, 0xb2, 0xf5, 0x32, 0xf3, 0xf5, 0x73, 0x13, 0x4b, 0x32, + 0xf4, 0x7c, 0x52, 0xd3, 0x13, 0x93, 0x2b, 0x5d, 0x52, 0x93, 0x3f, 0xdd, 0x93, 0x17, 0xa8, 0x4c, + 0xcc, 0xcd, 0xb1, 0x52, 0x82, 0xeb, 0x56, 0xba, 0xb4, 0x45, 0x97, 0x0b, 0x6a, 0xb7, 0x4b, 0x6a, + 0x72, 0x10, 0xc2, 0x5c, 0xa1, 0x72, 0x2e, 0x81, 0xca, 0xd4, 0xc4, 0xa2, 0xf8, 0xe4, 0xfc, 0xd4, + 0xb4, 0xb4, 0xcc, 0xe4, 0xcc, 0xd4, 0xbc, 0x12, 0x09, 0x26, 0xb0, 0x5d, 0x3e, 0xc4, 0xd9, 0x25, + 0x0e, 0xb1, 0x0b, 0xdd, 0x10, 0x74, 0x2b, 0xf9, 0x41, 0x0a, 0x9c, 0x11, 0xf2, 0x56, 0x2c, 0x33, + 0x16, 0xc8, 0x33, 0x38, 0x39, 0x9e, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, + 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, + 0x7a, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0xae, 0x7e, 0x71, 0x7a, 0xaa, 0x6e, + 0x5e, 0x6a, 0x49, 0x79, 0x7e, 0x51, 0x36, 0x88, 0xad, 0x5f, 0x01, 0x09, 0xff, 0x92, 0xca, 0x82, + 0xd4, 0xe2, 0x24, 0x36, 0x70, 0xb8, 0x19, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0xbd, 0x21, 0xdb, + 0x1e, 0x98, 0x01, 0x00, 0x00, } func (m *Phase) Marshal() (dAtA []byte, err error) { diff --git a/x/mint/types/query.pb.go b/x/mint/types/query.pb.go index bec0ca98..68f378bc 100644 --- a/x/mint/types/query.pb.go +++ b/x/mint/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/mint/query.proto +// source: sge/mint/v1beta/query.proto package types @@ -7,6 +7,8 @@ import ( context "context" cosmossdk_io_math "cosmossdk.io/math" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + _ "github.com/cosmos/cosmos-sdk/types/tx/amino" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" @@ -39,7 +41,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{0} + return fileDescriptor_6b5dcc7415e3fdf1, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -79,7 +81,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{1} + return fileDescriptor_6b5dcc7415e3fdf1, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -124,7 +126,7 @@ func (m *QueryInflationRequest) Reset() { *m = QueryInflationRequest{} } func (m *QueryInflationRequest) String() string { return proto.CompactTextString(m) } func (*QueryInflationRequest) ProtoMessage() {} func (*QueryInflationRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{2} + return fileDescriptor_6b5dcc7415e3fdf1, []int{2} } func (m *QueryInflationRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -165,7 +167,7 @@ func (m *QueryInflationResponse) Reset() { *m = QueryInflationResponse{} func (m *QueryInflationResponse) String() string { return proto.CompactTextString(m) } func (*QueryInflationResponse) ProtoMessage() {} func (*QueryInflationResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{3} + return fileDescriptor_6b5dcc7415e3fdf1, []int{3} } func (m *QueryInflationResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -203,7 +205,7 @@ func (m *QueryPhaseStepRequest) Reset() { *m = QueryPhaseStepRequest{} } func (m *QueryPhaseStepRequest) String() string { return proto.CompactTextString(m) } func (*QueryPhaseStepRequest) ProtoMessage() {} func (*QueryPhaseStepRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{4} + return fileDescriptor_6b5dcc7415e3fdf1, []int{4} } func (m *QueryPhaseStepRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -244,7 +246,7 @@ func (m *QueryPhaseStepResponse) Reset() { *m = QueryPhaseStepResponse{} func (m *QueryPhaseStepResponse) String() string { return proto.CompactTextString(m) } func (*QueryPhaseStepResponse) ProtoMessage() {} func (*QueryPhaseStepResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{5} + return fileDescriptor_6b5dcc7415e3fdf1, []int{5} } func (m *QueryPhaseStepResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -289,7 +291,7 @@ func (m *QueryPhaseProvisionsRequest) Reset() { *m = QueryPhaseProvision func (m *QueryPhaseProvisionsRequest) String() string { return proto.CompactTextString(m) } func (*QueryPhaseProvisionsRequest) ProtoMessage() {} func (*QueryPhaseProvisionsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{6} + return fileDescriptor_6b5dcc7415e3fdf1, []int{6} } func (m *QueryPhaseProvisionsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -329,7 +331,7 @@ func (m *QueryPhaseProvisionsResponse) Reset() { *m = QueryPhaseProvisio func (m *QueryPhaseProvisionsResponse) String() string { return proto.CompactTextString(m) } func (*QueryPhaseProvisionsResponse) ProtoMessage() {} func (*QueryPhaseProvisionsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{7} + return fileDescriptor_6b5dcc7415e3fdf1, []int{7} } func (m *QueryPhaseProvisionsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -368,7 +370,7 @@ func (m *QueryEndPhaseStatusRequest) Reset() { *m = QueryEndPhaseStatusR func (m *QueryEndPhaseStatusRequest) String() string { return proto.CompactTextString(m) } func (*QueryEndPhaseStatusRequest) ProtoMessage() {} func (*QueryEndPhaseStatusRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{8} + return fileDescriptor_6b5dcc7415e3fdf1, []int{8} } func (m *QueryEndPhaseStatusRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -410,7 +412,7 @@ func (m *QueryEndPhaseStatusResponse) Reset() { *m = QueryEndPhaseStatus func (m *QueryEndPhaseStatusResponse) String() string { return proto.CompactTextString(m) } func (*QueryEndPhaseStatusResponse) ProtoMessage() {} func (*QueryEndPhaseStatusResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ee35ae03c8ab12c8, []int{9} + return fileDescriptor_6b5dcc7415e3fdf1, []int{9} } func (m *QueryEndPhaseStatusResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -447,59 +449,61 @@ func (m *QueryEndPhaseStatusResponse) GetIsInEndPhase() bool { } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "sgenetwork.sge.mint.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "sgenetwork.sge.mint.QueryParamsResponse") - proto.RegisterType((*QueryInflationRequest)(nil), "sgenetwork.sge.mint.QueryInflationRequest") - proto.RegisterType((*QueryInflationResponse)(nil), "sgenetwork.sge.mint.QueryInflationResponse") - proto.RegisterType((*QueryPhaseStepRequest)(nil), "sgenetwork.sge.mint.QueryPhaseStepRequest") - proto.RegisterType((*QueryPhaseStepResponse)(nil), "sgenetwork.sge.mint.QueryPhaseStepResponse") - proto.RegisterType((*QueryPhaseProvisionsRequest)(nil), "sgenetwork.sge.mint.QueryPhaseProvisionsRequest") - proto.RegisterType((*QueryPhaseProvisionsResponse)(nil), "sgenetwork.sge.mint.QueryPhaseProvisionsResponse") - proto.RegisterType((*QueryEndPhaseStatusRequest)(nil), "sgenetwork.sge.mint.QueryEndPhaseStatusRequest") - proto.RegisterType((*QueryEndPhaseStatusResponse)(nil), "sgenetwork.sge.mint.QueryEndPhaseStatusResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/mint/query.proto", fileDescriptor_ee35ae03c8ab12c8) } - -var fileDescriptor_ee35ae03c8ab12c8 = []byte{ - // 585 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x94, 0x41, 0x6f, 0x12, 0x4d, - 0x1c, 0xc6, 0xd9, 0x37, 0x2f, 0x44, 0xc6, 0x46, 0x9a, 0x69, 0xd5, 0x66, 0xa1, 0x0b, 0x59, 0x6d, - 0x69, 0xd4, 0xee, 0x96, 0x7a, 0x30, 0x1e, 0x4b, 0xea, 0xa1, 0x89, 0x31, 0x88, 0x37, 0x3d, 0x90, - 0x01, 0xc6, 0x65, 0xd2, 0x32, 0x33, 0x65, 0x66, 0xab, 0x5c, 0x3d, 0x7b, 0x30, 0xf1, 0x13, 0x78, - 0xf0, 0xbb, 0xf4, 0xd8, 0xc4, 0x8b, 0xf1, 0xd0, 0x18, 0xf0, 0xe0, 0xc7, 0x30, 0x3b, 0x3b, 0xbb, - 0xc0, 0xb2, 0x94, 0xf6, 0x46, 0xe6, 0xff, 0x7f, 0x9e, 0xe7, 0xb7, 0xcc, 0xb3, 0x0b, 0xca, 0xc2, - 0xc3, 0x14, 0xcb, 0x0f, 0x6c, 0x70, 0xec, 0x0a, 0x0f, 0xbb, 0x7d, 0x42, 0xa5, 0x7b, 0xea, 0xe3, - 0xc1, 0xd0, 0xe1, 0x03, 0x26, 0x19, 0x5c, 0x9b, 0x2c, 0x38, 0xc2, 0xc3, 0x4e, 0xb0, 0x60, 0xae, - 0x7b, 0xcc, 0x63, 0x6a, 0xee, 0x06, 0xbf, 0xc2, 0x55, 0xb3, 0xe4, 0x31, 0xe6, 0x9d, 0x60, 0x17, - 0x71, 0xe2, 0x22, 0x4a, 0x99, 0x44, 0x92, 0x30, 0x2a, 0xf4, 0xb4, 0x92, 0x96, 0xc4, 0xd1, 0x00, - 0xf5, 0xf5, 0x86, 0xbd, 0x0e, 0xe0, 0xeb, 0x20, 0xb9, 0xa1, 0x0e, 0x9b, 0xf8, 0xd4, 0xc7, 0x42, - 0xda, 0x0d, 0xb0, 0x36, 0x73, 0x2a, 0x38, 0xa3, 0x02, 0xc3, 0xe7, 0x20, 0x17, 0x8a, 0x37, 0x8c, - 0x8a, 0xb1, 0x73, 0x7b, 0xbf, 0xe8, 0xa4, 0x80, 0x3a, 0xa1, 0xa8, 0xfe, 0xff, 0xf9, 0x65, 0x39, - 0xd3, 0xd4, 0x02, 0xfb, 0x3e, 0xb8, 0xab, 0x1c, 0x8f, 0xe8, 0xfb, 0x13, 0x85, 0x18, 0x45, 0xbd, - 0x03, 0xf7, 0x92, 0x03, 0x9d, 0x76, 0x00, 0xf2, 0x24, 0x3a, 0x54, 0x81, 0x2b, 0xf5, 0x07, 0x81, - 0xe7, 0xaf, 0xcb, 0x72, 0xb1, 0xc3, 0x44, 0x9f, 0x09, 0xd1, 0x3d, 0x76, 0x08, 0x73, 0xfb, 0x48, - 0xf6, 0x9c, 0x97, 0xd8, 0x43, 0x9d, 0xe1, 0x21, 0xee, 0x34, 0x27, 0xaa, 0x38, 0xb5, 0xd1, 0x43, - 0x02, 0xbf, 0x91, 0x98, 0x47, 0xa9, 0xcf, 0x74, 0xea, 0xd4, 0x40, 0xa7, 0x6e, 0x02, 0xc0, 0x83, - 0xc3, 0x96, 0x90, 0x98, 0xab, 0xd8, 0x6c, 0x33, 0xcf, 0xa3, 0x35, 0x7b, 0x13, 0x14, 0x27, 0xc2, - 0xc6, 0x80, 0x9d, 0x11, 0x11, 0xfc, 0xdf, 0x91, 0x2f, 0x05, 0xa5, 0xf4, 0xb1, 0x76, 0x7f, 0x05, - 0x56, 0x43, 0x77, 0x1e, 0xcf, 0x6e, 0xf2, 0x68, 0x05, 0x3e, 0xeb, 0x6b, 0x97, 0x80, 0xa9, 0xf2, - 0x5e, 0xd0, 0xae, 0x7e, 0x14, 0x24, 0xfd, 0x98, 0xe6, 0x50, 0xc3, 0x26, 0xa7, 0x1a, 0x66, 0x0b, - 0x14, 0x88, 0x68, 0x11, 0xda, 0xc2, 0xb4, 0xdb, 0x52, 0xce, 0x8a, 0xe5, 0x56, 0x73, 0x85, 0x88, - 0x23, 0x1a, 0x89, 0xf6, 0xff, 0x66, 0x41, 0x56, 0xd9, 0x40, 0x1f, 0xe4, 0xc2, 0xcb, 0x85, 0xd5, - 0xd4, 0x9b, 0x9f, 0x6f, 0x92, 0xb9, 0xb3, 0x7c, 0x31, 0xa4, 0xb1, 0x37, 0x3e, 0xfd, 0xf8, 0xf3, - 0xf5, 0x3f, 0x08, 0x57, 0x93, 0x4d, 0x85, 0x9f, 0x0d, 0x90, 0x8f, 0xeb, 0x01, 0x1f, 0x2d, 0x76, - 0x4c, 0x96, 0xcb, 0x7c, 0x7c, 0xad, 0x5d, 0x0d, 0xb0, 0xad, 0x00, 0x2a, 0xd0, 0x72, 0xc3, 0x2b, - 0x08, 0x19, 0xce, 0x6a, 0x6d, 0x2c, 0x51, 0xcd, 0x8d, 0x4b, 0xa5, 0x70, 0xe2, 0xde, 0x5c, 0x85, - 0x93, 0x6c, 0xdd, 0x55, 0x38, 0x73, 0x45, 0x5c, 0x82, 0xa3, 0xae, 0x2b, 0xa8, 0x28, 0xfc, 0x6e, - 0x80, 0x42, 0xa2, 0x6e, 0x70, 0x6f, 0x49, 0xd0, 0x5c, 0x71, 0xcd, 0xda, 0x0d, 0x14, 0x1a, 0x70, - 0x57, 0x01, 0x56, 0xe1, 0xd6, 0x62, 0xc0, 0xa9, 0x9a, 0xc3, 0x6f, 0x06, 0xb8, 0x33, 0x5b, 0x44, - 0xe8, 0x2e, 0x0e, 0x4d, 0x2d, 0xb4, 0xb9, 0x77, 0x7d, 0x81, 0x86, 0x7c, 0xa2, 0x20, 0xb7, 0xe1, - 0xc3, 0x54, 0x48, 0x4c, 0xbb, 0xd1, 0xcb, 0x1e, 0xa8, 0xea, 0x07, 0xe7, 0x23, 0xcb, 0xb8, 0x18, - 0x59, 0xc6, 0xef, 0x91, 0x65, 0x7c, 0x19, 0x5b, 0x99, 0x8b, 0xb1, 0x95, 0xf9, 0x39, 0xb6, 0x32, - 0x6f, 0xab, 0x1e, 0x91, 0x3d, 0xbf, 0xed, 0x74, 0x58, 0x3f, 0xe8, 0xe7, 0xee, 0xf4, 0x57, 0xf5, - 0x63, 0x68, 0x2a, 0x87, 0x1c, 0x8b, 0x76, 0x4e, 0x7d, 0x57, 0x9f, 0xfe, 0x0b, 0x00, 0x00, 0xff, - 0xff, 0xcd, 0x1b, 0xcf, 0xa5, 0xe5, 0x05, 0x00, 0x00, + proto.RegisterType((*QueryParamsRequest)(nil), "sge.mint.v1beta.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "sge.mint.v1beta.QueryParamsResponse") + proto.RegisterType((*QueryInflationRequest)(nil), "sge.mint.v1beta.QueryInflationRequest") + proto.RegisterType((*QueryInflationResponse)(nil), "sge.mint.v1beta.QueryInflationResponse") + proto.RegisterType((*QueryPhaseStepRequest)(nil), "sge.mint.v1beta.QueryPhaseStepRequest") + proto.RegisterType((*QueryPhaseStepResponse)(nil), "sge.mint.v1beta.QueryPhaseStepResponse") + proto.RegisterType((*QueryPhaseProvisionsRequest)(nil), "sge.mint.v1beta.QueryPhaseProvisionsRequest") + proto.RegisterType((*QueryPhaseProvisionsResponse)(nil), "sge.mint.v1beta.QueryPhaseProvisionsResponse") + proto.RegisterType((*QueryEndPhaseStatusRequest)(nil), "sge.mint.v1beta.QueryEndPhaseStatusRequest") + proto.RegisterType((*QueryEndPhaseStatusResponse)(nil), "sge.mint.v1beta.QueryEndPhaseStatusResponse") +} + +func init() { proto.RegisterFile("sge/mint/v1beta/query.proto", fileDescriptor_6b5dcc7415e3fdf1) } + +var fileDescriptor_6b5dcc7415e3fdf1 = []byte{ + // 618 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x94, 0xcf, 0x6e, 0x12, 0x41, + 0x1c, 0x80, 0x59, 0x13, 0x88, 0x8c, 0x8d, 0xd4, 0xb1, 0xda, 0xba, 0xd0, 0x6d, 0xb3, 0xb6, 0x60, + 0x14, 0x76, 0xd3, 0x9a, 0x68, 0xe2, 0x4d, 0x82, 0x87, 0x26, 0x1e, 0x28, 0x7a, 0xf2, 0x42, 0x06, + 0x18, 0x97, 0x4d, 0xbb, 0x33, 0x53, 0x66, 0xa8, 0x72, 0xd4, 0xf8, 0x00, 0x26, 0x9e, 0x3c, 0x78, + 0xf7, 0xe8, 0xc1, 0x07, 0xf0, 0xd8, 0x63, 0xa3, 0x17, 0xe3, 0xa1, 0x31, 0x60, 0xe2, 0x6b, 0x98, + 0x9d, 0x99, 0xdd, 0xc2, 0x02, 0x6d, 0x13, 0x2f, 0x84, 0xfd, 0xfd, 0xfd, 0x66, 0xf9, 0x06, 0x90, + 0xe7, 0x1e, 0x76, 0x03, 0x9f, 0x08, 0xf7, 0x70, 0xab, 0x85, 0x05, 0x72, 0x0f, 0xfa, 0xb8, 0x37, + 0x70, 0x58, 0x8f, 0x0a, 0x0a, 0x73, 0xdc, 0xc3, 0x4e, 0x98, 0x74, 0x54, 0xd2, 0xbc, 0x86, 0x02, + 0x9f, 0x50, 0x57, 0x7e, 0xaa, 0x1a, 0xf3, 0x56, 0x9b, 0xf2, 0x80, 0xf2, 0xa6, 0x7c, 0x72, 0xd5, + 0x83, 0x4e, 0x2d, 0x79, 0xd4, 0xa3, 0x2a, 0x1e, 0x7e, 0xd3, 0xd1, 0x82, 0x47, 0xa9, 0xb7, 0x8f, + 0x5d, 0xc4, 0x7c, 0x17, 0x11, 0x42, 0x05, 0x12, 0x3e, 0x25, 0x51, 0x4f, 0x21, 0xc9, 0xc3, 0x50, + 0x0f, 0x05, 0x3a, 0x6b, 0x2f, 0x01, 0xb8, 0x1b, 0xf2, 0xd5, 0x65, 0xb0, 0x81, 0x0f, 0xfa, 0x98, + 0x0b, 0x7b, 0x17, 0x5c, 0x9f, 0x88, 0x72, 0x46, 0x09, 0xc7, 0xf0, 0x11, 0xc8, 0xa8, 0xe6, 0x15, + 0x63, 0xdd, 0xb8, 0x73, 0x65, 0x7b, 0xd9, 0x49, 0x1c, 0xc7, 0x51, 0x0d, 0xd5, 0xec, 0xd1, 0xc9, + 0x5a, 0xea, 0xf3, 0xdf, 0x2f, 0x77, 0x8d, 0x86, 0xee, 0xb0, 0x97, 0xc1, 0x0d, 0x39, 0x72, 0x87, + 0xbc, 0xdc, 0x97, 0x7c, 0xd1, 0x2e, 0x02, 0x6e, 0x26, 0x13, 0x7a, 0xdd, 0x73, 0x90, 0xf5, 0xa3, + 0xa0, 0xdc, 0xb8, 0x50, 0x7d, 0x10, 0x0e, 0xfe, 0x75, 0xb2, 0x96, 0x57, 0xaf, 0x85, 0x77, 0xf6, + 0x1c, 0x9f, 0xba, 0x01, 0x12, 0x5d, 0xe7, 0x29, 0xf6, 0x50, 0x7b, 0x50, 0xc3, 0xed, 0xef, 0x5f, + 0x2b, 0x40, 0xbf, 0xb5, 0x1a, 0x6e, 0x2b, 0x8a, 0xd3, 0x41, 0x31, 0x48, 0xbd, 0x8b, 0x38, 0x7e, + 0x26, 0x30, 0x8b, 0x40, 0x1e, 0x6a, 0x90, 0xb1, 0x84, 0x06, 0x59, 0x05, 0x80, 0x85, 0xc1, 0x26, + 0x17, 0x98, 0x49, 0x92, 0x74, 0x23, 0xcb, 0xa2, 0x32, 0x7b, 0x15, 0xe4, 0x4f, 0x1b, 0xeb, 0x3d, + 0x7a, 0xe8, 0xf3, 0xf0, 0xfd, 0x47, 0x73, 0xdf, 0x18, 0xa0, 0x30, 0x3b, 0xaf, 0xc7, 0x23, 0xb0, + 0xa8, 0xc6, 0xb3, 0x38, 0xf7, 0x9f, 0xc7, 0xcd, 0xb1, 0xc9, 0x55, 0x76, 0x01, 0x98, 0x12, 0xe1, + 0x09, 0xe9, 0xe8, 0xe3, 0x21, 0xd1, 0x8f, 0x09, 0x6b, 0xfa, 0x00, 0xc9, 0xac, 0xe6, 0xdb, 0x04, + 0x39, 0x9f, 0x37, 0x7d, 0xd2, 0xc4, 0xa4, 0xd3, 0x94, 0x93, 0x25, 0xde, 0xe5, 0xc6, 0x82, 0xcf, + 0x77, 0x48, 0xd4, 0xb4, 0xfd, 0x2d, 0x0d, 0xd2, 0x72, 0x0c, 0x0c, 0x40, 0x46, 0x89, 0x00, 0x6f, + 0x4f, 0x19, 0x32, 0x6d, 0x9b, 0xb9, 0x71, 0x76, 0x91, 0xa2, 0xb0, 0x57, 0xde, 0xfe, 0xf8, 0xf3, + 0xe1, 0x12, 0x84, 0x8b, 0x6e, 0x2c, 0xb4, 0x52, 0x0b, 0xbe, 0x33, 0x40, 0x36, 0xb6, 0x07, 0x16, + 0x67, 0x4f, 0x4b, 0x7a, 0x67, 0x96, 0xce, 0xad, 0xd3, 0x8b, 0x8b, 0x72, 0xf1, 0x3a, 0xb4, 0xf4, + 0x5d, 0x1c, 0xbf, 0x4c, 0x5b, 0x6e, 0x2c, 0x96, 0xc4, 0x88, 0xdd, 0x99, 0x87, 0x91, 0xb4, 0x6e, + 0x1e, 0xc6, 0x94, 0x84, 0xe7, 0x60, 0xc8, 0x9f, 0x25, 0xd4, 0x13, 0x7e, 0x32, 0x40, 0x2e, 0x61, + 0x1a, 0x2c, 0x9f, 0xb1, 0x64, 0x4a, 0x58, 0xb3, 0x72, 0xc1, 0x6a, 0x0d, 0x56, 0x91, 0x60, 0x25, + 0xb8, 0x39, 0x1f, 0x6c, 0xcc, 0x6c, 0xf8, 0xd1, 0x00, 0x57, 0x27, 0x45, 0x83, 0xf7, 0x66, 0x2f, + 0x9c, 0x29, 0xab, 0x59, 0xbe, 0x58, 0xb1, 0x86, 0x2b, 0x4b, 0xb8, 0x22, 0xdc, 0x98, 0x09, 0x87, + 0x49, 0x27, 0xba, 0xd8, 0x61, 0x57, 0xf5, 0xf1, 0xd1, 0xd0, 0x32, 0x8e, 0x87, 0x96, 0xf1, 0x7b, + 0x68, 0x19, 0xef, 0x47, 0x56, 0xea, 0x78, 0x64, 0xa5, 0x7e, 0x8e, 0xac, 0xd4, 0x8b, 0x92, 0xe7, + 0x8b, 0x6e, 0xbf, 0xe5, 0xb4, 0x69, 0x10, 0xfa, 0x57, 0x21, 0x58, 0xbc, 0xa2, 0xbd, 0x3d, 0xe9, + 0xe2, 0x6b, 0x35, 0x54, 0x0c, 0x18, 0xe6, 0xad, 0x8c, 0xfc, 0x5f, 0xbd, 0xff, 0x2f, 0x00, 0x00, + 0xff, 0xff, 0x5a, 0x74, 0x38, 0x14, 0x07, 0x06, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -536,7 +540,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.mint.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.mint.v1beta.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -545,7 +549,7 @@ func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts . func (c *queryClient) Inflation(ctx context.Context, in *QueryInflationRequest, opts ...grpc.CallOption) (*QueryInflationResponse, error) { out := new(QueryInflationResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.mint.Query/Inflation", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.mint.v1beta.Query/Inflation", in, out, opts...) if err != nil { return nil, err } @@ -554,7 +558,7 @@ func (c *queryClient) Inflation(ctx context.Context, in *QueryInflationRequest, func (c *queryClient) PhaseStep(ctx context.Context, in *QueryPhaseStepRequest, opts ...grpc.CallOption) (*QueryPhaseStepResponse, error) { out := new(QueryPhaseStepResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.mint.Query/PhaseStep", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.mint.v1beta.Query/PhaseStep", in, out, opts...) if err != nil { return nil, err } @@ -563,7 +567,7 @@ func (c *queryClient) PhaseStep(ctx context.Context, in *QueryPhaseStepRequest, func (c *queryClient) PhaseProvisions(ctx context.Context, in *QueryPhaseProvisionsRequest, opts ...grpc.CallOption) (*QueryPhaseProvisionsResponse, error) { out := new(QueryPhaseProvisionsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.mint.Query/PhaseProvisions", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.mint.v1beta.Query/PhaseProvisions", in, out, opts...) if err != nil { return nil, err } @@ -572,7 +576,7 @@ func (c *queryClient) PhaseProvisions(ctx context.Context, in *QueryPhaseProvisi func (c *queryClient) EndPhaseStatus(ctx context.Context, in *QueryEndPhaseStatusRequest, opts ...grpc.CallOption) (*QueryEndPhaseStatusResponse, error) { out := new(QueryEndPhaseStatusResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.mint.Query/EndPhaseStatus", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.mint.v1beta.Query/EndPhaseStatus", in, out, opts...) if err != nil { return nil, err } @@ -627,7 +631,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.mint.Query/Params", + FullMethod: "/sge.mint.v1beta.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -645,7 +649,7 @@ func _Query_Inflation_Handler(srv interface{}, ctx context.Context, dec func(int } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.mint.Query/Inflation", + FullMethod: "/sge.mint.v1beta.Query/Inflation", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Inflation(ctx, req.(*QueryInflationRequest)) @@ -663,7 +667,7 @@ func _Query_PhaseStep_Handler(srv interface{}, ctx context.Context, dec func(int } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.mint.Query/PhaseStep", + FullMethod: "/sge.mint.v1beta.Query/PhaseStep", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PhaseStep(ctx, req.(*QueryPhaseStepRequest)) @@ -681,7 +685,7 @@ func _Query_PhaseProvisions_Handler(srv interface{}, ctx context.Context, dec fu } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.mint.Query/PhaseProvisions", + FullMethod: "/sge.mint.v1beta.Query/PhaseProvisions", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PhaseProvisions(ctx, req.(*QueryPhaseProvisionsRequest)) @@ -699,7 +703,7 @@ func _Query_EndPhaseStatus_Handler(srv interface{}, ctx context.Context, dec fun } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.mint.Query/EndPhaseStatus", + FullMethod: "/sge.mint.v1beta.Query/EndPhaseStatus", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).EndPhaseStatus(ctx, req.(*QueryEndPhaseStatusRequest)) @@ -707,8 +711,9 @@ func _Query_EndPhaseStatus_Handler(srv interface{}, ctx context.Context, dec fun return interceptor(ctx, in, info, handler) } +var Query_serviceDesc = _Query_serviceDesc var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.mint.Query", + ServiceName: "sge.mint.v1beta.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -733,7 +738,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/mint/query.proto", + Metadata: "sge/mint/v1beta/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/mint/types/query.pb.gw.go b/x/mint/types/query.pb.gw.go index 33bc62a8..13dae753 100644 --- a/x/mint/types/query.pb.gw.go +++ b/x/mint/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: sgenetwork/sge/mint/query.proto +// source: sge/mint/v1beta/query.proto /* Package types is a reverse proxy. diff --git a/x/mint/types/tx.pb.go b/x/mint/types/tx.pb.go index 7e829349..e6350bdc 100644 --- a/x/mint/types/tx.pb.go +++ b/x/mint/types/tx.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: sgenetwork/sge/mint/tx.proto +// source: sge/mint/v1beta/tx.proto package types @@ -48,7 +48,7 @@ func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { - return fileDescriptor_e427455b4e24bcf3, []int{0} + return fileDescriptor_7272ca78af5acaf8, []int{0} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -102,7 +102,7 @@ func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_e427455b4e24bcf3, []int{1} + return fileDescriptor_7272ca78af5acaf8, []int{1} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -132,36 +132,36 @@ func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { - proto.RegisterType((*MsgUpdateParams)(nil), "sgenetwork.sge.mint.MsgUpdateParams") - proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sgenetwork.sge.mint.MsgUpdateParamsResponse") -} - -func init() { proto.RegisterFile("sgenetwork/sge/mint/tx.proto", fileDescriptor_e427455b4e24bcf3) } - -var fileDescriptor_e427455b4e24bcf3 = []byte{ - // 347 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x29, 0x4e, 0x4f, 0xcd, - 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0x4f, 0xd5, 0xcf, 0xcd, 0xcc, 0x2b, 0xd1, - 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x46, 0xc8, 0xea, 0x15, 0xa7, 0xa7, - 0xea, 0x81, 0x64, 0xa5, 0xc4, 0x93, 0xf3, 0x8b, 0x73, 0xf3, 0x8b, 0xf5, 0x73, 0x8b, 0xd3, 0xf5, - 0xcb, 0x0c, 0x41, 0x14, 0x44, 0xb5, 0x94, 0x60, 0x62, 0x6e, 0x66, 0x5e, 0xbe, 0x3e, 0x98, 0x84, - 0x0a, 0x89, 0xa4, 0xe7, 0xa7, 0xe7, 0x83, 0x99, 0xfa, 0x20, 0x16, 0x54, 0x54, 0x12, 0x62, 0x42, - 0x3c, 0x44, 0x02, 0xc2, 0x81, 0x4a, 0x29, 0x60, 0x73, 0x4f, 0x41, 0x62, 0x51, 0x62, 0x2e, 0x54, - 0x85, 0xd2, 0x0e, 0x46, 0x2e, 0x7e, 0xdf, 0xe2, 0xf4, 0xd0, 0x82, 0x94, 0xc4, 0x92, 0xd4, 0x00, - 0xb0, 0x8c, 0x90, 0x19, 0x17, 0x67, 0x62, 0x69, 0x49, 0x46, 0x7e, 0x51, 0x66, 0x49, 0xa5, 0x04, - 0xa3, 0x02, 0xa3, 0x06, 0xa7, 0x93, 0xc4, 0xa5, 0x2d, 0xba, 0x22, 0x50, 0xa3, 0x1d, 0x53, 0x52, - 0x8a, 0x52, 0x8b, 0x8b, 0x83, 0x4b, 0x8a, 0x32, 0xf3, 0xd2, 0x83, 0x10, 0x4a, 0x85, 0xec, 0xb8, - 0xd8, 0x20, 0x66, 0x4b, 0x30, 0x29, 0x30, 0x6a, 0x70, 0x1b, 0x49, 0xeb, 0x61, 0xf1, 0xb0, 0x1e, - 0xc4, 0x12, 0x27, 0xce, 0x13, 0xf7, 0xe4, 0x19, 0x56, 0x3c, 0xdf, 0xa0, 0xc5, 0x18, 0x04, 0xd5, - 0x65, 0xa5, 0xdb, 0xf4, 0x7c, 0x83, 0x16, 0xc2, 0xbc, 0xae, 0xe7, 0x1b, 0xb4, 0xa4, 0x40, 0xae, - 0xae, 0x80, 0xb8, 0x1b, 0xcd, 0x99, 0x4a, 0x92, 0x5c, 0xe2, 0x68, 0x42, 0x41, 0xa9, 0xc5, 0x05, - 0xf9, 0x79, 0xc5, 0xa9, 0x46, 0x05, 0x5c, 0xcc, 0xbe, 0xc5, 0xe9, 0x42, 0x49, 0x5c, 0x3c, 0x28, - 0x1e, 0x53, 0xc1, 0xea, 0x20, 0x34, 0x43, 0xa4, 0x74, 0x88, 0x51, 0x05, 0xb3, 0x4a, 0x8a, 0xb5, - 0x01, 0xe4, 0x07, 0x27, 0xc7, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, - 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0x52, - 0x4f, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0x05, 0xc5, 0x81, 0x2e, 0x72, 0x7c, - 0x40, 0x7d, 0x56, 0x52, 0x59, 0x90, 0x5a, 0x9c, 0xc4, 0x06, 0x8e, 0x11, 0x63, 0x40, 0x00, 0x00, - 0x00, 0xff, 0xff, 0xfa, 0xbf, 0x3b, 0x92, 0x45, 0x02, 0x00, 0x00, + proto.RegisterType((*MsgUpdateParams)(nil), "sge.mint.v1beta.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "sge.mint.v1beta.MsgUpdateParamsResponse") +} + +func init() { proto.RegisterFile("sge/mint/v1beta/tx.proto", fileDescriptor_7272ca78af5acaf8) } + +var fileDescriptor_7272ca78af5acaf8 = []byte{ + // 349 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x28, 0x4e, 0x4f, 0xd5, + 0xcf, 0xcd, 0xcc, 0x2b, 0xd1, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, + 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x2f, 0x4e, 0x4f, 0xd5, 0x03, 0xc9, 0xe8, 0x41, 0x64, 0xa4, + 0x04, 0x13, 0x73, 0x33, 0xf3, 0xf2, 0xf5, 0xc1, 0x24, 0x44, 0x8d, 0x94, 0x78, 0x72, 0x7e, 0x71, + 0x6e, 0x7e, 0xb1, 0x7e, 0x6e, 0x71, 0xba, 0x7e, 0x99, 0x21, 0x88, 0x82, 0x4a, 0x48, 0x42, 0x24, + 0xe2, 0xc1, 0x3c, 0x7d, 0x08, 0x07, 0x2a, 0x25, 0x92, 0x9e, 0x9f, 0x9e, 0x0f, 0x11, 0x07, 0xb1, + 0xa0, 0xa2, 0x32, 0xe8, 0xee, 0x28, 0x48, 0x2c, 0x4a, 0xcc, 0x85, 0xea, 0x51, 0xda, 0xc2, 0xc8, + 0xc5, 0xef, 0x5b, 0x9c, 0x1e, 0x5a, 0x90, 0x92, 0x58, 0x92, 0x1a, 0x00, 0x96, 0x11, 0x32, 0xe3, + 0xe2, 0x4c, 0x2c, 0x2d, 0xc9, 0xc8, 0x2f, 0xca, 0x2c, 0xa9, 0x94, 0x60, 0x54, 0x60, 0xd4, 0xe0, + 0x74, 0x92, 0xb8, 0xb4, 0x45, 0x57, 0x04, 0x6a, 0x99, 0x63, 0x4a, 0x4a, 0x51, 0x6a, 0x71, 0x71, + 0x70, 0x49, 0x51, 0x66, 0x5e, 0x7a, 0x10, 0x42, 0xa9, 0x90, 0x15, 0x17, 0x1b, 0xc4, 0x6c, 0x09, + 0x26, 0x05, 0x46, 0x0d, 0x6e, 0x23, 0x71, 0x3d, 0x34, 0x8f, 0xea, 0x41, 0x2c, 0x70, 0xe2, 0x3c, + 0x71, 0x4f, 0x9e, 0x61, 0xc5, 0xf3, 0x0d, 0x5a, 0x8c, 0x41, 0x50, 0x1d, 0x56, 0xba, 0x4d, 0xcf, + 0x37, 0x68, 0x21, 0xcc, 0xea, 0x7a, 0xbe, 0x41, 0x4b, 0x0a, 0xe4, 0xf0, 0x0a, 0x88, 0xd3, 0xd1, + 0x9c, 0xa8, 0x24, 0xc9, 0x25, 0x8e, 0x26, 0x14, 0x94, 0x5a, 0x5c, 0x90, 0x9f, 0x57, 0x9c, 0x6a, + 0x94, 0xc1, 0xc5, 0xec, 0x5b, 0x9c, 0x2e, 0x14, 0xc5, 0xc5, 0x83, 0xe2, 0x29, 0x05, 0x0c, 0xc7, + 0xa0, 0x19, 0x20, 0xa5, 0x41, 0x48, 0x05, 0xcc, 0x0a, 0x29, 0xd6, 0x06, 0x90, 0xdb, 0x9d, 0x1c, + 0x4f, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, + 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x3d, 0x3d, 0xb3, 0x24, 0xa3, + 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0xbf, 0x38, 0x3d, 0x55, 0x37, 0x2f, 0xb5, 0xa4, 0x3c, 0xbf, + 0x28, 0x5b, 0x1f, 0xc9, 0x47, 0x25, 0x95, 0x05, 0xa9, 0xc5, 0x49, 0x6c, 0xe0, 0x58, 0x30, 0x06, + 0x04, 0x00, 0x00, 0xff, 0xff, 0xcd, 0x2c, 0xf1, 0x78, 0x2d, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -193,7 +193,7 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) - err := c.cc.Invoke(ctx, "/sgenetwork.sge.mint.Msg/UpdateParams", in, out, opts...) + err := c.cc.Invoke(ctx, "/sge.mint.v1beta.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } @@ -231,7 +231,7 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/sgenetwork.sge.mint.Msg/UpdateParams", + FullMethod: "/sge.mint.v1beta.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) @@ -239,8 +239,9 @@ func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +var Msg_serviceDesc = _Msg_serviceDesc var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "sgenetwork.sge.mint.Msg", + ServiceName: "sge.mint.v1beta.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { @@ -249,7 +250,7 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "sgenetwork/sge/mint/tx.proto", + Metadata: "sge/mint/v1beta/tx.proto", } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { diff --git a/x/orderbook/client/cli/query_bet_test.go b/x/orderbook/client/cli/query_bet_test.go deleted file mode 100644 index 6bd4db73..00000000 --- a/x/orderbook/client/cli/query_bet_test.go +++ /dev/null @@ -1,135 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - - bettypes "github.com/sge-network/sge/x/bet/types" - "github.com/sge-network/sge/x/orderbook/client/cli" - "github.com/sge-network/sge/x/orderbook/types" -) - -func networkWithParticipationBetObjects(t *testing.T, n int) (*network.Network, []types.ParticipationBetPair) { - t.Helper() - cfg := network.DefaultConfig() - - // bet module state - betState := bettypes.GenesisState{} - betState.BetList = []bettypes.Bet{} - betState.Uid2IdList = []bettypes.UID2ID{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[bettypes.ModuleName], &betState)) - - // orderbook module state - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - bet := bettypes.Bet{ - UID: uuid.NewString(), - Creator: simapp.TestParamUsers["user"+cast.ToString(i+1)].Address.String(), - } - nullify.Fill(&bet) - betState.BetList = append(betState.BetList, bet) - betState.Uid2IdList = append(betState.Uid2IdList, bettypes.UID2ID{UID: bet.UID, ID: cast.ToUint64(i + 1)}) - - betPair := types.ParticipationBetPair{ - OrderBookUID: testMarketUID, - ParticipationIndex: testParticipationIndex, - BetUID: bet.UID, - } - nullify.Fill(&betPair) - - state.ParticipationBetPairExposureList = append(state.ParticipationBetPairExposureList, betPair) - } - - betBuf, err := cfg.Codec.MarshalJSON(&betState) - require.NoError(t, err) - cfg.GenesisState[bettypes.ModuleName] = betBuf - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), state.ParticipationBetPairExposureList -} - -func TestQueryParticipationBetPair(t *testing.T) { - net, objs := networkWithParticipationBetObjects(t, 5) - - t.Run("ListParticipation", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testMarketUID, - cast.ToString(testParticipationIndex), - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryParticipationBets(), args) - require.NoError(t, err) - var resp types.QueryParticipationFulfilledBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationBets), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationBets), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryParticipationBets(), args) - require.NoError(t, err) - var resp types.QueryParticipationFulfilledBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationBets), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationBets), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryParticipationBets(), args) - require.NoError(t, err) - var resp types.QueryParticipationFulfilledBetsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationBets), - ) - }) - }) -} diff --git a/x/orderbook/client/cli/query_exposure_odds_test.go b/x/orderbook/client/cli/query_exposure_odds_test.go deleted file mode 100644 index 6c9a2384..00000000 --- a/x/orderbook/client/cli/query_exposure_odds_test.go +++ /dev/null @@ -1,172 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/client/cli" - "github.com/sge-network/sge/x/orderbook/types" -) - -func networkWithOddsExposureObjects(t *testing.T, n int) (*network.Network, []types.OrderBookOddsExposure) { - t.Helper() - cfg := network.DefaultConfig() - - // orderbook module state - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - exposure := types.OrderBookOddsExposure{ - OrderBookUID: testMarketUID, - OddsUID: uuid.NewString(), - FulfillmentQueue: []uint64{}, - } - nullify.Fill(&exposure) - - state.OrderBookExposureList = append(state.OrderBookExposureList, exposure) - } - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), state.OrderBookExposureList -} - -func TestQueryOddsExposure(t *testing.T) { - net, objs := networkWithOddsExposureObjects(t, 5) - - t.Run("ShowParticipation", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - for _, tc := range []struct { - desc string - orderBookUID string - oddsUID string - - args []string - err error - obj types.OrderBookOddsExposure - }{ - { - desc: "found", - orderBookUID: testMarketUID, - oddsUID: objs[0].OddsUID, - - args: common, - obj: objs[0], - }, - { - desc: "not found", - oddsUID: "dummy", - orderBookUID: cast.ToString(100000), - - args: common, - err: status.Error(codes.NotFound, "not found"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.orderBookUID, - cast.ToString(tc.oddsUID), - } - args = append(args, tc.args...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookExposure(), args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.ErrorIs(t, stat.Err(), tc.err) - } else { - require.NoError(t, err) - var resp types.OrderBookOddsExposure - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NotNil(t, resp) - require.Equal(t, - nullify.Fill(&tc.obj), - nullify.Fill(&resp), - ) - } - }) - } - }) - - t.Run("ListOrderBookExposures", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testMarketUID, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookExposures(), args) - require.NoError(t, err) - var resp types.QueryOrderBookExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.OrderBookExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.OrderBookExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookExposures(), args) - require.NoError(t, err) - var resp types.QueryOrderBookExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.OrderBookExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.OrderBookExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookExposures(), args) - require.NoError(t, err) - var resp types.QueryOrderBookExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.OrderBookExposures), - ) - }) - }) -} diff --git a/x/orderbook/client/cli/query_exposure_participation_test.go b/x/orderbook/client/cli/query_exposure_participation_test.go deleted file mode 100644 index 1e96d39b..00000000 --- a/x/orderbook/client/cli/query_exposure_participation_test.go +++ /dev/null @@ -1,251 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/client/cli" - "github.com/sge-network/sge/x/orderbook/types" -) - -func networkWithParticipationExposureObjects(t *testing.T, n int) (*network.Network, []types.ParticipationExposure) { - t.Helper() - cfg := network.DefaultConfig() - - // orderbook module state - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - exposure := types.ParticipationExposure{ - OddsUID: uuid.NewString(), - ParticipationIndex: testParticipationIndex, - OrderBookUID: testMarketUID, - Exposure: sdkmath.NewInt(1000), - BetAmount: sdkmath.NewInt(1000), - IsFulfilled: false, - Round: 1, - } - nullify.Fill(&exposure) - - state.ParticipationExposureList = append(state.ParticipationExposureList, exposure) - state.HistoricalParticipationExposureList = append(state.HistoricalParticipationExposureList, exposure) - } - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), state.ParticipationExposureList -} - -func TestQueryParticipationExposure(t *testing.T) { - net, objs := networkWithParticipationExposureObjects(t, 5) - - t.Run("ListOrderBookParticipationExposures", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testMarketUID, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryOrderBookParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryOrderBookParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryOrderBookParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - }) - }) - - t.Run("ListParticipationExposures", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testMarketUID, - cast.ToString(testParticipationIndex), - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - }) - }) - - t.Run("ListHistoricalParticipationExposures", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testMarketUID, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryHistoricalParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryHistoricalParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryHistoricalParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryHistoricalParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryHistoricalParticipationExposures(), args) - require.NoError(t, err) - var resp types.QueryHistoricalParticipationExposuresResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.ParticipationExposures), - ) - }) - }) -} diff --git a/x/orderbook/client/cli/query_orderbook_test.go b/x/orderbook/client/cli/query_orderbook_test.go deleted file mode 100644 index 4114af29..00000000 --- a/x/orderbook/client/cli/query_orderbook_test.go +++ /dev/null @@ -1,170 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/client/cli" - "github.com/sge-network/sge/x/orderbook/types" -) - -func networkWithOrderBookObjects(t *testing.T, n int) (*network.Network, []types.OrderBook) { - t.Helper() - cfg := network.DefaultConfig() - - // orderbook module state - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - orderBook := types.OrderBook{ - UID: uuid.NewString(), - ParticipationCount: 0, - OddsCount: 1, - Status: 1, - } - nullify.Fill(&orderBook) - - state.OrderBookList = append(state.OrderBookList, orderBook) - } - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), state.OrderBookList -} - -func TestQueryOrderBook(t *testing.T) { - net, objs := networkWithOrderBookObjects(t, 5) - - t.Run("ShowOrderBook", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - for _, tc := range []struct { - desc string - orderBookUID string - participationIndex uint64 - - args []string - err error - obj types.OrderBook - }{ - { - desc: "found", - orderBookUID: testMarketUID, - - args: common, - obj: objs[0], - }, - { - desc: "not found", - participationIndex: 10000, - orderBookUID: cast.ToString(100000), - - args: common, - err: status.Error(codes.NotFound, "not found"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.obj.UID, - } - args = append(args, tc.args...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBook(), args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.ErrorIs(t, stat.Err(), tc.err) - } else { - require.NoError(t, err) - var resp types.OrderBook - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NotNil(t, resp) - require.Equal(t, - nullify.Fill(&tc.obj), - nullify.Fill(&resp), - ) - } - }) - } - }) - - t.Run("ListParticipation", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBooks(), args) - require.NoError(t, err) - var resp types.QueryOrderBooksResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Orderbooks), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Orderbooks), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBooks(), args) - require.NoError(t, err) - var resp types.QueryOrderBooksResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.Orderbooks), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.Orderbooks), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBooks(), args) - require.NoError(t, err) - var resp types.QueryOrderBooksResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.Orderbooks), - ) - }) - }) -} diff --git a/x/orderbook/client/cli/query_params_test.go b/x/orderbook/client/cli/query_params_test.go deleted file mode 100644 index a193158e..00000000 --- a/x/orderbook/client/cli/query_params_test.go +++ /dev/null @@ -1,62 +0,0 @@ -package cli_test - -import ( - "encoding/json" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/orderbook/client/cli" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestQueryParams(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdQueryParams(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - var params types.QueryParamsResponse - err = json.Unmarshal(res.Bytes(), ¶ms) - // command-line response, wraps the primitive numbers in double quotes, so it is not unmarshall-able. - require.EqualError( - t, - err, - "json: cannot unmarshal string into Go struct field Params.params.max_order_book_participations of type uint64", - "json: cannot unmarshal string into Go struct field Params.params.batch_settlement_count of type uint64", - "json: cannot unmarshal string into Go struct field Params.params.requeue_threshold of type uint64", - ) - - defaultParams := types.DefaultParams() - defaultParams.BatchSettlementCount = 0 - defaultParams.MaxOrderBookParticipations = 0 - defaultParams.RequeueThreshold = 0 - require.Equal(t, types.QueryParamsResponse{ - Params: defaultParams, - }, params) - }) - } -} diff --git a/x/orderbook/client/cli/query_participation_test.go b/x/orderbook/client/cli/query_participation_test.go deleted file mode 100644 index 043ba55a..00000000 --- a/x/orderbook/client/cli/query_participation_test.go +++ /dev/null @@ -1,190 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdkmath "cosmossdk.io/math" - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/client/cli" - "github.com/sge-network/sge/x/orderbook/types" -) - -const ( - testMarketUID = "5db09053-2901-4110-8fb5-c14e21f8d555" - testParticipationIndex = 1 -) - -func networkWithParticipationObjects(t *testing.T, n int) (*network.Network, []types.OrderBookParticipation) { - t.Helper() - cfg := network.DefaultConfig() - - // orderbook module state - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - participation := types.OrderBookParticipation{ - Index: cast.ToUint64(i + 1), - OrderBookUID: testMarketUID, - ParticipantAddress: testAddress, - Liquidity: sdkmath.NewInt(1000), - Fee: sdkmath.NewInt(10), - CurrentRoundLiquidity: sdkmath.NewInt(1000), - ExposuresNotFilled: 1, - TotalBetAmount: sdkmath.NewInt(0), - CurrentRoundTotalBetAmount: sdkmath.NewInt(0), - MaxLoss: sdkmath.NewInt(0), - CurrentRoundMaxLoss: sdkmath.NewInt(0), - CurrentRoundMaxLossOddsUID: "6db09053-2901-4110-8fb5-c14e21f8d666", - ActualProfit: sdkmath.NewInt(0), - IsSettled: false, - ReturnedAmount: sdkmath.NewInt(1010), - ReimbursedFee: sdkmath.NewInt(10), - } - nullify.Fill(&participation) - - state.OrderBookParticipationList = append(state.OrderBookParticipationList, participation) - } - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), state.OrderBookParticipationList -} - -func TestQueryParticipation(t *testing.T) { - net, objs := networkWithParticipationObjects(t, 5) - - t.Run("ShowParticipation", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - for _, tc := range []struct { - desc string - orderBookUID string - participationIndex uint64 - - args []string - err error - obj types.OrderBookParticipation - }{ - { - desc: "found", - orderBookUID: testMarketUID, - participationIndex: objs[0].Index, - - args: common, - obj: objs[0], - }, - { - desc: "not found", - participationIndex: 10000, - orderBookUID: cast.ToString(100000), - - args: common, - err: status.Error(codes.NotFound, "not found"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.orderBookUID, - cast.ToString(tc.participationIndex), - } - args = append(args, tc.args...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookParticipation(), args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.ErrorIs(t, stat.Err(), tc.err) - } else { - require.NoError(t, err) - var resp types.OrderBookParticipation - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NotNil(t, resp) - require.Equal(t, - nullify.Fill(&tc.obj), - nullify.Fill(&resp), - ) - } - }) - } - }) - - t.Run("ListParticipation", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - request := func(next []byte, offset, limit uint64, total bool) []string { - args := []string{ - testMarketUID, - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - if next == nil { - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagOffset, offset)) - } else { - args = append(args, fmt.Sprintf("--%s=%s", flags.FlagPageKey, next)) - } - args = append(args, fmt.Sprintf("--%s=%d", flags.FlagLimit, limit)) - if total { - args = append(args, fmt.Sprintf("--%s", flags.FlagCountTotal)) - } - return args - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(objs); i += step { - args := request(nil, uint64(i), uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookParticipations(), args) - require.NoError(t, err) - var resp types.QueryOrderBookParticipationsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.OrderBookParticipations), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.OrderBookParticipations), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(objs); i += step { - args := request(next, 0, uint64(step), false) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookParticipations(), args) - require.NoError(t, err) - var resp types.QueryOrderBookParticipationsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.LessOrEqual(t, len(resp.OrderBookParticipations), step) - require.Subset(t, - nullify.Fill(objs), - nullify.Fill(resp.OrderBookParticipations), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - args := request(nil, 0, uint64(len(objs)), true) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.GetCmdQueryOrderBookParticipations(), args) - require.NoError(t, err) - var resp types.QueryOrderBookParticipationsResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NoError(t, err) - require.Equal(t, len(objs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(objs), - nullify.Fill(resp.OrderBookParticipations), - ) - }) - }) -} diff --git a/x/orderbook/client/cli/query_test.go b/x/orderbook/client/cli/query_test.go deleted file mode 100644 index 13a6de9f..00000000 --- a/x/orderbook/client/cli/query_test.go +++ /dev/null @@ -1,49 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - "github.com/sge-network/sge/testutil/network" - - "github.com/sge-network/sge/x/orderbook/client/cli" -) - -const testAddress = "cosmos1s4ycalgh3gjemd4hmqcvcgmnf647rnd0tpg2w9" - -func TestGetQueryCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetQueryCmd(""), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True( - t, - strings.HasPrefix(string(res.Bytes()), "Querying commands for the orderbook module"), - ) - }) - } -} diff --git a/x/orderbook/handler.go b/x/orderbook/handler.go deleted file mode 100644 index 3f8d5c38..00000000 --- a/x/orderbook/handler.go +++ /dev/null @@ -1,32 +0,0 @@ -package orderbook - -import ( - "fmt" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" -) - -// NewHandler initialize a new sdk.handler instance for registered messages -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - _ = ctx - - switch msg := msg.(type) { - case *types.MsgUpdateParams: - res, err := msgServer.UpdateParams(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrtypes.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/orderbook/keeper/bet_settle_test.go b/x/orderbook/keeper/bet_settle_test.go deleted file mode 100644 index 6bfefdae..00000000 --- a/x/orderbook/keeper/bet_settle_test.go +++ /dev/null @@ -1,90 +0,0 @@ -package keeper_test - -import ( - "testing" - - sdkmath "cosmossdk.io/math" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/app/params" - bettypes "github.com/sge-network/sge/x/bet/types" - markettypes "github.com/sge-network/sge/x/market/types" -) - -func TestBetSettlement(t *testing.T) { - ts := newTestBetSuite(t) - bets, winner1PayoutProfit, winner2PayoutProfit := ts.placeBetsAndTest() - ts.settleBetsAndTest(bets, winner1PayoutProfit, winner2PayoutProfit) -} - -func (ts *testBetSuite) settleBetsAndTest( - bets []bettypes.Bet, - winner1PayoutProfit, winner2PayoutProfit sdkmath.LegacyDec, -) { - winner1BalAfterWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - sdk.MustAccAddressFromBech32(bets[0].Creator), - params.DefaultBondDenom, - ).Amount - winner2BalAfterWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - sdk.MustAccAddressFromBech32(bets[1].Creator), - params.DefaultBondDenom, - ).Amount - loserBalanceAfterWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - sdk.MustAccAddressFromBech32(bets[2].Creator), - params.DefaultBondDenom, - ).Amount - - // resolve market - // - ts.tApp.MarketKeeper.Resolve(ts.ctx, ts.market, &markettypes.MarketResolutionTicketPayload{ - UID: ts.market.UID, - ResolutionTS: ts.market.StartTS + 10, - WinnerOddsUIDs: []string{ts.market.Odds[0].UID, ts.market.Odds[1].UID}, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - - // settle all the resolved market - err := ts.tApp.BetKeeper.BatchMarketSettlements(ts.ctx) - require.NoError(ts.t, err) - - winner1BettorBalAfterSettlement := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - sdk.MustAccAddressFromBech32(bets[0].Creator), - params.DefaultBondDenom, - ) - expWinner1BalanceAfterSettlement := winner1BalAfterWager.Add(bets[0].Amount). - Add(winner1PayoutProfit.TruncateInt()) - require.Equal( - ts.t, - expWinner1BalanceAfterSettlement.Int64(), - winner1BettorBalAfterSettlement.Amount.Int64(), - ) - - winner2BettorBalAfterSettlement := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - sdk.MustAccAddressFromBech32(bets[1].Creator), - params.DefaultBondDenom, - ) - expWinner2BalanceAfterSettlement := winner2BalAfterWager.Add(bets[1].Amount). - Add(winner2PayoutProfit.TruncateInt()) - require.Equal( - ts.t, - expWinner2BalanceAfterSettlement.Int64(), - winner2BettorBalAfterSettlement.Amount.Int64(), - ) - - loserBettorBalAfterSettlement := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - sdk.MustAccAddressFromBech32(bets[2].Creator), - params.DefaultBondDenom, - ) - require.Equal( - ts.t, - loserBalanceAfterWager.Int64(), - loserBettorBalAfterSettlement.Amount.Int64(), - ) -} diff --git a/x/orderbook/keeper/bet_wager_test.go b/x/orderbook/keeper/bet_wager_test.go deleted file mode 100644 index 9407bb80..00000000 --- a/x/orderbook/keeper/bet_wager_test.go +++ /dev/null @@ -1,512 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/simapp" - bettypes "github.com/sge-network/sge/x/bet/types" - housetypes "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestWager(t *testing.T) { - ts := newTestBetSuite(t) - ts.placeBetsAndTest() -} - -type testBetSuite struct { - t *testing.T - k *keeper.KeeperTest - ctx sdk.Context - tApp simapp.TestApp - betFee sdkmath.Int - market markettypes.Market - deposits []housetypes.Deposit - participations []types.OrderBookParticipation -} - -func newTestBetSuite(t *testing.T) testBetSuite { - tApp, k, ctx := setupKeeperAndApp(t) - - betFee := sdkmath.NewInt(10) - - marketUID := uuid.NewString() - market := markettypes.Market{ - UID: marketUID, - StartTS: cast.ToUint64(time.Now().Unix()), - EndTS: cast.ToUint64(time.Now().Add(5 * time.Minute).Unix()), - Odds: []*markettypes.Odds{ - {UID: uuid.NewString(), Meta: "test odds1"}, - {UID: uuid.NewString(), Meta: "test odds2"}, - {UID: uuid.NewString(), Meta: "test odds3"}, - }, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - Creator: simapp.TestParamUsers["user1"].Address.String(), - Meta: "test market", - BookUID: marketUID, - } - - deposits := []housetypes.Deposit{ - { - DepositorAddress: simapp.TestParamUsers["user2"].Address.String(), - Amount: sdkmath.NewInt(8000), - }, - { - DepositorAddress: simapp.TestParamUsers["user3"].Address.String(), - Amount: sdkmath.NewInt(10000), - }, - { - DepositorAddress: simapp.TestParamUsers["user4"].Address.String(), - Amount: sdkmath.NewInt(10000), - }, - } - - participations := make([]types.OrderBookParticipation, len(deposits)) - - return testBetSuite{t, k, ctx, *tApp, betFee, market, deposits, participations} -} - -func (ts *testBetSuite) placeBetsAndTest() ([]bettypes.Bet, sdkmath.LegacyDec, sdkmath.LegacyDec) { - ts.tApp.MarketKeeper.SetMarket(ts.ctx, ts.market) - - err := ts.k.InitiateOrderBook(ts.ctx, ts.market.UID, []string{ - ts.market.Odds[0].UID, - ts.market.Odds[1].UID, - ts.market.Odds[2].UID, - }) - require.NoError(ts.t, err) - - found := false - participationIndex, _, err := ts.tApp.HouseKeeper.Deposit( - ts.ctx, - ts.deposits[0].DepositorAddress, - ts.deposits[0].DepositorAddress, - ts.market.BookUID, - ts.deposits[0].Amount, - ) - require.NoError(ts.t, err) - ts.deposits[0], found = ts.tApp.HouseKeeper.GetDeposit( - ts.ctx, - ts.deposits[0].DepositorAddress, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - ts.participations[0], found = ts.k.GetOrderBookParticipation( - ts.ctx, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - - participationIndex, _, err = ts.tApp.HouseKeeper.Deposit( - ts.ctx, - ts.deposits[1].DepositorAddress, - ts.deposits[1].DepositorAddress, - ts.market.BookUID, - ts.deposits[1].Amount, - ) - require.NoError(ts.t, err) - ts.deposits[1], found = ts.tApp.HouseKeeper.GetDeposit( - ts.ctx, - ts.deposits[1].DepositorAddress, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - ts.participations[1], found = ts.k.GetOrderBookParticipation( - ts.ctx, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - - participationIndex, _, err = ts.tApp.HouseKeeper.Deposit( - ts.ctx, - ts.deposits[2].DepositorAddress, - ts.deposits[2].DepositorAddress, - ts.market.BookUID, - ts.deposits[2].Amount, - ) - require.NoError(ts.t, err) - ts.deposits[2], found = ts.tApp.HouseKeeper.GetDeposit( - ts.ctx, - ts.deposits[2].DepositorAddress, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - ts.participations[2], found = ts.k.GetOrderBookParticipation( - ts.ctx, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - - oddsExposures, found := ts.k.GetOrderBookOddsExposure( - ts.ctx, - ts.market.BookUID, - ts.market.Odds[0].UID, - ) - require.True(ts.t, found) - require.Equal(ts.t, []uint64{1, 2, 3}, oddsExposures.FulfillmentQueue) - - defaultBetAmount := sdkmath.NewInt(400) - - betOdds := make(map[string]*bettypes.BetOddsCompact) - var oddUIDS []string - for _, odd := range ts.market.Odds { - betOdds[odd.UID] = &bettypes.BetOddsCompact{UID: odd.UID, MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.3")} - oddUIDS = append(oddUIDS, odd.UID) - } - - ///// winner1 bet placement - // - // - winner1BettorAddr := simapp.TestParamUsers["user5"].Address - winner1Bal := ts.tApp.BankKeeper.GetBalance(ts.ctx, winner1BettorAddr, params.DefaultBondDenom) - winner1BetID := uint64(1) - winner1Bet, winner1PayoutProfit, winner1BetFulfillment := ts.placeTestBet( - winner1BettorAddr, - ts.market.UID, - ts.market.Odds[0].UID, - winner1BetID, - defaultBetAmount, - ts.betFee, - nil, - betOdds, - oddUIDS, - ) - winner1Bet.BetFulfillment = winner1BetFulfillment - ts.tApp.BetKeeper.SetBet(ts.ctx, winner1Bet, winner1BetID) - winner1BalAfterWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - winner1BettorAddr, - params.DefaultBondDenom, - ) - expWinner1BalanceAfterWager := winner1Bal.Amount.Sub(winner1Bet.Amount).Sub(winner1Bet.Fee) - require.Equal( - ts.t, - expWinner1BalanceAfterWager.Int64(), - winner1BalAfterWager.Amount.Int64(), - ) - - oddsExposures, found = ts.k.GetOrderBookOddsExposure( - ts.ctx, - ts.market.BookUID, - ts.market.Odds[0].UID, - ) - require.True(ts.t, found) - require.Equal(ts.t, []uint64{2, 3}, oddsExposures.FulfillmentQueue) - - ///// winner2 bet placement - // - // - winner2BettorAddr := simapp.TestParamUsers["user6"].Address - winner2Bal := ts.tApp.BankKeeper.GetBalance(ts.ctx, winner2BettorAddr, params.DefaultBondDenom) - winner2BetID := uint64(2) - winner2Bet, winner2PayoutProfit, winner2BetFulfillment := ts.placeTestBet( - winner2BettorAddr, - ts.market.UID, - ts.market.Odds[0].UID, - winner2BetID, - defaultBetAmount, - ts.betFee, - nil, - betOdds, - oddUIDS, - ) - - winner2Bet.BetFulfillment = winner2BetFulfillment - ts.tApp.BetKeeper.SetBet(ts.ctx, winner2Bet, winner2BetID) - winner2BalAfterWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - winner1BettorAddr, - params.DefaultBondDenom, - ) - expWinner2BalanceAfterWager := winner2Bal.Amount.Sub(winner2Bet.Amount).Sub(winner2Bet.Fee) - require.Equal( - ts.t, - expWinner2BalanceAfterWager.Int64(), - winner2BalAfterWager.Amount.Int64(), - ) - oddsExposures, found = ts.k.GetOrderBookOddsExposure( - ts.ctx, - ts.market.BookUID, - ts.market.Odds[0].UID, - ) - require.True(ts.t, found) - require.Equal(ts.t, []uint64{3}, oddsExposures.FulfillmentQueue) - - ///// failed winner bet placement - // should fail because there is not participation to fulfill this bet. - // - failedWinnerBettorAddr := simapp.TestParamUsers["user7"].Address - failedWinnerBetID := uint64(3) - ts.placeTestBet( - failedWinnerBettorAddr, - ts.market.UID, - ts.market.Odds[0].UID, - failedWinnerBetID, - sdkmath.NewInt(100000000000), - ts.betFee, - types.ErrInsufficientLiquidityInOrderBook, - betOdds, - oddUIDS, - ) - - ///// loser bet placement - // - // - loserBettorAddr := simapp.TestParamUsers["user8"].Address - loserBal := ts.tApp.BankKeeper.GetBalance(ts.ctx, loserBettorAddr, params.DefaultBondDenom) - loserBetID := uint64(4) - loserBet, _, loserBetFulfillment := ts.placeTestBet( - loserBettorAddr, - ts.market.UID, - ts.market.Odds[2].UID, - loserBetID, - defaultBetAmount, - ts.betFee, - nil, - betOdds, - oddUIDS, - ) - loserBet.BetFulfillment = loserBetFulfillment - ts.tApp.BetKeeper.SetBet(ts.ctx, loserBet, loserBetID) - loserBalAfterWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - loserBettorAddr, - params.DefaultBondDenom, - ) - expLoserBalanceAfterWager := loserBal.Amount.Sub(loserBet.Amount).Sub(loserBet.Fee) - require.Equal(ts.t, expLoserBalanceAfterWager, loserBalAfterWager.Amount) - - return []bettypes.Bet{ - winner1Bet, - winner2Bet, - loserBet, - }, winner1PayoutProfit, winner2PayoutProfit -} - -func (ts *testBetSuite) placeTestBet( - bettorAddr sdk.AccAddress, - marketUID, oddsUID string, - betID uint64, - amount sdkmath.Int, - fee sdkmath.Int, - expErr error, - odds map[string]*bettypes.BetOddsCompact, - oddUIDS []string, -) (bettypes.Bet, sdkmath.LegacyDec, []*bettypes.BetFulfillment) { - bet := bettypes.Bet{ - UID: uuid.NewString(), - MarketUID: marketUID, - OddsUID: oddsUID, - OddsValue: "1.1", - Amount: amount, - Fee: fee, - Status: bettypes.Bet_STATUS_PENDING, - Creator: bettorAddr.String(), - CreatedAt: cast.ToInt64(ts.ctx.BlockTime().Unix()), - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - } - - payoutProfit, err := bettypes.CalculatePayoutProfit(bet.OddsValue, bet.Amount) - require.NoError(ts.t, err) - - betFeeCollectorBalanceBeforeWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - ts.tApp.AccountKeeper.GetModuleAddress(bettypes.BetFeeCollectorFunder{}.GetModuleAcc()), - params.DefaultBondDenom, - ) - liquidityPoolBalanceBeforeWager := ts.tApp.BankKeeper.GetBalance( - ts.ctx, - ts.tApp.AccountKeeper.GetModuleAddress(types.OrderBookLiquidityFunder{}.GetModuleAcc()), - params.DefaultBondDenom, - ) - - betFulfillment, err := ts.k.ProcessWager( - ts.ctx, bet.UID, bet.MarketUID, bet.OddsUID, bet.MaxLossMultiplier, bet.Amount, payoutProfit, - bettorAddr, bet.Fee, bet.OddsValue, 1, odds, oddUIDS, - ) - if expErr != nil { - require.ErrorIs(ts.t, expErr, err) - } else { - require.NoError(ts.t, err) - ts.tApp.BetKeeper.SetBet(ts.ctx, bet, betID) - ts.tApp.BetKeeper.SetPendingBet(ts.ctx, &bettypes.PendingBet{Creator: bet.Creator, UID: bet.UID}, betID, marketUID) - - betFeeCollectorBalanceAfterWager := ts.tApp.BankKeeper.GetBalance(ts.ctx, ts.tApp.AccountKeeper.GetModuleAddress(bettypes.BetFeeCollectorFunder{}.GetModuleAcc()), params.DefaultBondDenom) - require.Equal(ts.t, bet.Fee.Int64(), betFeeCollectorBalanceAfterWager.Sub(betFeeCollectorBalanceBeforeWager).Amount.Int64()) - - liquidityPoolBalanceAfterWager := ts.tApp.BankKeeper.GetBalance(ts.ctx, ts.tApp.AccountKeeper.GetModuleAddress(types.OrderBookLiquidityFunder{}.GetModuleAcc()), params.DefaultBondDenom) - require.Equal(ts.t, bet.Amount.Int64(), liquidityPoolBalanceAfterWager.Sub(liquidityPoolBalanceBeforeWager).Amount.Int64()) - } - - return bet, payoutProfit, betFulfillment -} - -// 100 Deposits case - -func TestWagerLargeNumbers(t *testing.T) { - ts := newTestBetSuiteForLargeNumbers(t) - ts.bulkDepositPlaceBetsAndTest() -} - -func newTestBetSuiteForLargeNumbers(t *testing.T) testBetSuite { - tApp, k, ctx := setupKeeperAndApp(t) - - betFee := sdkmath.NewInt(10) - - params := tApp.HouseKeeper.GetParams(ctx) - params.HouseParticipationFee = sdkmath.LegacyNewDec(0) - tApp.HouseKeeper.SetParams(ctx, params) - - marketUID := uuid.NewString() - market := markettypes.Market{ - UID: marketUID, - StartTS: cast.ToUint64(time.Now().Unix()), - EndTS: cast.ToUint64(time.Now().Add(5 * time.Minute).Unix()), - Odds: []*markettypes.Odds{ - {UID: uuid.NewString(), Meta: "test odds1"}, - {UID: uuid.NewString(), Meta: "test odds2"}, - {UID: uuid.NewString(), Meta: "test odds3"}, - {UID: uuid.NewString(), Meta: "test odds4"}, - {UID: uuid.NewString(), Meta: "test odds5"}, - {UID: uuid.NewString(), Meta: "test odds6"}, - }, - Status: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - Creator: simapp.TestParamUsers["user1"].Address.String(), - Meta: "test market", - BookUID: marketUID, - } - - deposits := []housetypes.Deposit{} - for i := 0; i < 100; i++ { - deposits = append(deposits, housetypes.Deposit{ - DepositorAddress: simapp.TestParamUsers["user2"].Address.String(), - Amount: sdkmath.NewInt(10000000), - }) - } - - participations := make([]types.OrderBookParticipation, len(deposits)) - - return testBetSuite{t, k, ctx, *tApp, betFee, market, deposits, participations} -} - -func (ts *testBetSuite) bulkDepositPlaceBetsAndTest() { - ts.tApp.MarketKeeper.SetMarket(ts.ctx, ts.market) - - betAmount := sdkmath.NewInt(25354548) - - oddsUIDs := []string{} - for _, o := range ts.market.Odds { - oddsUIDs = append(oddsUIDs, o.UID) - } - err := ts.k.InitiateOrderBook(ts.ctx, ts.market.UID, oddsUIDs) - require.NoError(ts.t, err) - - for i := 0; i < len(ts.deposits); i++ { - found := false - participationIndex, _, err := ts.tApp.HouseKeeper.Deposit( - ts.ctx, - ts.deposits[i].DepositorAddress, - ts.deposits[i].DepositorAddress, - ts.market.BookUID, - ts.deposits[i].Amount, - ) - require.NoError(ts.t, err) - ts.deposits[i], found = ts.tApp.HouseKeeper.GetDeposit( - ts.ctx, - ts.deposits[i].DepositorAddress, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - ts.participations[i], found = ts.k.GetOrderBookParticipation( - ts.ctx, - ts.market.UID, - participationIndex, - ) - require.True(ts.t, found) - } - - multipliers := []sdkmath.LegacyDec{ - sdkmath.LegacyMustNewDecFromStr("0.8649932157"), - sdkmath.LegacyMustNewDecFromStr("0.8658575751"), - sdkmath.LegacyMustNewDecFromStr("0.9368906369"), - sdkmath.LegacyMustNewDecFromStr("0.81411403723"), - sdkmath.LegacyMustNewDecFromStr("1.00"), - sdkmath.LegacyMustNewDecFromStr("0.92010393313"), - } - betOdds := make(map[string]*bettypes.BetOddsCompact) - var oddUIDS []string - for i, odd := range ts.market.Odds { - betOdds[odd.UID] = &bettypes.BetOddsCompact{UID: odd.UID, MaxLossMultiplier: multipliers[i]} - oddUIDS = append(oddUIDS, odd.UID) - } - - bettorAddr := simapp.TestParamUsers["user5"].Address - bet := bettypes.Bet{ - UID: uuid.NewString(), - MarketUID: ts.market.UID, - OddsUID: ts.market.Odds[1].UID, - OddsValue: "4.415", - Amount: betAmount, - Fee: sdkmath.ZeroInt(), - Status: bettypes.Bet_STATUS_PENDING, - Creator: bettorAddr.String(), - CreatedAt: cast.ToInt64(ts.ctx.BlockTime().Unix()), - MaxLossMultiplier: betOdds[ts.market.Odds[1].UID].MaxLossMultiplier, - } - - payoutProfit, err := bettypes.CalculatePayoutProfit(bet.OddsValue, bet.Amount) - require.NoError(ts.t, err) - - betFulfillment, err := ts.k.ProcessWager( - ts.ctx, bet.UID, bet.MarketUID, bet.OddsUID, bet.MaxLossMultiplier, bet.Amount, payoutProfit, - bettorAddr, bet.Fee, bet.OddsValue, 1, betOdds, oddUIDS, - ) - require.NoError(ts.t, err) - - expected := []*bettypes.BetFulfillment{ - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 1, BetAmount: sdkmath.NewInt(2535454), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 2, BetAmount: sdkmath.NewInt(2535454), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 3, BetAmount: sdkmath.NewInt(2535454), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 4, BetAmount: sdkmath.NewInt(2535453), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 5, BetAmount: sdkmath.NewInt(2535453), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 6, BetAmount: sdkmath.NewInt(2535453), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 7, BetAmount: sdkmath.NewInt(2535453), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 8, BetAmount: sdkmath.NewInt(2535454), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 9, BetAmount: sdkmath.NewInt(2535453), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 10, BetAmount: sdkmath.NewInt(2535454), PayoutProfit: sdkmath.NewInt(8658575)}, - {ParticipantAddress: simapp.TestParamUsers["user2"].Address.String(), ParticipationIndex: 11, BetAmount: sdkmath.NewInt(13), PayoutProfit: sdkmath.NewInt(31)}, - } - require.Equal(ts.t, expected, betFulfillment) - - // fulfilled bet amount sum should be equal to the actual bet amount - betAmountSum := sdkmath.NewInt(0) - for _, bf := range betFulfillment { - betAmountSum = betAmountSum.Add(bf.BetAmount) - } - require.Equal(ts.t, betAmount, betAmountSum) - - // fulfilled bet payout profit sum should be equal to the calculated payout profit - payoutProfitSum := sdkmath.NewInt(0) - for _, bf := range betFulfillment { - payoutProfitSum = payoutProfitSum.Add(bf.PayoutProfit) - } - require.Equal(ts.t, payoutProfit.TruncateInt(), payoutProfitSum) -} diff --git a/x/orderbook/keeper/exposure_odds_test.go b/x/orderbook/keeper/exposure_odds_test.go deleted file mode 100644 index 1fc591a1..00000000 --- a/x/orderbook/keeper/exposure_odds_test.go +++ /dev/null @@ -1,93 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" -) - -func createNOrderBookOddsExposure( - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.OrderBookOddsExposure { - items := make([]types.OrderBookOddsExposure, n) - - for i := range items { - items[i].FulfillmentQueue = []uint64{1} - items[i].OddsUID = uuid.NewString() - items[i].OrderBookUID = testOrderBookUID - - keeper.SetOrderBookOddsExposure(ctx, items[i]) - } - return items -} - -func TestOddsExposuresByOrderBookGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNOrderBookOddsExposure(k, ctx, 10) - - rst, err := k.GetOddsExposuresByOrderBook(ctx, - uuid.NewString(), - ) - var expectedResp []types.OrderBookOddsExposure - require.NoError(t, err) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - rst, err = k.GetOddsExposuresByOrderBook(ctx, - testOrderBookUID, - ) - - require.NoError(t, err) - require.Equal(t, len(items), len(rst)) -} - -func TestOrderBookOddsExposureGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNOrderBookOddsExposure(k, ctx, 10) - - rst, found := k.GetOrderBookOddsExposure(ctx, - uuid.NewString(), - uuid.NewString(), - ) - var expectedResp types.OrderBookOddsExposure - require.False(t, found) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - for _, item := range items { - rst, found := k.GetOrderBookOddsExposure(ctx, - item.OrderBookUID, - item.OddsUID, - ) - require.True(t, found) - require.Equal(t, - nullify.Fill(item), - nullify.Fill(rst), - ) - } -} - -func TestOrderBookOddsExposureGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNOrderBookOddsExposure(k, ctx, 10) - - exposures, err := k.GetAllOrderBookExposures(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(exposures), - ) -} diff --git a/x/orderbook/keeper/exposure_participation_test.go b/x/orderbook/keeper/exposure_participation_test.go deleted file mode 100644 index 365f82f6..00000000 --- a/x/orderbook/keeper/exposure_participation_test.go +++ /dev/null @@ -1,110 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" -) - -func createNParticipationExposure( - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.ParticipationExposure { - items := make([]types.ParticipationExposure, n) - - for i := range items { - items[i].ParticipationIndex = testParticipationIndex - items[i].OrderBookUID = testOrderBookUID - items[i].OddsUID = uuid.NewString() - items[i].Round = 1 - items[i].IsFulfilled = false - items[i].BetAmount = sdkmath.NewInt(100) - items[i].Exposure = sdkmath.NewInt(100) - - keeper.SetParticipationExposure(ctx, items[i]) - keeper.SetParticipationExposureByIndex(ctx, items[i]) - keeper.SetHistoricalParticipationExposure(ctx, items[i]) - } - return items -} - -func TestParticipationExposureGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipationExposure(k, ctx, 10) - - rst, err := k.GetExposureByOrderBookAndOdds(ctx, - items[0].OrderBookUID, - uuid.NewString(), - ) - var expectedResp []types.ParticipationExposure - require.NoError(t, err) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - for _, item := range items { - rst, err := k.GetExposureByOrderBookAndOdds(ctx, - item.OrderBookUID, - item.OddsUID, - ) - require.NoError(t, err) - require.Equal(t, - nullify.Fill([]types.ParticipationExposure{item}), - nullify.Fill(rst), - ) - } -} - -func TestExposureByOrderBookAndParticipationIndexGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipationExposure(k, ctx, 10) - - rst, err := k.GetExposureByOrderBookAndParticipationIndex(ctx, - items[0].OrderBookUID, - 1000, - ) - var expectedResp []types.ParticipationExposure - require.NoError(t, err) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - rst, err = k.GetExposureByOrderBookAndParticipationIndex(ctx, - testOrderBookUID, - testParticipationIndex, - ) - require.NoError(t, err) - require.Equal(t, len(items), len(rst)) -} - -func TestAllHistoricalParticipationExposuresGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipationExposure(k, ctx, 10) - - rst, err := k.GetAllHistoricalParticipationExposures(ctx) - require.NoError(t, err) - require.Equal(t, len(items), len(rst)) -} - -func TestParticipationExposureGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipationExposure(k, ctx, 10) - - exposures, err := k.GetAllParticipationExposures(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(exposures), - ) -} diff --git a/x/orderbook/keeper/fund_test.go b/x/orderbook/keeper/fund_test.go deleted file mode 100644 index 14e98c91..00000000 --- a/x/orderbook/keeper/fund_test.go +++ /dev/null @@ -1,105 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestFund(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - - senderAddr := simapp.TestParamUsers["user1"].Address - initialBalance := tApp.BankKeeper.GetBalance(ctx, senderAddr, params.DefaultBondDenom) - successAmount := sdkmath.NewInt(1000) - - for _, tc := range []struct { - desc string - amount sdkmath.Int - - err error - }{ - { - desc: "not enough balance", - amount: sdkmath.NewInt(100000000000000), - err: types.ErrInsufficientAccountBalance, - }, - { - desc: "success", - amount: successAmount, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - err := k.Fund( - types.OrderBookLiquidityFunder{}, - ctx, - senderAddr, - tc.amount, - ) - - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - balance := tApp.BankKeeper.GetBalance(ctx, senderAddr, params.DefaultBondDenom) - require.Equal(t, initialBalance.Sub(balance).Amount, successAmount) - } - }) - } -} - -func TestReFund(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - - successAmount := sdkmath.NewInt(1000) - err := k.Fund( - types.OrderBookLiquidityFunder{}, - ctx, - simapp.TestParamUsers["user2"].Address, - successAmount, - ) - require.NoError(t, err) - - receiverAddr := simapp.TestParamUsers["user1"].Address - initialBalance := tApp.BankKeeper.GetBalance(ctx, receiverAddr, params.DefaultBondDenom) - - for _, tc := range []struct { - desc string - amount sdkmath.Int - - err error - }{ - { - desc: "not enough balance", - amount: successAmount.Add(sdkmath.NewInt(1)), - err: types.ErrInsufficientBalanceInModuleAccount, - }, - { - desc: "success", - amount: successAmount, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - err := k.ReFund( - types.OrderBookLiquidityFunder{}, - ctx, - receiverAddr, - tc.amount, - ) - - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - balance := tApp.BankKeeper.GetBalance(ctx, receiverAddr, params.DefaultBondDenom) - require.Equal(t, balance.Sub(initialBalance).Amount, successAmount) - } - }) - } -} diff --git a/x/orderbook/keeper/grpc_query_exposure_odds_test.go b/x/orderbook/keeper/grpc_query_exposure_odds_test.go deleted file mode 100644 index 7f6c53cc..00000000 --- a/x/orderbook/keeper/grpc_query_exposure_odds_test.go +++ /dev/null @@ -1,128 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestOrderBookExposureQuerySingle(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNOrderBookOddsExposure(k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryOrderBookExposureRequest - response *types.QueryOrderBookExposureResponse - err error - }{ - { - desc: "First", - request: &types.QueryOrderBookExposureRequest{ - OrderBookUid: msgs[0].OrderBookUID, - OddsUid: msgs[0].OddsUID, - }, - response: &types.QueryOrderBookExposureResponse{OrderBookExposure: msgs[0]}, - }, - { - desc: "Second", - request: &types.QueryOrderBookExposureRequest{ - OrderBookUid: msgs[1].OrderBookUID, - OddsUid: msgs[1].OddsUID, - }, - response: &types.QueryOrderBookExposureResponse{OrderBookExposure: msgs[1]}, - }, - { - desc: "KeyNotFound", - request: &types.QueryOrderBookExposureRequest{ - OrderBookUid: cast.ToString(100000), - OddsUid: "9ca3b818-cfc3-43cd-987b-4cffdf01cc5e", - }, - err: status.Error(codes.NotFound, "order book exposure 100000, 9ca3b818-cfc3-43cd-987b-4cffdf01cc5e not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.OrderBookExposure(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} - -func TestOrderBookExposuresQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNOrderBookOddsExposure(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryOrderBookExposuresRequest { - return &types.QueryOrderBookExposuresRequest{ - OrderBookUid: testOrderBookUID, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBookExposures(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.OrderBookExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.OrderBookExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBookExposures(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.OrderBookExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.OrderBookExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.OrderBookExposures(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.OrderBookExposures), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.OrderBookExposures(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/orderbook/keeper/grpc_query_exposure_participation_test.go b/x/orderbook/keeper/grpc_query_exposure_participation_test.go deleted file mode 100644 index 1fa6cd8f..00000000 --- a/x/orderbook/keeper/grpc_query_exposure_participation_test.go +++ /dev/null @@ -1,188 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestOrderBookParticipationExposuresQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNParticipationExposure(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryOrderBookParticipationExposuresRequest { - return &types.QueryOrderBookParticipationExposuresRequest{ - OrderBookUid: testOrderBookUID, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBookParticipationExposures(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBookParticipationExposures(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.OrderBookParticipationExposures(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.OrderBookParticipationExposures(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} - -func TestParticipationExposuresQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNParticipationExposure(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryParticipationExposuresRequest { - return &types.QueryParticipationExposuresRequest{ - OrderBookUid: testOrderBookUID, - ParticipationIndex: testParticipationIndex, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.ParticipationExposures(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.ParticipationExposures(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.ParticipationExposures(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.ParticipationExposures(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} - -func TestHistoricalParticipationExposuresQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNParticipationExposure(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryHistoricalParticipationExposuresRequest { - return &types.QueryHistoricalParticipationExposuresRequest{ - OrderBookUid: testOrderBookUID, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.HistoricalParticipationExposures(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.HistoricalParticipationExposures(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationExposures), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.HistoricalParticipationExposures(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationExposures), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.HistoricalParticipationExposures(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/orderbook/keeper/grpc_query_orderbook_test.go b/x/orderbook/keeper/grpc_query_orderbook_test.go deleted file mode 100644 index 3d5d47ae..00000000 --- a/x/orderbook/keeper/grpc_query_orderbook_test.go +++ /dev/null @@ -1,124 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestOrderBookQuerySingle(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNOrderBook(k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryOrderBookRequest - response *types.QueryOrderBookResponse - err error - }{ - { - desc: "First", - request: &types.QueryOrderBookRequest{ - OrderBookUid: msgs[0].UID, - }, - response: &types.QueryOrderBookResponse{OrderBook: msgs[0]}, - }, - { - desc: "Second", - request: &types.QueryOrderBookRequest{ - OrderBookUid: msgs[1].UID, - }, - response: &types.QueryOrderBookResponse{OrderBook: msgs[1]}, - }, - { - desc: "KeyNotFound", - request: &types.QueryOrderBookRequest{ - OrderBookUid: cast.ToString(100000), - }, - err: status.Error(codes.NotFound, "order book 100000 not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.OrderBook(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} - -func TestOrderBooksQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNOrderBook(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryOrderBooksRequest { - return &types.QueryOrderBooksRequest{ - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBooks(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Orderbooks), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Orderbooks), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBooks(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Orderbooks), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Orderbooks), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.OrderBooks(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Orderbooks), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.OrderBooks(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/orderbook/keeper/grpc_query_params_test.go b/x/orderbook/keeper/grpc_query_params_test.go deleted file mode 100644 index 3f81d520..00000000 --- a/x/orderbook/keeper/grpc_query_params_test.go +++ /dev/null @@ -1,32 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestParamsQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - response, err := k.Params(wctx, &types.QueryParamsRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryParamsResponse{Params: params}, response) -} - -func TestParamsInvalidQuery(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - _, err := k.Params(wctx, nil) - require.Error(t, err) -} diff --git a/x/orderbook/keeper/grpc_query_participation_bet_test.go b/x/orderbook/keeper/grpc_query_participation_bet_test.go deleted file mode 100644 index a5e9c228..00000000 --- a/x/orderbook/keeper/grpc_query_participation_bet_test.go +++ /dev/null @@ -1,74 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestParticipationFulfilledBetsQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNParticipationBetPair(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryParticipationFulfilledBetsRequest { - return &types.QueryParticipationFulfilledBetsRequest{ - OrderBookUid: testOrderBookUID, - ParticipationIndex: testParticipationIndex, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.ParticipationFulfilledBets(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationBets), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationBets), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.ParticipationFulfilledBets(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.ParticipationBets), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationBets), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.ParticipationFulfilledBets(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.ParticipationBets), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.ParticipationFulfilledBets(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/orderbook/keeper/grpc_query_participation_test.go b/x/orderbook/keeper/grpc_query_participation_test.go deleted file mode 100644 index 2536e6ee..00000000 --- a/x/orderbook/keeper/grpc_query_participation_test.go +++ /dev/null @@ -1,128 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestParticipationQuerySingle(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNParticipation(k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryOrderBookParticipationRequest - response *types.QueryOrderBookParticipationResponse - err error - }{ - { - desc: "First", - request: &types.QueryOrderBookParticipationRequest{ - OrderBookUid: msgs[0].OrderBookUID, - ParticipationIndex: msgs[0].Index, - }, - response: &types.QueryOrderBookParticipationResponse{OrderBookParticipation: msgs[0]}, - }, - { - desc: "Second", - request: &types.QueryOrderBookParticipationRequest{ - OrderBookUid: msgs[1].OrderBookUID, - ParticipationIndex: msgs[1].Index, - }, - response: &types.QueryOrderBookParticipationResponse{OrderBookParticipation: msgs[1]}, - }, - { - desc: "KeyNotFound", - request: &types.QueryOrderBookParticipationRequest{ - OrderBookUid: cast.ToString(100000), - ParticipationIndex: 100, - }, - err: status.Error(codes.NotFound, "order book participation 100000, 100 not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.OrderBookParticipation(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} - -func TestOrderBookParticipationsQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNParticipation(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryOrderBookParticipationsRequest { - return &types.QueryOrderBookParticipationsRequest{ - OrderBookUid: testOrderBookUID, - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBookParticipations(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.OrderBookParticipations), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.OrderBookParticipations), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.OrderBookParticipations(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.OrderBookParticipations), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.OrderBookParticipations), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.OrderBookParticipations(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.OrderBookParticipations), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.OrderBookParticipations(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest)) - }) -} diff --git a/x/orderbook/keeper/keeper_test.go b/x/orderbook/keeper/keeper_test.go deleted file mode 100644 index 8e19f0d6..00000000 --- a/x/orderbook/keeper/keeper_test.go +++ /dev/null @@ -1,32 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/orderbook/keeper" -) - -var ( - testOrderBookUID = uuid.NewString() - testParticipationIndex = uint64(1) -) - -func setupKeeper(t testing.TB) (*keeper.KeeperTest, sdk.Context) { - _, k, ctx := setupKeeperAndApp(t) - - return k, ctx -} - -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp, tApp.OrderbookKeeper, ctx.WithBlockTime(time.Now()) -} diff --git a/x/orderbook/keeper/orderbook_settle_test.go b/x/orderbook/keeper/orderbook_settle_test.go deleted file mode 100644 index f90c76fe..00000000 --- a/x/orderbook/keeper/orderbook_settle_test.go +++ /dev/null @@ -1,89 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/app/params" -) - -func TestOrderBookSettlement(t *testing.T) { - ts := newTestBetSuite(t) - participant1BalanceBeforeDeposit := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[0].DepositorAddress), - params.DefaultBondDenom).Amount - - participant2BalanceBeforeDeposit := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[1].DepositorAddress), - params.DefaultBondDenom).Amount - - participant3BalanceBeforeDeposit := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[2].DepositorAddress), - params.DefaultBondDenom).Amount - - bets, winner1PayoutProfit, winner2PayoutProfit := ts.placeBetsAndTest() - ts.settleBetsAndTest(bets, winner1PayoutProfit, winner2PayoutProfit) - - participant1BalanceAfterDeposit := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[0].DepositorAddress), - params.DefaultBondDenom).Amount - require.Equal(t, - ts.deposits[0].Amount, - participant1BalanceBeforeDeposit.Sub(participant1BalanceAfterDeposit)) - - participant2BalanceAfterDeposit := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[1].DepositorAddress), - params.DefaultBondDenom).Amount - require.Equal(t, - ts.deposits[1].Amount, - participant2BalanceBeforeDeposit.Sub(participant2BalanceAfterDeposit)) - - participant3BalanceAfterDeposit := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[2].DepositorAddress), - params.DefaultBondDenom).Amount - require.Equal(t, - ts.deposits[2].Amount, - participant3BalanceBeforeDeposit.Sub(participant3BalanceAfterDeposit)) - - err := ts.k.BatchOrderBookSettlements(ts.ctx) - require.NoError(t, err) - - participant1BalanceAfterSettlement := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[0].DepositorAddress), - params.DefaultBondDenom).Amount - require.Equal(t, - participant1BalanceBeforeDeposit. - // subtract first winner payoutprofit - Sub(winner1PayoutProfit.TruncateInt()). - // subtract participation fee - Sub(ts.participations[0].Fee). - // add loser bet amount - Add(bets[2].Amount), - participant1BalanceAfterSettlement) - - participant2BalanceAfterSettlement := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[1].DepositorAddress), - params.DefaultBondDenom).Amount - require.Equal(t, - participant2BalanceBeforeDeposit. - // subtract second winner payoutprofit - Sub(winner2PayoutProfit.TruncateInt()). - // subtract participation fee - Sub(ts.participations[1].Fee), - participant2BalanceAfterSettlement) - - // In this case, in the orderbook we have a long loop of requeue - // and the payout is a large value. - // in the real scenario when the bet placement transaction fails duo to - // orderbook failure, the hole transaction would fail and no state change will happen. - participant3BalanceAfterSettlement := ts.tApp.BankKeeper.GetBalance( - ts.ctx, sdk.MustAccAddressFromBech32(ts.deposits[2].DepositorAddress), - params.DefaultBondDenom).Amount - require.Equal(t, - participant3BalanceBeforeDeposit. - // subtract participation fee - Sub(ts.participations[2].Fee), - participant3BalanceAfterSettlement) -} diff --git a/x/orderbook/keeper/orderbook_test.go b/x/orderbook/keeper/orderbook_test.go deleted file mode 100644 index 4b93e336..00000000 --- a/x/orderbook/keeper/orderbook_test.go +++ /dev/null @@ -1,90 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" -) - -func createNOrderBook( - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.OrderBook { - items := make([]types.OrderBook, n) - - for i := range items { - items[i].OddsCount = cast.ToUint64(i + 1) - items[i].ParticipationCount = cast.ToUint64(i + 10) - items[i].Status = types.OrderBookStatus_ORDER_BOOK_STATUS_STATUS_ACTIVE - items[i].UID = uuid.NewString() - - keeper.SetOrderBook(ctx, items[i]) - } - return items -} - -func TestOrderBookGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNOrderBook(k, ctx, 10) - - rst, found := k.GetOrderBook(ctx, - uuid.NewString(), - ) - var expectedResp types.OrderBook - require.False(t, found) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - for _, item := range items { - rst, found := k.GetOrderBook(ctx, - item.UID, - ) - require.True(t, found) - require.Equal(t, - nullify.Fill(item), - nullify.Fill(rst), - ) - } -} - -func TestOrderBookGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNOrderBook(k, ctx, 10) - - orderBooks, err := k.GetAllOrderBooks(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(orderBooks), - ) -} - -func TestInitiateOrderBook(t *testing.T) { - k, ctx := setupKeeper(t) - - odds := []string{ - uuid.NewString(), - uuid.NewString(), - } - - err := k.InitiateOrderBook(ctx, testOrderBookUID, odds) - require.NoError(t, err) - - exposures, err := k.GetAllOrderBookExposures(ctx) - require.NoError(t, err) - require.Equal(t, len(odds), len(exposures)) - - err = k.InitiateOrderBook(ctx, testOrderBookUID, odds) - require.ErrorIs(t, types.ErrOrderBookAlreadyPresent, err) -} diff --git a/x/orderbook/keeper/params_test.go b/x/orderbook/keeper/params_test.go deleted file mode 100644 index 0643e31c..00000000 --- a/x/orderbook/keeper/params_test.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestGetParams(t *testing.T) { - k, ctx := setupKeeper(t) - params := types.DefaultParams() - - k.SetParams(ctx, params) - - require.EqualValues(t, params, k.GetParams(ctx)) -} diff --git a/x/orderbook/keeper/participation_bet_test.go b/x/orderbook/keeper/participation_bet_test.go deleted file mode 100644 index 10ffc224..00000000 --- a/x/orderbook/keeper/participation_bet_test.go +++ /dev/null @@ -1,44 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" -) - -func createNParticipationBetPair( - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.ParticipationBetPair { - items := make([]types.ParticipationBetPair, n) - - for i := range items { - items[i].BetUID = uuid.NewString() - items[i].OrderBookUID = testOrderBookUID - items[i].ParticipationIndex = testParticipationIndex - - keeper.SetParticipationBetPair(ctx, items[i], cast.ToUint64(i+10)) - } - return items -} - -func TestParticipationBetPairGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipationBetPair(k, ctx, 10) - - betPairs, err := k.GetAllParticipationBetPair(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(betPairs), - ) -} diff --git a/x/orderbook/keeper/participation_test.go b/x/orderbook/keeper/participation_test.go deleted file mode 100644 index bbe6f345..00000000 --- a/x/orderbook/keeper/participation_test.go +++ /dev/null @@ -1,289 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/google/uuid" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - housetypes "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" - "github.com/sge-network/sge/x/orderbook/keeper" - "github.com/sge-network/sge/x/orderbook/types" -) - -func createNParticipation( - keeper *keeper.KeeperTest, - ctx sdk.Context, - n int, -) []types.OrderBookParticipation { - items := make([]types.OrderBookParticipation, n) - - for i := range items { - items[i].Index = cast.ToUint64(i + 1) - items[i].ParticipantAddress = simapp.TestParamUsers["user1"].Address.String() - items[i].OrderBookUID = testOrderBookUID - items[i].ActualProfit = sdkmath.NewInt(100) - items[i].CurrentRoundLiquidity = sdkmath.NewInt(100) - items[i].CurrentRoundMaxLoss = sdkmath.NewInt(100) - items[i].CurrentRoundTotalBetAmount = sdkmath.NewInt(100) - items[i].Liquidity = sdkmath.NewInt(100) - items[i].Fee = sdkmath.NewInt(10) - items[i].MaxLoss = sdkmath.NewInt(100) - items[i].TotalBetAmount = sdkmath.NewInt(100) - items[i].ReimbursedFee = sdkmath.NewInt(10) - items[i].ReturnedAmount = sdkmath.NewInt(1010) - - keeper.SetOrderBookParticipation(ctx, items[i]) - } - return items -} - -func createTestMarket( - tApp *simapp.TestApp, - ctx sdk.Context, - marketUID string, - status markettypes.MarketStatus, - oddsUIDs []string, -) markettypes.Market { - market := markettypes.NewMarket(marketUID, - uuid.NewString(), - cast.ToUint64(ctx.BlockTime().Unix()), - cast.ToUint64(ctx.BlockTime().Add(5*time.Minute).Unix()), - []*markettypes.Odds{ - {UID: oddsUIDs[0], Meta: "odds1"}, - {UID: oddsUIDs[1], Meta: "odds2"}, - }, - "test market", - marketUID, - status, - ) - tApp.MarketKeeper.SetMarket(ctx, market) - return market -} - -func TestParticipationGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipation(k, ctx, 10) - - rst, found := k.GetOrderBookParticipation(ctx, - items[0].OrderBookUID, - 10000, - ) - var expectedResp types.OrderBookParticipation - require.False(t, found) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - for i, item := range items { - rst, found := k.GetOrderBookParticipation(ctx, - items[i].OrderBookUID, - uint64(i+1), - ) - require.True(t, found) - require.Equal(t, - nullify.Fill(item), - nullify.Fill(rst), - ) - } -} - -func TestParticipationsOfOrderBookGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipation(k, ctx, 10) - - rst, err := k.GetParticipationsOfOrderBook(ctx, - uuid.NewString(), - ) - var expectedResp []types.OrderBookParticipation - require.NoError(t, err) - require.Equal(t, - nullify.Fill(expectedResp), - nullify.Fill(rst), - ) - - rst, err = k.GetParticipationsOfOrderBook(ctx, - testOrderBookUID, - ) - require.NoError(t, err) - require.Equal(t, - nullify.Fill(items), - nullify.Fill(rst), - ) -} - -func TestParticipationGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNParticipation(k, ctx, 10) - - participations, err := k.GetAllOrderBookParticipations(ctx) - require.NoError(t, err) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(participations), - ) -} - -func TestInitiateOrderBookParticipationNoMarket(t *testing.T) { - k, ctx := setupKeeper(t) - - _, err := k.InitiateOrderBookParticipation(ctx, - simapp.TestParamUsers["user1"].Address, - testOrderBookUID, - sdkmath.NewInt(1000), - sdkmath.NewInt(100)) - require.ErrorIs(t, types.ErrMarketNotFound, err) -} - -func TestInitiateOrderBookParticipation(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - - oddsUIDs := []string{uuid.NewString(), uuid.NewString()} - - for _, tc := range []struct { - desc string - depositorAddr sdk.AccAddress - marketStatus markettypes.MarketStatus - - err error - }{ - { - desc: "not active market", - depositorAddr: simapp.TestParamUsers["user1"].Address, - marketStatus: markettypes.MarketStatus_MARKET_STATUS_INACTIVE, - err: types.ErrParticipationOnInactiveMarket, - }, - { - desc: "not enough fund", - depositorAddr: sdk.MustAccAddressFromBech32(sample.AccAddress()), - marketStatus: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - err: types.ErrInsufficientAccountBalance, - }, - { - desc: "success", - depositorAddr: simapp.TestParamUsers["user1"].Address, - marketStatus: markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - marketUID := uuid.NewString() - createTestMarket(tApp, ctx, marketUID, tc.marketStatus, oddsUIDs) - - err := k.InitiateOrderBook(ctx, marketUID, oddsUIDs) - require.NoError(t, err) - - participationIndex, err := k.InitiateOrderBookParticipation(ctx, - tc.depositorAddr, - marketUID, - sdkmath.NewInt(1000), - sdkmath.NewInt(100)) - - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, testParticipationIndex, participationIndex) - } - }) - } -} - -func TestWithdrawOrderBookParticipation(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - - oddsUIDs := []string{uuid.NewString(), uuid.NewString()} - fee := sdkmath.NewInt(100) - - for _, tc := range []struct { - desc string - depositorAddr sdk.AccAddress - depositAmount sdkmath.Int - withdrawMode housetypes.WithdrawalMode - withdrawAmount sdkmath.Int - - expWithdrawnAmount sdkmath.Int - err error - }{ - { - desc: "no participation", - depositorAddr: simapp.TestParamUsers["user1"].Address, - depositAmount: sdkmath.ZeroInt(), - withdrawMode: housetypes.WithdrawalMode_WITHDRAWAL_MODE_FULL, - err: types.ErrOrderBookParticipationNotFound, - }, - { - desc: "withdraw amount too large", - depositorAddr: simapp.TestParamUsers["user1"].Address, - depositAmount: sdkmath.NewInt(1000), - withdrawMode: housetypes.WithdrawalMode_WITHDRAWAL_MODE_PARTIAL, - withdrawAmount: sdkmath.NewInt(10000), - err: types.ErrWithdrawalTooLarge, - }, - { - desc: "success full", - depositorAddr: simapp.TestParamUsers["user1"].Address, - depositAmount: sdkmath.NewInt(1000), - withdrawMode: housetypes.WithdrawalMode_WITHDRAWAL_MODE_FULL, - expWithdrawnAmount: sdkmath.NewInt(1000).Sub(fee), - }, - { - desc: "success partial", - depositorAddr: simapp.TestParamUsers["user1"].Address, - depositAmount: sdkmath.NewInt(500), - withdrawMode: housetypes.WithdrawalMode_WITHDRAWAL_MODE_FULL, - expWithdrawnAmount: sdkmath.NewInt(500).Sub(fee), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - marketUID := uuid.NewString() - createTestMarket(tApp, ctx, marketUID, markettypes.MarketStatus_MARKET_STATUS_ACTIVE, oddsUIDs) - - err := k.InitiateOrderBook(ctx, marketUID, oddsUIDs) - require.NoError(t, err) - - var participationIndex uint64 - if !tc.depositAmount.IsZero() { - participationIndex, err = k.InitiateOrderBookParticipation(ctx, - tc.depositorAddr, - marketUID, - tc.depositAmount, - sdkmath.NewInt(100)) - require.NoError(t, err) - } - - withdrawnAmount, err := k.CalcWithdrawalAmount(ctx, - tc.depositorAddr.String(), - marketUID, - participationIndex, - tc.withdrawMode, - sdkmath.ZeroInt(), - tc.depositAmount, - ) - - if err == nil { - err = k.WithdrawOrderBookParticipation(ctx, - marketUID, - participationIndex, - withdrawnAmount, - ) - } - - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, tc.expWithdrawnAmount, withdrawnAmount) - } - }) - } -} diff --git a/x/orderbook/keeper/stats_test.go b/x/orderbook/keeper/stats_test.go deleted file mode 100644 index f2f0631f..00000000 --- a/x/orderbook/keeper/stats_test.go +++ /dev/null @@ -1,26 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/sge-network/sge/testutil/nullify" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestStatsGet(t *testing.T) { - k, ctx := setupKeeper(t) - - stats := types.OrderBookStats{ - ResolvedUnsettled: []string{uuid.NewString()}, - } - k.SetOrderBookStats(ctx, stats) - - rst := k.GetOrderBookStats(ctx) - require.Equal(t, - nullify.Fill(stats), - nullify.Fill(rst), - ) -} diff --git a/x/orderbook/simulation/decoder_test.go b/x/orderbook/simulation/decoder_test.go deleted file mode 100644 index 8cbf082e..00000000 --- a/x/orderbook/simulation/decoder_test.go +++ /dev/null @@ -1,129 +0,0 @@ -package simulation_test - -import ( - "fmt" - "testing" - - sdkmath "cosmossdk.io/math" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - "github.com/cosmos/cosmos-sdk/types/kv" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/orderbook/simulation" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestDecodeStore(t *testing.T) { - cdc := app.MakeEncodingConfig().Marshaler - dec := simulation.NewDecodeStore(cdc) - - orderBookUID := uuid.NewString() - orderBook := types.OrderBook{ - UID: orderBookUID, - ParticipationCount: 1, - OddsCount: 1, - Status: types.OrderBookStatus_ORDER_BOOK_STATUS_STATUS_ACTIVE, - } - - participation := types.OrderBookParticipation{ - Index: 1, - OrderBookUID: orderBookUID, - ParticipantAddress: sample.AccAddress(), - Liquidity: sdkmath.NewInt(100), - CurrentRoundLiquidity: sdkmath.NewInt(50), - ExposuresNotFilled: 1, - TotalBetAmount: sdkmath.NewInt(10), - CurrentRoundTotalBetAmount: sdkmath.NewInt(10), - MaxLoss: sdkmath.NewInt(10), - CurrentRoundMaxLoss: sdkmath.NewInt(10), - CurrentRoundMaxLossOddsUID: uuid.NewString(), - ActualProfit: sdkmath.NewInt(20), - IsSettled: false, - } - - oddsExposures := types.OrderBookOddsExposure{ - OrderBookUID: orderBookUID, - OddsUID: uuid.NewString(), - FulfillmentQueue: []uint64{1}, - } - - participationExposures := types.ParticipationExposure{ - OrderBookUID: orderBookUID, - OddsUID: uuid.NewString(), - ParticipationIndex: 1, - Exposure: sdkmath.NewInt(10), - BetAmount: sdkmath.NewInt(10), - IsFulfilled: false, - Round: 1, - } - - orderBookStats := types.OrderBookStats{ - ResolvedUnsettled: []string{orderBookUID}, - } - - betPair := types.ParticipationBetPair{ - OrderBookUID: orderBookUID, - ParticipationIndex: 1, - BetUID: uuid.NewString(), - } - - kvPairs := kv.Pairs{ - Pairs: []kv.Pair{ - {Key: types.OrderBookKeyPrefix, Value: cdc.MustMarshal(&orderBook)}, - {Key: types.OrderBookParticipationKeyPrefix, Value: cdc.MustMarshal(&participation)}, - {Key: types.OrderBookOddsExposureKeyPrefix, Value: cdc.MustMarshal(&oddsExposures)}, - { - Key: types.ParticipationExposureKeyPrefix, - Value: cdc.MustMarshal(&participationExposures), - }, - { - Key: types.ParticipationExposureByIndexKeyPrefix, - Value: cdc.MustMarshal(&participationExposures), - }, - { - Key: types.HistoricalParticipationExposureKeyPrefix, - Value: cdc.MustMarshal(&participationExposures), - }, - {Key: types.OrderBookStatsKeyPrefix, Value: cdc.MustMarshal(&orderBookStats)}, - {Key: types.ParticipationBetPairKeyPrefix, Value: cdc.MustMarshal(&betPair)}, - {Key: []byte{0x99}, Value: []byte{0x99}}, - }, - } - tests := []struct { - name string - expectedLog string - }{ - {"order_book", fmt.Sprintf("%v\n%v", orderBook, orderBook)}, - {"order_book_participation", fmt.Sprintf("%v\n%v", participation, participation)}, - {"order_book_odds_exposure", fmt.Sprintf("%v\n%v", oddsExposures, oddsExposures)}, - { - "order_book_participation_exposure", - fmt.Sprintf("%v\n%v", participationExposures, participationExposures), - }, - { - "order_book_participation_exposure_by_index", - fmt.Sprintf("%v\n%v", participationExposures, participationExposures), - }, - { - "historical_order_book_participation_exposure", - fmt.Sprintf("%v\n%v", participationExposures, participationExposures), - }, - {"order_book_stats", fmt.Sprintf("%v\n%v", orderBookStats, orderBookStats)}, - {"order_book_participation_bet_pair", fmt.Sprintf("%v\n%v", betPair, betPair)}, - {"other", ""}, - } - - for i, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - switch i { - case len(tests) - 1: - require.Panics(t, func() { dec(kvPairs.Pairs[i], kvPairs.Pairs[i]) }, tt.name) - default: - require.Equal(t, tt.expectedLog, dec(kvPairs.Pairs[i], kvPairs.Pairs[i]), tt.name) - } - }) - } -} diff --git a/x/orderbook/simulation/genesis_test.go b/x/orderbook/simulation/genesis_test.go deleted file mode 100644 index 9259057d..00000000 --- a/x/orderbook/simulation/genesis_test.go +++ /dev/null @@ -1,78 +0,0 @@ -package simulation_test - -import ( - "encoding/json" - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/codec" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/types/module" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - - "github.com/sge-network/sge/x/orderbook/simulation" - "github.com/sge-network/sge/x/orderbook/types" -) - -// TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. -// Abnormal scenarios are not tested here. -func TestRandomizedGenState(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - simState := module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - NumBonded: 3, - Accounts: simtypes.RandomAccounts(r, 3), - InitialStake: sdkmath.NewInt(1000), - GenState: make(map[string]json.RawMessage), - } - - simulation.RandomizedGenState(&simState) - - var srGenesis types.GenesisState - simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &srGenesis) - - require.Equal(t, uint64(100), srGenesis.Params.BatchSettlementCount) - require.Equal(t, uint64(100), srGenesis.Params.MaxOrderBookParticipations) - require.Equal(t, uint64(1000), srGenesis.Params.RequeueThreshold) -} - -// TestRandomizedGenState tests abnormal scenarios of applying RandomizedGenState. -func TestRandomizedGenState1(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - // all these tests will panic - tests := []struct { - simState module.SimulationState - panicMsg string - }{ - { // panic => reason: incomplete initialization of the simState - module.SimulationState{}, "invalid memory address or nil pointer dereference"}, - { // panic => reason: incomplete initialization of the simState - module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - }, "assignment to entry in nil map"}, - } - - for _, tt := range tests { - simTest := tt.simState - require.Panicsf(t, func() { simulation.RandomizedGenState(&simTest) }, tt.panicMsg) - } -} diff --git a/x/orderbook/simulation/params_test.go b/x/orderbook/simulation/params_test.go deleted file mode 100644 index 595509eb..00000000 --- a/x/orderbook/simulation/params_test.go +++ /dev/null @@ -1,40 +0,0 @@ -package simulation_test - -import ( - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/orderbook/simulation" -) - -func TestParamChanges(t *testing.T) { - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - expected := []struct { - composedKey string - key string - subspace string - }{ - {"orderbook/BatchSettlementCount", "BatchSettlementCount", "orderbook"}, - { - "orderbook/MaxOrderBookParticipations", - "MaxOrderBookParticipations", - "orderbook", - }, - {"orderbook/RequeueThreshold", "RequeueThreshold", "orderbook"}, - } - - paramChanges := simulation.ParamChanges(r) - require.Len(t, paramChanges, 3) - - for i, p := range paramChanges { - require.Equal(t, expected[i].composedKey, p.ComposedKey()) - require.Equal(t, expected[i].key, p.Key()) - require.Equal(t, expected[i].subspace, p.Subspace()) - } -} diff --git a/x/orderbook/simulation/proposals_test.go b/x/orderbook/simulation/proposals_test.go deleted file mode 100644 index 9f73bdc5..00000000 --- a/x/orderbook/simulation/proposals_test.go +++ /dev/null @@ -1,46 +0,0 @@ -package simulation_test - -import ( - "fmt" - "math/rand" - "testing" - - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/address" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/orderbook/simulation" - "github.com/sge-network/sge/x/orderbook/types" -) - -func TestProposalMsgs(t *testing.T) { - // initialize parameters - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - ctx := sdk.NewContext(nil, tmproto.Header{}, true, nil) - accounts := simtypes.RandomAccounts(r, 3) - - // execute ProposalMsgs function - weightedProposalMsgs := simulation.ProposalMsgs() - require.Equal(t, len(weightedProposalMsgs), 1) - - w0 := weightedProposalMsgs[0] - - // tests w0 interface: - require.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) - require.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) - - msg := w0.MsgSimulatorFn()(r, ctx, accounts) - msgUpdateParams, ok := msg.(*types.MsgUpdateParams) - require.True(t, ok) - - fmt.Println(msgUpdateParams) - require.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) - require.Equal(t, uint64(2540), msgUpdateParams.Params.BatchSettlementCount) - require.Equal(t, uint64(456), msgUpdateParams.Params.MaxOrderBookParticipations) - require.Equal(t, uint64(300), msgUpdateParams.Params.RequeueThreshold) -} diff --git a/x/orderbook/types/genesis_test.go b/x/orderbook/types/genesis_test.go deleted file mode 100644 index 93fc3e4a..00000000 --- a/x/orderbook/types/genesis_test.go +++ /dev/null @@ -1,143 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/orderbook/types" -) - -const ( - testAddress = "cosmos1s4ycalgh3gjemd4hmqcvcgmnf647rnd0tpg2w9" -) - -func TestGenesisState_Validate(t *testing.T) { - marketUID := uuid.NewString() - oddsUID := uuid.NewString() - validState := types.GenesisState{ - OrderBookList: []types.OrderBook{ - { - UID: marketUID, - ParticipationCount: 1, - OddsCount: 1, - Status: types.OrderBookStatus_ORDER_BOOK_STATUS_STATUS_ACTIVE, - }, - }, - OrderBookExposureList: []types.OrderBookOddsExposure{ - { - OrderBookUID: marketUID, - OddsUID: oddsUID, - FulfillmentQueue: []uint64{}, - }, - }, - OrderBookParticipationList: []types.OrderBookParticipation{ - { - OrderBookUID: marketUID, - Index: 1, - ParticipantAddress: testAddress, - }, - }, - ParticipationExposureList: []types.ParticipationExposure{ - { - OrderBookUID: marketUID, - OddsUID: oddsUID, - ParticipationIndex: 1, - }, - }, - ParticipationExposureByIndexList: []types.ParticipationExposure{ - { - OrderBookUID: marketUID, - OddsUID: oddsUID, - ParticipationIndex: 1, - }, - }, - HistoricalParticipationExposureList: []types.ParticipationExposure{ - { - OrderBookUID: marketUID, - OddsUID: oddsUID, - ParticipationIndex: 1, - }, - }, - ParticipationBetPairExposureList: []types.ParticipationBetPair{ - { - OrderBookUID: marketUID, - ParticipationIndex: 1, - }, - }, - Stats: types.OrderBookStats{ - ResolvedUnsettled: []string{marketUID}, - }, - Params: types.DefaultParams(), - } - - invalidParticipantAddress := validState - invalidParticipantAddress.OrderBookParticipationList = []types.OrderBookParticipation{ - validState.OrderBookParticipationList[0], - } - invalidParticipantAddress.OrderBookParticipationList[0].ParticipantAddress = "wrong" - - notEqualOrderBookCount := validState - notEqualOrderBookCount.OrderBookList = []types.OrderBook{} - - notEqualOrderBookExposureCount := validState - notEqualOrderBookExposureCount.OrderBookExposureList = []types.OrderBookOddsExposure{} - - notEqualParticipationExposureCount := validState - notEqualParticipationExposureCount.ParticipationExposureList = []types.ParticipationExposure{} - - notEqualParticipationExposureIndexCount := validState - notEqualParticipationExposureIndexCount.ParticipationExposureByIndexList = []types.ParticipationExposure{} - - for _, tc := range []struct { - desc string - genState *types.GenesisState - valid bool - }{ - { - desc: "default is valid", - genState: types.DefaultGenesis(), - valid: true, - }, - { - desc: "valid genesis state", - genState: &validState, - valid: true, - }, - { - desc: "invalid participant address", - genState: &invalidParticipantAddress, - valid: false, - }, - { - desc: "not equal book", - genState: ¬EqualOrderBookCount, - valid: false, - }, - { - desc: "not equal book exposure", - genState: ¬EqualOrderBookExposureCount, - valid: false, - }, - { - desc: "not equal participation exposure", - genState: ¬EqualParticipationExposureCount, - valid: false, - }, - { - desc: "not equal participation exposure index", - genState: ¬EqualParticipationExposureIndexCount, - valid: false, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - err := tc.genState.Validate() - if tc.valid { - require.NoError(t, err) - } else { - require.Error(t, err) - } - }) - } -} diff --git a/x/ovm/client/cli/query_params_test.go b/x/ovm/client/cli/query_params_test.go deleted file mode 100644 index 6f15d0cf..00000000 --- a/x/ovm/client/cli/query_params_test.go +++ /dev/null @@ -1,53 +0,0 @@ -package cli_test - -import ( - "encoding/json" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - "github.com/sge-network/sge/testutil/network" - - "github.com/sge-network/sge/x/ovm/client/cli" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestQueryParams(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdQueryParams(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - var params types.QueryParamsResponse - err = json.Unmarshal(res.Bytes(), ¶ms) - require.NoError(t, err) - - defaultParams := types.DefaultParams() - require.Equal(t, types.QueryParamsResponse{ - Params: defaultParams, - }, params) - }) - } -} diff --git a/x/ovm/client/cli/query_proposal_test.go b/x/ovm/client/cli/query_proposal_test.go deleted file mode 100644 index fc1579c6..00000000 --- a/x/ovm/client/cli/query_proposal_test.go +++ /dev/null @@ -1,111 +0,0 @@ -package cli_test - -import ( - "fmt" - "strconv" - "testing" - "time" - - tmcli "github.com/cometbft/cometbft/libs/cli" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/ovm/client/cli" - "github.com/sge-network/sge/x/ovm/types" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" -) - -// Prevent strconv unused error -var _ = strconv.IntSize - -func networkWithPubkeysChangeProposalObjects( - t *testing.T, - n int, -) (*network.Network, []types.PublicKeysChangeProposal) { - t.Helper() - cfg := network.DefaultConfig() - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - for i := 0; i < n; i++ { - proposal := types.PublicKeysChangeProposal{ - Id: uint64(i), - Modifications: types.PubkeysChangeProposalPayload{ - PublicKeys: []string{}, - LeaderIndex: 0, - }, - Votes: []*types.Vote{}, - StartTS: time.Now().Unix(), - } - nullify.Fill(&proposal) - state.PubkeysChangeProposals = append(state.PubkeysChangeProposals, proposal) - } - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - return network.New(t, cfg), state.PubkeysChangeProposals -} - -func TestCmdQueryPubkeysChangeProposal(t *testing.T) { - net, objs := networkWithPubkeysChangeProposalObjects(t, 5) - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - - t.Run("ShowActiveProposal", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - for _, tc := range []struct { - desc string - id string - status types.ProposalStatus - - args []string - err error - obj types.PublicKeysChangeProposal - }{ - { - desc: "found", - id: cast.ToString(objs[0].Id), - status: types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - - args: common, - obj: objs[0], - }, - { - desc: "not found", - id: cast.ToString(100000), - status: types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - - args: common, - err: status.Error(codes.NotFound, "not found"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - cast.ToString(cast.ToInt32(tc.status)), - tc.id, - } - args = append(args, tc.args...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdPubkeysChangeProposal(), args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.ErrorIs(t, stat.Err(), tc.err) - } else { - require.NoError(t, err) - var resp types.QueryPublicKeysChangeProposalResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.NotNil(t, resp.Proposal) - require.Equal(t, - nullify.Fill(&tc.obj), - nullify.Fill(&resp.Proposal), - ) - } - }) - } - }) -} diff --git a/x/ovm/client/cli/query_pub_keys_test.go b/x/ovm/client/cli/query_pub_keys_test.go deleted file mode 100644 index 366b4429..00000000 --- a/x/ovm/client/cli/query_pub_keys_test.go +++ /dev/null @@ -1,73 +0,0 @@ -package cli_test - -import ( - "fmt" - "testing" - - tmcli "github.com/cometbft/cometbft/libs/cli" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/testutil/simapp" - - "github.com/sge-network/sge/x/ovm/client/cli" - "github.com/sge-network/sge/x/ovm/types" - "github.com/stretchr/testify/require" - "google.golang.org/grpc/status" -) - -func networkWithPublicKeys(t *testing.T) (*network.Network, *types.KeyVault) { - t.Helper() - cfg := network.DefaultConfig() - state := types.GenesisState{} - require.NoError(t, cfg.Codec.UnmarshalJSON(cfg.GenesisState[types.ModuleName], &state)) - - pubkeys := simapp.GenerateOvmPublicKeys(types.MinPubKeysCount) - - state.KeyVault = types.KeyVault{ - PublicKeys: pubkeys, - } - - buf, err := cfg.Codec.MarshalJSON(&state) - require.NoError(t, err) - cfg.GenesisState[types.ModuleName] = buf - - return network.New(t, cfg), &state.KeyVault -} - -func TestCmdPubKeysList(t *testing.T) { - net, _ := networkWithPublicKeys(t) - - t.Run("PubKeysList", func(t *testing.T) { - ctx := net.Validators[0].ClientCtx - common := []string{ - fmt.Sprintf("--%s=json", tmcli.OutputFlag), - } - TestCases := []struct { - desc string - args []string - err error - }{ - { - desc: "success", - args: common, - err: nil, - }, - } - for _, tc := range TestCases { - t.Run(tc.desc, func(t *testing.T) { - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdPubKeysList(), tc.args) - if tc.err != nil { - stat, ok := status.FromError(tc.err) - require.True(t, ok) - require.Error(t, stat.Err(), "") - } else { - require.NoError(t, err) - var resp types.QueryPubKeysResponse - require.NoError(t, net.Config.Codec.UnmarshalJSON(out.Bytes(), &resp)) - require.True(t, len(resp.List) > 0) - t.Log(resp.List) - } - }) - } - }) -} diff --git a/x/ovm/client/cli/query_test.go b/x/ovm/client/cli/query_test.go deleted file mode 100644 index f5bf1f57..00000000 --- a/x/ovm/client/cli/query_test.go +++ /dev/null @@ -1,48 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/ovm/client/cli" -) - -func TestGetQueryCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetQueryCmd(""), args) - if tc.err != nil { - require.Error(t, err, "") - } else { - require.NoError(t, err) - } - - require.True( - t, - strings.HasPrefix(string(res.Bytes()), "Querying commands for the ovm module") == true, - ) - }) - } -} diff --git a/x/ovm/client/cli/tx_pubkeys_proposal_test.go b/x/ovm/client/cli/tx_pubkeys_proposal_test.go deleted file mode 100644 index 8754538c..00000000 --- a/x/ovm/client/cli/tx_pubkeys_proposal_test.go +++ /dev/null @@ -1,92 +0,0 @@ -package cli_test - -import ( - "crypto/ed25519" - "crypto/rand" - "crypto/x509" - "fmt" - "testing" - "time" - - "github.com/golang-jwt/jwt/v4" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/client/flags" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/ovm/client/cli" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestCmdChangePubkeysListProposal(t *testing.T) { - net, _ := networkWithPublicKeys(t) - val := net.Validators[0] - ctx := val.ClientCtx - - commonArgs := []string{ - fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), - fmt.Sprintf("--%s=true", flags.FlagSkipConfirmation), - fmt.Sprintf("--%s=%s", flags.FlagBroadcastMode, flags.BroadcastSync), - fmt.Sprintf( - "--%s=%s", - flags.FlagFees, - sdk.NewCoins(sdk.NewCoin(net.Config.BondDenom, sdkmath.NewInt(10))).String(), - ), - } - - var pubs []string - for i := 0; i < types.MinPubKeysCount; i++ { - pub, _, err := ed25519.GenerateKey(rand.Reader) - require.NoError(t, err) - bs, err := x509.MarshalPKIXPublicKey(pub) - require.NoError(t, err) - pubs = append(pubs, string(utils.NewPubKeyMemory(bs))) - } - - t1 := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": 0, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedT1, err := t1.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - TestCases := []struct { - desc string - ticket string - - err error - code uint32 - }{ - { - desc: "success", - ticket: singedT1, - err: nil, - code: 0, - }, - } - for _, tc := range TestCases { - t.Run(tc.desc, func(t *testing.T) { - args := []string{ - tc.ticket, - } - args = append(args, commonArgs...) - out, err := clitestutil.ExecTestCLICmd(ctx, cli.CmdChangePubkeysListProposal(), args) - if tc.err != nil { - require.Error(t, err, "") - } else { - require.NoError(t, err) - - var resp sdk.TxResponse - - require.NoError(t, ctx.Codec.UnmarshalJSON(out.Bytes(), &resp)) - fmt.Println(resp) - require.True(t, resp.Code == tc.code) - } - }) - } -} diff --git a/x/ovm/client/cli/tx_test.go b/x/ovm/client/cli/tx_test.go deleted file mode 100644 index 4bc5075a..00000000 --- a/x/ovm/client/cli/tx_test.go +++ /dev/null @@ -1,48 +0,0 @@ -package cli_test - -import ( - "strings" - "testing" - - "github.com/stretchr/testify/require" - - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - - "github.com/sge-network/sge/testutil/network" - "github.com/sge-network/sge/x/ovm/client/cli" -) - -func TestGetTxCmd(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, tc.args...) - res, err := clitestutil.ExecTestCLICmd(ctx, cli.GetTxCmd(), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - - require.True( - t, - strings.HasPrefix(string(res.Bytes()), "ovm transactions subcommands") == true, - ) - }) - } -} diff --git a/x/ovm/genesis_test.go b/x/ovm/genesis_test.go deleted file mode 100644 index 0613f0bc..00000000 --- a/x/ovm/genesis_test.go +++ /dev/null @@ -1,32 +0,0 @@ -package ovm_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - - "github.com/sge-network/sge/x/ovm" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestGenesis(t *testing.T) { - genesisState := types.GenesisState{ - Params: types.DefaultParams(), - KeyVault: types.KeyVault{ - PublicKeys: []string{"Key1"}, - }, - } - - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - ovm.InitGenesis(ctx, *tApp.OVMKeeper, genesisState) - got := ovm.ExportGenesis(ctx, *tApp.OVMKeeper) - require.NotNil(t, got) - - nullify.Fill(&genesisState) - nullify.Fill(got) -} diff --git a/x/ovm/handler.go b/x/ovm/handler.go deleted file mode 100644 index 921629db..00000000 --- a/x/ovm/handler.go +++ /dev/null @@ -1,37 +0,0 @@ -package ovm - -import ( - "fmt" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/x/ovm/keeper" - "github.com/sge-network/sge/x/ovm/types" -) - -// NewHandler initialize a new sdk.handler instance for registered messages -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - - switch msg := msg.(type) { - case *types.MsgSubmitPubkeysChangeProposalRequest: - res, err := msgServer.SubmitPubkeysChangeProposal(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgVotePubkeysChangeRequest: - res, err := msgServer.VotePubkeysChange(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdateParams: - res, err := msgServer.UpdateParams(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrtypes.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/ovm/keeper/grpc_query.go b/x/ovm/keeper/grpc_query.go deleted file mode 100644 index 962e8dfa..00000000 --- a/x/ovm/keeper/grpc_query.go +++ /dev/null @@ -1,7 +0,0 @@ -package keeper - -import ( - "github.com/sge-network/sge/x/ovm/types" -) - -var _ types.QueryServer = Keeper{} diff --git a/x/ovm/keeper/grpc_query_params_test.go b/x/ovm/keeper/grpc_query_params_test.go deleted file mode 100644 index 10b603dd..00000000 --- a/x/ovm/keeper/grpc_query_params_test.go +++ /dev/null @@ -1,29 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/ovm/types" -) - -func TestParamsQuery(t *testing.T) { - k, ctx := setupKeeper(t) - - wctx := sdk.WrapSDKContext(ctx) - params := types.DefaultParams() - k.SetParams(ctx, params) - - t.Run("valid", func(t *testing.T) { - response, err := k.Params(wctx, &types.QueryParamsRequest{}) - require.NoError(t, err) - require.Equal(t, &types.QueryParamsResponse{Params: params}, response) - }) - t.Run("error", func(t *testing.T) { - _, err := k.Params(wctx, nil) - require.Error(t, err) - }) -} diff --git a/x/ovm/keeper/grpc_query_pubkeys_proposal_test.go b/x/ovm/keeper/grpc_query_pubkeys_proposal_test.go deleted file mode 100644 index efc67504..00000000 --- a/x/ovm/keeper/grpc_query_pubkeys_proposal_test.go +++ /dev/null @@ -1,81 +0,0 @@ -package keeper_test - -import ( - "strconv" - "testing" - - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/consts" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/ovm/types" -) - -// Prevent strconv unused error -var _ = strconv.IntSize - -func TestActivePubkeysChangeProposalQuerySingle(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNActiveProposal(k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryPublicKeysChangeProposalRequest - response *types.QueryPublicKeysChangeProposalResponse - err error - }{ - { - desc: "First", - request: &types.QueryPublicKeysChangeProposalRequest{ - Id: msgs[0].Id, - Status: types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - }, - response: &types.QueryPublicKeysChangeProposalResponse{Proposal: msgs[0]}, - }, - { - desc: "Second", - request: &types.QueryPublicKeysChangeProposalRequest{ - Id: msgs[1].Id, - Status: types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - }, - response: &types.QueryPublicKeysChangeProposalResponse{Proposal: msgs[1]}, - }, - { - desc: "ActiveNotFound", - request: &types.QueryPublicKeysChangeProposalRequest{ - Id: msgs[1].Id, - Status: types.ProposalStatus_PROPOSAL_STATUS_FINISHED, - }, - err: status.Error(codes.NotFound, "not found"), - }, - { - desc: "KeyNotFound", - request: &types.QueryPublicKeysChangeProposalRequest{ - Id: 100000, - Status: types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - }, - err: status.Error(codes.NotFound, "not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, consts.ErrTextInvalidRequest), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.PublicKeysChangeProposal(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} diff --git a/x/ovm/keeper/grpc_query_pubkeys_test.go b/x/ovm/keeper/grpc_query_pubkeys_test.go deleted file mode 100644 index 9fe20480..00000000 --- a/x/ovm/keeper/grpc_query_pubkeys_test.go +++ /dev/null @@ -1,27 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/x/ovm/types" -) - -func TestPubKeysList(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - - t.Run("valid", func(t *testing.T) { - resp, err := k.PubKeys(wctx, &types.QueryPubKeysRequest{}) - require.Nil(t, err) - _ = resp - }) - t.Run("error", func(t *testing.T) { - resp, err := k.PubKeys(wctx, nil) - require.Error(t, err) - _ = resp - }) -} diff --git a/x/ovm/keeper/keeper_test.go b/x/ovm/keeper/keeper_test.go deleted file mode 100644 index 91097a7a..00000000 --- a/x/ovm/keeper/keeper_test.go +++ /dev/null @@ -1,31 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/ovm/keeper" -) - -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp, tApp.OVMKeeper, ctx -} - -func setupKeeper(t testing.TB) (*keeper.KeeperTest, sdk.Context) { - _, k, ctx := setupKeeperAndApp(t) - - return k, ctx -} - -func TestLogger(t *testing.T) { - k, ctx := setupKeeper(t) - logger := k.Logger(ctx) - require.True(t, logger != nil) -} diff --git a/x/ovm/keeper/key_vault_test.go b/x/ovm/keeper/key_vault_test.go deleted file mode 100644 index cf9bd397..00000000 --- a/x/ovm/keeper/key_vault_test.go +++ /dev/null @@ -1,60 +0,0 @@ -package keeper_test - -import ( - "crypto/ed25519" - "crypto/rand" - "crypto/x509" - "testing" - "time" - - "github.com/golang-jwt/jwt/v4" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestQueryPublicKeys(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - creator := simapp.TestParamUsers["user1"] - var pubs []string - for i := 0; i < types.MaxPubKeysCount; i++ { - pub, _, err := ed25519.GenerateKey(rand.Reader) - require.NoError(t, err) - bs, err := x509.MarshalPKIXPublicKey(pub) - require.NoError(t, err) - pubs = append(pubs, string(utils.NewPubKeyMemory(bs))) - } - - T1 := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": 0, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedT1, err := T1.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - resp, err := msgk.SubmitPubkeysChangeProposal(wctx, &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: singedT1, - }) - require.Nil(t, err) - require.Equal(t, true, resp.Success) - - l, found := k.GetKeyVault(ctx) - require.True(t, found) - require.Greater(t, len(l.PublicKeys), 0) -} - -func TestSetKeys(t *testing.T) { - k, ctx := setupKeeper(t) - t.Run("valid", func(_ *testing.T) { - k.SetKeyVault(ctx, types.KeyVault{ - PublicKeys: []string{ - "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA+9wlxVu9a8lzUO2kcFLu\nUBIuV0+DpUdgEmsyQXr4y65sPSx/XjbK3GSZS1fB4irYPPG8EPHa6Z9KwWJLrTBr\nHayQcUBV5GQPf7nDktCkljYEBRmJZ+x3tlTf2kyKf3JMPAYgSFcs792dMpx8EiuE\n683QzUyeCutmiSWj1e7/IR9tjD4X/XFGkLES6wtqpQpOsL10z3hZllQEqZif8pDZ\nZcDvF97dg0l+JIWW3jBINL/UzuBRmdtDMuS1d57bpaMNb7L9HLUDBiwlZTGhs1+v\n9eTMY6IEdIzQ6M1KTFDeLYdnpGWP0ttBpt7SesLNpsKStbZ7QkbNtzlkTN8eJ6qu\nJQIDAQAB\n-----END PUBLIC KEY-----", - }, - }) - }) -} diff --git a/x/ovm/keeper/msg_server_params.go b/x/ovm/keeper/msg_server_params.go deleted file mode 100644 index e417e821..00000000 --- a/x/ovm/keeper/msg_server_params.go +++ /dev/null @@ -1,27 +0,0 @@ -package keeper - -import ( - "context" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - - "github.com/sge-network/sge/x/ovm/types" -) - -func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { - ctx := sdk.UnwrapSDKContext(goCtx) - - if k.GetAuthority() != req.Authority { - return nil, sdkerrors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.GetAuthority(), req.Authority) - } - - if err := req.Params.Validate(); err != nil { - return nil, err - } - - k.SetParams(ctx, req.Params) - - return &types.MsgUpdateParamsResponse{}, nil -} diff --git a/x/ovm/keeper/msg_server_pubkeys_proposal_test.go b/x/ovm/keeper/msg_server_pubkeys_proposal_test.go deleted file mode 100644 index a9fd47a0..00000000 --- a/x/ovm/keeper/msg_server_pubkeys_proposal_test.go +++ /dev/null @@ -1,184 +0,0 @@ -package keeper_test - -import ( - "crypto/ed25519" - "crypto/rand" - "crypto/x509" - "testing" - "time" - - "github.com/golang-jwt/jwt/v4" - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/ovm/types" -) - -func createNTestPubKeys(n int) ([]string, error) { - var items []string - - for i := 0; i < n; i++ { - pub1, _, err := ed25519.GenerateKey(rand.Reader) - if err != nil { - return nil, err - } - - bs, err := x509.MarshalPKIXPublicKey(pub1) - if err != nil { - return nil, err - } - - pb := string(utils.NewPubKeyMemory(bs)) - items = append(items, pb) - } - - return items, nil -} - -func TestChangePubkeysListProposal(t *testing.T) { - t.Run("success", func(t *testing.T) { - msgk, _, wctx := setupMsgServer(t) - creator := simapp.TestParamUsers["user1"] - pubs, err := createNTestPubKeys(types.MinPubKeysCount) - require.NoError(t, err) - - T1 := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": 0, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedT1, err := T1.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - resp, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: singedT1, - }, - ) - require.NoError(t, err) - require.Equal(t, true, resp.Success) - }) - - t.Run("few pubkeys", func(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - createNActiveProposal(k, ctx, 1) - creator := simapp.TestParamUsers["user1"] - pubs, err := createNTestPubKeys(types.MinPubKeysCount - 1) - require.NoError(t, err) - - proposalTicket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": 0, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedProposalTicket, err := proposalTicket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - resp, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: singedProposalTicket, - }, - ) - require.ErrorIs(t, sdkerrtypes.ErrInvalidRequest, err) - require.Nil(t, resp) - }) - - t.Run("lots of pubkeys", func(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - createNActiveProposal(k, ctx, 1) - creator := simapp.TestParamUsers["user1"] - pubs, err := createNTestPubKeys(types.MaxPubKeysCount + 1) - require.NoError(t, err) - - proposalTicket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": 0, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedProposalTicket, err := proposalTicket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - resp, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: singedProposalTicket, - }, - ) - require.ErrorIs(t, sdkerrtypes.ErrInvalidRequest, err) - require.Nil(t, resp) - }) - - t.Run("wrong index", func(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - createNActiveProposal(k, ctx, 1) - creator := simapp.TestParamUsers["user1"] - pubs, err := createNTestPubKeys(types.MinPubKeysCount) - require.NoError(t, err) - - proposalTicket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": types.MaxPubKeysCount, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedProposalTicket, err := proposalTicket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - resp, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: singedProposalTicket, - }, - ) - require.ErrorIs(t, sdkerrtypes.ErrInvalidRequest, err) - require.Nil(t, resp) - }) - - t.Run("fails", func(t *testing.T) { - msgk, _, wctx := setupMsgServer(t) - - creator := simapp.TestParamUsers["user1"] - t.Run("public keys change proposal", func(t *testing.T) { - _, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJBZGRzIjpbIi0tLS0tQkVHSU4gUFVCTElDIEtFWS0tLS0tXG5NRnd3RFFZSktvWklodmNOQVFFQkJRQURTd0F3U0FKQkFLcTU1aTg4bitDVlBTbWgwV0YrMVZHQ05nYlczMWVCXG41NmJ0SEd5WVM3QnZoMExLS2x2OTY3c3Y4WU1KTUo0eEJvc1pHa081V3lGejhGNFBEc2N5bkRzQ0F3RUFBUT09XG4tLS0tLUVORCBQVUJMSUMgS0VZLS0tLS0iXSwiZXhwIjoxNzU3NzAwMjEyfQ.PDO2Ha7Hj4SOQIbrTJeSUiKBvTnicm60VVZryoVFgfu1hCAgWqdFEYJ2aSwYU9b_O76f5AR1JDCA0roo4jJI0EbJricJLOIuPHol6Fp99rZYi4QRFt4J4ePegwMxpg-VqVqoh8ItP9GknYsOnTrtqYYCFDFjINPQ6BrUcOeEiQr5WkWOHnE_H6NfuPPOwno-pPf5lr94IIHPkWOY8VkXcFBREjJkMsUIgZmu7euI6Nim8beuReb-O3sYxtg8dCKv9vt9Bti4lAKVvESCwdcx3Yk7ARmbJvZdk4-_tKUqqJCuuDzeudyoT7Og3U1lqbzHkQyx31t8HrxRMBB19jaUTg", - }, - ) - require.Error(t, err) - }) - t.Run("invalid ticekt", func(t *testing.T) { - _, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: "Invalid.Ticket", - }, - ) - require.Error(t, err) - }) - - t.Run("unmarshal ticket", func(t *testing.T) { - _, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJBZGRzIjoiSGVsbG8iLCJleHAiOjE3NTc3MDAyMTJ9.cf9X_5pvR7Bd8Ze37u2pfeUPignG-Tg-JQayEbGUtKJcXY3ilmi4rMKaGkX44jJWbDsTlBH7zDw8Bmlr1DqmUqzEaCUg9m2gcs5qsF9dqRQsJtki0308GaTl5PnX_wlYYOSulAvYDH9o9wyGkLSSjamZZKPo3epRoefIxYeF3NMpYxZhB2zmsNqQy8oA4lxyx4ptmEv0p1nfpr9vX1P2gSojHXwXhBsFYhTsuKI2-90lPyy6Aa-u7c4kfYqrhrnJutMsyHycSe7BvC4UXUmF8cBc_uPGTY5UwISkOTAiBkxSx_n2aL-4rB8ChnrbpoyoR3HONJPBuHncVixH6nzYVQ", - }, - ) - require.Error(t, err) - }) - }) -} diff --git a/x/ovm/keeper/msg_server_test.go b/x/ovm/keeper/msg_server_test.go deleted file mode 100644 index bdb4f78f..00000000 --- a/x/ovm/keeper/msg_server_test.go +++ /dev/null @@ -1,39 +0,0 @@ -package keeper_test - -import ( - "context" - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/ovm/keeper" - "github.com/sge-network/sge/x/ovm/types" -) - -func setupMsgServer(t testing.TB) (types.MsgServer, sdk.Context, context.Context) { - _, _, msgk, ctx, wctx := setupMsgServerAndApp(t) - return msgk, ctx, wctx -} - -func setupMsgServerAndKeeper( - t testing.TB, -) (*keeper.KeeperTest, types.MsgServer, sdk.Context, context.Context) { - _, k, msgk, ctx, wctx := setupMsgServerAndApp(t) - return k, msgk, ctx, wctx -} - -func setupMsgServerAndApp( - t testing.TB, -) (*simapp.TestApp, *keeper.KeeperTest, types.MsgServer, sdk.Context, context.Context) { - tApp, k, ctx := setupKeeperAndApp(t) - return tApp, k, keeper.NewMsgServerImpl(*k), ctx, sdk.WrapSDKContext(ctx) -} - -func TestNewMsgServerImpl(t *testing.T) { - msgk, _, _ := setupMsgServer(t) - - require.True(t, msgk != nil) -} diff --git a/x/ovm/keeper/msg_server_vote_test.go b/x/ovm/keeper/msg_server_vote_test.go deleted file mode 100644 index 4adf73c1..00000000 --- a/x/ovm/keeper/msg_server_vote_test.go +++ /dev/null @@ -1,118 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt/v4" - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestChangePubkeysVote(t *testing.T) { - t.Run("success", func(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - createNActiveProposal(k, ctx, 1) - creator := simapp.TestParamUsers["user1"] - pubs, err := createNTestPubKeys(types.MinPubKeysCount) - require.NoError(t, err) - - proposalTicket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": 0, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedProposalTicket, err := proposalTicket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - resp, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: singedProposalTicket, - }, - ) - require.NoError(t, err) - require.Equal(t, true, resp.Success) - - voteTicket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "proposal_id": 1, - "vote": types.ProposalVote_PROPOSAL_VOTE_YES, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedVoteTicket, err := voteTicket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - respVote, err := msgk.VotePubkeysChange(wctx, &types.MsgVotePubkeysChangeRequest{ - Creator: creator.Address.String(), - Ticket: singedVoteTicket, - VoterKeyIndex: 0, - }) - require.NoError(t, err) - require.Equal(t, true, respVote.Success) - }) - - t.Run("duplicate vote", func(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - createNActiveProposal(k, ctx, 1) - creator := simapp.TestParamUsers["user1"] - pubs, err := createNTestPubKeys(types.MinPubKeysCount) - require.NoError(t, err) - - proposalTicket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "public_keys": pubs, - "leader_index": 0, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedProposalTicket, err := proposalTicket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - resp, err := msgk.SubmitPubkeysChangeProposal( - wctx, - &types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: creator.Address.String(), - Ticket: singedProposalTicket, - }, - ) - require.NoError(t, err) - require.Equal(t, true, resp.Success) - - vote1Ticket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "proposal_id": 1, - "vote": types.ProposalVote_PROPOSAL_VOTE_YES, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedVote1Ticket, err := vote1Ticket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - respVote, err := msgk.VotePubkeysChange(wctx, &types.MsgVotePubkeysChangeRequest{ - Creator: creator.Address.String(), - Ticket: singedVote1Ticket, - VoterKeyIndex: 0, - }) - require.NoError(t, err) - require.Equal(t, true, respVote.Success) - - vote2Ticket := jwt.NewWithClaims(jwt.SigningMethodEdDSA, jwt.MapClaims{ - "proposal_id": 1, - "vote": types.ProposalVote_PROPOSAL_VOTE_YES, - "exp": jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }) - singedVote2Ticket, err := vote2Ticket.SignedString(simapp.TestOVMPrivateKeys[0]) - require.NoError(t, err) - - respVote, err = msgk.VotePubkeysChange(wctx, &types.MsgVotePubkeysChangeRequest{ - Creator: creator.Address.String(), - Ticket: singedVote2Ticket, - VoterKeyIndex: 0, - }) - require.ErrorIs(t, sdkerrtypes.ErrInvalidRequest, err) - require.Nil(t, respVote) - }) -} diff --git a/x/ovm/keeper/params_test.go b/x/ovm/keeper/params_test.go deleted file mode 100644 index 1d4e906f..00000000 --- a/x/ovm/keeper/params_test.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/ovm/types" -) - -func TestGetParams(t *testing.T) { - k, ctx := setupKeeper(t) - params := types.DefaultParams() - - k.SetParams(ctx, params) - - require.EqualValues(t, params, k.GetParams(ctx)) -} diff --git a/x/ovm/keeper/proposal_test.go b/x/ovm/keeper/proposal_test.go deleted file mode 100644 index f4e39244..00000000 --- a/x/ovm/keeper/proposal_test.go +++ /dev/null @@ -1,225 +0,0 @@ -package keeper_test - -import ( - "crypto/x509" - "testing" - "time" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/utils" - - "github.com/sge-network/sge/x/ovm/keeper" - "github.com/sge-network/sge/x/ovm/types" -) - -func createNActiveProposal( - keeper *keeper.Keeper, - ctx sdk.Context, - n int, -) []types.PublicKeysChangeProposal { - items := make([]types.PublicKeysChangeProposal, n) - - pubKeys, err := createNTestPubKeys(types.MinPubKeysCount) - if err != nil { - panic(err) - } - - for i := range items { - items[i].Id = uint64(i) - items[i].Creator = simapp.TestParamUsers["user"+cast.ToString(i)].Address.String() - items[i].Modifications = types.PubkeysChangeProposalPayload{PublicKeys: pubKeys, LeaderIndex: 0} - items[i].StartTS = ctx.BlockTime().Unix() - items[i].Status = types.ProposalStatus_PROPOSAL_STATUS_ACTIVE - - keeper.SetPubkeysChangeProposal(ctx, items[i]) - } - return items -} - -func TestGetActivePubkeysChangeProposal(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNActiveProposal(k, ctx, 10) - _, found := k.GetPubkeysChangeProposal(ctx, types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, 5000000) - require.False(t, found) - - for _, item := range items { - rst, found := k.GetPubkeysChangeProposal( - ctx, - types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - item.Id, - ) - require.True(t, found) - require.EqualValues(t, item, rst) - } -} - -func TestRemoveActivePubkeysChangeProposal(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNActiveProposal(k, ctx, 10) - for _, item := range items { - k.RemoveProposal(ctx, - types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - item.Id, - ) - _, found := k.GetPubkeysChangeProposal(ctx, - types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - item.Id, - ) - require.False(t, found) - } -} - -func TestGetAllActivePubkeysChangeProposal(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNActiveProposal(k, ctx, 10) - - Markets, err := k.GetAllPubkeysChangeProposalsByStatus( - ctx, - types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - ) - require.NoError(t, err) - - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(Markets), - ) -} - -func TestFinishProposals(t *testing.T) { - k, ctx := setupKeeper(t) - ctx = ctx.WithBlockTime(time.Now()) - items := createNActiveProposal(k, ctx, 10) - - proposals, err := k.GetAllPubkeysChangeProposalsByStatus( - ctx, - types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - ) - require.NoError(t, err) - require.Equal(t, len(items), len(proposals)) - - // set the block time equal to the half of the valid time range. - ctx = ctx.WithBlockTime(ctx.BlockTime().Add(types.MaxValidProposalMinutes / 2 * time.Minute)) - - for _, proposal := range items { - for _, p := range simapp.TestOVMPublicKeys { - bs, err := x509.MarshalPKIXPublicKey(p) - if err != nil { - panic(err) - } - - proposal.Votes = append(proposal.Votes, - types.NewVote( - string(utils.NewPubKeyMemory(bs)), - types.ProposalVote_PROPOSAL_VOTE_YES, - ), - ) - } - - k.SetPubkeysChangeProposal(ctx, proposal) - } - - proposals, err = k.GetAllPubkeysChangeProposalsByStatus( - ctx, - types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - ) - require.NoError(t, err) - require.Equal(t, len(items), len(proposals)) - - err = k.FinishProposals(ctx) - require.NoError(t, err) - - proposals, err = k.GetAllPubkeysChangeProposalsByStatus( - ctx, - types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - ) - require.NoError(t, err) - require.Equal(t, 0, len(proposals)) - - finishedProposals, err := k.GetAllPubkeysChangeProposalsByStatus( - ctx, - types.ProposalStatus_PROPOSAL_STATUS_FINISHED, - ) - require.NoError(t, err) - require.Equal(t, len(items), len(finishedProposals)) - - finishedProposals, err = k.GetAllPubkeysChangeProposals(ctx) - require.NoError(t, err) - - require.Equal(t, len(items), len(finishedProposals)) - - keyVault, found := k.GetKeyVault(ctx) - require.True(t, found) - require.Equal(t, types.MinPubKeysCount, len(keyVault.PublicKeys)) -} - -func TestFinishProposal(t *testing.T) { - k, ctx := setupKeeper(t) - ctx = ctx.WithBlockTime(time.Now()) - proposals := createNActiveProposal(k, ctx, 3) - - voteAll := func(proposal *types.PublicKeysChangeProposal, vote types.ProposalVote) { - for _, p := range simapp.TestOVMPublicKeys { - bs, err := x509.MarshalPKIXPublicKey(p) - if err != nil { - panic(err) - } - - proposal.Votes = append(proposal.Votes, - types.NewVote( - string(utils.NewPubKeyMemory(bs)), - vote, - ), - ) - } - } - - for _, tc := range []struct { - timeDiff time.Duration - vote types.ProposalVote - result types.ProposalResult - proposal *types.PublicKeysChangeProposal - - err error - }{ - { - timeDiff: types.MaxValidProposalMinutes / 2 * time.Minute, - proposal: &proposals[0], - vote: types.ProposalVote_PROPOSAL_VOTE_YES, - result: types.ProposalResult_PROPOSAL_RESULT_APPROVED, - }, - { - timeDiff: types.MaxValidProposalMinutes / 2 * time.Minute, - proposal: &proposals[1], - vote: types.ProposalVote_PROPOSAL_VOTE_NO, - result: types.ProposalResult_PROPOSAL_RESULT_REJECTED, - }, - { - timeDiff: types.MaxValidProposalMinutes * 2 * time.Minute, - proposal: &proposals[2], - vote: types.ProposalVote_PROPOSAL_VOTE_YES, - result: types.ProposalResult_PROPOSAL_RESULT_EXPIRED, - }, - } { - ctx = ctx.WithBlockTime(ctx.BlockTime().Add(tc.timeDiff)) - - voteAll(tc.proposal, tc.vote) - - k.SetPubkeysChangeProposal(ctx, *tc.proposal) - - err := k.FinishProposals(ctx) - require.NoError(t, err) - - finishedProposal, found := k.GetPubkeysChangeProposal( - ctx, - types.ProposalStatus_PROPOSAL_STATUS_FINISHED, - tc.proposal.Id, - ) - require.True(t, found) - require.Equal(t, tc.result, finishedProposal.Result) - } -} diff --git a/x/ovm/keeper/ticket_test.go b/x/ovm/keeper/ticket_test.go deleted file mode 100644 index 2ad6e219..00000000 --- a/x/ovm/keeper/ticket_test.go +++ /dev/null @@ -1,152 +0,0 @@ -package keeper_test - -import ( - "crypto/ed25519" - "crypto/rand" - "crypto/x509" - "encoding/pem" - "testing" - "time" - - "github.com/golang-jwt/jwt/v4" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestVerifyTicket(t *testing.T) { - k, msgk, _, wctx := setupMsgServerAndKeeper(t) - - creator := simapp.TestParamUsers["user1"] - - t.Run("valid", func(t *testing.T) { - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title string - }{ - Title: "Test", - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - tkn, err := Token.SignedString(&simapp.TestOVMPrivateKeys[0]) - require.Nil(t, err) - - err = k.VerifyTicket(wctx, tkn) - require.Nil(t, err) - }) - - t.Run("invalid token", func(t *testing.T) { - err := k.VerifyTicket(wctx, "invalid.Token") - require.Error(t, err) - }) - t.Run("Verify Error", func(t *testing.T) { - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title string - }{ - Title: "Test", - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - _, intrustedPrivateKey, err := ed25519.GenerateKey(rand.Reader) - require.Nil(t, err) - tkn, err := Token.SignedString(intrustedPrivateKey) - require.Nil(t, err) - - err = k.VerifyTicket(wctx, tkn) - require.Error(t, err) - }) - _, _, _ = msgk, wctx, creator -} - -func TestVerifyTicketUnmarshal(t *testing.T) { - k, msgk, ctx, wctx := setupMsgServerAndKeeper(t) - - creator := simapp.TestParamUsers["user1"] - - Pub, Pri, err := ed25519.GenerateKey(rand.Reader) - require.Nil(t, err) - Pub2, Pri2, err := ed25519.GenerateKey(rand.Reader) - require.Nil(t, err) - _, _ = Pub, Pub2 - - var clm struct { - jwt.RegisteredClaims - Title string - } - bs, err := x509.MarshalPKIXPublicKey(Pri.Public()) - require.Nil(t, err) - - Pbs := pem.EncodeToMemory(&pem.Block{ - Type: "PUBLIC KEY", - Bytes: bs, - }) - - k.SetKeyVault(ctx, types.KeyVault{ - PublicKeys: []string{string(Pbs)}, - }) - - t.Run("valid", func(t *testing.T) { - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title string - }{ - Title: "Test", - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - tkn, err := Token.SignedString(Pri) - require.Nil(t, err) - - err = k.VerifyTicketUnmarshal(wctx, tkn, &clm) - require.Nil(t, err) - require.NotEmpty(t, clm.Title) - }) - t.Run("invalid token", func(t *testing.T) { - err = k.VerifyTicketUnmarshal(wctx, "invalid.Token", &clm) - require.Error(t, err) - }) - t.Run("Verify Error", func(t *testing.T) { - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title string - }{ - Title: "Test", - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - tkn, err := Token.SignedString(Pri2) - require.Nil(t, err) - - err = k.VerifyTicketUnmarshal(wctx, tkn, &clm) - require.Error(t, err) - }) - - t.Run("Unmarshal Error", func(t *testing.T) { - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title int - }{ - Title: 1, - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - tkn, err := Token.SignedString(Pri) - require.Nil(t, err) - - err = k.VerifyTicketUnmarshal(wctx, tkn, &clm) - require.Error(t, err) - }) - _, _, _ = msgk, wctx, creator -} diff --git a/x/ovm/simulation/decoder_test.go b/x/ovm/simulation/decoder_test.go deleted file mode 100644 index 2596dd6f..00000000 --- a/x/ovm/simulation/decoder_test.go +++ /dev/null @@ -1,79 +0,0 @@ -package simulation_test - -import ( - "fmt" - "testing" - "time" - - "github.com/spf13/cast" - "github.com/stretchr/testify/require" - - "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/testutil/sample" - - "github.com/sge-network/sge/x/ovm/simulation" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestDecodeStore(t *testing.T) { - cdc := app.MakeEncodingConfig().Marshaler - dec := simulation.NewDecodeStore(cdc) - - keyVault := types.KeyVault{ - PublicKeys: []string{"sample key"}, - } - - proposalStats := types.ProposalStats{ - PubkeysChangeCount: 1, - } - - proposal := types.PublicKeysChangeProposal{ - Id: 1, - Creator: sample.AccAddress(), - StartTS: cast.ToInt64(time.Now().UTC()), - Modifications: types.PubkeysChangeProposalPayload{ - PublicKeys: []string{"new key"}, - LeaderIndex: 0, - }, - Votes: []*types.Vote{ - { - Vote: types.ProposalVote_PROPOSAL_VOTE_YES, - PublicKey: "sample key", - }, - }, - Result: types.ProposalResult_PROPOSAL_RESULT_UNSPECIFIED, - ResultMeta: "sample metadata", - Status: types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - FinishTS: cast.ToInt64(time.Now().Add(1 * time.Hour).UTC().String()), - } - - kvPairs := kv.Pairs{ - Pairs: []kv.Pair{ - {Key: types.KeyVaultKey, Value: cdc.MustMarshal(&keyVault)}, - {Key: types.ProposalStatsKey, Value: cdc.MustMarshal(&proposalStats)}, - {Key: types.PubKeysChangeProposalListPrefix, Value: cdc.MustMarshal(&proposal)}, - {Key: []byte{0x99}, Value: []byte{0x99}}, - }, - } - tests := []struct { - name string - expectedLog string - }{ - {"key_vault", fmt.Sprintf("%v\n%v", keyVault, keyVault)}, - {"proposals_stats", fmt.Sprintf("%v\n%v", proposalStats, proposalStats)}, - {"pubkeys_change_proposal", fmt.Sprintf("%v\n%v", proposal, proposal)}, - {"other", ""}, - } - - for i, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - switch i { - case len(tests) - 1: - require.Panics(t, func() { dec(kvPairs.Pairs[i], kvPairs.Pairs[i]) }, tt.name) - default: - require.Equal(t, tt.expectedLog, dec(kvPairs.Pairs[i], kvPairs.Pairs[i]), tt.name) - } - }) - } -} diff --git a/x/ovm/simulation/genesis_test.go b/x/ovm/simulation/genesis_test.go deleted file mode 100644 index 76a2efe9..00000000 --- a/x/ovm/simulation/genesis_test.go +++ /dev/null @@ -1,74 +0,0 @@ -package simulation_test - -import ( - "encoding/json" - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/codec" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/types/module" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - - "github.com/sge-network/sge/x/ovm/simulation" - "github.com/sge-network/sge/x/ovm/types" -) - -// TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. -// Abnormal scenarios are not tested here. -func TestRandomizedGenState(_ *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - simState := module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - NumBonded: 3, - Accounts: simtypes.RandomAccounts(r, 3), - InitialStake: sdkmath.NewInt(1000), - GenState: make(map[string]json.RawMessage), - } - - simulation.RandomizedGenState(&simState) - - var ovmGenesis types.GenesisState - simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &ovmGenesis) -} - -// TestRandomizedGenState tests abnormal scenarios of applying RandomizedGenState. -func TestRandomizedGenState1(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - // all these tests will panic - tests := []struct { - simState module.SimulationState - panicMsg string - }{ - { // panic => reason: incomplete initialization of the simState - module.SimulationState{}, "invalid memory address or nil pointer dereference"}, - { // panic => reason: incomplete initialization of the simState - module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - }, "assignment to entry in nil map"}, - } - - for _, tt := range tests { - simTest := tt.simState - require.Panicsf(t, func() { simulation.RandomizedGenState(&simTest) }, tt.panicMsg) - } -} diff --git a/x/ovm/simulation/proposals_test.go b/x/ovm/simulation/proposals_test.go deleted file mode 100644 index 8183cf30..00000000 --- a/x/ovm/simulation/proposals_test.go +++ /dev/null @@ -1,43 +0,0 @@ -package simulation_test - -import ( - "fmt" - "math/rand" - "testing" - - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/address" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/ovm/simulation" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestProposalMsgs(t *testing.T) { - // initialize parameters - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - ctx := sdk.NewContext(nil, tmproto.Header{}, true, nil) - accounts := simtypes.RandomAccounts(r, 3) - - // execute ProposalMsgs function - weightedProposalMsgs := simulation.ProposalMsgs() - require.Equal(t, len(weightedProposalMsgs), 1) - - w0 := weightedProposalMsgs[0] - - // tests w0 interface: - require.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) - require.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) - - msg := w0.MsgSimulatorFn()(r, ctx, accounts) - msgUpdateParams, ok := msg.(*types.MsgUpdateParams) - require.True(t, ok) - - fmt.Println(msgUpdateParams) - require.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) -} diff --git a/x/ovm/types/genesis_test.go b/x/ovm/types/genesis_test.go deleted file mode 100644 index dee26256..00000000 --- a/x/ovm/types/genesis_test.go +++ /dev/null @@ -1,90 +0,0 @@ -package types_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/ovm/types" -) - -const ( - testAddress = "cosmos1s4ycalgh3gjemd4hmqcvcgmnf647rnd0tpg2w9" -) - -func TestGenesisState_Validate(t *testing.T) { - pubkeys := simapp.GenerateOvmPublicKeys(types.MaxPubKeysCount) - - var votes []*types.Vote - for _, v := range pubkeys { - votes = append(votes, &types.Vote{PublicKey: v, Vote: types.ProposalVote_PROPOSAL_VOTE_YES}) - } - - validState := types.GenesisState{ - KeyVault: types.KeyVault{ - PublicKeys: pubkeys, - }, - PubkeysChangeProposals: []types.PublicKeysChangeProposal{ - { - Id: 1, - Creator: testAddress, - StartTS: time.Now().Unix(), - Modifications: types.PubkeysChangeProposalPayload{ - PublicKeys: pubkeys, - LeaderIndex: 0, - }, - Votes: votes, - Status: types.ProposalStatus_PROPOSAL_STATUS_ACTIVE, - }, - }, - ProposalStats: types.ProposalStats{ - PubkeysChangeCount: 1, - }, - Params: types.DefaultParams(), - } - - corruptPublicKeys := make([]string, len(pubkeys)) - copy(corruptPublicKeys, pubkeys) - corruptPublicKeys[0] = "-----BEGIN PUBLIC KEY-----\n \n-----END PUBLIC KEY-----" - invalidPublicKeysState := types.GenesisState{ - KeyVault: types.KeyVault{ - PublicKeys: corruptPublicKeys, - }, - PubkeysChangeProposals: validState.PubkeysChangeProposals, - ProposalStats: validState.ProposalStats, - Params: types.DefaultParams(), - } - - for _, tc := range []struct { - desc string - genState *types.GenesisState - valid bool - }{ - { - desc: "default is not valid", - genState: types.DefaultGenesis(), - valid: false, - }, - { - desc: "valid genesis state", - genState: &validState, - valid: true, - }, - { - desc: "invalid genesis state", - genState: &invalidPublicKeysState, - valid: false, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - err := tc.genState.Validate() - if tc.valid { - require.NoError(t, err) - } else { - require.Error(t, err) - } - }) - } -} diff --git a/x/ovm/types/key_vault_test.go b/x/ovm/types/key_vault_test.go deleted file mode 100644 index 0a643381..00000000 --- a/x/ovm/types/key_vault_test.go +++ /dev/null @@ -1,49 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestMajority(t *testing.T) { - tests := []struct { - name string - publicKeys []string - - exp int64 - }{ - { - name: "odd public keys", - publicKeys: simapp.GenerateOvmPublicKeys(5), - exp: 4, - }, - { - name: "even public keys", - publicKeys: simapp.GenerateOvmPublicKeys(4), - exp: 3, - }, - { - name: "large odd number", - publicKeys: simapp.GenerateOvmPublicKeys(51), - exp: 35, - }, - { - name: "large even number", - publicKeys: simapp.GenerateOvmPublicKeys(50), - exp: 34, - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - keyVault := types.KeyVault{ - PublicKeys: tc.publicKeys, - } - require.Equal(t, tc.exp, keyVault.MajorityCount()) - }) - } -} diff --git a/x/ovm/types/message_pubkeys_proposal_test.go b/x/ovm/types/message_pubkeys_proposal_test.go deleted file mode 100644 index a4d57057..00000000 --- a/x/ovm/types/message_pubkeys_proposal_test.go +++ /dev/null @@ -1,43 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestMsgChangePubkeysListProposalValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgSubmitPubkeysChangeProposalRequest - err error - }{ - { - name: "invalid address", - msg: types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: "invalid_address", - }, - err: sdkerrtypes.ErrInvalidAddress, - }, { - name: "valid address", - msg: types.MsgSubmitPubkeysChangeProposalRequest{ - Creator: sample.AccAddress(), - }, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/ovm/types/message_pubkeys_vote_test.go b/x/ovm/types/message_pubkeys_vote_test.go deleted file mode 100644 index 400e4a42..00000000 --- a/x/ovm/types/message_pubkeys_vote_test.go +++ /dev/null @@ -1,46 +0,0 @@ -package types_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestMsgChangePubkeysVoteValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgVotePubkeysChangeRequest - err error - }{ - { - name: "invalid address", - msg: types.MsgVotePubkeysChangeRequest{ - Creator: "invalid_address", - VoterKeyIndex: 0, - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - name: "valid address", - msg: types.MsgVotePubkeysChangeRequest{ - Creator: sample.AccAddress(), - VoterKeyIndex: 0, - }, - }, - } - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - err := tc.msg.ValidateBasic() - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/ovm/types/ticket_jwt_test.go b/x/ovm/types/ticket_jwt_test.go deleted file mode 100644 index 08282f6c..00000000 --- a/x/ovm/types/ticket_jwt_test.go +++ /dev/null @@ -1,166 +0,0 @@ -package types_test - -import ( - "crypto/ed25519" - "crypto/rand" - "crypto/x509" - "encoding/pem" - "strings" - "testing" - "time" - - "github.com/golang-jwt/jwt/v4" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/utils" - "github.com/sge-network/sge/x/ovm/types" -) - -func TestVerifyWithKey(t *testing.T) { - Pub2, Pri2, err := ed25519.GenerateKey(rand.Reader) - require.NoError(t, err) - bs, err := x509.MarshalPKIXPublicKey(Pub2) - require.NoError(t, err) - - T1 := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - PublicKeys []string - LeaderIndex uint32 - jwt.RegisteredClaims - }{ - PublicKeys: []string{string(utils.NewPubKeyMemory(bs))}, - LeaderIndex: 0, - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(1 * time.Hour)), - }, - }) - singedT1, err := T1.SignedString(Pri2) - require.NoError(t, err) - ss := strings.Split(singedT1, ".") - - ticket := types.NewTestJwtToken(ss[0], ss[1], ss[2]) - require.Nil(t, err) - t.Run("Success", func(t *testing.T) { - _, err = ticket.VerifyJwtKey(string(utils.NewPubKeyMemory(bs))) - require.NoError(t, err) - }) - t.Run("Error", func(t *testing.T) { - invalidKey := "MIGeMA0GCSqGSIb3DQEBAQUAA4GMADCBiAKBgGiRKsHZPpIWUVyHVePzoZLHLvFZ+TdnAI2Xg7WJjrJKEX5D3R5KV9uFU5lwmT09fj4BrKjwOf4Yv8+u/BJhfdsiDbkqln3FhNG1ZSxAa+9n6CKBeJku9OLpDt7olBpcydyCf8CYmTNq+YABpJbVX6iYZrbpsWK34C9fppe3rzFDAgMBAAE=" - _, err := ticket.VerifyJwtKey(invalidKey) - require.Error(t, err) - }) -} - -func TestNewTicket(t *testing.T) { - t.Run("valid", func(t *testing.T) { - Pub, Pri, err := ed25519.GenerateKey(rand.Reader) - require.Nil(t, err) - _ = Pub - - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title string - }{ - Title: "Test", - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - tkn, err := Token.SignedString(Pri) - require.Nil(t, err) - t.Log(err) - it, err := types.NewJwtTicket(tkn) - t.Log(err) - require.Nil(t, err) - require.NotNil(t, it) - }) - - t.Run("invalid", func(t *testing.T) { - it, err := types.NewJwtTicket("invlaid.Token") - require.Error(t, err) - // require.Nil(t, it) - _ = it - }) -} - -func TestUnmarshal(t *testing.T) { - Pub, Pri, err := ed25519.GenerateKey(rand.Reader) - require.Nil(t, err) - _ = Pub - - // bs, err := x509.MarshalPKIXPublicKey(Pri.Public()) - // require.Nil(t, err) - // Pbs := pem.EncodeToMemory(&pem.Block{ - // Type: "PUBLIC KEY", - // Bytes: bs, - // }) - - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title string - }{ - Title: "Test", - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - tkn, err := Token.SignedString(Pri) - require.Nil(t, err) - - it, err := types.NewJwtTicket(tkn) - require.Nil(t, err) - require.NotNil(t, it) - - t.Run("valid", func(t *testing.T) { - var clm struct { - jwt.RegisteredClaims - Title string - } - err := it.Unmarshal(&clm) - require.Nil(t, err) - require.NotEmpty(t, clm.Title) - }) -} - -func TestVerify(t *testing.T) { - Pub, Pri, err := ed25519.GenerateKey(rand.Reader) - require.Nil(t, err) - - bs, err := x509.MarshalPKIXPublicKey(Pub) - require.Nil(t, err) - Pbs := pem.EncodeToMemory(&pem.Block{ - Type: "PUBLIC KEY", - Bytes: bs, - }) - - Token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, struct { - jwt.RegisteredClaims - Title string - }{ - Title: "Test", - RegisteredClaims: jwt.RegisteredClaims{ - ExpiresAt: jwt.NewNumericDate(time.Now().Add(24 * time.Hour)), - IssuedAt: jwt.NewNumericDate(time.Now()), - }, - }) - tkn, err := Token.SignedString(Pri) - require.Nil(t, err) - - it, err := types.NewJwtTicket(tkn) - require.Nil(t, err) - require.NotNil(t, it) - - t.Run("valid", func(t *testing.T) { - err := it.Verify(string(Pbs)) - require.Nil(t, err) - }) - t.Run("invalid", func(t *testing.T) { - err := it.Verify("invalidPubKey") - require.Error(t, err) - }) - t.Run("no key", func(t *testing.T) { - err := it.Verify("") - require.Error(t, err) - }) -} diff --git a/x/reward/genesis_test.go b/x/reward/genesis_test.go deleted file mode 100644 index 590bf851..00000000 --- a/x/reward/genesis_test.go +++ /dev/null @@ -1,99 +0,0 @@ -package reward_test - -import ( - "testing" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/reward" - "github.com/sge-network/sge/x/reward/types" -) - -func TestGenesis(t *testing.T) { - promoterAddr := "promoter" - promoterUID := uuid.NewString() - - campaignUID1 := uuid.NewString() - campaignUID2 := uuid.NewString() - - rewardID1 := uuid.NewString() - rewardID2 := uuid.NewString() - - genesisState := types.GenesisState{ - Params: types.DefaultParams(), - - PromoterList: []types.Promoter{ - { - Creator: promoterAddr, - UID: promoterUID, - Addresses: []string{promoterAddr}, - Conf: types.PromoterConf{ - CategoryCap: []types.CategoryCap{ - { - Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, - CapPerAcc: 1, - }, - }, - }, - }, - }, - PromoterByAddressList: []types.PromoterByAddress{ - { - PromoterUID: promoterUID, - Address: promoterAddr, - }, - }, - CampaignList: []types.Campaign{ - { - UID: campaignUID1, - Promoter: promoterAddr, - }, - { - UID: campaignUID2, - Promoter: promoterAddr, - }, - }, - RewardList: []types.Reward{ - { - UID: rewardID1, - CampaignUID: campaignUID1, - }, - { - UID: rewardID2, - CampaignUID: campaignUID2, - }, - }, - RewardByCategoryList: []types.RewardByCategory{ - { - UID: rewardID1, - }, - { - UID: rewardID2, - }, - }, - RewardByCampaignList: []types.RewardByCampaign{ - { - UID: rewardID1, - CampaignUID: campaignUID1, - }, - { - UID: rewardID1, - CampaignUID: campaignUID2, - }, - }, - } - - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - reward.InitGenesis(ctx, *tApp.RewardKeeper, genesisState) - got := reward.ExportGenesis(ctx, *tApp.RewardKeeper) - require.NotNil(t, got) - - nullify.Fill(&genesisState) - nullify.Fill(got) - - require.ElementsMatch(t, genesisState.CampaignList, got.CampaignList) -} diff --git a/x/reward/handler.go b/x/reward/handler.go deleted file mode 100644 index e982ac82..00000000 --- a/x/reward/handler.go +++ /dev/null @@ -1,43 +0,0 @@ -package reward - -import ( - "fmt" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" -) - -// NewHandler returns sdk.handler instance with configured message handler function -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - - switch msg := msg.(type) { - case *types.MsgCreateCampaign: - res, err := msgServer.CreateCampaign(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdateCampaign: - res, err := msgServer.UpdateCampaign(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgWithdrawFunds: - res, err := msgServer.WithdrawFunds(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgGrantReward: - res, err := msgServer.GrantReward(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdateParams: - res, err := msgServer.UpdateParams(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrtypes.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/reward/keeper/campaign_test.go b/x/reward/keeper/campaign_test.go deleted file mode 100644 index 075b811c..00000000 --- a/x/reward/keeper/campaign_test.go +++ /dev/null @@ -1,79 +0,0 @@ -package keeper_test - -import ( - "strconv" - "testing" - "time" - - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" -) - -// Prevent strconv unused error -var _ = strconv.IntSize - -func createNCampaign(keeper *keeper.Keeper, ctx sdk.Context, n int) []types.Campaign { - items := make([]types.Campaign, n) - for i := range items { - items[i].UID = uuid.NewString() - items[i].Creator = sample.AccAddress() - items[i].Promoter = sample.AccAddress() - items[i].StartTS = uint64(time.Now().Unix()) - items[i].EndTS = uint64(time.Now().Add(5 * time.Minute).Unix()) - items[i].RewardCategory = types.RewardCategory_REWARD_CATEGORY_SIGNUP - items[i].RewardType = types.RewardType_REWARD_TYPE_REFERRAL - items[i].RewardAmountType = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - items[i].IsActive = true - items[i].Meta = "campaign " + items[i].UID - items[i].Pool = types.Pool{Spent: sdkmath.ZeroInt(), Withdrawn: sdkmath.ZeroInt(), Total: sdkmath.NewInt(100)} - - keeper.SetCampaign(ctx, items[i]) - } - return items -} - -func TestCampaignGet(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNCampaign(k, ctx, 10) - for _, item := range items { - rst, found := k.GetCampaign(ctx, - item.UID, - ) - require.True(t, found) - require.Equal(t, - nullify.Fill(item), - nullify.Fill(rst), - ) - } -} - -func TestCampaignRemove(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNCampaign(k, ctx, 10) - for _, item := range items { - k.RemoveCampaign(ctx, - item.UID, - ) - _, found := k.GetCampaign(ctx, - item.UID, - ) - require.False(t, found) - } -} - -func TestCampaignGetAll(t *testing.T) { - k, ctx := setupKeeper(t) - items := createNCampaign(k, ctx, 10) - require.ElementsMatch(t, - nullify.Fill(items), - nullify.Fill(k.GetAllCampaign(ctx)), - ) -} diff --git a/x/reward/keeper/export_test.go b/x/reward/keeper/export_test.go deleted file mode 100644 index d22f197e..00000000 --- a/x/reward/keeper/export_test.go +++ /dev/null @@ -1,5 +0,0 @@ -package keeper - -// KeeperTest is a wrapper object for the keeper, It is being used -// to export unexported methods of the keeper -type KeeperTest = Keeper diff --git a/x/reward/keeper/keeper_test.go b/x/reward/keeper/keeper_test.go deleted file mode 100644 index 02f9e83e..00000000 --- a/x/reward/keeper/keeper_test.go +++ /dev/null @@ -1,25 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/reward/keeper" -) - -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp, tApp.RewardKeeper, ctx -} - -func setupKeeper(t testing.TB) (*keeper.KeeperTest, sdk.Context) { - _, k, ctx := setupKeeperAndApp(t) - - return k, ctx -} diff --git a/x/reward/keeper/msg_server.go b/x/reward/keeper/msg_server.go deleted file mode 100644 index ba524e70..00000000 --- a/x/reward/keeper/msg_server.go +++ /dev/null @@ -1,17 +0,0 @@ -package keeper - -import ( - "github.com/sge-network/sge/x/reward/types" -) - -type msgServer struct { - Keeper -} - -// NewMsgServerImpl returns an implementation of the MsgServer interface -// for the provided Keeper. -func NewMsgServerImpl(keeper Keeper) types.MsgServer { - return &msgServer{Keeper: keeper} -} - -var _ types.MsgServer = msgServer{} diff --git a/x/reward/keeper/msg_server_campaign_test.go b/x/reward/keeper/msg_server_campaign_test.go deleted file mode 100644 index f64de9b0..00000000 --- a/x/reward/keeper/msg_server_campaign_test.go +++ /dev/null @@ -1,409 +0,0 @@ -package keeper_test - -import ( - "strconv" - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" -) - -// Prevent strconv unused error -var _ = strconv.IntSize - -func setTestPromoter(k *keeper.Keeper, ctx sdk.Context, promoterAddr string) { - k.SetPromoter(ctx, types.Promoter{ - Creator: promoterAddr, - UID: promoterUID, - Addresses: []string{ - promoterAddr, - }, - }) - k.SetPromoterByAddress(ctx, types.PromoterByAddress{ - PromoterUID: promoterUID, - Address: promoterAddr, - }) -} - -func TestCampaignMsgServerCreate(t *testing.T) { - k, ctx := setupKeeper(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - creator := simapp.TestParamUsers["user1"].Address.String() - - setTestPromoter(k, ctx, creator) - - for i := 0; i < 5; i++ { - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": creator, - "start_ts": time.Now().Unix(), - "end_ts": time.Now().Add(5 * time.Minute).Unix(), - "category": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_type": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_amount_type": types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED, - "reward_amount": types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - }, - "is_active": true, - "meta": "sample campaign", - "constraints": &types.CampaignConstraints{ - MaxBetAmount: sdkmath.NewInt(300), - }, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - expected := &types.MsgCreateCampaign{ - Creator: creator, - Uid: uuid.NewString(), - Ticket: ticket, - TotalFunds: sdkmath.NewInt(1000000), - } - _, err = srv.CreateCampaign(wctx, expected) - require.NoError(t, err) - rst, found := k.GetCampaign(ctx, - expected.Uid, - ) - require.True(t, found) - require.Equal(t, expected.Creator, rst.Creator) - } -} - -func TestCampaignMsgServerCreateWithAuthoriation(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - creator := simapp.TestParamUsers["user2"] - promoter := simapp.TestParamUsers["user1"] - - setTestPromoter(k, ctx, promoter.Address.String()) - - grantAmount := sdkmath.NewInt(1000000) - - expTime := time.Now().Add(5 * time.Minute) - err := tApp.AuthzKeeper.SaveGrant(ctx, - creator.Address, - promoter.Address, - types.NewCreateCampaignAuthorization(grantAmount), - &expTime, - ) - require.NoError(t, err) - - authzBefore, _ := tApp.AuthzKeeper.GetAuthorization( - ctx, - creator.Address, - promoter.Address, - sdk.MsgTypeURL(&types.MsgCreateCampaign{}), - ) - authzBeforeW, ok := authzBefore.(*types.CreateCampaignAuthorization) - require.True(t, ok) - require.Equal(t, grantAmount, authzBeforeW.SpendLimit) - - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": promoter.Address.String(), - "start_ts": time.Now().Unix(), - "end_ts": time.Now().Add(5 * time.Minute).Unix(), - "category": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_type": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_amount_type": types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED, - "reward_amount": types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - }, - "is_active": true, - "meta": "sample campaign", - "constraints": &types.CampaignConstraints{ - MaxBetAmount: sdkmath.NewInt(300), - }, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - expected := &types.MsgCreateCampaign{ - Creator: creator.Address.String(), - Uid: uuid.NewString(), - Ticket: ticket, - TotalFunds: sdkmath.NewInt(1000000), - } - _, err = srv.CreateCampaign(wctx, expected) - require.NoError(t, err) - rst, found := k.GetCampaign(ctx, - expected.Uid, - ) - require.True(t, found) - require.Equal(t, expected.Creator, rst.Creator) - - authzAfter, _ := tApp.AuthzKeeper.GetAuthorization(ctx, - creator.Address, - promoter.Address, - sdk.MsgTypeURL(&types.MsgCreateCampaign{}), - ) - require.Nil(t, authzAfter) -} - -func TestCampaignMsgServerUnAuthorizedCreate(t *testing.T) { - k, ctx := setupKeeper(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - creator := simapp.TestParamUsers["user1"].Address.String() - promoter := sample.AccAddress() - - setTestPromoter(k, ctx, promoter) - - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": promoter, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - expected := &types.MsgCreateCampaign{ - Creator: creator, - Uid: uuid.NewString(), - Ticket: ticket, - TotalFunds: sdkmath.NewInt(1000000), - } - _, err = srv.CreateCampaign(wctx, expected) - require.ErrorIs(t, types.ErrAuthorizationNotFound, err) -} - -func TestCampaignMsgServerUpdate(t *testing.T) { - expectedUID := uuid.NewString() - - for _, tc := range []struct { - desc string - request *types.MsgUpdateCampaign - err error - }{ - { - desc: "Completed", - request: &types.MsgUpdateCampaign{ - Uid: expectedUID, - }, - }, - { - desc: "Unauthorized", - request: &types.MsgUpdateCampaign{ - Creator: sample.AccAddress(), - Uid: expectedUID, - }, - err: types.ErrAuthorizationNotFound, - }, - { - desc: "KeyNotFound", - request: &types.MsgUpdateCampaign{ - Uid: uuid.NewString(), - }, - err: sdkerrtypes.ErrKeyNotFound, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - k, ctx := setupKeeper(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - creator := simapp.TestParamUsers["user1"].Address.String() - - setTestPromoter(k, ctx, creator) - - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": creator, - "start_ts": time.Now().Unix(), - "end_ts": time.Now().Add(5 * time.Minute).Unix(), - "category": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_type": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_amount_type": types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED, - "reward_amount": types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - }, - "is_active": true, - "meta": "sample campaign", - "constraints": &types.CampaignConstraints{ - MaxBetAmount: sdkmath.NewInt(300), - }, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - expected := &types.MsgCreateCampaign{ - Creator: creator, - Uid: expectedUID, - Ticket: ticket, - TotalFunds: sdkmath.NewInt(1000000), - } - _, err = srv.CreateCampaign(wctx, expected) - require.NoError(t, err) - - ticketClaimUpdate := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "end_ts": time.Now().Add(5 * time.Minute).Unix(), - } - ticketUpdate, err := simapp.CreateJwtTicket(ticketClaimUpdate) - require.Nil(t, err) - tc.request.Ticket = ticketUpdate - - if tc.request.Creator == "" { - tc.request.Creator = creator - } - - _, err = srv.UpdateCampaign(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - rst, found := k.GetCampaign(ctx, - expected.Uid, - ) - require.True(t, found) - require.Equal(t, expected.Creator, rst.Creator) - } - }) - } -} - -func TestCampaignMsgServerUpdateWithAuthorization(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - expectedUID := uuid.NewString() - - creator := simapp.TestParamUsers["user2"] - promoter := simapp.TestParamUsers["user1"] - - setTestPromoter(k, ctx, promoter.Address.String()) - - grantAmount := sdkmath.NewInt(1000000) - - expTime := time.Now().Add(5 * time.Minute) - err := tApp.AuthzKeeper.SaveGrant(ctx, - creator.Address, - promoter.Address, - types.NewCreateCampaignAuthorization(grantAmount), - &expTime, - ) - require.NoError(t, err) - - authzCreateBefore, _ := tApp.AuthzKeeper.GetAuthorization( - ctx, - creator.Address, - promoter.Address, - sdk.MsgTypeURL(&types.MsgCreateCampaign{}), - ) - authzCreateBeforeW, ok := authzCreateBefore.(*types.CreateCampaignAuthorization) - require.True(t, ok) - require.Equal(t, grantAmount, authzCreateBeforeW.SpendLimit) - - err = tApp.AuthzKeeper.SaveGrant(ctx, - creator.Address, - promoter.Address, - types.NewUpdateCampaignAuthorization(grantAmount), - &expTime, - ) - require.NoError(t, err) - - authzUpdateBefore, _ := tApp.AuthzKeeper.GetAuthorization( - ctx, - creator.Address, - promoter.Address, - sdk.MsgTypeURL(&types.MsgUpdateCampaign{}), - ) - authzUpdateBeforeW, ok := authzUpdateBefore.(*types.UpdateCampaignAuthorization) - require.True(t, ok) - require.Equal(t, grantAmount, authzUpdateBeforeW.SpendLimit) - - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": promoter.Address.String(), - "start_ts": time.Now().Unix(), - "end_ts": time.Now().Add(5 * time.Minute).Unix(), - "category": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_type": types.RewardType_REWARD_TYPE_SIGNUP, - "reward_amount_type": types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED, - "reward_amount": types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - }, - "is_active": true, - "meta": "sample campaign", - "constraints": &types.CampaignConstraints{ - MaxBetAmount: sdkmath.NewInt(300), - }, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - expected := &types.MsgCreateCampaign{ - Creator: creator.Address.String(), - Uid: expectedUID, - Ticket: ticket, - TotalFunds: sdkmath.NewInt(1000000), - } - _, err = srv.CreateCampaign(wctx, expected) - require.NoError(t, err) - - ticketClaimUpdate := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "end_ts": time.Now().Add(5 * time.Minute).Unix(), - "is_active": true, - } - ticketUpdate, err := simapp.CreateJwtTicket(ticketClaimUpdate) - require.Nil(t, err) - - _, err = srv.UpdateCampaign(wctx, &types.MsgUpdateCampaign{ - Creator: creator.Address.String(), - Uid: expectedUID, - TopupFunds: sdkmath.NewInt(1000000), - Ticket: ticketUpdate, - }) - - require.NoError(t, err) - rst, found := k.GetCampaign(ctx, - expected.Uid, - ) - require.True(t, found) - require.Equal(t, expected.Creator, rst.Creator) - - authzCreateAfter, _ := tApp.AuthzKeeper.GetAuthorization(ctx, - creator.Address, - promoter.Address, - sdk.MsgTypeURL(&types.MsgCreateCampaign{}), - ) - require.Nil(t, authzCreateAfter) - - authzUpdateAfter, _ := tApp.AuthzKeeper.GetAuthorization(ctx, - creator.Address, - promoter.Address, - sdk.MsgTypeURL(&types.MsgUpdateCampaign{}), - ) - require.Nil(t, authzUpdateAfter) -} diff --git a/x/reward/keeper/msg_server_params.go b/x/reward/keeper/msg_server_params.go deleted file mode 100644 index 7b907e00..00000000 --- a/x/reward/keeper/msg_server_params.go +++ /dev/null @@ -1,27 +0,0 @@ -package keeper - -import ( - "context" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - - "github.com/sge-network/sge/x/reward/types" -) - -func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { - ctx := sdk.UnwrapSDKContext(goCtx) - - if k.GetAuthority() != req.Authority { - return nil, sdkerrors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.GetAuthority(), req.Authority) - } - - if err := req.Params.Validate(); err != nil { - return nil, err - } - - k.SetParams(ctx, req.Params) - - return &types.MsgUpdateParamsResponse{}, nil -} diff --git a/x/reward/keeper/msg_server_promoter_test.go b/x/reward/keeper/msg_server_promoter_test.go deleted file mode 100644 index 5ce13fe2..00000000 --- a/x/reward/keeper/msg_server_promoter_test.go +++ /dev/null @@ -1,116 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/sge-network/sge/testutil/simapp" - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" -) - -func TestSetPromoterConfig(t *testing.T) { - k, ctx := setupKeeper(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - promoter := simapp.TestParamUsers["user1"].Address.String() - promoterUID := uuid.NewString() - k.SetPromoter(ctx, types.Promoter{ - Creator: promoter, - UID: promoterUID, - Addresses: []string{ - promoter, - }, - Conf: types.PromoterConf{ - CategoryCap: []types.CategoryCap{ - { - Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, - CapPerAcc: 1, - }, - }, - }, - }) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - uid string - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "conf": "invalid", - }, - uid: promoterUID, - err: types.ErrInTicketVerification, - }, - { - desc: "duplicate cap category", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "conf": types.PromoterConf{ - CategoryCap: []types.CategoryCap{ - {Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, CapPerAcc: 1}, - {Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, CapPerAcc: 1}, - }, - }, - }, - uid: promoterUID, - err: types.ErrDuplicateCategoryInConf, - }, - { - desc: "low cap category", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "conf": types.PromoterConf{ - CategoryCap: []types.CategoryCap{ - {Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, CapPerAcc: 0}, - {Category: types.RewardCategory_REWARD_CATEGORY_AFFILIATE, CapPerAcc: 1}, - }, - }, - }, - uid: promoterUID, - err: types.ErrCategoryCapShouldBePos, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "conf": types.PromoterConf{ - CategoryCap: []types.CategoryCap{ - {Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, CapPerAcc: 1}, - }, - }, - }, - uid: promoterUID, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - conf := &types.MsgSetPromoterConf{ - Uid: tc.uid, - Creator: promoter, - Ticket: ticket, - } - _, err = srv.SetPromoterConf(wctx, conf) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} diff --git a/x/reward/keeper/msg_server_reward_test.go b/x/reward/keeper/msg_server_reward_test.go deleted file mode 100644 index 36630b4a..00000000 --- a/x/reward/keeper/msg_server_reward_test.go +++ /dev/null @@ -1,988 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - bettypes "github.com/sge-network/sge/x/bet/types" - "github.com/sge-network/sge/x/reward/keeper" - "github.com/sge-network/sge/x/reward/types" - subaccounttypes "github.com/sge-network/sge/x/subaccount/types" -) - -var promoterUID = uuid.NewString() - -var defaultCategoryCap = []types.CategoryCap{ - {Category: types.RewardCategory_REWARD_CATEGORY_SIGNUP, CapPerAcc: 1}, -} - -func getDefaultClaim(creator string) jwt.MapClaims { - return jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "promoter": creator, - "start_ts": time.Now().Unix(), - "end_ts": time.Now().Add(5 * time.Minute).Unix(), - "category": types.RewardCategory_REWARD_CATEGORY_SIGNUP, - "is_active": true, - "meta": "sample campaign", - } -} - -func createCampaign(t *testing.T, k *keeper.Keeper, srv types.MsgServer, ctx sdk.Context, - promoter string, claims jwt.MapClaims, categoryCap []types.CategoryCap, -) string { - k.SetPromoter(ctx, types.Promoter{ - Creator: promoter, - UID: promoterUID, - Addresses: []string{promoter}, - Conf: types.PromoterConf{ - CategoryCap: categoryCap, - }, - }) - - k.SetPromoterByAddress(ctx, - types.PromoterByAddress{ - Address: promoter, - PromoterUID: promoterUID, - }) - - ticket, err := simapp.CreateJwtTicket(claims) - require.Nil(t, err) - - expected := &types.MsgCreateCampaign{ - Creator: promoter, - Uid: uuid.NewString(), - Ticket: ticket, - TotalFunds: sdkmath.NewInt(1000000), - } - _, err = srv.CreateCampaign(sdk.WrapSDKContext(ctx), expected) - require.NoError(t, err) - rst, found := k.GetCampaign(ctx, - expected.Uid, - ) - require.True(t, found) - require.Equal(t, expected.Creator, rst.Creator) - return expected.Uid -} - -func TestMsgApplySignupReward(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, receiverAddr, receiverAddr, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - campClaims := getDefaultClaim(promoter) - campClaims["reward_type"] = types.RewardType_REWARD_TYPE_SIGNUP - campClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - campClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - - campUID := createCampaign(t, k, srv, ctx, promoter, campClaims, defaultCategoryCap) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": "invalid", - }, - err: types.ErrInTicketVerification, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - }, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: campUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} - -func TestMsgApplySignupRewardWithCap(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, receiverAddr, receiverAddr, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - campClaims := getDefaultClaim(promoter) - campClaims["reward_type"] = types.RewardType_REWARD_TYPE_SIGNUP - campClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - campClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - campClaims["cap_count"] = 1 - - campUID := createCampaign(t, k, srv, ctx, promoter, campClaims, []types.CategoryCap{}) - - ticket, err := simapp.CreateJwtTicket(jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - }) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: campUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - require.NoError(t, err) - - reward.Uid = uuid.NewString() - _, err = srv.GrantReward(wctx, reward) - require.ErrorContains(t, err, "maximum count cap of the campaign is reached") -} - -func TestMsgApplySignupRefereeReward(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - referrer := simapp.TestParamUsers["user3"].Address.String() - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, receiverAddr, receiverAddr, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - campClaims := getDefaultClaim(promoter) - campClaims["reward_type"] = types.RewardType_REWARD_TYPE_REFERRAL_SIGNUP - campClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - campClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - - campUID := createCampaign(t, k, srv, ctx, promoter, campClaims, defaultCategoryCap) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": "invalid", - }, - err: types.ErrInTicketVerification, - }, - { - desc: "invalid referrer", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - }, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: referrer, - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - }, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: campUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} - -func TestMsgApplySignupReferrerReward(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - referee := simapp.TestParamUsers["user3"].Address.String() - referrer := simapp.TestParamUsers["user4"].Address.String() - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, receiverAddr, receiverAddr, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - // referral signup campaign - referralSignupCampClaims := getDefaultClaim(promoter) - referralSignupCampClaims["reward_type"] = types.RewardType_REWARD_TYPE_REFERRAL_SIGNUP - referralSignupCampClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - referralSignupCampClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - referralSignupCampUID := createCampaign(t, k, srv, ctx, promoter, referralSignupCampClaims, defaultCategoryCap) - - // referral campaign - referralCampClaims := getDefaultClaim(promoter) - referralCampClaims["category"] = types.RewardCategory_REWARD_CATEGORY_REFERRAL - referralCampClaims["reward_type"] = types.RewardType_REWARD_TYPE_REFERRAL - referralCampClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - referralCampClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - referralCampUID := createCampaign(t, k, srv, ctx, promoter, referralCampClaims, defaultCategoryCap) - - refereeClaims := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: referee, - SourceUID: referrer, - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: referee, - }, - }, - } - refereeTicket, err := simapp.CreateJwtTicket(refereeClaims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: referralSignupCampUID, - Ticket: refereeTicket, - } - _, err = srv.GrantReward(wctx, reward) - require.NoError(t, err) - - rewardGrant, err := k.GetRewardsOfReceiverByPromoterAndCategory(ctx, promoterUID, referee, types.RewardCategory_REWARD_CATEGORY_SIGNUP) - require.NoError(t, err) - require.Equal(t, types.RewardByCategory{ - UID: reward.Uid, - Addr: referee, - RewardCategory: types.RewardCategory_REWARD_CATEGORY_SIGNUP, - }, rewardGrant[0]) - - require.True(t, k.HasRewardOfReceiverByPromoter(ctx, promoterUID, referee, types.RewardCategory_REWARD_CATEGORY_SIGNUP)) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": "invalid", - }, - err: types.ErrInTicketVerification, - }, - { - desc: "invalid referrer", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - }, - "referee": "invalid", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - "referee": referee, - }, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: referralCampUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} - -func TestMsgApplySignupAffiliateReward(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - leadGen := simapp.TestParamUsers["user3"].Address.String() - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, receiverAddr, receiverAddr, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - campClaims := getDefaultClaim(promoter) - campClaims["reward_type"] = types.RewardType_REWARD_TYPE_AFFILIATE_SIGNUP - campClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - campClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - - campUID := createCampaign(t, k, srv, ctx, promoter, campClaims, defaultCategoryCap) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": "invalid", - }, - err: types.ErrInTicketVerification, - }, - { - desc: "invalid lead generator", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - }, - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: leadGen, - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - }, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: campUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} - -func TestMsgApplySignupAffiliateeReward(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - affiliatee := simapp.TestParamUsers["user3"].Address.String() - affiliator := simapp.TestParamUsers["user4"].Address.String() - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, receiverAddr, receiverAddr, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - // referral signup campaign - affiliateSignupCampClaims := getDefaultClaim(promoter) - affiliateSignupCampClaims["reward_type"] = types.RewardType_REWARD_TYPE_AFFILIATE_SIGNUP - affiliateSignupCampClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - affiliateSignupCampClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - affiliateSignupCampUID := createCampaign(t, k, srv, ctx, promoter, affiliateSignupCampClaims, defaultCategoryCap) - - // affiliate campaign - affiliateCampClaims := getDefaultClaim(promoter) - affiliateCampClaims["category"] = types.RewardCategory_REWARD_CATEGORY_AFFILIATE - affiliateCampClaims["reward_type"] = types.RewardType_REWARD_TYPE_AFFILIATE - affiliateCampClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - affiliateCampClaims["reward_amount"] = types.RewardAmount{ - MainAccountAmount: sdkmath.NewInt(100), - UnlockPeriod: 0, - } - affiliateCampUID := createCampaign(t, k, srv, ctx, promoter, affiliateCampClaims, defaultCategoryCap) - - affiliateClaims := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: affiliatee, - SourceUID: affiliator, - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: affiliatee, - }, - }, - } - affiliateeTicket, err := simapp.CreateJwtTicket(affiliateClaims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: affiliateSignupCampUID, - Ticket: affiliateeTicket, - } - _, err = srv.GrantReward(wctx, reward) - require.NoError(t, err) - - rewardGrant, err := k.GetRewardsOfReceiverByPromoterAndCategory(ctx, promoterUID, affiliatee, types.RewardCategory_REWARD_CATEGORY_SIGNUP) - require.NoError(t, err) - require.Equal(t, types.RewardByCategory{ - UID: reward.Uid, - Addr: affiliatee, - RewardCategory: types.RewardCategory_REWARD_CATEGORY_SIGNUP, - }, rewardGrant[0]) - - require.True(t, k.HasRewardOfReceiverByPromoter(ctx, promoterUID, affiliatee, types.RewardCategory_REWARD_CATEGORY_SIGNUP)) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": "invalid", - }, - err: types.ErrInTicketVerification, - }, - { - desc: "invalid affiliator", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - }, - "affiliatee": "invalid", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - "affiliatee": affiliatee, - }, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: affiliateCampUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} - -func TestMsgApplyBetBonus(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - bettor := simapp.TestParamUsers["user2"].Address.String() - - bet := bettypes.Bet{ - Creator: bettor, - UID: uuid.NewString(), - MarketUID: uuid.NewString(), - Amount: sdkmath.NewInt(301), - Result: bettypes.Bet_RESULT_LOST, - Status: bettypes.Bet_STATUS_SETTLED, - Meta: bettypes.MetaData{ - IsMainMarket: true, - }, - } - tApp.BetKeeper.SetBet(ctx, bet, 1) - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, bettor, bettor, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - // referral signup campaign - betBonusCampClaims := getDefaultClaim(promoter) - betBonusCampClaims["category"] = types.RewardCategory_REWARD_CATEGORY_BET_DISCOUNT - betBonusCampClaims["reward_type"] = types.RewardType_REWARD_TYPE_BET_DISCOUNT - betBonusCampClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_PERCENTAGE - betBonusCampClaims["reward_amount"] = types.RewardAmount{ - MainAccountPercentage: sdk.NewDecWithPrec(10, 2), - UnlockPeriod: 0, - } - betBonusCampClaims["constraints"] = types.CampaignConstraints{ - MaxBetAmount: sdkmath.NewInt(300), - } - betBonusCampUID := createCampaign(t, k, srv, ctx, promoter, betBonusCampClaims, defaultCategoryCap) - - betBonusClaims := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: bettor, - SourceUID: "", - Meta: "bet bonus reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: bettor, - }, - }, - "bet_uid": bet.UID, - } - betBonusTicket, err := simapp.CreateJwtTicket(betBonusClaims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: betBonusCampUID, - Ticket: betBonusTicket, - } - _, err = srv.GrantReward(wctx, reward) - require.NoError(t, err) - - rewardGrant, err := k.GetRewardsOfReceiverByPromoterAndCategory(ctx, promoterUID, bettor, types.RewardCategory_REWARD_CATEGORY_BET_DISCOUNT) - require.NoError(t, err) - require.Equal(t, types.RewardByCategory{ - UID: reward.Uid, - Addr: bettor, - RewardCategory: types.RewardCategory_REWARD_CATEGORY_BET_DISCOUNT, - }, rewardGrant[0]) - - require.True(t, k.HasRewardOfReceiverByPromoter(ctx, promoterUID, bettor, types.RewardCategory_REWARD_CATEGORY_BET_DISCOUNT)) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": "invalid", - }, - err: types.ErrInTicketVerification, - }, - { - desc: "invalid bettor", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: bettor, - SourceUID: "", - Meta: "bet bonus reward for sample user", - }, - "bet_uid": "invalid", - }, - err: sdkerrtypes.ErrInvalidRequest, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: bettor, - SourceUID: "", - Meta: "bet bonus reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: bettor, - }, - }, - "bet_uid": bet.UID, - }, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: betBonusCampUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} - -func TestMsgApplySignupRewardSubaccount(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - campClaims := getDefaultClaim(promoter) - campClaims["reward_type"] = types.RewardType_REWARD_TYPE_SIGNUP - campClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - campClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - - campUID := createCampaign(t, k, srv, ctx, promoter, campClaims, defaultCategoryCap) - - _, err := tApp.SubaccountKeeper.CreateSubaccount(ctx, receiverAddr, receiverAddr, []subaccounttypes.LockedBalance{ - { - Amount: sdkmath.ZeroInt(), - UnlockTS: uint64(ctx.BlockTime().Add(60 * time.Minute).Unix()), - }, - }) - require.NoError(t, err) - - for _, tc := range []struct { - desc string - claims jwt.MapClaims - err error - }{ - { - desc: "invalid ticket", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": "invalid", - }, - err: types.ErrInTicketVerification, - }, - { - desc: "invalid receiver address", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: "invalid", - SourceUID: "source id", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: false, - ID: "", - Ignore: true, - }, - }, - }, - err: sdkerrtypes.ErrInvalidAddress, - }, - { - desc: "subaccount not exists", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: sample.AccAddress(), - SourceUID: "source id", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: false, - ID: "", - Ignore: true, - }, - }, - }, - }, - { - desc: "valid", - claims: jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "source id", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - }, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - ticket, err := simapp.CreateJwtTicket(tc.claims) - require.Nil(t, err) - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: campUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - if tc.err != nil { - require.ErrorContains(t, err, tc.err.Error()) - } else { - require.NoError(t, err) - } - }) - } -} - -func TestMsgApplySubaccountFunds(t *testing.T) { - tApp, k, ctx := setupKeeperAndApp(t) - srv := keeper.NewMsgServerImpl(*k) - ctx = ctx.WithBlockTime(time.Now()) - wctx := sdk.WrapSDKContext(ctx) - - promoter := simapp.TestParamUsers["user1"].Address.String() - receiverAddr := simapp.TestParamUsers["user2"].Address.String() - - rewardAmount := int64(100) - - campClaims := getDefaultClaim(promoter) - campClaims["type"] = types.RewardType_REWARD_TYPE_SIGNUP - campClaims["reward_type"] = types.RewardType_REWARD_TYPE_SIGNUP - campClaims["reward_amount_type"] = types.RewardAmountType_REWARD_AMOUNT_TYPE_FIXED - campClaims["reward_amount"] = types.RewardAmount{ - SubaccountAmount: sdkmath.NewInt(100), - UnlockPeriod: uint64(ctx.BlockTime().Add(10 * time.Minute).Unix()), - } - - campUID := createCampaign(t, k, srv, ctx, promoter, campClaims, defaultCategoryCap) - - claims := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "common": types.RewardPayloadCommon{ - Receiver: receiverAddr, - SourceUID: "source id", - Meta: "signup reward for sample user", - KycData: &sgetypes.KycDataPayload{ - Approved: true, - ID: receiverAddr, - }, - }, - } - - ticket, err := simapp.CreateJwtTicket(claims) - require.Nil(t, err) - - reward := &types.MsgGrantReward{ - Uid: uuid.NewString(), - Creator: promoter, - CampaignUid: campUID, - Ticket: ticket, - } - _, err = srv.GrantReward(wctx, reward) - require.NoError(t, err) - - subAccAddr, found := tApp.SubaccountKeeper.GetSubaccountByOwner(ctx, sdk.MustAccAddressFromBech32(receiverAddr)) - require.True(t, found) - - balance, found := tApp.SubaccountKeeper.GetAccountSummary(ctx, subAccAddr) - require.True(t, found) - - require.Equal(t, rewardAmount, balance.DepositedAmount.Int64()) -} diff --git a/x/reward/keeper/query_campaign_test.go b/x/reward/keeper/query_campaign_test.go deleted file mode 100644 index 7eedadf4..00000000 --- a/x/reward/keeper/query_campaign_test.go +++ /dev/null @@ -1,126 +0,0 @@ -package keeper_test - -import ( - "strconv" - "testing" - - "github.com/stretchr/testify/require" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/query" - - "github.com/sge-network/sge/testutil/nullify" - "github.com/sge-network/sge/x/reward/types" -) - -// Prevent strconv unused error -var _ = strconv.IntSize - -func TestCampaignQuerySingle(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNCampaign(k, ctx, 2) - for _, tc := range []struct { - desc string - request *types.QueryCampaignRequest - response *types.QueryCampaignResponse - err error - }{ - { - desc: "First", - request: &types.QueryCampaignRequest{ - Uid: msgs[0].UID, - }, - response: &types.QueryCampaignResponse{Campaign: msgs[0]}, - }, - { - desc: "Second", - request: &types.QueryCampaignRequest{ - Uid: msgs[1].UID, - }, - response: &types.QueryCampaignResponse{Campaign: msgs[1]}, - }, - { - desc: "KeyNotFound", - request: &types.QueryCampaignRequest{ - Uid: strconv.Itoa(100000), - }, - err: status.Error(codes.NotFound, "not found"), - }, - { - desc: "InvalidRequest", - err: status.Error(codes.InvalidArgument, "invalid request"), - }, - } { - t.Run(tc.desc, func(t *testing.T) { - response, err := k.Campaign(wctx, tc.request) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - require.Equal(t, - nullify.Fill(tc.response), - nullify.Fill(response), - ) - } - }) - } -} - -func TestCampaignQueryPaginated(t *testing.T) { - k, ctx := setupKeeper(t) - wctx := sdk.WrapSDKContext(ctx) - msgs := createNCampaign(k, ctx, 5) - - request := func(next []byte, offset, limit uint64, total bool) *types.QueryCampaignsRequest { - return &types.QueryCampaignsRequest{ - Pagination: &query.PageRequest{ - Key: next, - Offset: offset, - Limit: limit, - CountTotal: total, - }, - } - } - t.Run("ByOffset", func(t *testing.T) { - step := 2 - for i := 0; i < len(msgs); i += step { - resp, err := k.Campaigns(wctx, request(nil, uint64(i), uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Campaign), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Campaign), - ) - } - }) - t.Run("ByKey", func(t *testing.T) { - step := 2 - var next []byte - for i := 0; i < len(msgs); i += step { - resp, err := k.Campaigns(wctx, request(next, 0, uint64(step), false)) - require.NoError(t, err) - require.LessOrEqual(t, len(resp.Campaign), step) - require.Subset(t, - nullify.Fill(msgs), - nullify.Fill(resp.Campaign), - ) - next = resp.Pagination.NextKey - } - }) - t.Run("Total", func(t *testing.T) { - resp, err := k.Campaigns(wctx, request(nil, 0, 0, true)) - require.NoError(t, err) - require.Equal(t, len(msgs), int(resp.Pagination.Total)) - require.ElementsMatch(t, - nullify.Fill(msgs), - nullify.Fill(resp.Campaign), - ) - }) - t.Run("InvalidRequest", func(t *testing.T) { - _, err := k.Campaigns(wctx, nil) - require.ErrorIs(t, err, status.Error(codes.InvalidArgument, "invalid request")) - }) -} diff --git a/x/reward/simulation/proposals_test.go b/x/reward/simulation/proposals_test.go deleted file mode 100644 index a2e01a33..00000000 --- a/x/reward/simulation/proposals_test.go +++ /dev/null @@ -1,43 +0,0 @@ -package simulation_test - -import ( - "fmt" - "math/rand" - "testing" - - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/address" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/reward/simulation" - "github.com/sge-network/sge/x/reward/types" -) - -func TestProposalMsgs(t *testing.T) { - // initialize parameters - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - ctx := sdk.NewContext(nil, tmproto.Header{}, true, nil) - accounts := simtypes.RandomAccounts(r, 3) - - // execute ProposalMsgs function - weightedProposalMsgs := simulation.ProposalMsgs() - require.Equal(t, len(weightedProposalMsgs), 1) - - w0 := weightedProposalMsgs[0] - - // tests w0 interface: - require.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) - require.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) - - msg := w0.MsgSimulatorFn()(r, ctx, accounts) - msgUpdateParams, ok := msg.(*types.MsgUpdateParams) - require.True(t, ok) - - fmt.Println(msgUpdateParams) - require.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) -} diff --git a/x/reward/types/campaign_authorizaton_test.go b/x/reward/types/campaign_authorizaton_test.go deleted file mode 100644 index 092f805e..00000000 --- a/x/reward/types/campaign_authorizaton_test.go +++ /dev/null @@ -1,98 +0,0 @@ -package types_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - authz "github.com/cosmos/cosmos-sdk/x/authz" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/reward/types" -) - -func TestCreateCampaignGrantValidateBasic(t *testing.T) { - tests := []struct { - name string - spendLimit sdkmath.Int - expiration time.Time - err error - }{ - { - name: "invalid coins", - spendLimit: sdkmath.Int{}, - expiration: time.Now().Add(5 * time.Minute), - err: sdkerrtypes.ErrInvalidCoins, - }, - { - name: "valid", - spendLimit: sdkmath.NewInt(10000), - expiration: time.Now().Add(5 * time.Minute), - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - expTime := tt.expiration - msgGrant, err := authz.NewMsgGrant( - sdk.MustAccAddressFromBech32(sample.AccAddress()), - sdk.MustAccAddressFromBech32(sample.AccAddress()), - &types.CreateCampaignAuthorization{ - SpendLimit: tt.spendLimit, - }, - &expTime) - require.NoError(t, err) - - err = msgGrant.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestUpdateCampaignGrantValidateBasic(t *testing.T) { - tests := []struct { - name string - spendLimit sdkmath.Int - expiration time.Time - err error - }{ - { - name: "invalid coins", - spendLimit: sdkmath.Int{}, - expiration: time.Now().Add(5 * time.Minute), - err: sdkerrtypes.ErrInvalidCoins, - }, - { - name: "valid", - spendLimit: sdkmath.NewInt(10000), - expiration: time.Now().Add(5 * time.Minute), - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - expTime := tt.expiration - msgGrant, err := authz.NewMsgGrant( - sdk.MustAccAddressFromBech32(sample.AccAddress()), - sdk.MustAccAddressFromBech32(sample.AccAddress()), - &types.UpdateCampaignAuthorization{ - SpendLimit: tt.spendLimit, - }, - &expTime) - require.NoError(t, err) - - err = msgGrant.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/reward/types/messages_campaign_test.go b/x/reward/types/messages_campaign_test.go deleted file mode 100644 index e542357a..00000000 --- a/x/reward/types/messages_campaign_test.go +++ /dev/null @@ -1,136 +0,0 @@ -package types_test - -import ( - "testing" - - sdkmath "cosmossdk.io/math" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/sge-network/sge/testutil/sample" - - "github.com/sge-network/sge/x/reward/types" -) - -func TestMsgCreateCampaign_ValidateBasic(t *testing.T) { - poolBalance := sdkmath.NewInt(100) - tests := []struct { - name string - msg types.MsgCreateCampaign - err error - }{ - { - name: "invalid address", - msg: types.MsgCreateCampaign{ - Creator: "invalid_address", - Uid: uuid.NewString(), - Ticket: "ticket", - TotalFunds: poolBalance, - }, - err: sdkerrors.ErrInvalidAddress, - }, - { - name: "invalid uid", - msg: types.MsgCreateCampaign{ - Creator: sample.AccAddress(), - Uid: "invalid uid", - Ticket: "ticket", - TotalFunds: poolBalance, - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "invalid ticket", - msg: types.MsgCreateCampaign{ - Creator: sample.AccAddress(), - Uid: uuid.NewString(), - Ticket: "", - TotalFunds: poolBalance, - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "negative pool amount", - msg: types.MsgCreateCampaign{ - Creator: sample.AccAddress(), - Uid: uuid.NewString(), - Ticket: "ticket", - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "valid address", - msg: types.MsgCreateCampaign{ - Creator: sample.AccAddress(), - Uid: uuid.NewString(), - Ticket: "ticket", - TotalFunds: poolBalance, - }, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} - -func TestMsgUpdateCampaign_ValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgUpdateCampaign - err error - }{ - { - name: "invalid address", - msg: types.MsgUpdateCampaign{ - Creator: "invalid_address", - Uid: uuid.NewString(), - Ticket: "ticket", - }, - err: sdkerrors.ErrInvalidAddress, - }, - { - name: "invalid uid", - msg: types.MsgUpdateCampaign{ - Creator: sample.AccAddress(), - Uid: "invalid uid", - Ticket: "ticket", - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "invalid ticket", - msg: types.MsgUpdateCampaign{ - Creator: sample.AccAddress(), - Uid: uuid.NewString(), - Ticket: "", - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "valid address", - msg: types.MsgUpdateCampaign{ - Creator: sample.AccAddress(), - Uid: uuid.NewString(), - Ticket: "ticket", - }, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/reward/types/messages_promoter_test.go b/x/reward/types/messages_promoter_test.go deleted file mode 100644 index bc0b5afb..00000000 --- a/x/reward/types/messages_promoter_test.go +++ /dev/null @@ -1,62 +0,0 @@ -package types_test - -import ( - "testing" - - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/google/uuid" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/reward/types" - "github.com/stretchr/testify/require" -) - -func TestMsgSetPromoterConf_ValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgSetPromoterConf - err error - }{ - { - name: "invalid address", - msg: types.MsgSetPromoterConf{ - Creator: "invalid_address", - }, - err: sdkerrors.ErrInvalidAddress, - }, - { - name: "invalid campaign uid", - msg: types.MsgSetPromoterConf{ - Creator: sample.AccAddress(), - Uid: "bad uid", - Ticket: "ticket", - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "invalid ticket", - msg: types.MsgSetPromoterConf{ - Creator: sample.AccAddress(), - Uid: uuid.NewString(), - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "valid address", - msg: types.MsgSetPromoterConf{ - Creator: sample.AccAddress(), - Uid: uuid.NewString(), - Ticket: "ticket", - }, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/reward/types/messages_reward_test.go b/x/reward/types/messages_reward_test.go deleted file mode 100644 index 28d99891..00000000 --- a/x/reward/types/messages_reward_test.go +++ /dev/null @@ -1,74 +0,0 @@ -package types_test - -import ( - "testing" - - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/google/uuid" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/reward/types" - "github.com/stretchr/testify/require" -) - -func TestMsgGrantReward_ValidateBasic(t *testing.T) { - tests := []struct { - name string - msg types.MsgGrantReward - err error - }{ - { - name: "invalid address", - msg: types.MsgGrantReward{ - Creator: "invalid_address", - }, - err: sdkerrors.ErrInvalidAddress, - }, - { - name: "invalid campaign uid", - msg: types.MsgGrantReward{ - Creator: sample.AccAddress(), - CampaignUid: "bad uid", - Uid: uuid.NewString(), - Ticket: "ticket", - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "invalid reward uid", - msg: types.MsgGrantReward{ - Creator: sample.AccAddress(), - CampaignUid: uuid.NewString(), - Uid: "bad uid", - Ticket: "ticket", - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "invalid ticket", - msg: types.MsgGrantReward{ - Creator: sample.AccAddress(), - CampaignUid: uuid.NewString(), - }, - err: sdkerrors.ErrInvalidRequest, - }, - { - name: "valid address", - msg: types.MsgGrantReward{ - Creator: sample.AccAddress(), - CampaignUid: uuid.NewString(), - Uid: uuid.NewString(), - Ticket: "ticket", - }, - }, - } - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - err := tt.msg.ValidateBasic() - if tt.err != nil { - require.ErrorIs(t, err, tt.err) - return - } - require.NoError(t, err) - }) - } -} diff --git a/x/subaccount/genesis_test.go b/x/subaccount/genesis_test.go deleted file mode 100644 index 79b4fc17..00000000 --- a/x/subaccount/genesis_test.go +++ /dev/null @@ -1,62 +0,0 @@ -package subaccount_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/subaccount" - "github.com/sge-network/sge/x/subaccount/types" -) - -var ( - subAccOwner = sample.NativeAccAddress() - micro = sdkmath.NewInt(1_000_000) - subAccFunds = sdkmath.NewInt(10_000).Mul(micro) - subAccAddr = types.NewAddressFromSubaccount(1) -) - -func TestGenesis(t *testing.T) { - app, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - k := app.SubaccountKeeper - - wantGenesis := types.GenesisState{ - Params: types.DefaultParams(), - Subaccounts: []types.GenesisSubaccount{ - { - Address: subAccAddr.String(), - Owner: subAccOwner.String(), - Balance: types.AccountSummary{ - DepositedAmount: subAccFunds, - SpentAmount: sdkmath.ZeroInt(), - WithdrawnAmount: sdkmath.ZeroInt(), - LostAmount: sdkmath.ZeroInt(), - }, - LockedBalances: []types.LockedBalance{ - { - UnlockTS: uint64(time.Now().Add(24 * time.Hour).Unix()), - Amount: subAccFunds, - }, - }, - }, - }, - SubaccountId: 2, // next subaccount id - } - - subaccount.InitGenesis(ctx, *k, wantGenesis) - - require.Equal(t, wantGenesis.SubaccountId, k.Peek(ctx)) - require.Equal(t, wantGenesis.Params, k.GetParams(ctx)) - require.Len(t, wantGenesis.Subaccounts, 1) - require.Equal(t, wantGenesis.Subaccounts[0], k.GetAllSubaccounts(ctx)[0]) - - exportedGenesis := subaccount.ExportGenesis(ctx, *k) - require.Equal(t, wantGenesis, *exportedGenesis) -} diff --git a/x/subaccount/handler.go b/x/subaccount/handler.go deleted file mode 100644 index beb68a13..00000000 --- a/x/subaccount/handler.go +++ /dev/null @@ -1,50 +0,0 @@ -package subaccount - -import ( - "fmt" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrtypes "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/x/subaccount/keeper" - "github.com/sge-network/sge/x/subaccount/types" -) - -// NewHandler initialize a new sdk.handler instance for registered messages -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - _ = ctx - - switch msg := msg.(type) { - case *types.MsgCreate: - res, err := msgServer.Create(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgTopUp: - res, err := msgServer.TopUp(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgWithdrawUnlockedBalances: - res, err := msgServer.WithdrawUnlockedBalances(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgWager: - res, err := msgServer.Wager(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgHouseDeposit: - res, err := msgServer.HouseDeposit(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgHouseWithdraw: - res, err := msgServer.HouseWithdraw(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgUpdateParams: - res, err := msgServer.UpdateParams(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrtypes.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/subaccount/keeper/balance_test.go b/x/subaccount/keeper/balance_test.go deleted file mode 100644 index 949c60a4..00000000 --- a/x/subaccount/keeper/balance_test.go +++ /dev/null @@ -1,49 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - sdkmath "cosmossdk.io/math" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/subaccount/types" - "github.com/spf13/cast" - "github.com/stretchr/testify/require" -) - -func TestUnlockedBalanceQuery(t *testing.T) { - _, k, ctx := setupKeeperAndApp(t) - - subAccAddr := sample.NativeAccAddress() - blockTime := time.Now() - ctx = ctx.WithBlockTime(blockTime) - k.SetLockedBalances(ctx, subAccAddr, []types.LockedBalance{ - { - UnlockTS: cast.ToUint64(blockTime.Unix()), - Amount: sdkmath.NewInt(100), - }, - { - UnlockTS: cast.ToUint64(blockTime.Add(1 * time.Second).Unix()), - Amount: sdkmath.NewInt(200), - }, - { - UnlockTS: cast.ToUint64(blockTime.Add(-1 * time.Second).Unix()), - Amount: sdkmath.NewInt(1000), - }, - }) - - locked, _ := k.GetBalances(ctx, subAccAddr, types.LockedBalanceStatus_LOCKED_BALANCE_STATUS_LOCKED) - require.Equal(t, []types.LockedBalance{ - { - UnlockTS: cast.ToUint64(blockTime.Unix()), - Amount: sdkmath.NewInt(100), - }, - { - UnlockTS: cast.ToUint64(blockTime.Add(1 * time.Second).Unix()), - Amount: sdkmath.NewInt(200), - }, - }, locked) - - _, unlockedAmount := k.GetBalances(ctx, subAccAddr, types.LockedBalanceStatus_LOCKED_BALANCE_STATUS_UNLOCKED) - require.Equal(t, int64(1000), unlockedAmount.Int64()) -} diff --git a/x/subaccount/keeper/export_test.go b/x/subaccount/keeper/export_test.go deleted file mode 100644 index d22f197e..00000000 --- a/x/subaccount/keeper/export_test.go +++ /dev/null @@ -1,5 +0,0 @@ -package keeper - -// KeeperTest is a wrapper object for the keeper, It is being used -// to export unexported methods of the keeper -type KeeperTest = Keeper diff --git a/x/subaccount/keeper/keeper_test.go b/x/subaccount/keeper/keeper_test.go deleted file mode 100644 index 06d290a5..00000000 --- a/x/subaccount/keeper/keeper_test.go +++ /dev/null @@ -1,20 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/sge-network/sge/testutil/simapp" - - "github.com/sge-network/sge/x/subaccount/keeper" -) - -func setupKeeperAndApp(t testing.TB) (*simapp.TestApp, *keeper.KeeperTest, sdk.Context) { - tApp, ctx, err := simapp.GetTestObjects() - require.NoError(t, err) - - return tApp, tApp.SubaccountKeeper, ctx.WithBlockTime(time.Now()) -} diff --git a/x/subaccount/keeper/msg_server_balance_test.go b/x/subaccount/keeper/msg_server_balance_test.go deleted file mode 100644 index ff47dad5..00000000 --- a/x/subaccount/keeper/msg_server_balance_test.go +++ /dev/null @@ -1,291 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/bank/testutil" - - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/subaccount/keeper" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestMsgServer_WithdrawUnlockedBalances(t *testing.T) { - creatorAddr := sample.NativeAccAddress() - subaccountOwner := sample.NativeAccAddress() - lockedTime := time.Now().Add(time.Hour * 24 * 365).UTC() - lockedTime2 := time.Now().Add(time.Hour * 24 * 365 * 2).UTC() - - app, _, msgServer, ctx := setupMsgServerAndApp(t) - - t.Log("funder account") - err := testutil.FundAccount(app.BankKeeper, ctx, creatorAddr, sdk.NewCoins(sdk.NewInt64Coin("usge", 1000))) - require.NoError(t, err) - - t.Log("Create sub account") - _, err = msgServer.Create(sdk.WrapSDKContext(ctx), &types.MsgCreate{ - Creator: creatorAddr.String(), - Owner: subaccountOwner.String(), - LockedBalances: []types.LockedBalance{ - { - Amount: sdkmath.NewInt(100), - UnlockTS: uint64(lockedTime.Unix()), - }, - { - Amount: sdkmath.NewInt(200), - UnlockTS: uint64(lockedTime2.Unix()), - }, - }, - }) - require.NoError(t, err) - - t.Log("check balance of sub account") - subAccountAddr := types.NewAddressFromSubaccount(1) - balance := app.BankKeeper.GetBalance(ctx, subAccountAddr, "usge") - require.Equal(t, sdkmath.NewInt(300), balance.Amount) - - t.Log("check balance of subaccount owner") - balance = app.BankKeeper.GetBalance(ctx, subaccountOwner, "usge") - require.Equal(t, sdkmath.NewInt(0), balance.Amount) - - t.Log("Withdraw unlocked balances, with 0 expires") - _, err = msgServer.WithdrawUnlockedBalances(sdk.WrapSDKContext(ctx), &types.MsgWithdrawUnlockedBalances{ - Creator: subaccountOwner.String(), - }) - require.ErrorContains(t, err, types.ErrNothingToWithdraw.Error()) - - t.Log("balance of subaccount owner should be zero") - balance = app.BankKeeper.GetBalance(ctx, subaccountOwner, "usge") - require.True(t, balance.IsZero()) - - t.Log("expire first locked balance") - ctx = ctx.WithBlockTime(lockedTime.Add(1 * time.Second)) - t.Log("Withdraw unlocked balances, with 1 expires") - _, err = msgServer.WithdrawUnlockedBalances(sdk.WrapSDKContext(ctx), &types.MsgWithdrawUnlockedBalances{ - Creator: subaccountOwner.String(), - }) - require.NoError(t, err) - - t.Log("balance of subaccount owner should be the same as first locked balance") - balance = app.BankKeeper.GetBalance(ctx, subaccountOwner, "usge") - require.True(t, balance.Amount.Equal(sdkmath.NewInt(100)), balance.Amount.String()) - - t.Log("expire second locked balance, also force money to be spent") - // we force some money to be spent on the subaccount to correctly test - // that if the amount is unlocked but spent, it will not be withdrawable. - subAccountAddress := types.NewAddressFromSubaccount(1) - subaccountBalance, exists := app.SubaccountKeeper.GetAccountSummary(ctx, subAccountAddress) - require.True(t, exists) - require.NoError(t, subaccountBalance.Spend(sdkmath.NewInt(100))) - app.SubaccountKeeper.SetAccountSummary(ctx, subAccountAddr, subaccountBalance) - - ctx = ctx.WithBlockTime(lockedTime2.Add(1 * time.Second)) - t.Log("Withdraw unlocked balances, with 2 expires") - _, err = msgServer.WithdrawUnlockedBalances(sdk.WrapSDKContext(ctx), &types.MsgWithdrawUnlockedBalances{ - Creator: subaccountOwner.String(), - }) - require.NoError(t, err) - - t.Log("balance of subaccount owner should be the same as both expired locked balances minus spent money") - balance = app.BankKeeper.GetBalance(ctx, subaccountOwner, "usge") - require.Equal(t, sdkmath.NewInt(200), balance.Amount) - - t.Log("check bank balance of sub account address") - balance = app.BankKeeper.GetBalance(ctx, subAccountAddr, "usge") - require.Equal(t, sdkmath.NewInt(100), balance.Amount) - - t.Log("after unspending the money of the subaccount, the owner will be able to get the money back when withdrawing") - subaccountBalance, exists = app.SubaccountKeeper.GetAccountSummary(ctx, subAccountAddress) - require.True(t, exists) - require.NoError(t, subaccountBalance.Unspend(sdkmath.NewInt(100))) - app.SubaccountKeeper.SetAccountSummary(ctx, subAccountAddr, subaccountBalance) - _, err = msgServer.WithdrawUnlockedBalances(sdk.WrapSDKContext(ctx), &types.MsgWithdrawUnlockedBalances{ - Creator: subaccountOwner.String(), - }) - require.NoError(t, err) - - // check balances - balance = app.BankKeeper.GetBalance(ctx, subAccountAddr, "usge") - require.Equal(t, sdkmath.NewInt(0), balance.Amount) - subaccountBalance, exists = app.SubaccountKeeper.GetAccountSummary(ctx, subAccountAddress) - require.True(t, exists) - require.Equal(t, sdkmath.NewInt(300), subaccountBalance.WithdrawnAmount) - - // check that the owner has received the last money - balance = app.BankKeeper.GetBalance(ctx, subaccountOwner, "usge") - require.Equal(t, sdkmath.NewInt(300), balance.Amount) - - // check that the owner can't withdraw again - _, err = msgServer.WithdrawUnlockedBalances(sdk.WrapSDKContext(ctx), &types.MsgWithdrawUnlockedBalances{ - Creator: subaccountOwner.String(), - }) - require.ErrorContains(t, err, types.ErrNothingToWithdraw.Error()) -} - -func TestMsgServer_WithdrawUnlockedBalances_Errors(t *testing.T) { - creatorAddr := sample.AccAddress() - tests := []struct { - name string - msg types.MsgWithdrawUnlockedBalances - prepare func(ctx sdk.Context, keeper keeper.Keeper) - expectedErr string - }{ - { - name: "sub account does not exist", - msg: types.MsgWithdrawUnlockedBalances{ - Creator: creatorAddr, - }, - prepare: func(_ sdk.Context, _ keeper.Keeper) {}, - expectedErr: types.ErrSubaccountDoesNotExist.Error(), - }, - } - - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - _, k, msgServer, ctx := setupMsgServerAndApp(t) - - tt.prepare(ctx, *k) - - _, err := msgServer.WithdrawUnlockedBalances(sdk.WrapSDKContext(ctx), &tt.msg) - require.ErrorContains(t, err, tt.expectedErr) - }) - } -} - -func TestMsgServerTopUp_HappyPath(t *testing.T) { - afterTime := uint64(time.Now().Add(10 * time.Minute).Unix()) - creatirAddr := sample.NativeAccAddress() - subaccount := sample.AccAddress() - - app, k, msgServer, ctx := setupMsgServerAndApp(t) - - // Funder - err := testutil.FundAccount(app.BankKeeper, ctx, creatirAddr, sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(100000000)))) - require.NoError(t, err) - - // Create subaccount - msg := &types.MsgCreate{ - Creator: creatirAddr.String(), - Owner: subaccount, - LockedBalances: []types.LockedBalance{}, - } - _, err = msgServer.Create(sdk.WrapSDKContext(ctx), msg) - require.NoError(t, err) - - subAccountAddr := types.NewAddressFromSubaccount(1) - - balance, exists := k.GetAccountSummary(ctx, subAccountAddr) - require.True(t, exists) - require.Equal(t, sdkmath.NewInt(0), balance.DepositedAmount) - balances, _ := k.GetBalances(ctx, subAccountAddr, types.LockedBalanceStatus_LOCKED_BALANCE_STATUS_LOCKED) - require.Len(t, balances, 0) - - msgTopUp := &types.MsgTopUp{ - Creator: creatirAddr.String(), - Address: subaccount, - LockedBalances: []types.LockedBalance{ - { - UnlockTS: afterTime, - Amount: sdkmath.NewInt(123), - }, - }, - } - _, err = msgServer.TopUp(sdk.WrapSDKContext(ctx), msgTopUp) - require.NoError(t, err) - - // Check balance - balance, exists = k.GetAccountSummary(ctx, subAccountAddr) - require.True(t, exists) - require.Equal(t, sdkmath.NewInt(123), balance.DepositedAmount) - balances, _ = k.GetBalances(ctx, subAccountAddr, types.LockedBalanceStatus_LOCKED_BALANCE_STATUS_LOCKED) - require.Len(t, balances, 1) - require.True(t, afterTime == balances[0].UnlockTS) - require.Equal(t, sdkmath.NewInt(123), balances[0].Amount) -} - -func TestNewMsgServerTopUp_Errors(t *testing.T) { - beforeTime := uint64(time.Now().Add(-10 * time.Minute).Unix()) - afterTime := uint64(time.Now().Add(10 * time.Minute).Unix()) - - creatorAddr := sample.AccAddress() - subaccount := sample.AccAddress() - - tests := []struct { - name string - msg types.MsgTopUp - prepare func(ctx sdk.Context, msgServer types.MsgServer) - expectedErr string - }{ - { - name: "unlock time is expired", - msg: types.MsgTopUp{ - Creator: creatorAddr, - Address: subaccount, - LockedBalances: []types.LockedBalance{ - { - UnlockTS: beforeTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - prepare: func(_ sdk.Context, _ types.MsgServer) {}, - expectedErr: types.ErrUnlockTokenTimeExpired.Error(), - }, - { - name: "sub account does not exist", - msg: types.MsgTopUp{ - Creator: creatorAddr, - Address: subaccount, - LockedBalances: []types.LockedBalance{ - { - UnlockTS: afterTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - prepare: func(_ sdk.Context, _ types.MsgServer) {}, - expectedErr: types.ErrSubaccountDoesNotExist.Error(), - }, - { - name: "creator has not enough balance", - msg: types.MsgTopUp{ - Creator: creatorAddr, - Address: subaccount, - LockedBalances: []types.LockedBalance{ - { - UnlockTS: afterTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - prepare: func(ctx sdk.Context, msgServer types.MsgServer) { - // Create subaccount - msg := &types.MsgCreate{ - Creator: creatorAddr, - Owner: subaccount, - LockedBalances: []types.LockedBalance{}, - } - _, err := msgServer.Create(sdk.WrapSDKContext(ctx), msg) - require.NoError(t, err) - }, - expectedErr: "spendable balance is smaller than 123usge", - }, - } - - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - _, _, msgServer, ctx := setupMsgServerAndApp(t) - - tt.prepare(ctx, msgServer) - - _, err := msgServer.TopUp(sdk.WrapSDKContext(ctx), &tt.msg) - require.ErrorContains(t, err, tt.expectedErr) - }) - } -} diff --git a/x/subaccount/keeper/msg_server_bet_test.go b/x/subaccount/keeper/msg_server_bet_test.go deleted file mode 100644 index 20162ae0..00000000 --- a/x/subaccount/keeper/msg_server_bet_test.go +++ /dev/null @@ -1,286 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/bank/testutil" - - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - bettypes "github.com/sge-network/sge/x/bet/types" - marketkeeper "github.com/sge-network/sge/x/market/keeper" - markettypes "github.com/sge-network/sge/x/market/types" - "github.com/sge-network/sge/x/subaccount/types" -) - -var ( - testMarketUID = "5db09053-2901-4110-8fb5-c14e21f8d555" - testOddsUID1 = "6db09053-2901-4110-8fb5-c14e21f8d666" - testOddsUID2 = "5e31c60f-2025-48ce-ae79-1dc110f16358" - testOddsUID3 = "6e31c60f-2025-48ce-ae79-1dc110f16354" - testMarketOdds = []*markettypes.Odds{ - {UID: testOddsUID1, Meta: "Odds 1"}, - {UID: testOddsUID2, Meta: "Odds 2"}, - {UID: testOddsUID3, Meta: "Odds 3"}, - } - testSelectedBetOdds = &bettypes.BetOdds{ - UID: testOddsUID1, - MarketUID: testMarketUID, - Value: "4.20", - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - } - testBetOdds = &[]bettypes.BetOdds{ - { - UID: testOddsUID1, - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - { - UID: testOddsUID2, - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - { - UID: testOddsUID3, - MaxLossMultiplier: sdkmath.LegacyMustNewDecFromStr("0.1"), - }, - } - testCreator string -) - -var ( - micro = sdkmath.NewInt(1_000_000) - subAccFunds = sdkmath.NewInt(10_000).Mul(micro) - subAccAddr = types.NewAddressFromSubaccount(1) -) - -func TestMsgServer_Bet(t *testing.T) { - app, k, msgServer, ctx := setupMsgServerAndApp(t) - - parm := k.GetParams(ctx) - parm.WagerEnabled = true - k.SetParams(ctx, parm) - - subAccOwner := simapp.TestParamUsers["user2"].Address - subAccFunder := simapp.TestParamUsers["user1"].Address - - initialOwnerBalance := app.BankKeeper.GetBalance(ctx, subAccOwner, params.DefaultBondDenom).Amount - - // do subaccount creation - require.NoError( - t, - testutil.FundAccount( - app.BankKeeper, - ctx, - subAccFunder, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, subAccFunds)), - ), - ) - - _, err := msgServer.Create(sdk.WrapSDKContext(ctx), &types.MsgCreate{ - Creator: subAccFunder.String(), - Owner: subAccOwner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: uint64(time.Now().Add(24 * time.Hour).Unix()), - Amount: subAccFunds, - }, - }, - }) - require.NoError(t, err) - - // add market - market := addTestMarket(t, app, ctx, true) - - // start betting using the subaccount - betAmt := sdkmath.NewInt(1000).Mul(micro) - halfBetAmt := betAmt.Quo(sdkmath.NewInt(2)) - - _, err = msgServer.Wager( - sdk.WrapSDKContext(ctx), - testMsgWager(t, subAccOwner, betAmt, halfBetAmt, halfBetAmt), - ) - require.NoError(t, err) - - afterBetOwnerBalance := app.BankKeeper.GetBalance(ctx, subAccOwner, params.DefaultBondDenom).Amount - - require.Equal(t, initialOwnerBalance.Sub(halfBetAmt).Int64(), afterBetOwnerBalance.Int64()) - - // check subaccount accSumm - accSumm, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - betFees := sdkmath.NewInt(100) - - require.Equal(t, accSumm.SpentAmount, sdkmath.ZeroInt()) - require.Equal(t, accSumm.WithdrawnAmount, halfBetAmt) - - t.Run("resolve market – bettor wins", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - // resolve the market – bettor wins - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID1}, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - err := app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - - // now we check the subaccount accSumm - accSumm, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.Equal(t, halfBetAmt.String(), accSumm.WithdrawnAmount.String()) - - // now we want the user to have some balance which is the payout - winningAmount := betAmt.Sub(betFees).ToLegacyDec(). - Mul(sdkmath.LegacyMustNewDecFromStr("4.2")).TruncateInt(). - Sub(halfBetAmt) - - ownerBalance := app.BankKeeper.GetBalance(ctx, subAccOwner, params.DefaultBondDenom).Amount - require.Equal(t, - initialOwnerBalance.Add(winningAmount).Int64(), // 4.2 - 1 = 3.2 - ownerBalance.Int64(), - ) - }) - - // resolve the market – bettor loses - t.Run("resolve market – bettor loses", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - // resolve the market – bettor loses - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID2}, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - err := app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - - // now we check the subaccount balance - balance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.Equal(t, sdkmath.ZeroInt(), balance.SpentAmount) - require.Equal(t, sdkmath.ZeroInt(), balance.LostAmount) - require.Equal(t, halfBetAmt, balance.WithdrawnAmount) - // the owner has no balances - ownerBalance := app.BankKeeper.GetBalance(ctx, subAccOwner, params.DefaultBondDenom).Amount - require.Equal(t, - initialOwnerBalance.Sub(halfBetAmt).Int64(), - ownerBalance.Int64(), - ) - }) - t.Run("resolve market – refund", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - // resolve the market – refund - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID1}, - Status: markettypes.MarketStatus_MARKET_STATUS_CANCELED, - }) - err := app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - - // now we check the subaccount balance - balance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.Equal(t, balance.SpentAmount, sdkmath.ZeroInt()) - - ownerBalance := app.BankKeeper.GetBalance(ctx, subAccOwner, params.DefaultBondDenom).Amount - - // the owner balance is zero - require.Equal(t, initialOwnerBalance.Add(halfBetAmt).Int64(), ownerBalance.Int64()) - }) -} - -func addTestMarket(t testing.TB, tApp *simapp.TestApp, ctx sdk.Context, prefund bool) *markettypes.Market { - testCreator = simapp.TestParamUsers["user1"].Address.String() - testAddMarketClaim := jwt.MapClaims{ - "uid": testMarketUID, - "start_ts": 1111111111, - "end_ts": uint64(ctx.BlockTime().Unix()) + 1000, - "odds": testMarketOdds, - "exp": 9999999999, - "iat": 7777777777, - "meta": "Winner of x:y", - "status": markettypes.MarketStatus_MARKET_STATUS_ACTIVE, - } - testAddMarketTicket, err := createJwtTicket(testAddMarketClaim) - require.Nil(t, err) - - testAddMarket := &markettypes.MsgAdd{ - Creator: testCreator, - Ticket: testAddMarketTicket, - } - wctx := sdk.WrapSDKContext(ctx) - marketSrv := marketkeeper.NewMsgServerImpl(*tApp.MarketKeeper) - resAddMarket, err := marketSrv.Add(wctx, testAddMarket) - require.Nil(t, err) - require.NotNil(t, resAddMarket) - - if prefund { - // add liquidity - err = testutil.FundAccount( - tApp.BankKeeper, - ctx, - simapp.TestParamUsers["user1"].Address, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(1_000_000).Mul(micro))), - ) - require.NoError(t, err) - _, err = tApp.OrderbookKeeper.InitiateOrderBookParticipation( - ctx, - simapp.TestParamUsers["user1"].Address, - resAddMarket.Data.UID, - sdkmath.NewInt(1_000_000).Mul(micro), - sdkmath.NewInt(1), - ) - require.NoError(t, err) - } - return resAddMarket.Data -} - -func createJwtTicket(claim jwt.MapClaims) (string, error) { - token := jwt.NewWithClaims(jwt.SigningMethodEdDSA, claim) - return token.SignedString(simapp.TestOVMPrivateKeys[0]) -} - -func testMsgWager(t testing.TB, bettor sdk.AccAddress, amount sdkmath.Int, mainAccDeduct, subAccDeduct sdkmath.Int) *types.MsgWager { - betTicket, err := createJwtTicket(jwt.MapClaims{ - "exp": 9999999999, - "iat": 7777777777, - "selected_odds": testSelectedBetOdds, - "kyc_data": &sgetypes.KycDataPayload{ - Approved: true, - ID: bettor.String(), - }, - "all_odds": testBetOdds, - }) - require.NoError(t, err) - - subAccTicket, err := createJwtTicket(jwt.MapClaims{ - "exp": 9999999999, - "iat": 7777777777, - "msg": bettypes.MsgWager{ - Creator: bettor.String(), - Props: &bettypes.WagerProps{ - UID: uuid.NewString(), - Amount: amount, - Ticket: betTicket, - }, - }, - "mainacc_deduct_amount": mainAccDeduct, - "subacc_deduct_amount": subAccDeduct, - }) - require.NoError(t, err) - - return &types.MsgWager{ - Creator: bettor.String(), - Ticket: subAccTicket, - } -} diff --git a/x/subaccount/keeper/msg_server_house_test.go b/x/subaccount/keeper/msg_server_house_test.go deleted file mode 100644 index c0213f6a..00000000 --- a/x/subaccount/keeper/msg_server_house_test.go +++ /dev/null @@ -1,374 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/golang-jwt/jwt" - "github.com/google/uuid" - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/bank/testutil" - - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/testutil/simapp" - sgetypes "github.com/sge-network/sge/types" - betmodulekeeper "github.com/sge-network/sge/x/bet/keeper" - bettypes "github.com/sge-network/sge/x/bet/types" - housetypes "github.com/sge-network/sge/x/house/types" - markettypes "github.com/sge-network/sge/x/market/types" - "github.com/sge-network/sge/x/subaccount/types" -) - -var ( - bettor1 = sample.NativeAccAddress() - bettor1Funds = sdkmath.NewInt(10).Mul(micro) -) - -func TestMsgServer(t *testing.T) { - app, k, msgServer, ctx := setupMsgServerAndApp(t) - - parm := k.GetParams(ctx) - parm.DepositEnabled = true - k.SetParams(ctx, parm) - - subAccOwner := sample.NativeAccAddress() - subAccFunder := sample.NativeAccAddress() - - // do subaccount creation - require.NoError( - t, - testutil.FundAccount( - app.BankKeeper, - ctx, - subAccFunder, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, subAccFunds)), - ), - ) - - _, err := msgServer.Create(sdk.WrapSDKContext(ctx), &types.MsgCreate{ - Creator: subAccFunder.String(), - Owner: subAccOwner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: uint64(time.Now().Add(24 * time.Hour).Unix()), - Amount: subAccFunds, - }, - }, - }) - require.NoError(t, err) - - // fund a bettor - require.NoError( - t, - testutil.FundAccount( - app.BankKeeper, - ctx, - bettor1, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, subAccFunds)), - ), - ) - - // add market - market := addTestMarket(t, app, ctx, false) - - // do house deposit - deposit := sdkmath.NewInt(1000).Mul(micro) - depResp, err := msgServer.HouseDeposit(sdk.WrapSDKContext(ctx), houseDepositMsg(t, subAccOwner, market.UID, deposit)) - require.NoError(t, err) - // check spend - subBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.Equal(t, subBalance.SpentAmount, deposit) - - // place bet - betMsgServer := betmodulekeeper.NewMsgServerImpl(*app.BetKeeper) - _, err = betMsgServer.Wager(sdk.WrapSDKContext(ctx), testBetMsgWager(t, bettor1, bettor1Funds)) - require.NoError(t, err) - - participateFee := app.HouseKeeper.GetHouseParticipationFee(ctx).Mul(sdkmath.LegacyNewDecFromInt(deposit)).TruncateInt() - bettorFee := sdkmath.NewInt(100) - - t.Run("house wins", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID2}, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - err := app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - err = app.OrderbookKeeper.BatchOrderBookSettlements(ctx) - require.NoError(t, err) - - subBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.NoError(t, err) - - require.Equal(t, subBalance.SpentAmount.String(), sdkmath.ZeroInt().Add(participateFee).String()) - // check profits were forwarded to subacc owner - ownerBalance := app.BankKeeper.GetAllBalances(ctx, subAccOwner) - require.Equal(t, - ownerBalance.AmountOf(params.DefaultBondDenom).String(), - sdkmath.NewInt(10).Mul(micro).Sub(bettorFee).String()) - }) - - t.Run("house loses", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID1}, - Status: markettypes.MarketStatus_MARKET_STATUS_RESULT_DECLARED, - }) - err := app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - err = app.OrderbookKeeper.BatchOrderBookSettlements(ctx) - require.NoError(t, err) - - subBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.NoError(t, err) - - require.Equal(t, subBalance.SpentAmount.String(), sdkmath.ZeroInt().Add(participateFee).String()) - require.Equal(t, subBalance.LostAmount, sdkmath.LegacyNewDecFromInt(bettor1Funds.Sub(bettorFee)).Mul(sdkmath.LegacyMustNewDecFromStr("3.2")).TruncateInt()) - // check profits were forwarded to subacc owner - ownerBalance := app.BankKeeper.GetAllBalances(ctx, subAccOwner) - require.Equal(t, ownerBalance.AmountOf(params.DefaultBondDenom), sdkmath.ZeroInt()) - }) - t.Run("house refund", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID1}, - Status: markettypes.MarketStatus_MARKET_STATUS_CANCELED, - }) - err := app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - err = app.OrderbookKeeper.BatchOrderBookSettlements(ctx) - require.NoError(t, err) - - subBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.NoError(t, err) - - require.Equal(t, subBalance.SpentAmount, sdkmath.ZeroInt()) - require.Equal(t, subBalance.LostAmount, sdkmath.ZeroInt()) - // check profits were forwarded to subacc owner - ownerBalance := app.BankKeeper.GetAllBalances(ctx, subAccOwner) - require.Equal(t, ownerBalance.AmountOf(params.DefaultBondDenom), sdkmath.ZeroInt()) - }) - - // TODO: not participated in bet fulfillment. - - t.Run("withdrawal", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - _, err := msgServer.HouseWithdraw(sdk.WrapSDKContext(ctx), &types.MsgHouseWithdraw{Msg: houseWithdrawMsg(t, subAccOwner, deposit, depResp.Response.ParticipationIndex)}) - require.NoError(t, err) - - // do subaccount balance check - subBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - - require.Equal(t, subBalance.SpentAmount.String(), sdkmath.NewInt(131999680).String()) // NOTE: there was a match in the bet + participate fee - require.Equal(t, subBalance.LostAmount.String(), sdkmath.ZeroInt().String()) - }) - - t.Run("withdrawal and market refund with bet fulfillment", func(t *testing.T) { - ctx, _ := ctx.CacheContext() - - _, err := msgServer.HouseWithdraw(sdk.WrapSDKContext(ctx), &types.MsgHouseWithdraw{Msg: houseWithdrawMsg(t, subAccOwner, deposit, depResp.Response.ParticipationIndex)}) - require.NoError(t, err) - - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID1}, - Status: markettypes.MarketStatus_MARKET_STATUS_CANCELED, - }) - err = app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - err = app.OrderbookKeeper.BatchOrderBookSettlements(ctx) - require.NoError(t, err) - - subBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.NoError(t, err) - - require.Equal(t, subBalance.SpentAmount, sdkmath.ZeroInt()) - require.Equal(t, subBalance.LostAmount, sdkmath.ZeroInt()) - // check profits were forwarded to subacc owner - ownerBalance := app.BankKeeper.GetAllBalances(ctx, subAccOwner) - require.Equal(t, ownerBalance.AmountOf(params.DefaultBondDenom), sdkmath.ZeroInt()) - }) -} - -func TestHouseWithdrawal_MarketRefund(t *testing.T) { - app, k, msgServer, ctx := setupMsgServerAndApp(t) - - parm := k.GetParams(ctx) - parm.DepositEnabled = true - k.SetParams(ctx, parm) - - subAccOwner := sample.NativeAccAddress() - subAccFunder := sample.NativeAccAddress() - // do subaccount creation - require.NoError( - t, - testutil.FundAccount( - app.BankKeeper, - ctx, - subAccFunder, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, subAccFunds)), - ), - ) - - _, err := msgServer.Create(sdk.WrapSDKContext(ctx), &types.MsgCreate{ - Creator: subAccFunder.String(), - Owner: subAccOwner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: uint64(time.Now().Add(24 * time.Hour).Unix()), - Amount: subAccFunds, - }, - }, - }) - require.NoError(t, err) - - // fund a bettor - require.NoError( - t, - testutil.FundAccount( - app.BankKeeper, - ctx, - bettor1, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, subAccFunds)), - ), - ) - - // add market - market := addTestMarket(t, app, ctx, false) - - // do house deposit - deposit := sdkmath.NewInt(1000).Mul(micro) - depResp, err := msgServer.HouseDeposit(sdk.WrapSDKContext(ctx), houseDepositMsg(t, subAccOwner, market.UID, deposit)) - require.NoError(t, err) - // check spend - subBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.Equal(t, subBalance.SpentAmount, deposit) - - // do house withdrawal - _, err = msgServer.HouseWithdraw(sdk.WrapSDKContext(ctx), &types.MsgHouseWithdraw{Msg: houseWithdrawMsg(t, subAccOwner, deposit, depResp.Response.ParticipationIndex)}) - require.NoError(t, err) - - // we expect the balance to be the original one minus participation fee - subBalance, exists = k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.Equal(t, subBalance.SpentAmount, sdkmath.NewInt(100).Mul(micro)) // all minus participation fee - require.Equal(t, subBalance.LostAmount, sdkmath.ZeroInt()) - require.Equal(t, subBalance.DepositedAmount, subAccFunds) - subBankBalance := app.BankKeeper.GetAllBalances(ctx, subAccAddr) - require.Equal(t, subBankBalance.AmountOf(params.DefaultBondDenom), subAccFunds.Sub(sdkmath.NewInt(100).Mul(micro))) // original funds - fee - - // resolve market with refund - app.MarketKeeper.Resolve(ctx, *market, &markettypes.MarketResolutionTicketPayload{ - UID: market.UID, - ResolutionTS: uint64(ctx.BlockTime().Unix()) + 10000, - WinnerOddsUIDs: []string{testOddsUID1}, - Status: markettypes.MarketStatus_MARKET_STATUS_CANCELED, - }) - err = app.BetKeeper.BatchMarketSettlements(ctx) - require.NoError(t, err) - err = app.OrderbookKeeper.BatchOrderBookSettlements(ctx) - require.NoError(t, err) - - subBalance, exists = k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.NoError(t, err) - - require.Equal(t, subBalance.SpentAmount, sdkmath.ZeroInt()) - require.Equal(t, subBalance.LostAmount, sdkmath.ZeroInt()) - subBankBalance = app.BankKeeper.GetAllBalances(ctx, subAccAddr) - require.Equal(t, subBankBalance.AmountOf(params.DefaultBondDenom), subAccFunds) // original funds - fee was refunded - // check profits were not forwarded to subacc owner - ownerBalance := app.BankKeeper.GetAllBalances(ctx, subAccOwner) - require.Equal(t, ownerBalance.AmountOf(params.DefaultBondDenom), sdkmath.ZeroInt()) -} - -func houseWithdrawMsg(t testing.TB, owner sdk.AccAddress, amt sdkmath.Int, partecipationIndex uint64) *housetypes.MsgWithdraw { - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: owner.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": testKyc, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputWithdraw := &housetypes.MsgWithdraw{ - Creator: owner.String(), - MarketUID: testMarketUID, - Amount: amt, - ParticipationIndex: partecipationIndex, - Mode: housetypes.WithdrawalMode_WITHDRAWAL_MODE_FULL, - Ticket: ticket, - } - return inputWithdraw -} - -func houseDepositMsg(t *testing.T, owner sdk.AccAddress, uid string, amt sdkmath.Int) *types.MsgHouseDeposit { - testKyc := &sgetypes.KycDataPayload{ - Approved: true, - ID: owner.String(), - } - ticketClaim := jwt.MapClaims{ - "exp": time.Now().Add(time.Minute * 5).Unix(), - "iat": time.Now().Unix(), - "kyc_data": testKyc, - } - ticket, err := simapp.CreateJwtTicket(ticketClaim) - require.Nil(t, err) - - inputDeposit := &housetypes.MsgDeposit{ - Creator: owner.String(), - MarketUID: uid, - Amount: amt, - Ticket: ticket, - } - - return &types.MsgHouseDeposit{ - Msg: inputDeposit, - } -} - -func testBetMsgWager(t testing.TB, bettor sdk.AccAddress, amount sdkmath.Int) *bettypes.MsgWager { - betTicket, err := createJwtTicket(jwt.MapClaims{ - "exp": 9999999999, - "iat": 7777777777, - "selected_odds": testSelectedBetOdds, - "kyc_data": &sgetypes.KycDataPayload{ - Approved: true, - ID: bettor.String(), - }, - "all_odds": testBetOdds, - }) - require.NoError(t, err) - - return &bettypes.MsgWager{ - Creator: bettor.String(), - Props: &bettypes.WagerProps{ - UID: uuid.NewString(), - Amount: amount, - Ticket: betTicket, - }, - } -} diff --git a/x/subaccount/keeper/msg_server_params.go b/x/subaccount/keeper/msg_server_params.go deleted file mode 100644 index 29269762..00000000 --- a/x/subaccount/keeper/msg_server_params.go +++ /dev/null @@ -1,27 +0,0 @@ -package keeper - -import ( - "context" - - sdkerrors "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - - "github.com/sge-network/sge/x/subaccount/types" -) - -func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { - ctx := sdk.UnwrapSDKContext(goCtx) - - if k.GetAuthority() != req.Authority { - return nil, sdkerrors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.GetAuthority(), req.Authority) - } - - if err := req.Params.Validate(); err != nil { - return nil, err - } - - k.SetParams(ctx, req.Params) - - return &types.MsgUpdateParamsResponse{}, nil -} diff --git a/x/subaccount/keeper/msg_server_subaccount_test.go b/x/subaccount/keeper/msg_server_subaccount_test.go deleted file mode 100644 index cd0ef3e0..00000000 --- a/x/subaccount/keeper/msg_server_subaccount_test.go +++ /dev/null @@ -1,144 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/bank/testutil" - - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/subaccount/keeper" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestMsgServer_Create(t *testing.T) { - account := sample.NativeAccAddress() - creatorAddr := sample.NativeAccAddress() - - app, _, msgServer, ctx := setupMsgServerAndApp(t) - - err := testutil.FundAccount(app.BankKeeper, ctx, creatorAddr, sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(100000000)))) - require.NoError(t, err) - - // Check that the account has been created - require.False(t, app.AccountKeeper.HasAccount(ctx, types.NewAddressFromSubaccount(1))) - - someTime := uint64(time.Now().Add(10 * time.Minute).Unix()) - msg := &types.MsgCreate{ - Creator: creatorAddr.String(), - Owner: account.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: someTime, - Amount: sdkmath.NewInt(123), - }, - }, - } - - _, err = msgServer.Create(sdk.WrapSDKContext(ctx), msg) - require.NoError(t, err) - - // Check that the account has been created - require.True(t, app.AccountKeeper.HasAccount(ctx, types.NewAddressFromSubaccount(1))) - - // Check that the account has the correct balance - balance := app.BankKeeper.GetBalance(ctx, types.NewAddressFromSubaccount(1), params.DefaultBondDenom) - require.Equal(t, sdkmath.NewInt(123), balance.Amount) - - // Check that we can get the account by owner - owner, exists := app.SubaccountKeeper.GetSubaccountOwner(ctx, types.NewAddressFromSubaccount(1)) - require.True(t, exists) - require.Equal(t, account, owner) - - // check that balance unlocks are set correctly - lockedBalances, _ := app.SubaccountKeeper.GetBalances(ctx, types.NewAddressFromSubaccount(1), types.LockedBalanceStatus_LOCKED_BALANCE_STATUS_LOCKED) - require.Len(t, lockedBalances, 1) - require.True(t, someTime == lockedBalances[0].UnlockTS) - require.Equal(t, sdkmath.NewInt(123), lockedBalances[0].Amount) - - // get the balance of the account - subaccountBalance, exists := app.SubaccountKeeper.GetAccountSummary(ctx, types.NewAddressFromSubaccount(1)) - require.True(t, exists) - require.Equal(t, sdkmath.ZeroInt(), subaccountBalance.SpentAmount) - require.Equal(t, sdkmath.ZeroInt(), subaccountBalance.LostAmount) - require.Equal(t, sdkmath.ZeroInt(), subaccountBalance.WithdrawnAmount) - require.Equal(t, sdkmath.NewInt(123), subaccountBalance.DepositedAmount) -} - -func TestMsgServer_CreateSubaccount_Errors(t *testing.T) { - beforeTime := uint64(time.Now().Add(-10 * time.Minute).Unix()) - afterTime := uint64(time.Now().Add(10 * time.Minute).Unix()) - account := sample.NativeAccAddress() - creatorAddr := sample.NativeAccAddress() - - tests := []struct { - name string - msg types.MsgCreate - prepare func(ctx sdk.Context, keeper *keeper.Keeper) - expectedErr string - }{ - { - name: "unlock time is expired", - msg: types.MsgCreate{ - Creator: creatorAddr.String(), - Owner: account.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: beforeTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - prepare: func(_ sdk.Context, _ *keeper.Keeper) {}, - expectedErr: types.ErrUnlockTokenTimeExpired.Error(), - }, - { - name: "account has already sub account", - msg: types.MsgCreate{ - Creator: creatorAddr.String(), - Owner: account.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: afterTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - prepare: func(ctx sdk.Context, k *keeper.Keeper) { - k.SetSubaccountOwner(ctx, types.NewAddressFromSubaccount(1), account) - }, - expectedErr: types.ErrSubaccountAlreadyExist.Error(), - }, - { - name: "invalid request", - msg: types.MsgCreate{ - Creator: creatorAddr.String(), - Owner: account.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: afterTime, - Amount: sdkmath.Int{}, - }, - }, - }, - prepare: func(_ sdk.Context, _ *keeper.Keeper) {}, - expectedErr: "invalid request", - }, - } - - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - _, k, msgServer, ctx := setupMsgServerAndApp(t) - - tt.prepare(ctx, k) - - _, err := msgServer.Create(sdk.WrapSDKContext(ctx), &tt.msg) - require.ErrorContains(t, err, tt.expectedErr) - }) - } -} diff --git a/x/subaccount/keeper/msg_server_test.go b/x/subaccount/keeper/msg_server_test.go deleted file mode 100644 index 079bff35..00000000 --- a/x/subaccount/keeper/msg_server_test.go +++ /dev/null @@ -1,18 +0,0 @@ -package keeper_test - -import ( - "testing" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/subaccount/keeper" - "github.com/sge-network/sge/x/subaccount/types" -) - -func setupMsgServerAndApp( - t testing.TB, -) (*simapp.TestApp, *keeper.Keeper, types.MsgServer, sdk.Context) { - tApp, k, ctx := setupKeeperAndApp(t) - return tApp, k, keeper.NewMsgServerImpl(*k), ctx -} diff --git a/x/subaccount/keeper/params_test.go b/x/subaccount/keeper/params_test.go deleted file mode 100644 index 77dc1ba6..00000000 --- a/x/subaccount/keeper/params_test.go +++ /dev/null @@ -1,16 +0,0 @@ -package keeper_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestKeeper_GetParams(t *testing.T) { - _, k, ctx := setupKeeperAndApp(t) - - params := k.GetParams(ctx) - require.Equal(t, params, types.DefaultParams()) -} diff --git a/x/subaccount/keeper/query_server_test.go b/x/subaccount/keeper/query_server_test.go deleted file mode 100644 index 118b577f..00000000 --- a/x/subaccount/keeper/query_server_test.go +++ /dev/null @@ -1,73 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - sdkmath "cosmossdk.io/math" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/cosmos/cosmos-sdk/x/bank/testutil" - "github.com/sge-network/sge/app/params" - "github.com/sge-network/sge/testutil/simapp" - "github.com/sge-network/sge/x/subaccount/keeper" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestQueryServer(t *testing.T) { - app, k, msgServer, ctx := setupMsgServerAndApp(t) - queryServer := keeper.NewQueryServer(*k) - - subAccOwner := simapp.TestParamUsers["user1"].Address - subAccFunder := simapp.TestParamUsers["user1"].Address - // setup - wantParams := types.DefaultParams() - k.SetParams(ctx, wantParams) - - // do subaccount creation - require.NoError( - t, - testutil.FundAccount( - app.BankKeeper, - ctx, - subAccFunder, - sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, subAccFunds)), - ), - ) - - _, err := msgServer.Create(sdk.WrapSDKContext(ctx), &types.MsgCreate{ - Creator: subAccFunder.String(), - Owner: subAccOwner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: uint64(time.Now().Add(24 * time.Hour).Unix()), - Amount: subAccFunds, - }, - }, - }) - require.NoError(t, err) - - t.Run("Params", func(t *testing.T) { - gotParams, err := queryServer.Params(sdk.WrapSDKContext(ctx), &types.QueryParamsRequest{}) - require.NoError(t, err) - require.Equal(t, wantParams, gotParams.Params) - }) - - t.Run("Subaccount", func(t *testing.T) { - gotSubaccount, err := queryServer.Subaccount(sdk.WrapSDKContext(ctx), &types.QuerySubaccountRequest{ - Address: subAccOwner.String(), - }) - require.NoError(t, err) - require.Equal(t, subAccAddr.String(), gotSubaccount.Address) - require.Equal(t, types.AccountSummary{ - DepositedAmount: subAccFunds, - SpentAmount: sdkmath.ZeroInt(), - WithdrawnAmount: sdkmath.ZeroInt(), - LostAmount: sdkmath.ZeroInt(), - }, gotSubaccount.Balance) - require.Len(t, gotSubaccount.LockedBalance, 1) - require.Equal(t, subAccFunds, gotSubaccount.LockedBalance[0].Amount) - }) -} diff --git a/x/subaccount/keeper/subaccount_test.go b/x/subaccount/keeper/subaccount_test.go deleted file mode 100644 index 73900e66..00000000 --- a/x/subaccount/keeper/subaccount_test.go +++ /dev/null @@ -1,145 +0,0 @@ -package keeper_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestSubaccountID(t *testing.T) { - _, k, ctx := setupKeeperAndApp(t) - - // Peek from beginning should return 1 - require.Equal(t, uint64(1), k.Peek(ctx)) - - // NextID returns the actual ID and increments the ID - require.Equal(t, uint64(1), k.NextID(ctx)) - require.Equal(t, uint64(2), k.Peek(ctx)) - - // We can set an arbitrary ID and continue from there - k.SetID(ctx, 100) - require.Equal(t, uint64(100), k.Peek(ctx)) -} - -func TestSubaccountOwner(t *testing.T) { - _, k, ctx := setupKeeperAndApp(t) - - owner := sample.NativeAccAddress() - - // Account should not have subaccount - _, exists := k.GetSubaccountOwner(ctx, owner) - require.False(t, exists) - - // Set subaccount owner - id := k.NextID(ctx) - k.SetSubaccountOwner(ctx, types.NewAddressFromSubaccount(id), owner) - - // Account should have subaccount - _, exists = k.GetSubaccountByOwner(ctx, owner) - require.True(t, exists) - - // Get subaccount ID - subAccountAddress, exists := k.GetSubaccountByOwner(ctx, owner) - require.True(t, exists) - require.Equal(t, types.NewAddressFromSubaccount(id), subAccountAddress) - - // Get owner of subaccount - gotOwner, exists := k.GetSubaccountOwner(ctx, subAccountAddress) - require.True(t, exists) - require.Equal(t, owner, gotOwner) - // Get account ID by owner - gotSubaccount, exists := k.GetSubaccountByOwner(ctx, owner) - require.True(t, exists) - require.Equal(t, types.NewAddressFromSubaccount(id), gotSubaccount) -} - -func TestSetLockedBalances(t *testing.T) { - _, k, ctx := setupKeeperAndApp(t) - - someUnlockTime := uint64(time.Now().Add(time.Hour * 24 * 365).Unix()) - otherUnlockTime := uint64(time.Now().Add(time.Hour * 24 * 365 * 2).Unix()) - - balanceUnlocks := []types.LockedBalance{ - { - Amount: sdkmath.NewInt(10000), - UnlockTS: someUnlockTime, - }, - { - Amount: sdkmath.NewInt(20000), - UnlockTS: otherUnlockTime, - }, - } - - addr := types.NewAddressFromSubaccount(1) - - k.SetLockedBalances(ctx, addr, balanceUnlocks) - - // Get locked balances - lockedBalances, _ := k.GetBalances(ctx, addr, types.LockedBalanceStatus_LOCKED_BALANCE_STATUS_LOCKED) - for i, lockedBalance := range lockedBalances { - require.Equal(t, lockedBalance.Amount, balanceUnlocks[i].Amount) - require.True(t, lockedBalance.UnlockTS == balanceUnlocks[i].UnlockTS) - } -} - -func TestSetBalances(t *testing.T) { - _, k, ctx := setupKeeperAndApp(t) - - balance := types.AccountSummary{ - DepositedAmount: sdkmath.ZeroInt(), - SpentAmount: sdkmath.ZeroInt(), - WithdrawnAmount: sdkmath.ZeroInt(), - LostAmount: sdkmath.OneInt(), - } - - subAccAddr := types.NewAddressFromSubaccount(1) - k.SetAccountSummary(ctx, subAccAddr, balance) - - // Get balance - gotBalance, exists := k.GetAccountSummary(ctx, subAccAddr) - require.True(t, exists) - require.Equal(t, balance, gotBalance) -} - -func TestKeeper_GetLockedBalances(t *testing.T) { - _, k, ctx := setupKeeperAndApp(t) - - beforeUnlockTime1 := uint64(time.Now().Add(-time.Hour * 24 * 365).Unix()) - beforeUnlockTime2 := uint64(time.Now().Add(-time.Hour * 24 * 365 * 2).Unix()) - - afterUnlockTime1 := uint64(time.Now().Add(time.Hour * 24 * 365).Unix()) - afterUnlockTime2 := uint64(time.Now().Add(time.Hour * 24 * 365 * 2).Unix()) - - // I added them unordered to make sure they are sorted - balanceUnlocks := []types.LockedBalance{ - { - Amount: sdkmath.NewInt(10000), - UnlockTS: beforeUnlockTime1, - }, - { - Amount: sdkmath.NewInt(30000), - UnlockTS: afterUnlockTime1, - }, - { - Amount: sdkmath.NewInt(20000), - UnlockTS: beforeUnlockTime2, - }, - { - Amount: sdkmath.NewInt(40000), - UnlockTS: afterUnlockTime2, - }, - } - - addr := types.NewAddressFromSubaccount(1) - k.SetLockedBalances(ctx, addr, balanceUnlocks) - - // get unlocked balance - _, unlockedAmount := k.GetBalances(ctx, addr, types.LockedBalanceStatus_LOCKED_BALANCE_STATUS_UNLOCKED) - require.True(t, unlockedAmount.Equal(sdkmath.NewInt(10000+20000))) -} diff --git a/x/subaccount/simulation/decoder_test.go b/x/subaccount/simulation/decoder_test.go deleted file mode 100644 index cd42a1ff..00000000 --- a/x/subaccount/simulation/decoder_test.go +++ /dev/null @@ -1,70 +0,0 @@ -package simulation_test - -import ( - "fmt" - "testing" - - sdkmath "cosmossdk.io/math" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/kv" - - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/subaccount/simulation" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestDecodeStore(t *testing.T) { - cdc := app.MakeEncodingConfig().Marshaler - dec := simulation.NewDecodeStore(cdc) - - subID := 100 - address := sample.NativeAccAddress() - - lockedBalance := types.LockedBalance{ - UnlockTS: 100, - Amount: sdkmath.NewInt(100), - } - - accSummary := types.AccountSummary{ - DepositedAmount: sdkmath.NewInt(100), - SpentAmount: sdkmath.NewInt(0), - WithdrawnAmount: sdkmath.ZeroInt(), - LostAmount: sdkmath.ZeroInt(), - } - - kvPairs := kv.Pairs{ - Pairs: []kv.Pair{ - {Key: types.SubaccountIDPrefix, Value: sdk.Uint64ToBigEndian(uint64(subID))}, - {Key: types.SubaccountOwnerPrefix, Value: address}, - {Key: types.SubaccountOwnerReversePrefix, Value: address}, - {Key: types.LockedBalancePrefix, Value: cdc.MustMarshal(&lockedBalance)}, - {Key: types.AccountSummaryPrefix, Value: cdc.MustMarshal(&accSummary)}, - {Key: []byte{0x99}, Value: []byte{0x99}}, - }, - } - tests := []struct { - name string - expectedLog string - }{ - {"subID", fmt.Sprintf("%d\n%d", subID, subID)}, - {"address", fmt.Sprintf("%d\n%d", address, address)}, - {"reverseAddress", fmt.Sprintf("%d\n%d", address, address)}, - {"lockedBalances", fmt.Sprintf("%v\n%v", lockedBalance, lockedBalance)}, - {"accsum", fmt.Sprintf("%v\n%v", accSummary, accSummary)}, - {"other", ""}, - } - - for i, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - switch i { - case len(tests) - 1: - require.Panics(t, func() { dec(kvPairs.Pairs[i], kvPairs.Pairs[i]) }, tt.name) - default: - require.Equal(t, tt.expectedLog, dec(kvPairs.Pairs[i], kvPairs.Pairs[i]), tt.name) - } - }) - } -} diff --git a/x/subaccount/simulation/genesis_test.go b/x/subaccount/simulation/genesis_test.go deleted file mode 100644 index 056733bb..00000000 --- a/x/subaccount/simulation/genesis_test.go +++ /dev/null @@ -1,74 +0,0 @@ -package simulation_test - -import ( - "encoding/json" - //#nosec - "math/rand" - "testing" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/codec" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/types/module" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - - "github.com/sge-network/sge/x/subaccount/simulation" - "github.com/sge-network/sge/x/subaccount/types" -) - -// TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. -// Abnormal scenarios are not tested here. -func TestRandomizedGenState(_ *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - simState := module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - NumBonded: 3, - Accounts: simtypes.RandomAccounts(r, 3), - InitialStake: sdkmath.NewInt(1000), - GenState: make(map[string]json.RawMessage), - } - - simulation.RandomizedGenState(&simState) - - var houseGenesis types.GenesisState - simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &houseGenesis) -} - -// TestRandomizedGenState tests abnormal scenarios of applying RandomizedGenState. -func TestRandomizedGenState1(t *testing.T) { - interfaceRegistry := codectypes.NewInterfaceRegistry() - cdc := codec.NewProtoCodec(interfaceRegistry) - - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - // all these tests will panic - tests := []struct { - simState module.SimulationState - panicMsg string - }{ - { // panic => reason: incomplete initialization of the simState - module.SimulationState{}, "invalid memory address or nil pointer dereference"}, - { // panic => reason: incomplete initialization of the simState - module.SimulationState{ - AppParams: make(simtypes.AppParams), - Cdc: cdc, - Rand: r, - }, "assignment to entry in nil map"}, - } - - for _, tt := range tests { - simTest := tt.simState - require.Panicsf(t, func() { simulation.RandomizedGenState(&simTest) }, tt.panicMsg) - } -} diff --git a/x/subaccount/simulation/proposals_test.go b/x/subaccount/simulation/proposals_test.go deleted file mode 100644 index 43e7a464..00000000 --- a/x/subaccount/simulation/proposals_test.go +++ /dev/null @@ -1,45 +0,0 @@ -package simulation_test - -import ( - "fmt" - "math/rand" - "testing" - - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/stretchr/testify/require" - - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/address" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/sge-network/sge/x/subaccount/simulation" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestProposalMsgs(t *testing.T) { - // initialize parameters - s := rand.NewSource(1) - //#nosec - r := rand.New(s) - - ctx := sdk.NewContext(nil, tmproto.Header{}, true, nil) - accounts := simtypes.RandomAccounts(r, 3) - - // execute ProposalMsgs function - weightedProposalMsgs := simulation.ProposalMsgs() - require.Equal(t, len(weightedProposalMsgs), 1) - - w0 := weightedProposalMsgs[0] - - // tests w0 interface: - require.Equal(t, simulation.OpWeightMsgUpdateParams, w0.AppParamsKey()) - require.Equal(t, simulation.DefaultWeightMsgUpdateParams, w0.DefaultWeight()) - - msg := w0.MsgSimulatorFn()(r, ctx, accounts) - msgUpdateParams, ok := msg.(*types.MsgUpdateParams) - require.True(t, ok) - - fmt.Println(msgUpdateParams) - require.Equal(t, sdk.AccAddress(address.Module("gov")).String(), msgUpdateParams.Authority) - require.Equal(t, true, msgUpdateParams.Params.DepositEnabled) - require.Equal(t, true, msgUpdateParams.Params.WagerEnabled) -} diff --git a/x/subaccount/simulation/simap.go b/x/subaccount/simulation/simap.go deleted file mode 100644 index 92c437c0..00000000 --- a/x/subaccount/simulation/simap.go +++ /dev/null @@ -1,15 +0,0 @@ -package simulation - -import ( - sdk "github.com/cosmos/cosmos-sdk/types" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" -) - -// FindAccount find a specific address from an account list -func FindAccount(accs []simtypes.Account, address string) (simtypes.Account, bool) { - creator, err := sdk.AccAddressFromBech32(address) - if err != nil { - panic(err) - } - return simtypes.FindAccount(accs, creator) -} diff --git a/x/subaccount/types/messages_balance_test.go b/x/subaccount/types/messages_balance_test.go deleted file mode 100644 index 379aae29..00000000 --- a/x/subaccount/types/messages_balance_test.go +++ /dev/null @@ -1,77 +0,0 @@ -package types_test - -import ( - "fmt" - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestMsgTopUpValidateBasic(t *testing.T) { - creatorAddr := sample.NativeAccAddress() - owner := sample.NativeAccAddress() - - someTime := uint64(time.Now().Unix()) - tests := []struct { - name string - msg types.MsgTopUp - want error - }{ - { - name: "invalid creator", - msg: types.MsgTopUp{ - Creator: "someInvalidAddress", - Address: owner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: someTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - want: errors.ErrInvalidAddress, - }, - { - name: "invalid sub account owner", - msg: types.MsgTopUp{ - Creator: creatorAddr.String(), - Address: "someInvalidAddress", - LockedBalances: []types.LockedBalance{ - { - UnlockTS: someTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - want: errors.ErrInvalidAddress, - }, - { - name: "unlock time zero", - msg: types.MsgTopUp{ - Creator: creatorAddr.String(), - Address: owner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: 0, - Amount: sdkmath.NewInt(123), - }, - }, - }, - want: fmt.Errorf("invalid locked balance: unlock time is zero"), - }, - } - - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - got := tt.msg.ValidateBasic() - require.ErrorContains(t, got, tt.want.Error()) - }) - } -} diff --git a/x/subaccount/types/messages_subaccount_test.go b/x/subaccount/types/messages_subaccount_test.go deleted file mode 100644 index 16539e59..00000000 --- a/x/subaccount/types/messages_subaccount_test.go +++ /dev/null @@ -1,76 +0,0 @@ -package types_test - -import ( - "testing" - "time" - - "github.com/stretchr/testify/require" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/sge-network/sge/testutil/sample" - "github.com/sge-network/sge/x/subaccount/types" -) - -func TestMsgCreateValidateBasic(t *testing.T) { - creatorAddr := sample.NativeAccAddress() - owner := sample.NativeAccAddress() - - someTime := uint64(time.Now().Unix()) - tests := []struct { - name string - msg types.MsgCreate - want error - }{ - { - name: "invalid creator", - msg: types.MsgCreate{ - Creator: "someInvalidAddress", - Owner: owner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: someTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - want: errors.ErrInvalidAddress, - }, - { - name: "invalid sub account owner", - msg: types.MsgCreate{ - Creator: creatorAddr.String(), - Owner: "someInvalidAddress", - LockedBalances: []types.LockedBalance{ - { - UnlockTS: someTime, - Amount: sdkmath.NewInt(123), - }, - }, - }, - want: errors.ErrInvalidAddress, - }, - { - name: "unlock time zero", - msg: types.MsgCreate{ - Creator: creatorAddr.String(), - Owner: owner.String(), - LockedBalances: []types.LockedBalance{ - { - UnlockTS: 0, - Amount: sdkmath.NewInt(123), - }, - }, - }, - want: types.ErrInvalidLockedBalance, - }, - } - - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - got := tt.msg.ValidateBasic() - require.ErrorContains(t, got, tt.want.Error()) - }) - } -} From 9987d835be2fad01646fefeba3e4be4c7f64aaaf Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Mon, 10 Feb 2025 16:32:53 +0300 Subject: [PATCH 07/16] feat: upgrade app wiring using depinject --- app/ante.go | 75 ++-- app/app.go | 614 ++++++++++++------------- app/app_config.go | 281 ++++++++++++ app/app_test.go | 32 -- app/config.go | 35 ++ app/const.go | 3 - app/encoding.go | 17 - app/errors.go | 1 - app/export.go | 245 +++++----- app/export_test.go | 39 -- app/genesis.go | 6 - app/ibc.go | 214 +++++++++ app/keepers/keepers.go | 740 +++---------------------------- app/keepers/keys.go | 109 ----- app/modules.go | 405 ----------------- app/params/encoding.go | 17 - app/params/params.go | 6 - app/params/proto.go | 22 - app/params/weights.go | 22 - app/prefix.go | 45 -- app/sim_bench_test.go | 149 +++++++ app/sim_test.go | 415 +++++++++++++---- app/upgrades/types.go | 4 +- app/upgrades/v10/consts.go | 11 +- app/upgrades/v10/upgrades.go | 92 ++-- app/upgrades/v9/consts.go | 32 -- app/upgrades/v9/upgrades.go | 128 ------ app/wasm.go | 155 +++++++ cmd/sged/cmd/args.go | 11 - cmd/sged/cmd/commands.go | 195 ++++++++ cmd/sged/cmd/config.go | 62 +++ cmd/sged/cmd/errors.go | 18 - cmd/sged/cmd/genaccounts.go | 265 ----------- cmd/sged/cmd/genaccounts_test.go | 77 ---- cmd/sged/cmd/root.go | 357 ++++----------- cmd/sged/cmd/root_test.go | 21 - cmd/sged/cmd/testnet.go | 285 ++++++++++++ cmd/sged/main.go | 17 +- 38 files changed, 2337 insertions(+), 2885 deletions(-) create mode 100644 app/app_config.go delete mode 100644 app/app_test.go create mode 100644 app/config.go delete mode 100644 app/const.go delete mode 100644 app/encoding.go delete mode 100644 app/export_test.go create mode 100644 app/ibc.go delete mode 100644 app/keepers/keys.go delete mode 100644 app/modules.go delete mode 100644 app/params/encoding.go delete mode 100644 app/params/proto.go delete mode 100644 app/params/weights.go delete mode 100644 app/prefix.go create mode 100644 app/sim_bench_test.go delete mode 100644 app/upgrades/v9/consts.go delete mode 100644 app/upgrades/v9/upgrades.go create mode 100644 app/wasm.go delete mode 100644 cmd/sged/cmd/args.go create mode 100644 cmd/sged/cmd/commands.go create mode 100644 cmd/sged/cmd/config.go delete mode 100644 cmd/sged/cmd/errors.go delete mode 100644 cmd/sged/cmd/genaccounts.go delete mode 100644 cmd/sged/cmd/genaccounts_test.go delete mode 100644 cmd/sged/cmd/root_test.go create mode 100644 cmd/sged/cmd/testnet.go diff --git a/app/ante.go b/app/ante.go index 098f62ac..c3d67782 100644 --- a/app/ante.go +++ b/app/ante.go @@ -1,82 +1,67 @@ package app import ( - wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - - ibcante "github.com/cosmos/ibc-go/v7/modules/core/ante" - ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" - - errorsmod "cosmossdk.io/errors" + "errors" - "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" + corestoretypes "cosmossdk.io/core/store" + circuitante "cosmossdk.io/x/circuit/ante" + circuitkeeper "cosmossdk.io/x/circuit/keeper" + wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" + wasmTypes "github.com/CosmWasm/wasmd/x/wasm/types" sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/ante" - bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" - stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" + ibcante "github.com/cosmos/ibc-go/v8/modules/core/ante" + "github.com/cosmos/ibc-go/v8/modules/core/keeper" ) -// HandlerOptions extends the SDK's AnteHandler options by requiring the IBC -// channel keeper and a BankKeeper with an added method for fee sharing. +// HandlerOptions extend the SDK's AnteHandler options by requiring the IBC +// channel keeper. type HandlerOptions struct { ante.HandlerOptions - GovKeeper govkeeper.Keeper - IBCKeeper *ibckeeper.Keeper - BankKeeper bankkeeper.Keeper - TxCounterStoreKey storetypes.StoreKey - WasmConfig *wasmtypes.WasmConfig - WasmKeeper *wasmkeeper.Keeper - Cdc codec.BinaryCodec - - StakingKeeper stakingkeeper.Keeper + IBCKeeper *keeper.Keeper + WasmConfig *wasmTypes.WasmConfig + WasmKeeper *wasmkeeper.Keeper + TXCounterStoreService corestoretypes.KVStoreService + CircuitKeeper *circuitkeeper.Keeper } -// NewAnteHandler returns an AnteHandler that checks and increments sequence -// numbers, checks signatures & account numbers, and deducts fees from the first -// signer. +// NewAnteHandler constructor func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { if options.AccountKeeper == nil { - return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "account keeper is required for ante builder") + return nil, errors.New("account keeper is required for ante builder") } - if options.BankKeeper == nil { - return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "bank keeper is required for ante builder") + return nil, errors.New("bank keeper is required for ante builder") } - if options.SignModeHandler == nil { - return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "sign mode handler is required for ante builder") + return nil, errors.New("sign mode handler is required for ante builder") } - if options.WasmConfig == nil { - return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "wasm config is required for ante builder") + return nil, errors.New("wasm config is required for ante builder") } - - sigGasConsumer := options.SigGasConsumer - if sigGasConsumer == nil { - sigGasConsumer = ante.DefaultSigVerificationGasConsumer + if options.TXCounterStoreService == nil { + return nil, errors.New("wasm store service is required for ante builder") + } + if options.CircuitKeeper == nil { + return nil, errors.New("circuit keeper is required for ante builder") } anteDecorators := []sdk.AnteDecorator{ - // GlobalFee query params for minimum fee ante.NewSetUpContextDecorator(), // outermost AnteDecorator. SetUpContext must be called first - wasmkeeper.NewLimitSimulationGasDecorator(options.WasmConfig.SimulationGasLimit), - wasmkeeper.NewCountTXDecorator(options.TxCounterStoreKey), + wasmkeeper.NewLimitSimulationGasDecorator(options.WasmConfig.SimulationGasLimit), // after setup context to enforce limits early + wasmkeeper.NewCountTXDecorator(options.TXCounterStoreService), wasmkeeper.NewGasRegisterDecorator(options.WasmKeeper.GetGasRegister()), + circuitante.NewCircuitBreakerDecorator(options.CircuitKeeper), ante.NewExtensionOptionsDecorator(options.ExtensionOptionChecker), ante.NewValidateBasicDecorator(), ante.NewTxTimeoutHeightDecorator(), ante.NewValidateMemoDecorator(options.AccountKeeper), ante.NewConsumeGasForTxSizeDecorator(options.AccountKeeper), ante.NewDeductFeeDecorator(options.AccountKeeper, options.BankKeeper, options.FeegrantKeeper, options.TxFeeChecker), - - // SetPubKeyDecorator must be called before all signature verification decorators - ante.NewSetPubKeyDecorator(options.AccountKeeper), + ante.NewSetPubKeyDecorator(options.AccountKeeper), // SetPubKeyDecorator must be called before all signature verification decorators ante.NewValidateSigCountDecorator(options.AccountKeeper), - ante.NewSigGasConsumeDecorator(options.AccountKeeper, sigGasConsumer), + ante.NewSigGasConsumeDecorator(options.AccountKeeper, options.SigGasConsumer), ante.NewSigVerificationDecorator(options.AccountKeeper, options.SignModeHandler), ante.NewIncrementSequenceDecorator(options.AccountKeeper), ibcante.NewRedundantRelayDecorator(options.IBCKeeper), diff --git a/app/app.go b/app/app.go index 982c34b7..d1a318f9 100644 --- a/app/app.go +++ b/app/app.go @@ -3,83 +3,86 @@ package app import ( "fmt" "io" - "net/http" "os" "path/filepath" - "strconv" - dbm "github.com/cometbft/cometbft-db" + _ "cosmossdk.io/api/cosmos/tx/config/v1" // import for side-effects + clienthelpers "cosmossdk.io/client/v2/helpers" + "cosmossdk.io/depinject" + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" + _ "cosmossdk.io/x/circuit" // import for side-effects + _ "cosmossdk.io/x/evidence" // import for side-effects + _ "cosmossdk.io/x/feegrant/module" // import for side-effects + _ "cosmossdk.io/x/nft/module" // import for side-effects + _ "cosmossdk.io/x/upgrade" // import for side-effects + upgradetypes "cosmossdk.io/x/upgrade/types" + abci "github.com/cometbft/cometbft/abci/types" - tmjson "github.com/cometbft/cometbft/libs/json" - "github.com/cometbft/cometbft/libs/log" - tmos "github.com/cometbft/cometbft/libs/os" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - autocliv1 "cosmossdk.io/api/cosmos/autocli/v1" - reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" - "github.com/gorilla/mux" - "github.com/rakyll/statik/fs" - "github.com/spf13/cast" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + dbm "github.com/cosmos/cosmos-db" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" - nodeservice "github.com/cosmos/cosmos-sdk/client/grpc/node" - "github.com/cosmos/cosmos-sdk/client/grpc/tmservice" "github.com/cosmos/cosmos-sdk/codec" - "github.com/cosmos/cosmos-sdk/codec/types" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/runtime" - runtimeservices "github.com/cosmos/cosmos-sdk/runtime/services" + "github.com/cosmos/cosmos-sdk/server" "github.com/cosmos/cosmos-sdk/server/api" "github.com/cosmos/cosmos-sdk/server/config" servertypes "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/cosmos/cosmos-sdk/version" - "github.com/cosmos/cosmos-sdk/x/auth/ante" - authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" + "github.com/cosmos/cosmos-sdk/x/auth" + authsims "github.com/cosmos/cosmos-sdk/x/auth/simulation" + _ "github.com/cosmos/cosmos-sdk/x/auth/tx/config" // import for side-effects authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/cosmos/cosmos-sdk/x/crisis" + _ "github.com/cosmos/cosmos-sdk/x/auth/vesting" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/authz/module" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/bank" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/consensus" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/crisis" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/distribution" // import for side-effects + "github.com/cosmos/cosmos-sdk/x/genutil" + genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" + "github.com/cosmos/cosmos-sdk/x/gov" govclient "github.com/cosmos/cosmos-sdk/x/gov/client" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + _ "github.com/cosmos/cosmos-sdk/x/group/module" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/mint" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/params" // import for side-effects paramsclient "github.com/cosmos/cosmos-sdk/x/params/client" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - upgradeclient "github.com/cosmos/cosmos-sdk/x/upgrade/client" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - ibcwasmkeeper "github.com/cosmos/ibc-go/modules/light-clients/08-wasm/keeper" - ibcclientHandler "github.com/cosmos/ibc-go/v7/modules/core/02-client/client" + _ "github.com/cosmos/cosmos-sdk/x/slashing" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/staking" // import for side-effects + + _ "github.com/cosmos/ibc-go/modules/capability" // import for side-effects + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" + _ "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts" // import for side-effects + _ "github.com/cosmos/ibc-go/v8/modules/apps/29-fee" // import for side-effects + ibckeeper "github.com/cosmos/ibc-go/v8/modules/core/keeper" - wasm "github.com/CosmWasm/wasmd/x/wasm" - wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" "github.com/sge-network/sge/app/keepers" - sgeappparams "github.com/sge-network/sge/app/params" "github.com/sge-network/sge/app/upgrades" v10 "github.com/sge-network/sge/app/upgrades/v10" - v9 "github.com/sge-network/sge/app/upgrades/v9" - - // unnamed import of statik for swagger UI support - _ "github.com/cosmos/cosmos-sdk/client/docs/statik" + "github.com/sge-network/sge/docs" ) -func getGovProposalHandlers() []govclient.ProposalHandler { - var govProposalHandlers []govclient.ProposalHandler - - govProposalHandlers = append(govProposalHandlers, - paramsclient.ProposalHandler, - upgradeclient.LegacyProposalHandler, - upgradeclient.LegacyCancelProposalHandler, - ibcclientHandler.UpdateClientProposalHandler, - ibcclientHandler.UpgradeProposalHandler, - ) +const ( + // AccountAddressPrefix prefix used for generating account address + AccountAddressPrefix = "sge" - return govProposalHandlers -} + Name = "sge" +) var ( // DefaultNodeHome default home directories for the application daemon DefaultNodeHome string - Upgrades = []upgrades.Upgrade{ - v9.Upgrade, + + Upgrades = []upgrades.Upgrade{ v10.Upgrade, } // default wasmd binary maximum allowed size @@ -87,8 +90,8 @@ var ( ) var ( - _ runtime.AppI = (*SgeApp)(nil) - _ servertypes.Application = (*SgeApp)(nil) + _ runtime.AppI = (*App)(nil) + _ servertypes.Application = (*App)(nil) ) func init() { @@ -97,336 +100,298 @@ func init() { panic(err) } - DefaultNodeHome = filepath.Join(userHomeDir, "."+appName) + DefaultNodeHome = filepath.Join(userHomeDir, "."+Name) } -// SgeApp extends an ABCI application, but with most of its parameters exported. +// App extends an ABCI application, but with most of its parameters exported. // They are exported for convenience in creating helper functions, as object // capabilities aren't needed for testing. -type SgeApp struct { - *baseapp.BaseApp - keepers.AppKeepers +type App struct { + *runtime.App + *keepers.AppKeepers - cdc *codec.LegacyAmino + legacyAmino *codec.LegacyAmino appCodec codec.Codec - interfaceRegistry types.InterfaceRegistry + txConfig client.TxConfig + interfaceRegistry codectypes.InterfaceRegistry + + // simulation manager + sm *module.SimulationManager +} + +func init() { + var err error + clienthelpers.EnvPrefix = Name + DefaultNodeHome, err = clienthelpers.GetNodeHomeDirectory("." + Name) + if err != nil { + panic(err) + } +} - invCheckPeriod uint +// getGovProposalHandlers return the chain proposal handlers. +func getGovProposalHandlers() []govclient.ProposalHandler { + var govProposalHandlers []govclient.ProposalHandler - // the module manager - mm *module.Manager + govProposalHandlers = append(govProposalHandlers, + paramsclient.ProposalHandler, + ) - // simulation manager - sm *module.SimulationManager - configurator module.Configurator + return govProposalHandlers +} + +// Config returns the default app config. +func Config() depinject.Config { + return depinject.Configs( + appConfig, + // Alternatively, load the app config from a YAML file. + // appconfig.LoadYAML(AppConfigYAML), + depinject.Supply( + // supply custom module basics + map[string]module.AppModuleBasic{ + genutiltypes.ModuleName: genutil.NewAppModuleBasic(genutiltypes.DefaultMessageValidator), + govtypes.ModuleName: gov.NewAppModuleBasic(getGovProposalHandlers()), + }, + ), + ) } -// NewSgeApp returns a reference to an initialized Sge. -func NewSgeApp( +// NewApp returns a reference to an initialized Sge. +func NewApp( logger log.Logger, db dbm.DB, traceStore io.Writer, loadLatest bool, - skipUpgradeHeights map[int64]bool, - homePath string, - invCheckPeriod uint, - encodingConfig sgeappparams.EncodingConfig, appOpts servertypes.AppOptions, - wasmOpts []wasmkeeper.Option, baseAppOptions ...func(*baseapp.BaseApp), -) *SgeApp { - appCodec := encodingConfig.Marshaler - cdc := encodingConfig.Amino - interfaceRegistry := encodingConfig.InterfaceRegistry - - bApp := baseapp.NewBaseApp( - appName, - logger, - db, - encodingConfig.TxConfig.TxDecoder(), - baseAppOptions...) - bApp.SetCommitMultiStoreTracer(traceStore) - bApp.SetVersion(version.Version) - bApp.SetInterfaceRegistry(interfaceRegistry) - - app := &SgeApp{ - BaseApp: bApp, - cdc: cdc, - appCodec: appCodec, - interfaceRegistry: interfaceRegistry, - invCheckPeriod: invCheckPeriod, - } - - // Setup keepers - app.AppKeepers = keepers.NewAppKeeper( - appCodec, - bApp, - cdc, - mAccPerms, - skipUpgradeHeights, - homePath, - invCheckPeriod, - wasmOpts, - appOpts, +) (*App, error) { + overrideWasmVariables() + + var ( + app = &App{AppKeepers: &keepers.AppKeepers{ScopedKeepers: make(map[string]capabilitykeeper.ScopedKeeper)}} + appBuilder *runtime.AppBuilder + + // merge the AppConfig and other configuration in one config + appConfig = depinject.Configs( + Config(), + depinject.Supply( + appOpts, // supply app options + logger, // supply logger + // Supply with IBC keeper getter for the IBC modules with App Wiring. + // The IBC Keeper cannot be passed because it has not been initiated yet. + // Passing the getter, the app IBC Keeper will always be accessible. + // This needs to be removed after IBC supports App Wiring. + app.GetIBCKeeper, + app.GetCapabilityScopedKeeper, + + // here alternative options can be supplied to the DI container. + // those options can be used f.e to override the default behavior of some modules. + // for instance supplying a custom address codec for not using bech32 addresses. + // read the depinject documentation and depinject module wiring for more information + // on available options and how to use them. + ), + ) ) - if maxSize := os.Getenv("MAX_WASM_SIZE"); maxSize != "" { - // https://github.com/CosmWasm/wasmd#compile-time-parameters - val, _ := strconv.ParseInt(maxSize, 10, 32) - wasmtypes.MaxWasmSize = int(val) - } else { - wasmtypes.MaxWasmSize = defaultMaxWasmSize + if err := depinject.Inject(appConfig, + &appBuilder, + &app.appCodec, + &app.legacyAmino, + &app.txConfig, + &app.interfaceRegistry, + &app.AccountKeeper, + &app.BankKeeper, + &app.StakingKeeper, + &app.DistrKeeper, + &app.ConsensusParamsKeeper, + &app.SlashingKeeper, + &app.MintKeeper, + &app.GovKeeper, + &app.CrisisKeeper, + &app.UpgradeKeeper, + &app.ParamsKeeper, + &app.AuthzKeeper, + &app.EvidenceKeeper, + &app.FeeGrantKeeper, + &app.GroupKeeper, + &app.CircuitBreakerKeeper, + ); err != nil { + panic(err) } - // NOTE: we may consider parsing `appOpts` inside module constructors. For the moment - // we prefer to be more strict in what arguments the modules expect. - skipGenesisInvariants := cast.ToBool(appOpts.Get(crisis.FlagSkipGenesisInvariants)) - - // NOTE: Any module instantiated in the module manager that is later modified - // must be passed by reference here. - app.mm = module.NewManager(appModules(app, encodingConfig, skipGenesisInvariants)...) - - // During begin block slashing happens after distr.BeginBlocker so that - // there is nothing left over in the validator fee pool, so as to keep the - // CanWithdrawInvariant invariant. - // NOTE: staking module is required if HistoricalEntries param > 0 - app.mm.SetOrderBeginBlockers(orderBeginBlockers()...) - - app.mm.SetOrderEndBlockers(orderEndBlockers()...) + // add to default baseapp options + // enable optimistic execution + baseAppOptions = append(baseAppOptions, baseapp.SetOptimisticExecution()) - // NOTE: The genutils module must occur after staking so that pools are - // properly initialized with tokens from genesis accounts. - // NOTE: Capability module must occur first so that it can initialize any capabilities - // so that other modules that want to create or claim capabilities afterwards in InitChain - // can do so safely. - app.mm.SetOrderInitGenesis(orderInitBlockers()...) + // build app + app.App = appBuilder.Build(db, traceStore, baseAppOptions...) - app.mm.RegisterInvariants(app.CrisisKeeper) + app.setupUpgradeStoreLoaders() - app.configurator = module.NewConfigurator( - app.appCodec, - app.MsgServiceRouter(), - app.GRPCQueryRouter(), - ) - app.mm.RegisterServices(app.configurator) + app.setupUpgradeHandlers() - // v47 - no dependecy injection, so register new gRPC services. - //#nosec - autocliv1.RegisterQueryServer(app.GRPCQueryRouter(), runtimeservices.NewAutoCLIQueryService(app.mm.Modules)) - reflectionSvc, err := runtimeservices.NewReflectionService() - if err != nil { - panic(err) + // register legacy modules + if err := app.registerIBCModules(appOpts); err != nil { + return nil, err } - reflectionv1.RegisterReflectionServiceServer(app.GRPCQueryRouter(), reflectionSvc) - wasmConfig, err := wasm.ReadWasmConfig(appOpts) - if err != nil { - panic("error while reading wasm config: " + err.Error()) + // register streaming services + if err := app.RegisterStreamingServices(appOpts, app.kvStoreKeys()); err != nil { + return nil, err } - // create the simulation manager and define the order of the modules for deterministic simulations - // - // NOTE: this is not required apps that don't use the simulator for fuzz testing - // transactions - app.sm = module.NewSimulationManager( - simulationModules(app, encodingConfig, skipGenesisInvariants)...) - - app.sm.RegisterStoreDecoders() - - // initialize stores - app.MountKVStores(app.GetKVStoreKey()) - app.MountTransientStores(app.GetTransientStoreKey()) - app.MountMemoryStores(app.GetMemoryStoreKey()) - - // initialize BaseApp - app.SetInitChainer(app.InitChainer) - app.SetBeginBlocker(app.BeginBlocker) - anteHandler, err := NewAnteHandler( - HandlerOptions{ - HandlerOptions: ante.HandlerOptions{ - AccountKeeper: app.AppKeepers.AccountKeeper, - BankKeeper: app.AppKeepers.BankKeeper, - FeegrantKeeper: app.AppKeepers.FeeGrantKeeper, - SignModeHandler: encodingConfig.TxConfig.SignModeHandler(), - SigGasConsumer: ante.DefaultSigVerificationGasConsumer, - }, + /**** Module Options ****/ - GovKeeper: *app.AppKeepers.GovKeeper, - IBCKeeper: app.AppKeepers.IBCKeeper, - BankKeeper: app.AppKeepers.BankKeeper, - TxCounterStoreKey: app.AppKeepers.GetKey(wasmtypes.StoreKey), - WasmConfig: &wasmConfig, - WasmKeeper: &app.WasmKeeper, - Cdc: appCodec, + app.ModuleManager.RegisterInvariants(app.CrisisKeeper) - StakingKeeper: *app.AppKeepers.StakingKeeper, - }, - ) - if err != nil { - panic(fmt.Errorf(ErrTextFailedToCreateAnteHandler, err)) - } - app.SetAnteHandler(anteHandler) - app.SetEndBlocker(app.EndBlocker) - - if manager := app.SnapshotManager(); manager != nil { - err = manager.RegisterExtensions( - wasmkeeper.NewWasmSnapshotter(app.CommitMultiStore(), &app.AppKeepers.WasmKeeper), - // https://github.com/cosmos/ibc-go/pull/5439 - ibcwasmkeeper.NewWasmSnapshotter(app.CommitMultiStore(), &app.AppKeepers.WasmClientKeeper), - ) - if err != nil { - panic("failed to register snapshot extension: " + err.Error()) - } + // create the simulation manager and define the order of the modules for deterministic simulations + overrideModules := map[string]module.AppModuleSimulation{ + authtypes.ModuleName: auth.NewAppModule(app.appCodec, app.AccountKeeper, authsims.RandomGenesisAccounts, app.GetSubspace(authtypes.ModuleName)), } + app.sm = module.NewSimulationManagerFromAppModules(app.ModuleManager.Modules, overrideModules) + app.sm.RegisterStoreDecoders() - app.setupUpgradeHandlers() - app.setupUpgradeStoreLoaders() - - if loadLatest { - if err := app.LoadLatestVersion(); err != nil { - tmos.Exit(err.Error()) - } - ctx := app.BaseApp.NewUncachedContext(true, tmproto.Header{}) - - // https://github.com/cosmos/ibc-go/pull/5439 - if err := ibcwasmkeeper.InitializePinnedCodes(ctx, appCodec); err != nil { - tmos.Exit(fmt.Sprintf("wasmlckeeper failed initialize pinned codes %s", err)) - } - - if err := app.AppKeepers.WasmKeeper.InitializePinnedCodes(ctx); err != nil { - tmos.Exit(fmt.Sprintf("app.AppKeepers.WasmKeeper failed initialize pinned codes %s", err)) + // A custom InitChainer sets if extra pre-init-genesis logic is required. + // This is necessary for manually registered modules that do not support app wiring. + // Manually set the module version map as shown below. + // The upgrade module will automatically handle de-duplication of the module version map. + app.SetInitChainer(func(ctx sdk.Context, req *abci.RequestInitChain) (*abci.ResponseInitChain, error) { + if err := app.UpgradeKeeper.SetModuleVersionMap(ctx, app.ModuleManager.GetVersionMap()); err != nil { + return nil, err } + return app.App.InitChainer(ctx, req) + }) - app.AppKeepers.CapabilityKeeper.Seal() + if err := app.Load(loadLatest); err != nil { + return nil, err } - return app + return app, app.WasmKeeper.InitializePinnedCodes(app.NewUncachedContext(true, tmproto.Header{})) } -// MakeCodecs constructs the *std.Codec and *codec.LegacyAmino instances used by -// Sge. It is useful for tests and clients who do not want to construct the -// full sge application -func MakeCodecs() (codec.Codec, - *codec.LegacyAmino, -) { - config := MakeEncodingConfig() - return config.Marshaler, config.Amino +// LegacyAmino returns App's amino codec. +// +// NOTE: This is solely to be used for testing purposes as it may be desirable +// for modules to register their own custom testing types. +func (app *App) LegacyAmino() *codec.LegacyAmino { + return app.legacyAmino } -// Name returns the name of the App -func (app *SgeApp) Name() string { return app.BaseApp.Name() } - -// GetBaseApp returns the base app of the application -func (app *SgeApp) GetBaseApp() *baseapp.BaseApp { return app.BaseApp } +// AppCodec returns App's app codec. +// +// NOTE: This is solely to be used for testing purposes as it may be desirable +// for modules to register their own custom testing types. +func (app *App) AppCodec() codec.Codec { + return app.appCodec +} -// BeginBlocker application updates every begin block -func (app *SgeApp) BeginBlocker(ctx sdk.Context, req abci.RequestBeginBlock) abci.ResponseBeginBlock { - return app.mm.BeginBlock(ctx, req) +// InterfaceRegistry returns App's interfaceRegistry. +func (app *App) InterfaceRegistry() codectypes.InterfaceRegistry { + return app.interfaceRegistry } -// EndBlocker application updates every end block -func (app *SgeApp) EndBlocker(ctx sdk.Context, req abci.RequestEndBlock) abci.ResponseEndBlock { - return app.mm.EndBlock(ctx, req) +// TxConfig returns App's tx config. +func (app *App) TxConfig() client.TxConfig { + return app.txConfig } -// InitChainer application update at chain initialization -func (app *SgeApp) InitChainer(ctx sdk.Context, req abci.RequestInitChain) abci.ResponseInitChain { - var genesisState GenesisState - if err := tmjson.Unmarshal(req.AppStateBytes, &genesisState); err != nil { - panic(err) +// GetKey returns the KVStoreKey for the provided store key. +func (app *App) GetKey(storeKey string) *storetypes.KVStoreKey { + kvStoreKey, ok := app.UnsafeFindStoreKey(storeKey).(*storetypes.KVStoreKey) + if !ok { + return nil } - - app.UpgradeKeeper.SetModuleVersionMap(ctx, app.mm.GetVersionMap()) - - return app.mm.InitGenesis(ctx, app.appCodec, genesisState) + return kvStoreKey } -// LoadHeight loads a particular height -func (app *SgeApp) LoadHeight(height int64) error { - return app.LoadVersion(height) -} +// GetMemKey returns the MemoryStoreKey for the provided store key. +func (app *App) GetMemKey(storeKey string) *storetypes.MemoryStoreKey { + key, ok := app.UnsafeFindStoreKey(storeKey).(*storetypes.MemoryStoreKey) + if !ok { + return nil + } -// ModuleAccountAddrs returns all the app's module account addresses. -func (app *SgeApp) ModuleAccountAddrs() map[string]bool { - modAccAddrs := make(map[string]bool) + return key +} - //#nosec - for acc := range mAccPerms { - modAccAddrs[authtypes.NewModuleAddress(acc).String()] = true +// kvStoreKeys returns all the kv store keys registered inside App. +func (app *App) kvStoreKeys() map[string]*storetypes.KVStoreKey { + keys := make(map[string]*storetypes.KVStoreKey) + for _, k := range app.GetStoreKeys() { + if kv, ok := k.(*storetypes.KVStoreKey); ok { + keys[kv.Name()] = kv + } } - return modAccAddrs + return keys } -// LegacyAmino returns SgeApp's amino codec. -// -// NOTE: This is solely to be used for testing purposes as it may be desirable -// for modules to register their own custom testing types. -func (app *SgeApp) LegacyAmino() *codec.LegacyAmino { - return app.cdc +// GetSubspace returns a param subspace for a given module name. +func (app *App) GetSubspace(moduleName string) paramstypes.Subspace { + subspace, _ := app.ParamsKeeper.GetSubspace(moduleName) + return subspace } -// AppCodec returns Sge's app codec. -// -// NOTE: This is solely to be used for testing purposes as it may be desirable -// for modules to register their own custom testing types. -func (app *SgeApp) AppCodec() codec.Codec { - return app.appCodec +// GetIBCKeeper returns the IBC keeper. +func (app *App) GetIBCKeeper() *ibckeeper.Keeper { + return app.IBCKeeper } -// InterfaceRegistry returns Sge's InterfaceRegistry -func (app *SgeApp) InterfaceRegistry() types.InterfaceRegistry { - return app.interfaceRegistry +// GetCapabilityScopedKeeper returns the capability scoped keeper. +func (app *App) GetCapabilityScopedKeeper(moduleName string) capabilitykeeper.ScopedKeeper { + sk, ok := app.ScopedKeepers[moduleName] + if !ok { + sk = app.CapabilityKeeper.ScopeToModule(moduleName) + app.ScopedKeepers[moduleName] = sk + } + return sk } -// GetSubspace returns a param subspace for a given module name. -// -// NOTE: This is solely to be used for testing purposes. -func (app *SgeApp) GetSubspace(moduleName string) paramstypes.Subspace { - subspace, _ := app.ParamsKeeper.GetSubspace(moduleName) - return subspace +// SimulationManager implements the SimulationApp interface. +func (app *App) SimulationManager() *module.SimulationManager { + return app.sm } // RegisterAPIRoutes registers all application module routes with the provided // API server. -func (app *SgeApp) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig) { - clientCtx := apiSvr.ClientCtx - // Register new tx routes from grpc-gateway. - authtx.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) - // Register new tendermint queries routes from grpc-gateway. - tmservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) - // Register node gRPC service for grpc-gateway. - nodeservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) - // Register grpc-gateway routes for all modules. - ModuleBasics.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) - - // register swagger API from root so that other applications can override easily - if apiConfig.Swagger { - RegisterSwaggerAPI(apiSvr.Router) +func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig) { + app.App.RegisterAPIRoutes(apiSvr, apiConfig) + // register swagger API in app.go so that other applications can override easily + if err := server.RegisterSwaggerAPI(apiSvr.ClientCtx, apiSvr.Router, apiConfig.Swagger); err != nil { + panic(err) } -} -// RegisterTxService implements the Application.RegisterTxService method. -func (app *SgeApp) RegisterTxService(clientCtx client.Context) { - authtx.RegisterTxService( - app.BaseApp.GRPCQueryRouter(), - clientCtx, - app.BaseApp.Simulate, - app.interfaceRegistry, - ) + // register app's OpenAPI routes. + docs.RegisterOpenAPIService(Name, apiSvr.Router) } -// RegisterTendermintService implements the Application.RegisterTendermintService method. -func (app *SgeApp) RegisterTendermintService(clientCtx client.Context) { - tmservice.RegisterTendermintService(clientCtx, app.BaseApp.GRPCQueryRouter(), app.interfaceRegistry, app.Query) +// GetMaccPerms returns a copy of the module account permissions +// +// NOTE: This is solely to be used for testing purposes. +func GetMaccPerms() map[string][]string { + dup := make(map[string][]string) + for _, perms := range moduleAccPerms { + dup[perms.Account] = perms.Permissions + } + return dup } -func (app *SgeApp) RegisterNodeService(clientCtx client.Context) { - nodeservice.RegisterNodeService(clientCtx, app.GRPCQueryRouter()) +// BlockedAddresses returns all the app's blocked account addresses. +func BlockedAddresses() map[string]bool { + result := make(map[string]bool) + if len(blockAccAddrs) > 0 { + for _, addr := range blockAccAddrs { + result[addr] = true + } + } else { + for addr := range GetMaccPerms() { + result[addr] = true + } + } + return result } // configure store loader that checks if version == upgradeHeight and applies store upgrades -func (app *SgeApp) setupUpgradeStoreLoaders() { +func (app *App) setupUpgradeStoreLoaders() { upgradeInfo, err := app.UpgradeKeeper.ReadUpgradeInfoFromDisk() if err != nil { panic(fmt.Sprintf("failed to read upgrade info from disk %s", err)) @@ -438,48 +403,29 @@ func (app *SgeApp) setupUpgradeStoreLoaders() { for _, upgrade := range Upgrades { if upgradeInfo.Name == upgrade.UpgradeName { - storeUpgrade := upgrade.StoreUpgrades - app.SetStoreLoader( - upgradetypes.UpgradeStoreLoader(upgradeInfo.Height, &storeUpgrade), - ) + storeUpgrades := upgrade.StoreUpgrades + app.SetStoreLoader(upgradetypes.UpgradeStoreLoader(upgradeInfo.Height, &storeUpgrades)) } } } -func (app *SgeApp) setupUpgradeHandlers() { +func (app *App) setupUpgradeHandlers() { for _, upgrade := range Upgrades { app.UpgradeKeeper.SetUpgradeHandler( upgrade.UpgradeName, upgrade.CreateUpgradeHandler( - app.mm, - app.configurator, - &app.AppKeepers, + app.ModuleManager, + app.Configurator(), + app.AppKeepers, ), ) } } -// RegisterSwaggerAPI registers swagger route with API Server -func RegisterSwaggerAPI(rtr *mux.Router) { - statikFS, err := fs.New() - if err != nil { - panic(err) - } - - staticServer := http.FileServer(statikFS) - rtr.PathPrefix("/swagger/").Handler(http.StripPrefix("/swagger/", staticServer)) -} - -// GetMaccPerms returns a copy of the module account permissions -func GetMaccPerms() map[string][]string { - dupMaccPerms := make(map[string][]string) - for k, v := range mAccPerms { - dupMaccPerms[k] = v - } - return dupMaccPerms -} - -// SimulationManager implements the SimulationApp interface -func (app *SgeApp) SimulationManager() *module.SimulationManager { - return app.sm +// overrideWasmVariables overrides the wasm variables to: +// - allow for larger wasm files +func overrideWasmVariables() { + // Override Wasm size limitation from WASMD. + wasmtypes.MaxWasmSize = defaultMaxWasmSize + wasmtypes.MaxProposalWasmSize = wasmtypes.MaxWasmSize } diff --git a/app/app_config.go b/app/app_config.go new file mode 100644 index 00000000..e7188caa --- /dev/null +++ b/app/app_config.go @@ -0,0 +1,281 @@ +package app + +import ( + "time" + + runtimev1alpha1 "cosmossdk.io/api/cosmos/app/runtime/v1alpha1" + appv1alpha1 "cosmossdk.io/api/cosmos/app/v1alpha1" + authmodulev1 "cosmossdk.io/api/cosmos/auth/module/v1" + authzmodulev1 "cosmossdk.io/api/cosmos/authz/module/v1" + bankmodulev1 "cosmossdk.io/api/cosmos/bank/module/v1" + circuitmodulev1 "cosmossdk.io/api/cosmos/circuit/module/v1" + consensusmodulev1 "cosmossdk.io/api/cosmos/consensus/module/v1" + crisismodulev1 "cosmossdk.io/api/cosmos/crisis/module/v1" + distrmodulev1 "cosmossdk.io/api/cosmos/distribution/module/v1" + evidencemodulev1 "cosmossdk.io/api/cosmos/evidence/module/v1" + feegrantmodulev1 "cosmossdk.io/api/cosmos/feegrant/module/v1" + genutilmodulev1 "cosmossdk.io/api/cosmos/genutil/module/v1" + govmodulev1 "cosmossdk.io/api/cosmos/gov/module/v1" + groupmodulev1 "cosmossdk.io/api/cosmos/group/module/v1" + paramsmodulev1 "cosmossdk.io/api/cosmos/params/module/v1" + slashingmodulev1 "cosmossdk.io/api/cosmos/slashing/module/v1" + stakingmodulev1 "cosmossdk.io/api/cosmos/staking/module/v1" + txconfigv1 "cosmossdk.io/api/cosmos/tx/config/v1" + upgrademodulev1 "cosmossdk.io/api/cosmos/upgrade/module/v1" + vestingmodulev1 "cosmossdk.io/api/cosmos/vesting/module/v1" + "cosmossdk.io/core/appconfig" + circuittypes "cosmossdk.io/x/circuit/types" + evidencetypes "cosmossdk.io/x/evidence/types" + "cosmossdk.io/x/feegrant" + upgradetypes "cosmossdk.io/x/upgrade/types" + wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" + "github.com/cosmos/cosmos-sdk/runtime" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" + "github.com/cosmos/cosmos-sdk/x/authz" + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + consensustypes "github.com/cosmos/cosmos-sdk/x/consensus/types" + crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" + distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" + genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/cosmos-sdk/x/group" + paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" + slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" + stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + icatypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/types" + ibcfeetypes "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/types" + ibctransfertypes "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types" + ibcexported "github.com/cosmos/ibc-go/v8/modules/core/exported" + mintmodulev1 "github.com/sge-network/sge/api/sge/mint/module/v1" + minttypes "github.com/sge-network/sge/x/mint/types" + "google.golang.org/protobuf/types/known/durationpb" +) + +var ( + // NOTE: The genutils module must occur after staking so that pools are + // properly initialized with tokens from genesis accounts. + // NOTE: The genutils module must also occur after auth so that it can access the params from auth. + // NOTE: Capability module must occur first so that it can initialize any capabilities + // so that other modules that want to create or claim capabilities afterwards in InitChain + // can do so safely. + genesisModuleOrder = []string{ + // cosmos-sdk/ibc modules + capabilitytypes.ModuleName, + authtypes.ModuleName, + banktypes.ModuleName, + distrtypes.ModuleName, + stakingtypes.ModuleName, + slashingtypes.ModuleName, + govtypes.ModuleName, + minttypes.ModuleName, + crisistypes.ModuleName, + ibcexported.ModuleName, + genutiltypes.ModuleName, + evidencetypes.ModuleName, + authz.ModuleName, + ibctransfertypes.ModuleName, + icatypes.ModuleName, + ibcfeetypes.ModuleName, + feegrant.ModuleName, + paramstypes.ModuleName, + upgradetypes.ModuleName, + vestingtypes.ModuleName, + group.ModuleName, + consensustypes.ModuleName, + circuittypes.ModuleName, + // chain modules + wasmtypes.ModuleName, + } + + // During begin block slashing happens after distr.BeginBlocker so that + // there is nothing left over in the validator fee pool, so as to keep the + // CanWithdrawInvariant invariant. + // NOTE: staking module is required if HistoricalEntries param > 0 + // NOTE: capability module's beginblocker must come before any modules using capabilities (e.g. IBC) + beginBlockers = []string{ + // cosmos sdk modules + minttypes.ModuleName, + distrtypes.ModuleName, + slashingtypes.ModuleName, + evidencetypes.ModuleName, + stakingtypes.ModuleName, + authz.ModuleName, + genutiltypes.ModuleName, + // ibc modules + capabilitytypes.ModuleName, + ibcexported.ModuleName, + ibctransfertypes.ModuleName, + icatypes.ModuleName, + ibcfeetypes.ModuleName, + // chain modules + wasmtypes.ModuleName, + } + + endBlockers = []string{ + // cosmos sdk modules + crisistypes.ModuleName, + govtypes.ModuleName, + stakingtypes.ModuleName, + feegrant.ModuleName, + group.ModuleName, + genutiltypes.ModuleName, + // ibc modules + ibcexported.ModuleName, + ibctransfertypes.ModuleName, + capabilitytypes.ModuleName, + icatypes.ModuleName, + ibcfeetypes.ModuleName, + // chain modules + wasmtypes.ModuleName, + } + + preBlockers = []string{ + upgradetypes.ModuleName, + } + + // module account permissions + moduleAccPerms = []*authmodulev1.ModuleAccountPermission{ + {Account: authtypes.FeeCollectorName}, + {Account: distrtypes.ModuleName}, + {Account: minttypes.ModuleName, Permissions: []string{authtypes.Minter}}, + {Account: stakingtypes.BondedPoolName, Permissions: []string{authtypes.Burner, stakingtypes.ModuleName}}, + {Account: stakingtypes.NotBondedPoolName, Permissions: []string{authtypes.Burner, stakingtypes.ModuleName}}, + {Account: govtypes.ModuleName, Permissions: []string{authtypes.Burner}}, + {Account: ibctransfertypes.ModuleName, Permissions: []string{authtypes.Minter, authtypes.Burner}}, + {Account: ibcfeetypes.ModuleName}, + {Account: icatypes.ModuleName}, + {Account: wasmtypes.ModuleName, Permissions: []string{authtypes.Burner}}, + } + + // blocked account addresses + blockAccAddrs = []string{ + authtypes.FeeCollectorName, + distrtypes.ModuleName, + minttypes.ModuleName, + stakingtypes.BondedPoolName, + stakingtypes.NotBondedPoolName, + // We allow the following module accounts to receive funds: + // govtypes.ModuleName + } + + // appConfig application configuration (used by depinject) + appConfig = appconfig.Compose(&appv1alpha1.Config{ + Modules: []*appv1alpha1.ModuleConfig{ + { + Name: runtime.ModuleName, + Config: appconfig.WrapAny(&runtimev1alpha1.Module{ + AppName: Name, + PreBlockers: preBlockers, + BeginBlockers: beginBlockers, + EndBlockers: endBlockers, + InitGenesis: genesisModuleOrder, + OverrideStoreKeys: []*runtimev1alpha1.StoreKeyConfig{ + { + ModuleName: authtypes.ModuleName, + KvStoreKey: "acc", + }, + }, + // When ExportGenesis is not specified, the export genesis module order + // is equal to the init genesis order + // ExportGenesis: genesisModuleOrder, + // Uncomment if you want to set a custom migration order here. + // OrderMigrations: nil, + }), + }, + { + Name: authtypes.ModuleName, + Config: appconfig.WrapAny(&authmodulev1.Module{ + Bech32Prefix: AccountAddressPrefix, + ModuleAccountPermissions: moduleAccPerms, + // By default modules authority is the governance module. This is configurable with the following: + // Authority: "group", // A custom module authority can be set using a module name + // Authority: "cosmos1cwwv22j5ca08ggdv9c2uky355k908694z577tv", // or a specific address + }), + }, + { + Name: vestingtypes.ModuleName, + Config: appconfig.WrapAny(&vestingmodulev1.Module{}), + }, + { + Name: banktypes.ModuleName, + Config: appconfig.WrapAny(&bankmodulev1.Module{ + BlockedModuleAccountsOverride: blockAccAddrs, + }), + }, + { + Name: stakingtypes.ModuleName, + Config: appconfig.WrapAny(&stakingmodulev1.Module{ + // NOTE: specifying a prefix is only necessary when using bech32 addresses + // If not specfied, the auth Bech32Prefix appended with "valoper" and "valcons" is used by default + Bech32PrefixValidator: AccountAddressPrefix + "valoper", + Bech32PrefixConsensus: AccountAddressPrefix + "valcons", + }), + }, + { + Name: slashingtypes.ModuleName, + Config: appconfig.WrapAny(&slashingmodulev1.Module{}), + }, + { + Name: paramstypes.ModuleName, + Config: appconfig.WrapAny(¶msmodulev1.Module{}), + }, + { + Name: "tx", + Config: appconfig.WrapAny(&txconfigv1.Config{}), + }, + { + Name: genutiltypes.ModuleName, + Config: appconfig.WrapAny(&genutilmodulev1.Module{}), + }, + { + Name: authz.ModuleName, + Config: appconfig.WrapAny(&authzmodulev1.Module{}), + }, + { + Name: upgradetypes.ModuleName, + Config: appconfig.WrapAny(&upgrademodulev1.Module{}), + }, + { + Name: distrtypes.ModuleName, + Config: appconfig.WrapAny(&distrmodulev1.Module{}), + }, + { + Name: evidencetypes.ModuleName, + Config: appconfig.WrapAny(&evidencemodulev1.Module{}), + }, + { + Name: minttypes.ModuleName, + Config: appconfig.WrapAny(&mintmodulev1.Module{}), + }, + { + Name: group.ModuleName, + Config: appconfig.WrapAny(&groupmodulev1.Module{ + MaxExecutionPeriod: durationpb.New(time.Second * 1209600), + MaxMetadataLen: 255, + }), + }, + { + Name: feegrant.ModuleName, + Config: appconfig.WrapAny(&feegrantmodulev1.Module{}), + }, + { + Name: govtypes.ModuleName, + Config: appconfig.WrapAny(&govmodulev1.Module{}), + }, + { + Name: crisistypes.ModuleName, + Config: appconfig.WrapAny(&crisismodulev1.Module{}), + }, + { + Name: consensustypes.ModuleName, + Config: appconfig.WrapAny(&consensusmodulev1.Module{}), + }, + { + Name: circuittypes.ModuleName, + Config: appconfig.WrapAny(&circuitmodulev1.Module{}), + }, + }, + }) +) diff --git a/app/app_test.go b/app/app_test.go deleted file mode 100644 index 71adb6a6..00000000 --- a/app/app_test.go +++ /dev/null @@ -1,32 +0,0 @@ -package app_test - -import ( - "testing" - - wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" - tmdb "github.com/cometbft/cometbft-db" - "github.com/cometbft/cometbft/libs/log" - simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - "github.com/sge-network/sge/app" - "github.com/stretchr/testify/require" -) - -func TestApp(t *testing.T) { - panicFunc := func() { - db := tmdb.NewMemDB() - encCdc := app.MakeEncodingConfig() - app.NewSgeApp( - log.NewNopLogger(), - db, - nil, - true, - map[int64]bool{}, - "", - 0, - encCdc, - simtestutil.EmptyAppOptions{}, - []wasmkeeper.Option{}, - ) - } - require.NotPanics(t, panicFunc) -} diff --git a/app/config.go b/app/config.go new file mode 100644 index 00000000..7c3f0869 --- /dev/null +++ b/app/config.go @@ -0,0 +1,35 @@ +package app + +import ( + sdkmath "cosmossdk.io/math" + wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/sge-network/sge/app/params" +) + +func init() { + // Set prefixes + accountPubKeyPrefix := AccountAddressPrefix + "pub" + validatorAddressPrefix := AccountAddressPrefix + "valoper" + validatorPubKeyPrefix := AccountAddressPrefix + "valoperpub" + consNodeAddressPrefix := AccountAddressPrefix + "valcons" + consNodePubKeyPrefix := AccountAddressPrefix + "valconspub" + + // Set and seal config + config := sdk.GetConfig() + config.SetBech32PrefixForAccount(AccountAddressPrefix, accountPubKeyPrefix) + config.SetBech32PrefixForValidator(validatorAddressPrefix, validatorPubKeyPrefix) + config.SetBech32PrefixForConsensusNode(consNodeAddressPrefix, consNodePubKeyPrefix) + + config.SetAddressVerifier(wasmtypes.VerifyAddressLen()) + + err := sdk.RegisterDenom(params.HumanCoinUnit, sdkmath.LegacyOneDec()) + if err != nil { + panic(err) + } + err = sdk.RegisterDenom(params.BaseCoinUnit, sdkmath.LegacyNewDecWithPrec(1, params.SGEExponent)) + if err != nil { + panic(err) + } + config.Seal() +} diff --git a/app/const.go b/app/const.go deleted file mode 100644 index 8f5ce859..00000000 --- a/app/const.go +++ /dev/null @@ -1,3 +0,0 @@ -package app - -const appName = "sge" diff --git a/app/encoding.go b/app/encoding.go deleted file mode 100644 index c5d83b59..00000000 --- a/app/encoding.go +++ /dev/null @@ -1,17 +0,0 @@ -package app - -import ( - "github.com/cosmos/cosmos-sdk/std" - - "github.com/sge-network/sge/app/params" -) - -// MakeEncodingConfig creates an EncodingConfig for testing -func MakeEncodingConfig() params.EncodingConfig { - encodingConfig := params.MakeEncodingConfig() - std.RegisterLegacyAminoCodec(encodingConfig.Amino) - std.RegisterInterfaces(encodingConfig.InterfaceRegistry) - ModuleBasics.RegisterLegacyAminoCodec(encodingConfig.Amino) - ModuleBasics.RegisterInterfaces(encodingConfig.InterfaceRegistry) - return encodingConfig -} diff --git a/app/errors.go b/app/errors.go index d42e850e..9fa73667 100644 --- a/app/errors.go +++ b/app/errors.go @@ -3,5 +3,4 @@ package app // x/mint module sentinel errors const ( ErrTextVestingAccountStartBeforeEnd = "vesting start-time cannot be before end-time" - ErrTextFailedToCreateAnteHandler = "failed to create AnteHandler: %s" ) diff --git a/app/export.go b/app/export.go index 4b81b539..2b1771cd 100644 --- a/app/export.go +++ b/app/export.go @@ -5,7 +5,8 @@ import ( "fmt" "log" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + storetypes "cosmossdk.io/store/types" + cmtproto "github.com/cometbft/cometbft/proto/tendermint/types" servertypes "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" @@ -15,21 +16,23 @@ import ( // ExportAppStateAndValidators exports the state of the application for a genesis // file. -func (app *SgeApp) ExportAppStateAndValidators( - forZeroHeight bool, jailAllowedAddrs []string, modulesToExport []string, -) (servertypes.ExportedApp, error) { +func (app *App) ExportAppStateAndValidators(forZeroHeight bool, jailAllowedAddrs, modulesToExport []string) (servertypes.ExportedApp, error) { // as if they could withdraw from the start of the next block - ctx := app.NewContext(true, tmproto.Header{Height: app.LastBlockHeight()}) + ctx := app.NewContextLegacy(true, cmtproto.Header{Height: app.LastBlockHeight()}) // We export at last height + 1, because that's the height at which - // Tendermint will start InitChain. + // CometBFT will start InitChain. height := app.LastBlockHeight() + 1 if forZeroHeight { height = 0 app.prepForZeroHeightGenesis(ctx, jailAllowedAddrs) } - genState := app.mm.ExportGenesisForModules(ctx, app.appCodec, modulesToExport) + genState, err := app.ModuleManager.ExportGenesisForModules(ctx, app.appCodec, modulesToExport) + if err != nil { + return servertypes.ExportedApp{}, err + } + appState, err := json.MarshalIndent(genState, "", " ") if err != nil { return servertypes.ExportedApp{}, err @@ -47,10 +50,24 @@ func (app *SgeApp) ExportAppStateAndValidators( // prepare for fresh start at zero height // NOTE zero height genesis is a temporary feature which will be deprecated // -// in favour of export at a block height -func (app *SgeApp) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs []string) { - // get allowed validators - applyAllowedAddrs, allowedAddrsMap := app.getJailAllowedValidatorsMap(ctx, jailAllowedAddrs) +// in favor of export at a block height +func (app *App) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs []string) { + applyAllowedAddrs := false + + // check if there is a allowed address list + if len(jailAllowedAddrs) > 0 { + applyAllowedAddrs = true + } + + allowedAddrsMap := make(map[string]bool) + + for _, addr := range jailAllowedAddrs { + _, err := sdk.ValAddressFromBech32(addr) + if err != nil { + log.Fatal(err) + } + allowedAddrsMap[addr] = true + } /* Just to be safe, assert the invariants on current state. */ app.CrisisKeeper.AssertInvariants(ctx) @@ -58,17 +75,34 @@ func (app *SgeApp) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs [] /* Handle fee distribution state. */ // withdraw all validator commission - app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { - _, err := app.DistrKeeper.WithdrawValidatorCommission(ctx, val.GetOperator()) + err := app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { + valBz, err := app.StakingKeeper.ValidatorAddressCodec().StringToBytes(val.GetOperator()) if err != nil { - log := app.DistrKeeper.Logger(ctx) - log.Error(fmt.Sprintf("withdraw validator commission: %v", err)) + panic(err) } + _, _ = app.DistrKeeper.WithdrawValidatorCommission(ctx, valBz) return false }) + if err != nil { + panic(err) + } // withdraw all delegator rewards - dels := app.withdrawAllDelegatorRewards(ctx) + dels, err := app.StakingKeeper.GetAllDelegations(ctx) + if err != nil { + panic(err) + } + + for _, delegation := range dels { + valAddr, err := sdk.ValAddressFromBech32(delegation.ValidatorAddress) + if err != nil { + panic(err) + } + + delAddr := sdk.MustAccAddressFromBech32(delegation.DelegatorAddress) + + _, _ = app.DistrKeeper.WithdrawDelegationRewards(ctx, delAddr, valAddr) + } // clear validator slash events app.DistrKeeper.DeleteAllValidatorSlashEvents(ctx) @@ -81,151 +115,95 @@ func (app *SgeApp) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs [] ctx = ctx.WithBlockHeight(0) // reinitialize all validators - app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { + err = app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { + valBz, err := app.StakingKeeper.ValidatorAddressCodec().StringToBytes(val.GetOperator()) + if err != nil { + panic(err) + } // donate any unwithdrawn outstanding reward fraction tokens to the community pool - scraps := app.DistrKeeper.GetValidatorOutstandingRewardsCoins(ctx, val.GetOperator()) - feePool := app.DistrKeeper.GetFeePool(ctx) + scraps, err := app.DistrKeeper.GetValidatorOutstandingRewardsCoins(ctx, valBz) + if err != nil { + panic(err) + } + feePool, err := app.DistrKeeper.FeePool.Get(ctx) + if err != nil { + panic(err) + } feePool.CommunityPool = feePool.CommunityPool.Add(scraps...) - app.DistrKeeper.SetFeePool(ctx, feePool) + if err := app.DistrKeeper.FeePool.Set(ctx, feePool); err != nil { + panic(err) + } - if err := app.DistrKeeper.Hooks().AfterValidatorCreated(ctx, val.GetOperator()); err != nil { + if err := app.DistrKeeper.Hooks().AfterValidatorCreated(ctx, valBz); err != nil { panic(err) } return false }) // reinitialize all delegations - app.reInitializeAllDelegators(ctx, dels) - - // reset context height - ctx = ctx.WithBlockHeight(height) - - /* Handle staking state. */ - - app.resetRedelegationCreationHeight(ctx) - - app.resetUnboundingdelegationCreationHeight(ctx) - - app.resetValidatorsBondHeights(ctx, applyAllowedAddrs, allowedAddrsMap) - - /* Handle slashing state. */ - - // reset start height on signing infos - app.SlashingKeeper.IterateValidatorSigningInfos( - ctx, - func(addr sdk.ConsAddress, info slashingtypes.ValidatorSigningInfo) (stop bool) { - info.StartHeight = 0 - app.SlashingKeeper.SetValidatorSigningInfo(ctx, addr, info) - return false - }, - ) -} - -func (app *SgeApp) reInitializeAllDelegators(ctx sdk.Context, dels stakingtypes.Delegations) { for _, del := range dels { valAddr, err := sdk.ValAddressFromBech32(del.ValidatorAddress) if err != nil { panic(err) } - delAddr, err := sdk.AccAddressFromBech32(del.DelegatorAddress) - if err != nil { - panic(err) - } + delAddr := sdk.MustAccAddressFromBech32(del.DelegatorAddress) + if err := app.DistrKeeper.Hooks().BeforeDelegationCreated(ctx, delAddr, valAddr); err != nil { - panic(err) + // never called as BeforeDelegationCreated always returns nil + panic(fmt.Errorf("error while incrementing period: %w", err)) } + if err := app.DistrKeeper.Hooks().AfterDelegationModified(ctx, delAddr, valAddr); err != nil { - panic(err) + // never called as AfterDelegationModified always returns nil + panic(fmt.Errorf("error while creating a new delegation period record: %w", err)) } } -} - -func (app *SgeApp) getJailAllowedValidatorsMap( - _ sdk.Context, - jailAllowedAddrs []string, -) (bool, map[string]bool) { - applyAllowedAddrs := false - // check if there is a allowed address list - if len(jailAllowedAddrs) > 0 { - applyAllowedAddrs = true - } + // reset context height + ctx = ctx.WithBlockHeight(height) - allowedAddrsMap := make(map[string]bool) + /* Handle staking state. */ - for _, addr := range jailAllowedAddrs { - _, err := sdk.ValAddressFromBech32(addr) - if err != nil { - log.Fatal(err) + // iterate through redelegations, reset creation height + err = app.StakingKeeper.IterateRedelegations(ctx, func(_ int64, red stakingtypes.Redelegation) (stop bool) { + for i := range red.Entries { + red.Entries[i].CreationHeight = 0 } - allowedAddrsMap[addr] = true - } - return applyAllowedAddrs, allowedAddrsMap -} - -func (app *SgeApp) withdrawAllDelegatorRewards(ctx sdk.Context) []stakingtypes.Delegation { - dels := app.StakingKeeper.GetAllDelegations(ctx) - for _, delegation := range dels { - valAddr, err := sdk.ValAddressFromBech32(delegation.ValidatorAddress) + err = app.StakingKeeper.SetRedelegation(ctx, red) if err != nil { panic(err) } + return false + }) + if err != nil { + panic(err) + } - delAddr, err := sdk.AccAddressFromBech32(delegation.DelegatorAddress) - if err != nil { - panic(err) + // iterate through unbonding delegations, reset creation height + err = app.StakingKeeper.IterateUnbondingDelegations(ctx, func(_ int64, ubd stakingtypes.UnbondingDelegation) (stop bool) { + for i := range ubd.Entries { + ubd.Entries[i].CreationHeight = 0 } - _, err = app.DistrKeeper.WithdrawDelegationRewards(ctx, delAddr, valAddr) + err = app.StakingKeeper.SetUnbondingDelegation(ctx, ubd) if err != nil { panic(err) } + return false + }) + if err != nil { + panic(err) } - return dels -} - -func (app *SgeApp) resetRedelegationCreationHeight(ctx sdk.Context) { - // iterate through redelegations, reset creation height - app.StakingKeeper.IterateRedelegations( - ctx, - func(_ int64, red stakingtypes.Redelegation) (stop bool) { - for i := range red.Entries { - red.Entries[i].CreationHeight = 0 - } - app.StakingKeeper.SetRedelegation(ctx, red) - return false - }, - ) -} - -func (app *SgeApp) resetUnboundingdelegationCreationHeight(ctx sdk.Context) { - // iterate through unbonding delegations, reset creation height - app.StakingKeeper.IterateUnbondingDelegations( - ctx, - func(_ int64, ubd stakingtypes.UnbondingDelegation) (stop bool) { - for i := range ubd.Entries { - ubd.Entries[i].CreationHeight = 0 - } - app.StakingKeeper.SetUnbondingDelegation(ctx, ubd) - return false - }, - ) -} -func (app *SgeApp) resetValidatorsBondHeights( - ctx sdk.Context, - applyAllowedAddrs bool, - allowedAddrsMap map[string]bool, -) { // Iterate through validators by power descending, reset bond heights, and // update bond intra-tx counters. - store := ctx.KVStore(app.AppKeepers.GetKey(stakingtypes.StoreKey)) - iter := sdk.KVStoreReversePrefixIterator(store, stakingtypes.ValidatorsKey) + store := ctx.KVStore(app.GetKey(stakingtypes.StoreKey)) + iter := storetypes.KVStoreReversePrefixIterator(store, stakingtypes.ValidatorsKey) counter := int16(0) for ; iter.Valid(); iter.Next() { addr := sdk.ValAddress(stakingtypes.AddressFromValidatorsKey(iter.Key())) - validator, found := app.StakingKeeper.GetValidator(ctx, addr) - if !found { + validator, err := app.StakingKeeper.GetValidator(ctx, addr) + if err != nil { panic("expected validator, not found") } @@ -234,16 +212,33 @@ func (app *SgeApp) resetValidatorsBondHeights( validator.Jailed = true } - app.StakingKeeper.SetValidator(ctx, validator) + if err := app.StakingKeeper.SetValidator(ctx, validator); err != nil { + panic(err) + } counter++ } if err := iter.Close(); err != nil { - log.Println(err) + app.Logger().Error("error while closing the key-value store reverse prefix iterator: ", err) + return } - _, err := app.StakingKeeper.ApplyAndReturnValidatorSetUpdates(ctx) + _, err = app.StakingKeeper.ApplyAndReturnValidatorSetUpdates(ctx) if err != nil { log.Fatal(err) } + + /* Handle slashing state. */ + + // reset start height on signing infos + if err := app.SlashingKeeper.IterateValidatorSigningInfos( + ctx, + func(addr sdk.ConsAddress, info slashingtypes.ValidatorSigningInfo) (stop bool) { + info.StartHeight = 0 + _ = app.SlashingKeeper.SetValidatorSigningInfo(ctx, addr, info) + return false + }, + ); err != nil { + log.Fatal(err) + } } diff --git a/app/export_test.go b/app/export_test.go deleted file mode 100644 index ad4ed98d..00000000 --- a/app/export_test.go +++ /dev/null @@ -1,39 +0,0 @@ -package app_test - -import ( - "testing" - - "github.com/stretchr/testify/require" - - "github.com/sge-network/sge/testutil/simapp" -) - -func TestExport(t *testing.T) { - testCases := []struct { - name string - forZeroHeight bool - }{ - { - "for zero height", - true, - }, - { - "for non-zero height", - false, - }, - } - for _, tc := range testCases { - t.Run(tc.name, func(t *testing.T) { - tApp, _, err := simapp.GetTestObjectsWithOptions( - simapp.Options{ - CreateGenesisValidators: true, - }, - ) - require.NoError(t, err) - - tApp.Commit() - _, err = tApp.ExportAppStateAndValidators(tc.forZeroHeight, []string{}, []string{}) - require.NoError(t, err, "ExportAppStateAndValidators should not have an error") - }) - } -} diff --git a/app/genesis.go b/app/genesis.go index c0352795..fb0e6223 100644 --- a/app/genesis.go +++ b/app/genesis.go @@ -12,9 +12,3 @@ import ( // the ModuleBasicManager which populates json from each BasicModule // object provided to it during init. type GenesisState map[string]json.RawMessage - -// NewDefaultGenesisState generates the default state for the application. -func NewDefaultGenesisState() GenesisState { - encCfg := MakeEncodingConfig() - return ModuleBasics.DefaultGenesis(encCfg.Marshaler) -} diff --git a/app/ibc.go b/app/ibc.go new file mode 100644 index 00000000..c384542d --- /dev/null +++ b/app/ibc.go @@ -0,0 +1,214 @@ +package app + +import ( + "cosmossdk.io/core/appmodule" + storetypes "cosmossdk.io/store/types" + "github.com/CosmWasm/wasmd/x/wasm" + cdctypes "github.com/cosmos/cosmos-sdk/codec/types" + servertypes "github.com/cosmos/cosmos-sdk/server/types" + "github.com/cosmos/cosmos-sdk/types/module" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" + paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" + "github.com/cosmos/ibc-go/modules/capability" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + icamodule "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts" + icacontroller "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller" + icacontrollerkeeper "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/keeper" + icacontrollertypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/types" + icahost "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host" + icahostkeeper "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/keeper" + icahosttypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/types" + icatypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/types" + ibcfee "github.com/cosmos/ibc-go/v8/modules/apps/29-fee" + ibcfeekeeper "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/keeper" + ibcfeetypes "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/types" + ibctransfer "github.com/cosmos/ibc-go/v8/modules/apps/transfer" + ibctransferkeeper "github.com/cosmos/ibc-go/v8/modules/apps/transfer/keeper" + ibctransfertypes "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types" + ibc "github.com/cosmos/ibc-go/v8/modules/core" + ibcclienttypes "github.com/cosmos/ibc-go/v8/modules/core/02-client/types" + ibcconnectiontypes "github.com/cosmos/ibc-go/v8/modules/core/03-connection/types" + porttypes "github.com/cosmos/ibc-go/v8/modules/core/05-port/types" + ibcexported "github.com/cosmos/ibc-go/v8/modules/core/exported" + ibckeeper "github.com/cosmos/ibc-go/v8/modules/core/keeper" + solomachine "github.com/cosmos/ibc-go/v8/modules/light-clients/06-solomachine" + ibctm "github.com/cosmos/ibc-go/v8/modules/light-clients/07-tendermint" + + wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" +) + +// registerIBCModules register IBC keepers and non dependency inject modules. +func (app *App) registerIBCModules(appOpts servertypes.AppOptions) error { + // set up non depinject support modules store keys + if err := app.RegisterStores( + storetypes.NewKVStoreKey(capabilitytypes.StoreKey), + storetypes.NewKVStoreKey(ibcexported.StoreKey), + storetypes.NewKVStoreKey(ibctransfertypes.StoreKey), + storetypes.NewKVStoreKey(ibcfeetypes.StoreKey), + storetypes.NewKVStoreKey(icahosttypes.StoreKey), + storetypes.NewKVStoreKey(icacontrollertypes.StoreKey), + storetypes.NewMemoryStoreKey(capabilitytypes.MemStoreKey), + storetypes.NewTransientStoreKey(paramstypes.TStoreKey), + ); err != nil { + return err + } + + // register the key tables for legacy param subspaces + keyTable := ibcclienttypes.ParamKeyTable() + keyTable.RegisterParamSet(&ibcconnectiontypes.Params{}) + app.ParamsKeeper.Subspace(ibcexported.ModuleName).WithKeyTable(keyTable) + app.ParamsKeeper.Subspace(ibctransfertypes.ModuleName).WithKeyTable(ibctransfertypes.ParamKeyTable()) + app.ParamsKeeper.Subspace(icacontrollertypes.SubModuleName).WithKeyTable(icacontrollertypes.ParamKeyTable()) + app.ParamsKeeper.Subspace(icahosttypes.SubModuleName).WithKeyTable(icahosttypes.ParamKeyTable()) + + // add capability keeper and ScopeToModule for ibc module + app.CapabilityKeeper = capabilitykeeper.NewKeeper( + app.AppCodec(), + app.GetKey(capabilitytypes.StoreKey), + app.GetMemKey(capabilitytypes.MemStoreKey), + ) + + // add capability keeper and ScopeToModule for ibc module + scopedIBCKeeper := app.CapabilityKeeper.ScopeToModule(ibcexported.ModuleName) + scopedIBCTransferKeeper := app.CapabilityKeeper.ScopeToModule(ibctransfertypes.ModuleName) + scopedICAControllerKeeper := app.CapabilityKeeper.ScopeToModule(icacontrollertypes.SubModuleName) + scopedICAHostKeeper := app.CapabilityKeeper.ScopeToModule(icahosttypes.SubModuleName) + + // Create IBC keeper + app.IBCKeeper = ibckeeper.NewKeeper( + app.appCodec, + app.GetKey(ibcexported.StoreKey), + app.GetSubspace(ibcexported.ModuleName), + app.StakingKeeper, + app.UpgradeKeeper, + scopedIBCKeeper, + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + ) + + // Register the proposal types + // Deprecated: Avoid adding new handlers, instead use the new proposal flow + // by granting the governance module the right to execute the message. + // See: https://docs.cosmos.network/main/modules/gov#proposal-messages + govRouter := govv1beta1.NewRouter() + govRouter.AddRoute(govtypes.RouterKey, govv1beta1.ProposalHandler) + + app.IBCFeeKeeper = ibcfeekeeper.NewKeeper( + app.appCodec, app.GetKey(ibcfeetypes.StoreKey), + app.IBCKeeper.ChannelKeeper, // may be replaced with IBC middleware + app.IBCKeeper.ChannelKeeper, + app.IBCKeeper.PortKeeper, app.AccountKeeper, app.BankKeeper, + ) + + // Create IBC transfer keeper + app.TransferKeeper = ibctransferkeeper.NewKeeper( + app.appCodec, + app.GetKey(ibctransfertypes.StoreKey), + app.GetSubspace(ibctransfertypes.ModuleName), + app.IBCFeeKeeper, + app.IBCKeeper.ChannelKeeper, + app.IBCKeeper.PortKeeper, + app.AccountKeeper, + app.BankKeeper, + scopedIBCTransferKeeper, + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + ) + + // Create interchain account keepers + app.ICAHostKeeper = icahostkeeper.NewKeeper( + app.appCodec, + app.GetKey(icahosttypes.StoreKey), + app.GetSubspace(icahosttypes.SubModuleName), + app.IBCFeeKeeper, // use ics29 fee as ics4Wrapper in middleware stack + app.IBCKeeper.ChannelKeeper, + app.IBCKeeper.PortKeeper, + app.AccountKeeper, + scopedICAHostKeeper, + app.MsgServiceRouter(), + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + ) + app.ICAHostKeeper.WithQueryRouter(app.GRPCQueryRouter()) + + app.ICAControllerKeeper = icacontrollerkeeper.NewKeeper( + app.appCodec, + app.GetKey(icacontrollertypes.StoreKey), + app.GetSubspace(icacontrollertypes.SubModuleName), + app.IBCFeeKeeper, // use ics29 fee as ics4Wrapper in middleware stack + app.IBCKeeper.ChannelKeeper, + app.IBCKeeper.PortKeeper, + scopedICAControllerKeeper, + app.MsgServiceRouter(), + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + ) + app.GovKeeper.SetLegacyRouter(govRouter) + + // Create IBC modules with ibcfee middleware + transferIBCModule := ibcfee.NewIBCMiddleware(ibctransfer.NewIBCModule(app.TransferKeeper), app.IBCFeeKeeper) + + // integration point for custom authentication modules + var noAuthzModule porttypes.IBCModule + icaControllerIBCModule := ibcfee.NewIBCMiddleware( + icacontroller.NewIBCMiddleware(noAuthzModule, app.ICAControllerKeeper), + app.IBCFeeKeeper, + ) + + icaHostIBCModule := ibcfee.NewIBCMiddleware(icahost.NewIBCModule(app.ICAHostKeeper), app.IBCFeeKeeper) + + // Create static IBC router, add transfer route, then set and seal it + ibcRouter := porttypes.NewRouter(). + AddRoute(ibctransfertypes.ModuleName, transferIBCModule). + AddRoute(icacontrollertypes.SubModuleName, icaControllerIBCModule). + AddRoute(icahosttypes.SubModuleName, icaHostIBCModule) + + wasmStack, err := app.registerWasmModules(appOpts) + if err != nil { + return err + } + ibcRouter.AddRoute(wasmtypes.ModuleName, wasmStack) + + app.IBCKeeper.SetRouter(ibcRouter) + + app.ScopedIBCKeeper = scopedIBCKeeper + app.ScopedIBCTransferKeeper = scopedIBCTransferKeeper + app.ScopedICAHostKeeper = scopedICAHostKeeper + app.ScopedICAControllerKeeper = scopedICAControllerKeeper + + // register IBC modules + if err := app.RegisterModules( + ibc.NewAppModule(app.IBCKeeper), + ibctransfer.NewAppModule(app.TransferKeeper), + ibcfee.NewAppModule(app.IBCFeeKeeper), + icamodule.NewAppModule(&app.ICAControllerKeeper, &app.ICAHostKeeper), + capability.NewAppModule(app.appCodec, *app.CapabilityKeeper, false), + ibctm.NewAppModule(), + solomachine.NewAppModule(), + ); err != nil { + return err + } + + return nil +} + +// RegisterIBC Since the IBC modules don't support dependency injection, +// we need to manually register the modules on the client side. +// This needs to be removed after IBC supports App Wiring. +func RegisterIBC(registry cdctypes.InterfaceRegistry) map[string]appmodule.AppModule { + modules := map[string]appmodule.AppModule{ + ibcexported.ModuleName: ibc.AppModule{}, + ibctransfertypes.ModuleName: ibctransfer.AppModule{}, + ibcfeetypes.ModuleName: ibcfee.AppModule{}, + icatypes.ModuleName: icamodule.AppModule{}, + capabilitytypes.ModuleName: capability.AppModule{}, + ibctm.ModuleName: ibctm.AppModule{}, + solomachine.ModuleName: solomachine.AppModule{}, + wasmtypes.ModuleName: wasm.AppModule{}, + } + + for name, m := range modules { + module.CoreAppModuleBasicAdaptor(name, m).RegisterInterfaces(registry) + } + + return modules +} diff --git a/app/keepers/keepers.go b/app/keepers/keepers.go index c2a05ba8..0bdc12d2 100644 --- a/app/keepers/keepers.go +++ b/app/keepers/keepers.go @@ -1,712 +1,94 @@ package keepers import ( - "path/filepath" + _ "cosmossdk.io/api/cosmos/tx/config/v1" // import for side-effects + _ "cosmossdk.io/x/circuit" // import for side-effects + circuitkeeper "cosmossdk.io/x/circuit/keeper" + _ "cosmossdk.io/x/evidence" // import for side-effects + evidencekeeper "cosmossdk.io/x/evidence/keeper" + feegrantkeeper "cosmossdk.io/x/feegrant/keeper" + _ "cosmossdk.io/x/feegrant/module" // import for side-effects + nftkeeper "cosmossdk.io/x/nft/keeper" + _ "cosmossdk.io/x/nft/module" // import for side-effects + _ "cosmossdk.io/x/upgrade" // import for side-effects + upgradekeeper "cosmossdk.io/x/upgrade/keeper" - "github.com/cosmos/cosmos-sdk/baseapp" - "github.com/cosmos/cosmos-sdk/codec" - servertypes "github.com/cosmos/cosmos-sdk/server/types" - storetypes "github.com/cosmos/cosmos-sdk/store/types" - sdk "github.com/cosmos/cosmos-sdk/types" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + _ "github.com/cosmos/cosmos-sdk/x/auth/tx/config" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/auth/vesting" // import for side-effects authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" + _ "github.com/cosmos/cosmos-sdk/x/authz/module" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/bank" // import for side-effects bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - capabilitykeeper "github.com/cosmos/cosmos-sdk/x/capability/keeper" - capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" - consensusparamkeeper "github.com/cosmos/cosmos-sdk/x/consensus/keeper" - consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" + _ "github.com/cosmos/cosmos-sdk/x/consensus" // import for side-effects + consensuskeeper "github.com/cosmos/cosmos-sdk/x/consensus/keeper" + _ "github.com/cosmos/cosmos-sdk/x/crisis" // import for side-effects crisiskeeper "github.com/cosmos/cosmos-sdk/x/crisis/keeper" - crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" + _ "github.com/cosmos/cosmos-sdk/x/distribution" // import for side-effects distrkeeper "github.com/cosmos/cosmos-sdk/x/distribution/keeper" - distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" - evidencekeeper "github.com/cosmos/cosmos-sdk/x/evidence/keeper" - evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" - "github.com/cosmos/cosmos-sdk/x/feegrant" - feegrantkeeper "github.com/cosmos/cosmos-sdk/x/feegrant/keeper" govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" - "github.com/cosmos/cosmos-sdk/x/group" groupkeeper "github.com/cosmos/cosmos-sdk/x/group/keeper" - "github.com/cosmos/cosmos-sdk/x/params" + _ "github.com/cosmos/cosmos-sdk/x/group/module" // import for side-effects + _ "github.com/cosmos/cosmos-sdk/x/params" // import for side-effects paramskeeper "github.com/cosmos/cosmos-sdk/x/params/keeper" - paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - paramproposal "github.com/cosmos/cosmos-sdk/x/params/types/proposal" + _ "github.com/cosmos/cosmos-sdk/x/slashing" // import for side-effects slashingkeeper "github.com/cosmos/cosmos-sdk/x/slashing/keeper" - slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" + _ "github.com/cosmos/cosmos-sdk/x/staking" // import for side-effects stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/cosmos/cosmos-sdk/x/upgrade" - upgradekeeper "github.com/cosmos/cosmos-sdk/x/upgrade/keeper" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - // ibc-go + _ "github.com/cosmos/ibc-go/modules/capability" // import for side-effects + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" + _ "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts" // import for side-effects + icacontrollerkeeper "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/keeper" + icahostkeeper "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/keeper" + _ "github.com/cosmos/ibc-go/v8/modules/apps/29-fee" // import for side-effects + ibcfeekeeper "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/keeper" + ibctransferkeeper "github.com/cosmos/ibc-go/v8/modules/apps/transfer/keeper" + ibckeeper "github.com/cosmos/ibc-go/v8/modules/core/keeper" - ibc_hooks "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7" - ibchookskeeper "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/keeper" - ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" - ibcwasmkeeper "github.com/cosmos/ibc-go/modules/light-clients/08-wasm/keeper" - ibcwasmtypes "github.com/cosmos/ibc-go/modules/light-clients/08-wasm/types" - ica "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts" - icacontroller "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller" - icacontrollerkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" - icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" - icahost "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host" - icahostkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/keeper" - icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" - ibcfee "github.com/cosmos/ibc-go/v7/modules/apps/29-fee" - ibcfeekeeper "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/keeper" - ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" - "github.com/cosmos/ibc-go/v7/modules/apps/transfer" - ibctransferkeeper "github.com/cosmos/ibc-go/v7/modules/apps/transfer/keeper" - ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" - ibc "github.com/cosmos/ibc-go/v7/modules/core" - ibcclient "github.com/cosmos/ibc-go/v7/modules/core/02-client" - ibcclienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" - ibcporttypes "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" - ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" - ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" - - // cosmwasm - "github.com/CosmWasm/wasmd/x/wasm" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - - // sge + _ "github.com/sge-network/sge/x/mint" // import for side-effects mintkeeper "github.com/sge-network/sge/x/mint/keeper" - minttypes "github.com/sge-network/sge/x/mint/types" - - betmodule "github.com/sge-network/sge/x/bet" - betmodulekeeper "github.com/sge-network/sge/x/bet/keeper" - betmoduletypes "github.com/sge-network/sge/x/bet/types" - - marketmodule "github.com/sge-network/sge/x/market" - marketmodulekeeper "github.com/sge-network/sge/x/market/keeper" - marketmoduletypes "github.com/sge-network/sge/x/market/types" - - ovmmodule "github.com/sge-network/sge/x/ovm" - ovmmodulekeeper "github.com/sge-network/sge/x/ovm/keeper" - ovmmoduletypes "github.com/sge-network/sge/x/ovm/types" - - housemodule "github.com/sge-network/sge/x/house" - housemodulekeeper "github.com/sge-network/sge/x/house/keeper" - housemoduletypes "github.com/sge-network/sge/x/house/types" - - orderbookmodule "github.com/sge-network/sge/x/orderbook" - orderbookmodulekeeper "github.com/sge-network/sge/x/orderbook/keeper" - orderbookmoduletypes "github.com/sge-network/sge/x/orderbook/types" - - subaccountmodule "github.com/sge-network/sge/x/subaccount" - subaccountmodulekeeper "github.com/sge-network/sge/x/subaccount/keeper" - subaccountmoduletypes "github.com/sge-network/sge/x/subaccount/types" - - rewardmodule "github.com/sge-network/sge/x/reward" - rewardmodulekeeper "github.com/sge-network/sge/x/reward/keeper" - rewardmoduletypes "github.com/sge-network/sge/x/reward/types" - - // unnamed import of statik for swagger UI support - _ "github.com/cosmos/cosmos-sdk/client/docs/statik" ) type AppKeepers struct { - // keys to access the substores - keys map[string]*storetypes.KVStoreKey - tkeys map[string]*storetypes.TransientStoreKey - memKeys map[string]*storetypes.MemoryStoreKey - - // SDK keepers + // keepers AccountKeeper authkeeper.AccountKeeper BankKeeper bankkeeper.Keeper - CapabilityKeeper *capabilitykeeper.Keeper StakingKeeper *stakingkeeper.Keeper - SlashingKeeper slashingkeeper.Keeper DistrKeeper distrkeeper.Keeper - GovKeeper *govkeeper.Keeper - CrisisKeeper *crisiskeeper.Keeper - UpgradeKeeper *upgradekeeper.Keeper - ParamsKeeper paramskeeper.Keeper - EvidenceKeeper evidencekeeper.Keeper - TransferKeeper ibctransferkeeper.Keeper - FeeGrantKeeper feegrantkeeper.Keeper - AuthzKeeper authzkeeper.Keeper - GroupKeeper groupkeeper.Keeper - ConsensusParamsKeeper consensusparamkeeper.Keeper - - //// CosmWasm keepers \\\\ - ContractKeeper wasmtypes.ContractOpsKeeper - WasmClientKeeper ibcwasmkeeper.Keeper - WasmKeeper wasmkeeper.Keeper - ScopedWasmKeeper capabilitykeeper.ScopedKeeper - - //// SGE keepers \\\\ - BetKeeper *betmodulekeeper.Keeper - MarketKeeper *marketmodulekeeper.Keeper - MintKeeper mintkeeper.Keeper - HouseKeeper *housemodulekeeper.Keeper - OrderbookKeeper *orderbookmodulekeeper.Keeper - OVMKeeper *ovmmodulekeeper.Keeper - RewardKeeper *rewardmodulekeeper.Keeper - SubaccountKeeper *subaccountmodulekeeper.Keeper - - //// SGE modules \\\\ - BetModule betmodule.AppModule - MarketModule marketmodule.AppModule - HouseModule housemodule.AppModule - OrderbookModule orderbookmodule.AppModule - OVMModule ovmmodule.AppModule - RewardModule rewardmodule.AppModule - SubaccountModule subaccountmodule.AppModule - - // make scoped keepers public for test purposes - ScopedIBCKeeper capabilitykeeper.ScopedKeeper - ScopedTransferKeeper capabilitykeeper.ScopedKeeper - ScopedIBCFeeKeeper capabilitykeeper.ScopedKeeper - ScopedICAControllerKeeper capabilitykeeper.ScopedKeeper - ScopedICAHostKeeper capabilitykeeper.ScopedKeeper - - // IBC Keepers + ConsensusParamsKeeper consensuskeeper.Keeper + + SlashingKeeper slashingkeeper.Keeper + MintKeeper mintkeeper.Keeper + GovKeeper *govkeeper.Keeper + CrisisKeeper *crisiskeeper.Keeper + UpgradeKeeper *upgradekeeper.Keeper + ParamsKeeper paramskeeper.Keeper + AuthzKeeper authzkeeper.Keeper + EvidenceKeeper evidencekeeper.Keeper + FeeGrantKeeper feegrantkeeper.Keeper + GroupKeeper groupkeeper.Keeper + NFTKeeper nftkeeper.Keeper + CircuitBreakerKeeper circuitkeeper.Keeper + + // IBC IBCKeeper *ibckeeper.Keeper // IBC Keeper must be a pointer in the app, so we can SetRouter on it correctly + CapabilityKeeper *capabilitykeeper.Keeper IBCFeeKeeper ibcfeekeeper.Keeper - IBCHooksKeeper *ibchookskeeper.Keeper ICAControllerKeeper icacontrollerkeeper.Keeper ICAHostKeeper icahostkeeper.Keeper + TransferKeeper ibctransferkeeper.Keeper - // IBC Modules - IBCModule ibc.AppModule - ICAModule ica.AppModule - TransferModule transfer.AppModule - IBCFeeModule ibcfee.AppModule - - Ics20WasmHooks *ibc_hooks.WasmHooks - HooksICS4Wrapper ibc_hooks.ICS4Middleware -} - -func NewAppKeeper( - appCodec codec.Codec, - bApp *baseapp.BaseApp, - cdc *codec.LegacyAmino, - maccPerms map[string][]string, - skipUpgradeHeights map[int64]bool, - homePath string, - invCheckPeriod uint, - wasmOpts []wasmkeeper.Option, - appOpts servertypes.AppOptions, -) AppKeepers { - appKeepers := AppKeepers{} - // Set keys KVStoreKey, TransientStoreKey, MemoryStoreKey - appKeepers.GenerateKeys() - - appKeepers.ParamsKeeper = initParamsKeeper( - appCodec, - cdc, - appKeepers.keys[paramstypes.StoreKey], - appKeepers.tkeys[paramstypes.TStoreKey], - ) - - govModAddress := authtypes.NewModuleAddress(govtypes.ModuleName).String() - - // set the BaseApp's parameter store - appKeepers.ConsensusParamsKeeper = consensusparamkeeper.NewKeeper(appCodec, appKeepers.keys[consensusparamtypes.StoreKey], govModAddress) - bApp.SetParamStore(&appKeepers.ConsensusParamsKeeper) - - // add capability keeper and ScopeToModule for ibc module - appKeepers.CapabilityKeeper = capabilitykeeper.NewKeeper( - appCodec, - appKeepers.keys[capabilitytypes.StoreKey], - appKeepers.memKeys[capabilitytypes.MemStoreKey], - ) - - // grant capabilities for the ibc and ibc-transfer modules - appKeepers.ScopedIBCKeeper = appKeepers.CapabilityKeeper.ScopeToModule(ibcexported.ModuleName) - appKeepers.ScopedTransferKeeper = appKeepers.CapabilityKeeper.ScopeToModule(ibctransfertypes.ModuleName) - appKeepers.ScopedICAControllerKeeper = appKeepers.CapabilityKeeper.ScopeToModule(icacontrollertypes.SubModuleName) - appKeepers.ScopedICAHostKeeper = appKeepers.CapabilityKeeper.ScopeToModule(icahosttypes.SubModuleName) - appKeepers.ScopedWasmKeeper = appKeepers.CapabilityKeeper.ScopeToModule(wasmtypes.ModuleName) - - // add keepers - appKeepers.CrisisKeeper = crisiskeeper.NewKeeper( - appCodec, - appKeepers.keys[crisistypes.StoreKey], - invCheckPeriod, - appKeepers.BankKeeper, - authtypes.FeeCollectorName, - govModAddress, - ) - - appKeepers.AccountKeeper = authkeeper.NewAccountKeeper( - appCodec, - appKeepers.keys[authtypes.StoreKey], - authtypes.ProtoBaseAccount, - maccPerms, - AccountAddressPrefix, - govModAddress, - ) - appKeepers.BankKeeper = bankkeeper.NewBaseKeeper( - appCodec, - appKeepers.keys[banktypes.StoreKey], - appKeepers.AccountKeeper, - BlockedAddresses(maccPerms), - govModAddress, - ) - appKeepers.AuthzKeeper = authzkeeper.NewKeeper( - appKeepers.keys[authzkeeper.StoreKey], - appCodec, - bApp.MsgServiceRouter(), - appKeepers.AccountKeeper, - ) - - groupConfig := group.DefaultConfig() - appKeepers.GroupKeeper = groupkeeper.NewKeeper( - appKeepers.keys[group.StoreKey], - appCodec, - bApp.MsgServiceRouter(), - appKeepers.AccountKeeper, groupConfig, - ) - - appKeepers.FeeGrantKeeper = feegrantkeeper.NewKeeper( - appCodec, - appKeepers.keys[feegrant.StoreKey], - appKeepers.AccountKeeper, - ) - - appKeepers.StakingKeeper = stakingkeeper.NewKeeper( - appCodec, - appKeepers.keys[stakingtypes.StoreKey], - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - govModAddress, - ) - - appKeepers.MintKeeper = *mintkeeper.NewKeeper( - appCodec, - appKeepers.keys[minttypes.StoreKey], - appKeepers.GetSubspace(minttypes.ModuleName), - appKeepers.AccountKeeper, - mintkeeper.ExpectedKeepers{ - StakingKeeper: appKeepers.StakingKeeper, - BankKeeper: appKeepers.BankKeeper, - }, - authtypes.FeeCollectorName, - govModAddress, - ) - - appKeepers.DistrKeeper = distrkeeper.NewKeeper( - appCodec, - appKeepers.keys[distrtypes.StoreKey], - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - appKeepers.StakingKeeper, - authtypes.FeeCollectorName, - govModAddress, - ) - appKeepers.SlashingKeeper = slashingkeeper.NewKeeper( - appCodec, - cdc, - appKeepers.keys[slashingtypes.StoreKey], - appKeepers.StakingKeeper, - govModAddress, - ) - - // register the staking hooks - // NOTE: stakingKeeper above is passed by reference, so that it will contain these hooks - appKeepers.StakingKeeper.SetHooks( - stakingtypes.NewMultiStakingHooks( - appKeepers.DistrKeeper.Hooks(), - appKeepers.SlashingKeeper.Hooks(), - ), - ) - - // UpgradeKeeper must be created before IBCKeeper - appKeepers.UpgradeKeeper = upgradekeeper.NewKeeper( - skipUpgradeHeights, - appKeepers.keys[upgradetypes.StoreKey], - appCodec, - homePath, - bApp, - authtypes.NewModuleAddress(govtypes.ModuleName).String(), - ) - - // Create IBC Keeper - appKeepers.IBCKeeper = ibckeeper.NewKeeper( - appCodec, - appKeepers.keys[ibcexported.StoreKey], - appKeepers.GetSubspace(ibcexported.ModuleName), - appKeepers.StakingKeeper, - appKeepers.UpgradeKeeper, - appKeepers.ScopedIBCKeeper, - ) - - // register the proposal types - govRouter := govv1beta1.NewRouter() - govRouter. - AddRoute(govtypes.RouterKey, govv1beta1.ProposalHandler). - AddRoute(paramproposal.RouterKey, params.NewParamChangeProposalHandler(appKeepers.ParamsKeeper)). - AddRoute(upgradetypes.RouterKey, upgrade.NewSoftwareUpgradeProposalHandler(appKeepers.UpgradeKeeper)). - AddRoute(ibcclienttypes.RouterKey, ibcclient.NewClientProposalHandler(appKeepers.IBCKeeper.ClientKeeper)) - - govConfig := govtypes.DefaultConfig() - - appKeepers.GovKeeper = govkeeper.NewKeeper( - appCodec, - appKeepers.keys[govtypes.StoreKey], - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - appKeepers.StakingKeeper, - bApp.MsgServiceRouter(), - govConfig, - govModAddress, - ) - appKeepers.GovKeeper.SetLegacyRouter(govRouter) - - // Configure the hooks keeper - hooksKeeper := ibchookskeeper.NewKeeper( - appKeepers.keys[ibchookstypes.StoreKey], - ) - appKeepers.IBCHooksKeeper = &hooksKeeper - - sgePrefix := sdk.GetConfig().GetBech32AccountAddrPrefix() - wasmHooks := ibc_hooks.NewWasmHooks(appKeepers.IBCHooksKeeper, &appKeepers.WasmKeeper, sgePrefix) // The contract keeper needs to be set later - appKeepers.Ics20WasmHooks = &wasmHooks - appKeepers.HooksICS4Wrapper = ibc_hooks.NewICS4Middleware( - appKeepers.IBCKeeper.ChannelKeeper, - appKeepers.Ics20WasmHooks, - ) - - // IBC Fee Module keeper - appKeepers.IBCFeeKeeper = ibcfeekeeper.NewKeeper( - appCodec, - appKeepers.keys[ibcfeetypes.StoreKey], - appKeepers.IBCKeeper.ChannelKeeper, // more middlewares can be added in future - appKeepers.IBCKeeper.ChannelKeeper, - &appKeepers.IBCKeeper.PortKeeper, - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - ) - - appKeepers.TransferKeeper = ibctransferkeeper.NewKeeper( - appCodec, - appKeepers.keys[ibctransfertypes.StoreKey], - appKeepers.GetSubspace(ibctransfertypes.ModuleName), - appKeepers.IBCFeeKeeper, // ISC4 Wrapper: fee IBC middleware - appKeepers.IBCKeeper.ChannelKeeper, - &appKeepers.IBCKeeper.PortKeeper, - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - appKeepers.ScopedTransferKeeper, - ) - - appKeepers.ICAControllerKeeper = icacontrollerkeeper.NewKeeper( - appCodec, - appKeepers.keys[icacontrollertypes.StoreKey], - appKeepers.GetSubspace(icacontrollertypes.SubModuleName), - appKeepers.IBCFeeKeeper, - appKeepers.IBCKeeper.ChannelKeeper, - &appKeepers.IBCKeeper.PortKeeper, - appKeepers.ScopedICAControllerKeeper, - bApp.MsgServiceRouter(), - ) - - appKeepers.ICAHostKeeper = icahostkeeper.NewKeeper( - appCodec, appKeepers.keys[icahosttypes.StoreKey], - appKeepers.GetSubspace(icahosttypes.SubModuleName), - appKeepers.IBCFeeKeeper, - appKeepers.IBCKeeper.ChannelKeeper, - &appKeepers.IBCKeeper.PortKeeper, - appKeepers.AccountKeeper, - appKeepers.ScopedICAHostKeeper, - bApp.MsgServiceRouter(), - ) - - // Create evidence Keeper for to register the IBC light client misbehaviour evidence route - appKeepers.EvidenceKeeper = *evidencekeeper.NewKeeper( - appCodec, - appKeepers.keys[evidencetypes.StoreKey], - appKeepers.StakingKeeper, - appKeepers.SlashingKeeper, - ) - - wasmDir := filepath.Join(homePath, "cwvm") - wasmConfig, err := wasm.ReadWasmConfig(appOpts) - if err != nil { - panic("error while reading wasm config: " + err.Error()) - } - - ibcWasmConfig := ibcwasmtypes.WasmConfig{ - DataDir: filepath.Join(wasmDir, "ibc_08-wasm"), - SupportedCapabilities: "iterator,stargate,abort", - ContractDebugMode: false, - } - - wasmCapabilities := "iterator,staking,stargate,cosmwasm_1_1" - - appKeepers.WasmKeeper = wasmkeeper.NewKeeper( - appCodec, - appKeepers.keys[wasmtypes.StoreKey], - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - appKeepers.StakingKeeper, - distrkeeper.NewQuerier(appKeepers.DistrKeeper), - appKeepers.IBCFeeKeeper, - appKeepers.IBCKeeper.ChannelKeeper, - &appKeepers.IBCKeeper.PortKeeper, - appKeepers.ScopedWasmKeeper, - appKeepers.TransferKeeper, - bApp.MsgServiceRouter(), - bApp.GRPCQueryRouter(), - wasmDir, - wasmConfig, - wasmCapabilities, - govModAddress, - wasmOpts..., - ) - - appKeepers.WasmClientKeeper = ibcwasmkeeper.NewKeeperWithConfig( - appCodec, - appKeepers.keys[ibcwasmtypes.StoreKey], - appKeepers.IBCKeeper.ClientKeeper, - authtypes.NewModuleAddress(govtypes.ModuleName).String(), - ibcWasmConfig, - bApp.GRPCQueryRouter(), - ) - - // set the contract keeper for the Ics20WasmHooks - appKeepers.ContractKeeper = wasmkeeper.NewDefaultPermissionKeeper(&appKeepers.WasmKeeper) - appKeepers.Ics20WasmHooks.ContractKeeper = &appKeepers.WasmKeeper - - // // SGE keepers \\\\ - - appKeepers.OrderbookKeeper = orderbookmodulekeeper.NewKeeper( - appCodec, - appKeepers.keys[orderbookmoduletypes.StoreKey], - appKeepers.GetSubspace(orderbookmoduletypes.ModuleName), - orderbookmodulekeeper.SdkExpectedKeepers{ - BankKeeper: appKeepers.BankKeeper, - AccountKeeper: appKeepers.AccountKeeper, - FeeGrantKeeper: appKeepers.FeeGrantKeeper, - }, - govModAddress, - ) - - appKeepers.OVMKeeper = ovmmodulekeeper.NewKeeper( - appCodec, - appKeepers.keys[ovmmoduletypes.StoreKey], - appKeepers.keys[ovmmoduletypes.MemStoreKey], - appKeepers.GetSubspace(ovmmoduletypes.ModuleName), - govModAddress, - ) - - appKeepers.MarketKeeper = marketmodulekeeper.NewKeeper( - appCodec, - appKeepers.keys[marketmoduletypes.StoreKey], - appKeepers.keys[marketmoduletypes.MemStoreKey], - appKeepers.GetSubspace(marketmoduletypes.ModuleName), - govModAddress, - ) - appKeepers.MarketKeeper.SetOVMKeeper(appKeepers.OVMKeeper) - appKeepers.MarketKeeper.SetOrderbookKeeper(appKeepers.OrderbookKeeper) - - appKeepers.BetKeeper = betmodulekeeper.NewKeeper( - appCodec, - appKeepers.keys[betmoduletypes.StoreKey], - appKeepers.keys[betmoduletypes.MemStoreKey], - appKeepers.GetSubspace(betmoduletypes.ModuleName), - govModAddress, - ) - appKeepers.BetKeeper.SetMarketKeeper(appKeepers.MarketKeeper) - appKeepers.BetKeeper.SetOrderbookKeeper(appKeepers.OrderbookKeeper) - appKeepers.BetKeeper.SetOVMKeeper(appKeepers.OVMKeeper) - - appKeepers.OrderbookKeeper.SetBetKeeper(appKeepers.BetKeeper) - appKeepers.OrderbookKeeper.SetMarketKeeper(appKeepers.MarketKeeper) - appKeepers.OrderbookKeeper.SetOVMKeeper(appKeepers.OVMKeeper) - - appKeepers.HouseKeeper = housemodulekeeper.NewKeeper( - appCodec, - appKeepers.keys[housemoduletypes.StoreKey], - appKeepers.OrderbookKeeper, - appKeepers.OVMKeeper, - appKeepers.GetSubspace(housemoduletypes.ModuleName), - housemodulekeeper.SdkExpectedKeepers{ - AuthzKeeper: appKeepers.AuthzKeeper, - }, - govModAddress, - ) - appKeepers.OrderbookKeeper.SetHouseKeeper(appKeepers.HouseKeeper) - - appKeepers.SubaccountKeeper = subaccountmodulekeeper.NewKeeper( - appCodec, - appKeepers.keys[subaccountmoduletypes.StoreKey], - appKeepers.GetSubspace(subaccountmoduletypes.ModuleName), - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - appKeepers.OVMKeeper, - appKeepers.BetKeeper, - appKeepers.OrderbookKeeper, - appKeepers.HouseKeeper, - govModAddress, - ) - - appKeepers.RewardKeeper = rewardmodulekeeper.NewKeeper( - appCodec, - appKeepers.keys[rewardmoduletypes.StoreKey], - appKeepers.keys[rewardmoduletypes.MemStoreKey], - appKeepers.GetSubspace(rewardmoduletypes.ModuleName), - appKeepers.BetKeeper, - appKeepers.OVMKeeper, - appKeepers.SubaccountKeeper, - rewardmodulekeeper.SdkExpectedKeepers{ - AuthzKeeper: appKeepers.AuthzKeeper, - BankKeeper: appKeepers.BankKeeper, - AccountKeeper: appKeepers.AccountKeeper, - }, - govModAddress, - ) - - // ** Hooks ** \\ - - appKeepers.OrderbookKeeper.SetHooks( - orderbookmoduletypes.NewMultiOrderBookHooks( - appKeepers.SubaccountKeeper.Hooks(), - ), - ) - - // // SGE modules \\\\ - - appKeepers.BetModule = betmodule.NewAppModule( - appCodec, - *appKeepers.BetKeeper, - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - appKeepers.MarketKeeper, - appKeepers.OrderbookKeeper, - appKeepers.OVMKeeper, - ) - appKeepers.MarketModule = marketmodule.NewAppModule( - appCodec, - *appKeepers.MarketKeeper, - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - appKeepers.OVMKeeper, - ) - appKeepers.HouseModule = housemodule.NewAppModule( - appCodec, - *appKeepers.HouseKeeper, - ) - appKeepers.OrderbookModule = orderbookmodule.NewAppModule( - appCodec, - *appKeepers.OrderbookKeeper, - ) - appKeepers.OVMModule = ovmmodule.NewAppModule( - appCodec, - *appKeepers.OVMKeeper, - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - ) - appKeepers.RewardModule = rewardmodule.NewAppModule( - appCodec, - *appKeepers.RewardKeeper, - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - ) - - appKeepers.SubaccountModule = subaccountmodule.NewAppModule(*appKeepers.SubaccountKeeper) - - //// IBC modules \\\\ - appKeepers.IBCModule = ibc.NewAppModule(appKeepers.IBCKeeper) - appKeepers.IBCFeeModule = ibcfee.NewAppModule(appKeepers.IBCFeeKeeper) - appKeepers.TransferModule = transfer.NewAppModule(appKeepers.TransferKeeper) - appKeepers.ICAModule = ica.NewAppModule(&appKeepers.ICAControllerKeeper, &appKeepers.ICAHostKeeper) - - // IBC stacks \\\ - var transferStack ibcporttypes.IBCModule - transferStack = transfer.NewIBCModule(appKeepers.TransferKeeper) - transferStack = ibcfee.NewIBCMiddleware(transferStack, appKeepers.IBCFeeKeeper) - - var icaControllerStack ibcporttypes.IBCModule - icaControllerStack = icacontroller.NewIBCMiddleware(icaControllerStack, appKeepers.ICAControllerKeeper) - icaControllerStack = ibcfee.NewIBCMiddleware(icaControllerStack, appKeepers.IBCFeeKeeper) - - var icaHostStack ibcporttypes.IBCModule - icaHostStack = icahost.NewIBCModule(appKeepers.ICAHostKeeper) - icaHostStack = ibcfee.NewIBCMiddleware(icaHostStack, appKeepers.IBCFeeKeeper) - - // Create fee enabled wasm ibc Stack - var wasmStack ibcporttypes.IBCModule - wasmStack = wasm.NewIBCHandler(appKeepers.WasmKeeper, appKeepers.IBCKeeper.ChannelKeeper, appKeepers.IBCFeeKeeper) - wasmStack = ibcfee.NewIBCMiddleware(wasmStack, appKeepers.IBCFeeKeeper) - - // Create static IBC router, add transfer route, then set and seal it - ibcRouter := ibcporttypes.NewRouter() - ibcRouter.AddRoute(icacontrollertypes.SubModuleName, icaControllerStack) - ibcRouter.AddRoute(icahosttypes.SubModuleName, icaHostStack) - ibcRouter.AddRoute(ibctransfertypes.ModuleName, transferStack) - ibcRouter.AddRoute(wasmtypes.ModuleName, wasmStack) - - appKeepers.IBCKeeper.SetRouter(ibcRouter) - - /**** Module Options ****/ - return appKeepers -} - -// GetSubspace returns a param subspace for a given module name. -func (appKeepers *AppKeepers) GetSubspace(moduleName string) paramstypes.Subspace { - subspace, _ := appKeepers.ParamsKeeper.GetSubspace(moduleName) - return subspace -} - -// initParamsKeeper init params keeper and its subspaces -func initParamsKeeper(appCodec codec.BinaryCodec, - legacyAmino *codec.LegacyAmino, - key, tkey storetypes.StoreKey, -) paramskeeper.Keeper { - paramsKeeper := paramskeeper.NewKeeper(appCodec, legacyAmino, key, tkey) - - paramsKeeper.Subspace(authtypes.ModuleName) - paramsKeeper.Subspace(banktypes.ModuleName) - paramsKeeper.Subspace(stakingtypes.ModuleName) - paramsKeeper.Subspace(minttypes.ModuleName) - paramsKeeper.Subspace(distrtypes.ModuleName) - paramsKeeper.Subspace(slashingtypes.ModuleName) - paramsKeeper.Subspace(govtypes.ModuleName) - paramsKeeper.Subspace(crisistypes.ModuleName) - paramsKeeper.Subspace(ibctransfertypes.ModuleName) - paramsKeeper.Subspace(ibcexported.ModuleName) - paramsKeeper.Subspace(icacontrollertypes.SubModuleName) - paramsKeeper.Subspace(icahosttypes.SubModuleName) - paramsKeeper.Subspace(betmoduletypes.ModuleName) - paramsKeeper.Subspace(marketmoduletypes.ModuleName) - paramsKeeper.Subspace(orderbookmoduletypes.ModuleName) - paramsKeeper.Subspace(ovmmoduletypes.ModuleName) - paramsKeeper.Subspace(housemoduletypes.ModuleName) - paramsKeeper.Subspace(rewardmoduletypes.ModuleName) - paramsKeeper.Subspace(subaccountmoduletypes.ModuleName) - paramsKeeper.Subspace(wasmtypes.ModuleName) - - return paramsKeeper -} - -// BlockedAddresses returns all the app's blocked account addresses. -func BlockedAddresses(maccPerms map[string][]string) map[string]bool { - modAccAddrs := make(map[string]bool) - for acc := range GetMaccPerms(maccPerms) { - modAccAddrs[authtypes.NewModuleAddress(acc).String()] = true - } - - // allow the following addresses to receive funds - delete(modAccAddrs, authtypes.NewModuleAddress(govtypes.ModuleName).String()) - - return modAccAddrs -} - -// GetMaccPerms returns a copy of the module account permissions -func GetMaccPerms(maccPerms map[string][]string) map[string][]string { - dupMaccPerms := make(map[string][]string) - for k, v := range maccPerms { - dupMaccPerms[k] = v - } + // Scoped IBC + ScopedIBCKeeper capabilitykeeper.ScopedKeeper + ScopedIBCTransferKeeper capabilitykeeper.ScopedKeeper + ScopedICAControllerKeeper capabilitykeeper.ScopedKeeper + ScopedICAHostKeeper capabilitykeeper.ScopedKeeper + ScopedKeepers map[string]capabilitykeeper.ScopedKeeper - return dupMaccPerms + // CosmWasm + WasmKeeper wasmkeeper.Keeper + ScopedWasmKeeper capabilitykeeper.ScopedKeeper } diff --git a/app/keepers/keys.go b/app/keepers/keys.go deleted file mode 100644 index 4f24e08f..00000000 --- a/app/keepers/keys.go +++ /dev/null @@ -1,109 +0,0 @@ -package keepers - -import ( - storetypes "github.com/cosmos/cosmos-sdk/store/types" - sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" - consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" - crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" - distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" - evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" - "github.com/cosmos/cosmos-sdk/x/feegrant" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/cosmos/cosmos-sdk/x/group" - paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - - // ibc-go - ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" - ibcwasmtypes "github.com/cosmos/ibc-go/modules/light-clients/08-wasm/types" - icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" - icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" - ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" - ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" - ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" - - // cosmwasm - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - - betmoduletypes "github.com/sge-network/sge/x/bet/types" - housemoduletypes "github.com/sge-network/sge/x/house/types" - marketmoduletypes "github.com/sge-network/sge/x/market/types" - minttypes "github.com/sge-network/sge/x/mint/types" - orderbookmoduletypes "github.com/sge-network/sge/x/orderbook/types" - ovmmoduletypes "github.com/sge-network/sge/x/ovm/types" - rewardmoduletypes "github.com/sge-network/sge/x/reward/types" - subaccounttypes "github.com/sge-network/sge/x/subaccount/types" - - // unnamed import of statik for swagger UI support - _ "github.com/cosmos/cosmos-sdk/client/docs/statik" -) - -const ( - // AccountAddressPrefix prefix used for generating account address - AccountAddressPrefix = "sge" -) - -func (appKeepers *AppKeepers) GenerateKeys() { - // Define what keys will be used in the cosmos-sdk key/value store. - // Cosmos-SDK modules each have a "key" that allows the application to reference what they've stored on the chain. - appKeepers.keys = sdk.NewKVStoreKeys( - authtypes.StoreKey, banktypes.StoreKey, stakingtypes.StoreKey, crisistypes.StoreKey, - minttypes.StoreKey, distrtypes.StoreKey, slashingtypes.StoreKey, - govtypes.StoreKey, paramstypes.StoreKey, consensusparamtypes.StoreKey, upgradetypes.StoreKey, - feegrant.StoreKey, evidencetypes.StoreKey, capabilitytypes.StoreKey, authzkeeper.StoreKey, group.StoreKey, - wasmtypes.StoreKey, ibcwasmtypes.StoreKey, - ibcexported.StoreKey, ibctransfertypes.StoreKey, ibcfeetypes.StoreKey, icacontrollertypes.StoreKey, icahosttypes.StoreKey, ibchookstypes.StoreKey, - orderbookmoduletypes.StoreKey, - betmoduletypes.StoreKey, - marketmoduletypes.StoreKey, - ovmmoduletypes.StoreKey, - housemoduletypes.StoreKey, - rewardmoduletypes.StoreKey, - subaccounttypes.StoreKey, - ) - - // Define transient store keys - appKeepers.tkeys = sdk.NewTransientStoreKeys(paramstypes.TStoreKey) - - // MemKeys are for information that is stored only in RAM. - appKeepers.memKeys = sdk.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) -} - -func (appKeepers *AppKeepers) GetKVStoreKey() map[string]*storetypes.KVStoreKey { - return appKeepers.keys -} - -func (appKeepers *AppKeepers) GetTransientStoreKey() map[string]*storetypes.TransientStoreKey { - return appKeepers.tkeys -} - -func (appKeepers *AppKeepers) GetMemoryStoreKey() map[string]*storetypes.MemoryStoreKey { - return appKeepers.memKeys -} - -// GetKey returns the KVStoreKey for the provided store key. -// -// NOTE: This is solely to be used for testing purposes. -func (appKeepers *AppKeepers) GetKey(storeKey string) *storetypes.KVStoreKey { - return appKeepers.keys[storeKey] -} - -// GetTKey returns the TransientStoreKey for the provided store key. -// -// NOTE: This is solely to be used for testing purposes. -func (appKeepers *AppKeepers) GetTKey(storeKey string) *storetypes.TransientStoreKey { - return appKeepers.tkeys[storeKey] -} - -// GetMemKey returns the MemStoreKey for the provided mem key. -// -// NOTE: This is solely used for testing purposes. -func (appKeepers *AppKeepers) GetMemKey(storeKey string) *storetypes.MemoryStoreKey { - return appKeepers.memKeys[storeKey] -} diff --git a/app/modules.go b/app/modules.go deleted file mode 100644 index e426a7dd..00000000 --- a/app/modules.go +++ /dev/null @@ -1,405 +0,0 @@ -package app - -import ( - "github.com/cosmos/cosmos-sdk/types/module" - "github.com/cosmos/cosmos-sdk/x/auth" - authsims "github.com/cosmos/cosmos-sdk/x/auth/simulation" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/cosmos/cosmos-sdk/x/auth/vesting" - vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" - "github.com/cosmos/cosmos-sdk/x/authz" - authzmodule "github.com/cosmos/cosmos-sdk/x/authz/module" - "github.com/cosmos/cosmos-sdk/x/bank" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/cosmos-sdk/x/capability" - capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" - consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" - "github.com/cosmos/cosmos-sdk/x/crisis" - crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" - distr "github.com/cosmos/cosmos-sdk/x/distribution" - distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" - "github.com/cosmos/cosmos-sdk/x/evidence" - evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" - "github.com/cosmos/cosmos-sdk/x/feegrant" - feegrantmodule "github.com/cosmos/cosmos-sdk/x/feegrant/module" - "github.com/cosmos/cosmos-sdk/x/genutil" - genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" - "github.com/cosmos/cosmos-sdk/x/gov" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/cosmos/cosmos-sdk/x/group" - groupmodule "github.com/cosmos/cosmos-sdk/x/group/module" - "github.com/cosmos/cosmos-sdk/x/params" - paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/cosmos/cosmos-sdk/x/slashing" - slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" - "github.com/cosmos/cosmos-sdk/x/staking" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/cosmos/cosmos-sdk/x/upgrade" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - - ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" - ibcwasmmodule "github.com/cosmos/ibc-go/modules/light-clients/08-wasm" - ibcwasmtypes "github.com/cosmos/ibc-go/modules/light-clients/08-wasm/types" - ica "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts" - icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" - ibcfee "github.com/cosmos/ibc-go/v7/modules/apps/29-fee" - ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" - "github.com/cosmos/ibc-go/v7/modules/apps/transfer" - ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" - ibc "github.com/cosmos/ibc-go/v7/modules/core" - ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" - ibctm "github.com/cosmos/ibc-go/v7/modules/light-clients/07-tendermint" - - wasm "github.com/CosmWasm/wasmd/x/wasm" - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - - sgeappparams "github.com/sge-network/sge/app/params" - betmodule "github.com/sge-network/sge/x/bet" - betmoduletypes "github.com/sge-network/sge/x/bet/types" - housemodule "github.com/sge-network/sge/x/house" - housemoduletypes "github.com/sge-network/sge/x/house/types" - marketmodule "github.com/sge-network/sge/x/market" - marketmoduletypes "github.com/sge-network/sge/x/market/types" - mintmodule "github.com/sge-network/sge/x/mint" - mintmoduletypes "github.com/sge-network/sge/x/mint/types" - orderbookmodule "github.com/sge-network/sge/x/orderbook" - orderbookmoduletypes "github.com/sge-network/sge/x/orderbook/types" - ovmmodule "github.com/sge-network/sge/x/ovm" - ovmmoduletypes "github.com/sge-network/sge/x/ovm/types" - rewardmodule "github.com/sge-network/sge/x/reward" - rewardmoduletypes "github.com/sge-network/sge/x/reward/types" - subaccountmodule "github.com/sge-network/sge/x/subaccount" - subaccounttypes "github.com/sge-network/sge/x/subaccount/types" - - // unnamed import of statik for swagger UI support - _ "github.com/cosmos/cosmos-sdk/client/docs/statik" -) - -// module account permissions -var mAccPerms = map[string][]string{ - authtypes.FeeCollectorName: nil, - distrtypes.ModuleName: nil, - mintmoduletypes.ModuleName: {authtypes.Minter}, - stakingtypes.BondedPoolName: {authtypes.Burner, authtypes.Staking}, - stakingtypes.NotBondedPoolName: {authtypes.Burner, authtypes.Staking}, - govtypes.ModuleName: {authtypes.Burner}, - - // ibc - ibctransfertypes.ModuleName: {authtypes.Minter, authtypes.Burner}, - ibcfeetypes.ModuleName: nil, - icatypes.ModuleName: nil, - - // cosmwasm - wasmtypes.ModuleName: {authtypes.Burner}, - - // sge - betmoduletypes.BetFeeCollectorFunder{}.GetModuleAcc(): nil, - housemoduletypes.HouseFeeCollectorFunder{}.GetModuleAcc(): nil, - orderbookmoduletypes.OrderBookLiquidityFunder{}.GetModuleAcc(): nil, - rewardmoduletypes.RewardPoolFunder{}.GetModuleAcc(): nil, -} - -// ModuleBasics defines the module BasicManager is in charge of setting up basic, -// non-dependant module elements, such as codec registration -// and genesis verification. -var ModuleBasics = module.NewBasicManager( - auth.AppModuleBasic{}, - genutil.NewAppModuleBasic(genutiltypes.DefaultMessageValidator), - bank.AppModuleBasic{}, - capability.AppModuleBasic{}, - staking.AppModuleBasic{}, - mintmodule.AppModuleBasic{}, - distr.AppModuleBasic{}, - gov.NewAppModuleBasic(getGovProposalHandlers()), - params.AppModuleBasic{}, - crisis.AppModuleBasic{}, - slashing.AppModuleBasic{}, - upgrade.AppModuleBasic{}, - evidence.AppModuleBasic{}, - feegrantmodule.AppModuleBasic{}, - authzmodule.AppModuleBasic{}, - vesting.AppModuleBasic{}, - groupmodule.AppModuleBasic{}, - - ibc.AppModuleBasic{}, - wasm.AppModuleBasic{}, - transfer.AppModuleBasic{}, - ica.AppModuleBasic{}, - ibcfee.AppModuleBasic{}, - ibcwasmmodule.AppModuleBasic{}, - ibctm.AppModuleBasic{}, - - // sge - betmodule.AppModuleBasic{}, - marketmodule.AppModuleBasic{}, - orderbookmodule.AppModuleBasic{}, - ovmmodule.AppModuleBasic{}, - housemodule.AppModuleBasic{}, - rewardmodule.AppModuleBasic{}, - subaccountmodule.AppModuleBasic{}, -) - -func appModules( - app *SgeApp, - encodingConfig sgeappparams.EncodingConfig, - skipGenesisInvariants bool, -) []module.AppModule { - appCodec := encodingConfig.Marshaler - - return []module.AppModule{ - genutil.NewAppModule( - app.AccountKeeper, - app.StakingKeeper, - app.BaseApp.DeliverTx, - encodingConfig.TxConfig, - ), - auth.NewAppModule(appCodec, app.AccountKeeper, nil, app.GetSubspace(authtypes.ModuleName)), - vesting.NewAppModule(app.AccountKeeper, app.BankKeeper), - bank.NewAppModule(appCodec, app.BankKeeper, app.AccountKeeper, app.GetSubspace(banktypes.ModuleName)), - capability.NewAppModule(appCodec, *app.CapabilityKeeper, false), - crisis.NewAppModule(app.CrisisKeeper, skipGenesisInvariants, app.GetSubspace(crisistypes.ModuleName)), - gov.NewAppModule(appCodec, app.GovKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(govtypes.ModuleName)), - mintmodule.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper, app.BankKeeper), - slashing.NewAppModule( - appCodec, - app.SlashingKeeper, - app.AccountKeeper, - app.BankKeeper, - app.StakingKeeper, - app.GetSubspace(slashingtypes.ModuleName), - ), - distr.NewAppModule( - appCodec, - app.DistrKeeper, - app.AccountKeeper, - app.BankKeeper, - app.StakingKeeper, - app.GetSubspace(distrtypes.ModuleName), - ), - staking.NewAppModule(appCodec, app.StakingKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(stakingtypes.ModuleName)), - upgrade.NewAppModule(app.UpgradeKeeper), - evidence.NewAppModule(app.EvidenceKeeper), - feegrantmodule.NewAppModule( - appCodec, - app.AccountKeeper, - app.BankKeeper, - app.FeeGrantKeeper, - app.interfaceRegistry, - ), - authzmodule.NewAppModule( - appCodec, - app.AuthzKeeper, - app.AccountKeeper, - app.BankKeeper, - app.interfaceRegistry, - ), - groupmodule.NewAppModule(appCodec, - app.GroupKeeper, - app.AccountKeeper, - app.BankKeeper, - app.interfaceRegistry, - ), - wasm.NewAppModule( - appCodec, - &app.AppKeepers.WasmKeeper, - app.AppKeepers.StakingKeeper, - app.AppKeepers.AccountKeeper, - app.AppKeepers.BankKeeper, - app.MsgServiceRouter(), - app.GetSubspace(wasmtypes.ModuleName), - ), - app.IBCModule, - params.NewAppModule(app.ParamsKeeper), - app.TransferModule, - app.IBCFeeModule, - app.ICAModule, - ibcwasmmodule.NewAppModule(app.AppKeepers.WasmClientKeeper), - app.BetModule, - app.MarketModule, - app.OrderbookModule, - app.OVMModule, - app.HouseModule, - app.RewardModule, - app.SubaccountModule, - // this line is u - } -} - -// simulationModules returns modules for simulation manager -// define the order of the modules for deterministic simulations -func simulationModules( - app *SgeApp, - encodingConfig sgeappparams.EncodingConfig, - _ bool, -) []module.AppModuleSimulation { - appCodec := encodingConfig.Marshaler - - return []module.AppModuleSimulation{ - auth.NewAppModule(appCodec, app.AccountKeeper, authsims.RandomGenesisAccounts, app.GetSubspace(authtypes.ModuleName)), - bank.NewAppModule(appCodec, app.BankKeeper, app.AccountKeeper, app.GetSubspace(banktypes.ModuleName)), - capability.NewAppModule(appCodec, *app.CapabilityKeeper, false), - feegrantmodule.NewAppModule( - appCodec, - app.AccountKeeper, - app.BankKeeper, - app.FeeGrantKeeper, - app.interfaceRegistry, - ), - gov.NewAppModule(appCodec, app.GovKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(govtypes.ModuleName)), - mintmodule.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper, nil), - staking.NewAppModule(appCodec, app.StakingKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(stakingtypes.ModuleName)), - distr.NewAppModule( - appCodec, - app.DistrKeeper, - app.AccountKeeper, - app.BankKeeper, - app.StakingKeeper, - app.GetSubspace(distrtypes.ModuleName), - ), - slashing.NewAppModule( - appCodec, - app.SlashingKeeper, - app.AccountKeeper, - app.BankKeeper, - app.StakingKeeper, - app.GetSubspace(stakingtypes.ModuleName), - ), - params.NewAppModule(app.ParamsKeeper), - evidence.NewAppModule(app.EvidenceKeeper), - authzmodule.NewAppModule( - appCodec, - app.AuthzKeeper, - app.AccountKeeper, - app.BankKeeper, - app.interfaceRegistry, - ), - groupmodule.NewAppModule(appCodec, - app.GroupKeeper, - app.AccountKeeper, - app.BankKeeper, - app.interfaceRegistry, - ), - wasm.NewAppModule(appCodec, &app.AppKeepers.WasmKeeper, app.AppKeepers.StakingKeeper, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.MsgServiceRouter(), app.GetSubspace(wasmtypes.ModuleName)), - app.IBCModule, - app.TransferModule, - - app.BetModule, - app.MarketModule, - app.OVMModule, - app.RewardModule, - } -} - -// orderBeginBlockers Tell the app's module manager how to set the order of -// BeginBlockers, which are run at the beginning of every block. -func orderBeginBlockers() []string { - return []string{ - // upgrades should be run first - upgradetypes.ModuleName, - capabilitytypes.ModuleName, - mintmoduletypes.ModuleName, - distrtypes.ModuleName, - slashingtypes.ModuleName, - evidencetypes.ModuleName, - stakingtypes.ModuleName, - authtypes.ModuleName, - banktypes.ModuleName, - govtypes.ModuleName, - crisistypes.ModuleName, - genutiltypes.ModuleName, - authz.ModuleName, - feegrant.ModuleName, - group.ModuleName, - paramstypes.ModuleName, - vestingtypes.ModuleName, - consensusparamtypes.ModuleName, - ibctransfertypes.ModuleName, - ibcexported.ModuleName, - ibcfeetypes.ModuleName, - icatypes.ModuleName, - wasmtypes.ModuleName, - ibchookstypes.ModuleName, - ibcwasmtypes.ModuleName, - betmoduletypes.ModuleName, - marketmoduletypes.ModuleName, - orderbookmoduletypes.ModuleName, - ovmmoduletypes.ModuleName, - housemoduletypes.ModuleName, - rewardmoduletypes.ModuleName, - subaccounttypes.ModuleName, - } -} - -func orderEndBlockers() []string { - return []string{ - crisistypes.ModuleName, - govtypes.ModuleName, - stakingtypes.ModuleName, - capabilitytypes.ModuleName, - authtypes.ModuleName, - banktypes.ModuleName, - distrtypes.ModuleName, - slashingtypes.ModuleName, - mintmoduletypes.ModuleName, - genutiltypes.ModuleName, - evidencetypes.ModuleName, - authz.ModuleName, - feegrant.ModuleName, - group.ModuleName, - paramstypes.ModuleName, - upgradetypes.ModuleName, - vestingtypes.ModuleName, - consensusparamtypes.ModuleName, - ibcexported.ModuleName, - ibctransfertypes.ModuleName, - ibcfeetypes.ModuleName, - icatypes.ModuleName, - wasmtypes.ModuleName, - ibchookstypes.ModuleName, - ibcwasmtypes.ModuleName, - betmoduletypes.ModuleName, - marketmoduletypes.ModuleName, - orderbookmoduletypes.ModuleName, - ovmmoduletypes.ModuleName, - housemoduletypes.ModuleName, - rewardmoduletypes.ModuleName, - subaccounttypes.ModuleName, - } -} - -func orderInitBlockers() []string { - return []string{ - capabilitytypes.ModuleName, - authtypes.ModuleName, - banktypes.ModuleName, - distrtypes.ModuleName, - stakingtypes.ModuleName, - slashingtypes.ModuleName, - govtypes.ModuleName, - mintmoduletypes.ModuleName, - crisistypes.ModuleName, - genutiltypes.ModuleName, - evidencetypes.ModuleName, - authz.ModuleName, - paramstypes.ModuleName, - upgradetypes.ModuleName, - group.ModuleName, - vestingtypes.ModuleName, - feegrant.ModuleName, - consensusparamtypes.ModuleName, - ibctransfertypes.ModuleName, - ibcexported.ModuleName, - icatypes.ModuleName, - ibcfeetypes.ModuleName, - wasmtypes.ModuleName, - ibcwasmtypes.ModuleName, - ibchookstypes.ModuleName, - betmoduletypes.ModuleName, - marketmoduletypes.ModuleName, - orderbookmoduletypes.ModuleName, - ovmmoduletypes.ModuleName, - housemoduletypes.ModuleName, - rewardmoduletypes.ModuleName, - subaccounttypes.ModuleName, - } -} diff --git a/app/params/encoding.go b/app/params/encoding.go deleted file mode 100644 index ae082521..00000000 --- a/app/params/encoding.go +++ /dev/null @@ -1,17 +0,0 @@ -package params - -import ( - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/codec" - "github.com/cosmos/cosmos-sdk/codec/types" -) - -// EncodingConfig specifies the concrete encoding types to use for a given app. -// This is provided for compatibility between protobuf and amino implementations. -type EncodingConfig struct { - InterfaceRegistry types.InterfaceRegistry - Marshaler codec.Codec - TxConfig client.TxConfig - - Amino *codec.LegacyAmino -} diff --git a/app/params/params.go b/app/params/params.go index 84a7841a..e33d30ef 100644 --- a/app/params/params.go +++ b/app/params/params.go @@ -11,9 +11,3 @@ const ( // DefaultBondDenom is the default staking denom of application DefaultBondDenom = BaseCoinUnit ) - -// Simulation parameter constants -const ( - StakePerAccount = "stake_per_account" - InitiallyBondedValidators = "initially_bonded_validators" -) diff --git a/app/params/proto.go b/app/params/proto.go deleted file mode 100644 index 84ff35a3..00000000 --- a/app/params/proto.go +++ /dev/null @@ -1,22 +0,0 @@ -package params - -import ( - "github.com/cosmos/cosmos-sdk/codec" - "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/x/auth/tx" -) - -// MakeEncodingConfig creates an EncodingConfig for an amino based test configuration. -func MakeEncodingConfig() EncodingConfig { - amino := codec.NewLegacyAmino() - interfaceRegistry := types.NewInterfaceRegistry() - marshaler := codec.NewProtoCodec(interfaceRegistry) - txCfg := tx.NewTxConfig(marshaler, tx.DefaultSignModes) - - return EncodingConfig{ - InterfaceRegistry: interfaceRegistry, - Marshaler: marshaler, - TxConfig: txCfg, - Amino: amino, - } -} diff --git a/app/params/weights.go b/app/params/weights.go deleted file mode 100644 index 98dea472..00000000 --- a/app/params/weights.go +++ /dev/null @@ -1,22 +0,0 @@ -package params - -// Default simulation operation weights for messages and gov proposals -const ( - DefaultWeightMsgSend int = 100 - DefaultWeightMsgMultiSend int = 10 - DefaultWeightMsgSetWithdrawAddress int = 50 - DefaultWeightMsgWithdrawDelegationReward int = 50 - DefaultWeightMsgWithdrawValidatorCommission int = 50 - DefaultWeightMsgFundCommunityPool int = 50 - DefaultWeightMsgVote int = 67 - DefaultWeightMsgUnjail int = 100 - DefaultWeightMsgCreateValidator int = 100 - DefaultWeightMsgEditValidator int = 5 - DefaultWeightMsgDelegate int = 100 - DefaultWeightMsgUndelegate int = 100 - DefaultWeightMsgBeginRedelegate int = 100 - - DefaultWeightCommunitySpendProposal int = 5 - DefaultWeightTextProposal int = 5 - DefaultWeightParamChangeProposal int = 5 -) diff --git a/app/prefix.go b/app/prefix.go deleted file mode 100644 index bf7d304f..00000000 --- a/app/prefix.go +++ /dev/null @@ -1,45 +0,0 @@ -package app - -import ( - sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" - - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - - "github.com/sge-network/sge/app/keepers" - "github.com/sge-network/sge/app/params" -) - -var ( - // AccountPubKeyPrefix used for generating public key - AccountPubKeyPrefix = keepers.AccountAddressPrefix + "pub" - // ValidatorAddressPrefix used for generating validator address - ValidatorAddressPrefix = keepers.AccountAddressPrefix + "valoper" - // ValidatorPubKeyPrefix used for generating validator public key - ValidatorPubKeyPrefix = keepers.AccountAddressPrefix + "valoperpub" - // ConsNodeAddressPrefix used for generating consensus node address - ConsNodeAddressPrefix = keepers.AccountAddressPrefix + "valcons" - // ConsNodePubKeyPrefix used for generating consensus node public key - ConsNodePubKeyPrefix = keepers.AccountAddressPrefix + "valconspub" -) - -// SetConfig sets prefixes configuration -func SetConfig() { - config := sdk.GetConfig() - config.SetBech32PrefixForAccount(keepers.AccountAddressPrefix, AccountPubKeyPrefix) - config.SetBech32PrefixForValidator(ValidatorAddressPrefix, ValidatorPubKeyPrefix) - config.SetBech32PrefixForConsensusNode(ConsNodeAddressPrefix, ConsNodePubKeyPrefix) - - config.SetAddressVerifier(wasmtypes.VerifyAddressLen()) - - err := sdk.RegisterDenom(params.HumanCoinUnit, sdkmath.LegacyOneDec()) - if err != nil { - panic(err) - } - err = sdk.RegisterDenom(params.BaseCoinUnit, sdkmath.LegacyNewDecWithPrec(1, params.SGEExponent)) - if err != nil { - panic(err) - } - - config.Seal() -} diff --git a/app/sim_bench_test.go b/app/sim_bench_test.go new file mode 100644 index 00000000..dac7ab4f --- /dev/null +++ b/app/sim_bench_test.go @@ -0,0 +1,149 @@ +package app_test + +import ( + "fmt" + "os" + "testing" + + cmtproto "github.com/cometbft/cometbft/proto/tendermint/types" + "github.com/cosmos/cosmos-sdk/client/flags" + "github.com/cosmos/cosmos-sdk/server" + simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" + simtypes "github.com/cosmos/cosmos-sdk/types/simulation" + "github.com/cosmos/cosmos-sdk/x/simulation" + simcli "github.com/cosmos/cosmos-sdk/x/simulation/client/cli" + "github.com/stretchr/testify/require" + + "github.com/sge-network/sge/app" +) + +// Profile with: +// `go test -benchmem -run=^$ -bench ^BenchmarkFullAppSimulation ./app -Commit=true -cpuprofile cpu.out` +func BenchmarkFullAppSimulation(b *testing.B) { + b.ReportAllocs() + + config := simcli.NewConfigFromFlags() + config.ChainID = SimAppChainID + + db, dir, logger, skip, err := simtestutil.SetupSimulation(config, "goleveldb-app-sim", "Simulation", simcli.FlagVerboseValue, simcli.FlagEnabledValue) + if err != nil { + b.Fatalf("simulation setup failed: %s", err.Error()) + } + + if skip { + b.Skip("skipping benchmark application simulation") + } + + defer func() { + require.NoError(b, db.Close()) + require.NoError(b, os.RemoveAll(dir)) + }() + + appOptions := make(simtestutil.AppOptionsMap, 0) + appOptions[flags.FlagHome] = app.DefaultNodeHome + appOptions[server.FlagInvCheckPeriod] = simcli.FlagPeriodValue + + bApp, err := app.NewApp(logger, db, nil, true, appOptions, interBlockCacheOpt()) + require.NoError(b, err) + require.Equal(b, app.Name, bApp.Name()) + + // run randomized simulation + _, simParams, simErr := simulation.SimulateFromSeed( + b, + os.Stdout, + bApp.BaseApp, + simtestutil.AppStateFn(bApp.AppCodec(), bApp.SimulationManager(), bApp.DefaultGenesis()), + simtypes.RandomAccounts, // Replace with own random account function if using keys other than secp256k1 + simtestutil.SimulationOperations(bApp, bApp.AppCodec(), config), + app.BlockedAddresses(), + config, + bApp.AppCodec(), + ) + + // export state and simParams before the simulation error is checked + if err = simtestutil.CheckExportSimulation(bApp, config, simParams); err != nil { + b.Fatal(err) + } + + if simErr != nil { + b.Fatal(simErr) + } + + if config.Commit { + simtestutil.PrintStats(db) + } +} + +func BenchmarkInvariants(b *testing.B) { + b.ReportAllocs() + + config := simcli.NewConfigFromFlags() + config.ChainID = SimAppChainID + + db, dir, logger, skip, err := simtestutil.SetupSimulation(config, "leveldb-app-invariant-bench", "Simulation", simcli.FlagVerboseValue, simcli.FlagEnabledValue) + if err != nil { + b.Fatalf("simulation setup failed: %s", err.Error()) + } + + if skip { + b.Skip("skipping benchmark application simulation") + } + + config.AllInvariants = false + + defer func() { + require.NoError(b, db.Close()) + require.NoError(b, os.RemoveAll(dir)) + }() + + appOptions := make(simtestutil.AppOptionsMap, 0) + appOptions[flags.FlagHome] = app.DefaultNodeHome + appOptions[server.FlagInvCheckPeriod] = simcli.FlagPeriodValue + + bApp, err := app.NewApp(logger, db, nil, true, appOptions, interBlockCacheOpt()) + require.NoError(b, err) + require.Equal(b, app.Name, bApp.Name()) + + // run randomized simulation + _, simParams, simErr := simulation.SimulateFromSeed( + b, + os.Stdout, + bApp.BaseApp, + simtestutil.AppStateFn(bApp.AppCodec(), bApp.SimulationManager(), bApp.DefaultGenesis()), + simtypes.RandomAccounts, // Replace with own random account function if using keys other than secp256k1 + simtestutil.SimulationOperations(bApp, bApp.AppCodec(), config), + app.BlockedAddresses(), + config, + bApp.AppCodec(), + ) + + // export state and simParams before the simulation error is checked + if err = simtestutil.CheckExportSimulation(bApp, config, simParams); err != nil { + b.Fatal(err) + } + + if simErr != nil { + b.Fatal(simErr) + } + + if config.Commit { + simtestutil.PrintStats(db) + } + + ctx := bApp.NewContextLegacy(true, cmtproto.Header{Height: bApp.LastBlockHeight() + 1}) + + // 3. Benchmark each invariant separately + // + // NOTE: We use the crisis keeper as it has all the invariants registered with + // their respective metadata which makes it useful for testing/benchmarking. + for _, cr := range bApp.CrisisKeeper.Routes() { + b.Run(fmt.Sprintf("%s/%s", cr.ModuleName, cr.Route), func(b *testing.B) { + if res, stop := cr.Invar(ctx); stop { + b.Fatalf( + "broken invariant at block %d of %d\n%s", + ctx.BlockHeight()-1, config.NumBlocks, res, + ) + } + }) + } +} diff --git a/app/sim_test.go b/app/sim_test.go index e38bb02a..55207142 100644 --- a/app/sim_test.go +++ b/app/sim_test.go @@ -2,105 +2,328 @@ package app_test import ( "encoding/json" + "flag" "fmt" + "math/rand" "os" + "runtime/debug" + "strings" "testing" + "time" - wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" - dbm "github.com/cometbft/cometbft-db" - "github.com/cometbft/cometbft/libs/log" - "github.com/cometbft/cometbft/libs/rand" + "cosmossdk.io/log" + "cosmossdk.io/store" + storetypes "cosmossdk.io/store/types" + "cosmossdk.io/x/feegrant" + upgradetypes "cosmossdk.io/x/upgrade/types" + abci "github.com/cometbft/cometbft/abci/types" + cmtproto "github.com/cometbft/cometbft/proto/tendermint/types" + dbm "github.com/cosmos/cosmos-db" "github.com/cosmos/cosmos-sdk/baseapp" - "github.com/cosmos/cosmos-sdk/store" + "github.com/cosmos/cosmos-sdk/client/flags" + "github.com/cosmos/cosmos-sdk/server" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - simulation2 "github.com/cosmos/cosmos-sdk/types/simulation" + simulationtypes "github.com/cosmos/cosmos-sdk/types/simulation" + authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" "github.com/cosmos/cosmos-sdk/x/simulation" simcli "github.com/cosmos/cosmos-sdk/x/simulation/client/cli" - "github.com/sge-network/sge/app" + slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" + stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + "github.com/spf13/viper" "github.com/stretchr/testify/require" + + "github.com/sge-network/sge/app" ) -// SimAppChainID hardcoded chainID for simulation const ( - SimAppChainID = "sge-simapp" + SimAppChainID = "wasmapp-simapp" ) +var FlagEnableStreamingValue bool + +// Get flags every time the simulator is run func init() { simcli.GetSimulatorFlags() + flag.BoolVar(&FlagEnableStreamingValue, "EnableStreaming", false, "Enable streaming service") +} + +// fauxMerkleModeOpt returns a BaseApp option to use a dbStoreAdapter instead of +// an IAVLStore for faster simulation speed. +func fauxMerkleModeOpt(bapp *baseapp.BaseApp) { + bapp.SetFauxMerkleMode() +} + +// interBlockCacheOpt returns a BaseApp option function that sets the persistent +// inter-block write-through cache. +func interBlockCacheOpt() func(*baseapp.BaseApp) { + return baseapp.SetInterBlockCache(store.NewCommitKVStoreCacheManager()) } -// Profile with: -// /usr/local/go/bin/go test -benchmem -run=^$ github.com/cosmos/cosmos-sdk/SgeApp -bench ^BenchmarkFullAppSimulation$ -Commit=true -cpuprofile cpu.out -func BenchmarkFullAppSimulation(b *testing.B) { +// BenchmarkSimulation run the chain simulation +// Running using starport command: +// `ignite chain simulate -v --numBlocks 200 --blockSize 50` +// Running as go benchmark test: +// `go test -benchmem -run=^$ -bench ^BenchmarkSimulation ./app -NumBlocks=200 -BlockSize 50 -Commit=true -Verbose=true -Enabled=true` +func BenchmarkSimulation(b *testing.B) { + simcli.FlagSeedValue = time.Now().Unix() + simcli.FlagVerboseValue = true + simcli.FlagCommitValue = true + simcli.FlagEnabledValue = true + config := simcli.NewConfigFromFlags() - db, dir, logger, _, err := simtestutil.SetupSimulation( - config, - "goleveldb-app-sim", - "Simulation", - simcli.FlagVerboseValue, - simcli.FlagEnabledValue, - ) - if err != nil { - b.Fatalf("simulation setup failed: %s", err.Error()) + config.ChainID = SimAppChainID + + db, dir, logger, skip, err := simtestutil.SetupSimulation(config, "leveldb-app-sim", "Simulation", simcli.FlagVerboseValue, simcli.FlagEnabledValue) + if skip { + b.Skip("skipping application simulation") } + require.NoError(b, err, "simulation setup failed") defer func() { - db.Close() - err = os.RemoveAll(dir) - if err != nil { - b.Fatal(err) - } + require.NoError(b, db.Close()) + require.NoError(b, os.RemoveAll(dir)) }() - sApp := app.NewSgeApp( - logger, - db, - nil, - true, - map[int64]bool{}, - app.DefaultNodeHome, - simcli.FlagPeriodValue, - app.MakeEncodingConfig(), - simtestutil.EmptyAppOptions{}, - []wasmkeeper.Option{}, - interBlockCacheOpt(), - ) + appOptions := make(simtestutil.AppOptionsMap, 0) + appOptions[flags.FlagHome] = app.DefaultNodeHome + appOptions[server.FlagInvCheckPeriod] = simcli.FlagPeriodValue + + bApp, err := app.NewApp(logger, db, nil, true, appOptions, fauxMerkleModeOpt, baseapp.SetChainID(SimAppChainID)) + require.NoError(b, err) + require.Equal(b, app.Name, bApp.Name()) - // Run randomized simulation:w + // run randomized simulation _, simParams, simErr := simulation.SimulateFromSeed( b, os.Stdout, - sApp.BaseApp, - simtestutil.AppStateFn( - sApp.AppCodec(), - sApp.SimulationManager(), - app.NewDefaultGenesisState(), - ), - simulation2.RandomAccounts, // Replace with own random account function if using keys other than secp256k1 - simtestutil.SimulationOperations(sApp, sApp.AppCodec(), config), - sApp.ModuleAccountAddrs(), + bApp.BaseApp, + simtestutil.AppStateFn(bApp.AppCodec(), bApp.SimulationManager(), bApp.DefaultGenesis()), + simulationtypes.RandomAccounts, + simtestutil.SimulationOperations(bApp, bApp.AppCodec(), config), + app.BlockedAddresses(), config, - sApp.AppCodec(), + bApp.AppCodec(), ) // export state and simParams before the simulation error is checked - if err = simtestutil.CheckExportSimulation(sApp, config, simParams); err != nil { - b.Fatal(err) + err = simtestutil.CheckExportSimulation(bApp, config, simParams) + require.NoError(b, err) + require.NoError(b, simErr) + + if config.Commit { + simtestutil.PrintStats(db) } +} + +func TestAppImportExport(t *testing.T) { + config := simcli.NewConfigFromFlags() + config.ChainID = SimAppChainID - if simErr != nil { - b.Fatal(simErr) + db, dir, logger, skip, err := simtestutil.SetupSimulation(config, "leveldb-app-sim", "Simulation", simcli.FlagVerboseValue, simcli.FlagEnabledValue) + if skip { + t.Skip("skipping application import/export simulation") } + require.NoError(t, err, "simulation setup failed") + + defer func() { + require.NoError(t, db.Close()) + require.NoError(t, os.RemoveAll(dir)) + }() + + appOptions := make(simtestutil.AppOptionsMap, 0) + appOptions[flags.FlagHome] = app.DefaultNodeHome + appOptions[server.FlagInvCheckPeriod] = simcli.FlagPeriodValue + + bApp, err := app.NewApp(logger, db, nil, true, appOptions, fauxMerkleModeOpt, baseapp.SetChainID(SimAppChainID)) + require.NoError(t, err) + require.Equal(t, app.Name, bApp.Name()) + + // Run randomized simulation + _, simParams, simErr := simulation.SimulateFromSeed( + t, + os.Stdout, + bApp.BaseApp, + simtestutil.AppStateFn(bApp.AppCodec(), bApp.SimulationManager(), bApp.DefaultGenesis()), + simulationtypes.RandomAccounts, + simtestutil.SimulationOperations(bApp, bApp.AppCodec(), config), + app.BlockedAddresses(), + config, + bApp.AppCodec(), + ) + + // export state and simParams before the simulation error is checked + err = simtestutil.CheckExportSimulation(bApp, config, simParams) + require.NoError(t, err) + require.NoError(t, simErr) if config.Commit { simtestutil.PrintStats(db) } + + fmt.Printf("exporting genesis...\n") + + exported, err := bApp.ExportAppStateAndValidators(false, []string{}, []string{}) + require.NoError(t, err) + + fmt.Printf("importing genesis...\n") + + newDB, newDir, _, _, err := simtestutil.SetupSimulation(config, "leveldb-app-sim-2", "Simulation-2", simcli.FlagVerboseValue, simcli.FlagEnabledValue) + require.NoError(t, err, "simulation setup failed") + + defer func() { + require.NoError(t, newDB.Close()) + require.NoError(t, os.RemoveAll(newDir)) + }() + + newApp, err := app.NewApp(log.NewNopLogger(), newDB, nil, true, appOptions, fauxMerkleModeOpt, baseapp.SetChainID(SimAppChainID)) + require.NoError(t, err) + require.Equal(t, app.Name, newApp.Name()) + + var genesisState app.GenesisState + err = json.Unmarshal(exported.AppState, &genesisState) + require.NoError(t, err) + + ctxA := bApp.NewContextLegacy(true, cmtproto.Header{Height: bApp.LastBlockHeight()}) + ctxB := newApp.NewContextLegacy(true, cmtproto.Header{Height: bApp.LastBlockHeight()}) + _, err = newApp.ModuleManager.InitGenesis(ctxB, bApp.AppCodec(), genesisState) + if err != nil { + if strings.Contains(err.Error(), "validator set is empty after InitGenesis") { + logger.Info("Skipping simulation as all validators have been unbonded") + logger.Info("err", err, "stacktrace", string(debug.Stack())) + return + } + } + require.NoError(t, err) + err = newApp.StoreConsensusParams(ctxB, exported.ConsensusParams) + require.NoError(t, err) + fmt.Printf("comparing stores...\n") + + // skip certain prefixes + skipPrefixes := map[string][][]byte{ + upgradetypes.StoreKey: { + []byte{upgradetypes.VersionMapByte}, + }, + stakingtypes.StoreKey: { + stakingtypes.UnbondingQueueKey, stakingtypes.RedelegationQueueKey, stakingtypes.ValidatorQueueKey, + stakingtypes.HistoricalInfoKey, stakingtypes.UnbondingIDKey, stakingtypes.UnbondingIndexKey, + stakingtypes.UnbondingTypeKey, stakingtypes.ValidatorUpdatesKey, + }, + authzkeeper.StoreKey: {authzkeeper.GrantQueuePrefix}, + feegrant.StoreKey: {feegrant.FeeAllowanceQueueKeyPrefix}, + slashingtypes.StoreKey: {slashingtypes.ValidatorMissedBlockBitmapKeyPrefix}, + } + + storeKeys := bApp.GetStoreKeys() + require.NotEmpty(t, storeKeys) + + for _, appKeyA := range storeKeys { + // only compare kvstores + if _, ok := appKeyA.(*storetypes.KVStoreKey); !ok { + continue + } + + keyName := appKeyA.Name() + appKeyB := newApp.GetKey(keyName) + + storeA := ctxA.KVStore(appKeyA) + storeB := ctxB.KVStore(appKeyB) + + failedKVAs, failedKVBs := simtestutil.DiffKVStores(storeA, storeB, skipPrefixes[keyName]) + require.Equal(t, len(failedKVAs), len(failedKVBs), "unequal sets of key-values to compare %s", keyName) + + fmt.Printf("compared %d different key/value pairs between %s and %s\n", len(failedKVAs), appKeyA, appKeyB) + + require.Equal(t, 0, len(failedKVAs), simtestutil.GetSimulationLog(keyName, bApp.SimulationManager().StoreDecoders, failedKVAs, failedKVBs)) + } } -// interBlockCacheOpt returns a BaseApp option function that sets the persistent -// inter-block write-through cache. -func interBlockCacheOpt() func(*baseapp.BaseApp) { - return baseapp.SetInterBlockCache(store.NewCommitKVStoreCacheManager()) +func TestAppSimulationAfterImport(t *testing.T) { + config := simcli.NewConfigFromFlags() + config.ChainID = SimAppChainID + + db, dir, logger, skip, err := simtestutil.SetupSimulation(config, "leveldb-app-sim", "Simulation", simcli.FlagVerboseValue, simcli.FlagEnabledValue) + if skip { + t.Skip("skipping application simulation after import") + } + require.NoError(t, err, "simulation setup failed") + + defer func() { + require.NoError(t, db.Close()) + require.NoError(t, os.RemoveAll(dir)) + }() + + appOptions := make(simtestutil.AppOptionsMap, 0) + appOptions[flags.FlagHome] = app.DefaultNodeHome + appOptions[server.FlagInvCheckPeriod] = simcli.FlagPeriodValue + + bApp, err := app.NewApp(logger, db, nil, true, appOptions, fauxMerkleModeOpt, baseapp.SetChainID(SimAppChainID)) + require.NoError(t, err) + require.Equal(t, app.Name, bApp.Name()) + + // Run randomized simulation + stopEarly, simParams, simErr := simulation.SimulateFromSeed( + t, + os.Stdout, + bApp.BaseApp, + simtestutil.AppStateFn(bApp.AppCodec(), bApp.SimulationManager(), bApp.DefaultGenesis()), + simulationtypes.RandomAccounts, + simtestutil.SimulationOperations(bApp, bApp.AppCodec(), config), + app.BlockedAddresses(), + config, + bApp.AppCodec(), + ) + + // export state and simParams before the simulation error is checked + err = simtestutil.CheckExportSimulation(bApp, config, simParams) + require.NoError(t, err) + require.NoError(t, simErr) + + if config.Commit { + simtestutil.PrintStats(db) + } + + if stopEarly { + fmt.Println("can't export or import a zero-validator genesis, exiting test...") + return + } + + fmt.Printf("exporting genesis...\n") + + exported, err := bApp.ExportAppStateAndValidators(true, []string{}, []string{}) + require.NoError(t, err) + + fmt.Printf("importing genesis...\n") + + newDB, newDir, _, _, err := simtestutil.SetupSimulation(config, "leveldb-app-sim-2", "Simulation-2", simcli.FlagVerboseValue, simcli.FlagEnabledValue) + require.NoError(t, err, "simulation setup failed") + + defer func() { + require.NoError(t, newDB.Close()) + require.NoError(t, os.RemoveAll(newDir)) + }() + + newApp, err := app.NewApp(log.NewNopLogger(), newDB, nil, true, appOptions, fauxMerkleModeOpt, baseapp.SetChainID(SimAppChainID)) + require.NoError(t, err) + require.Equal(t, app.Name, newApp.Name()) + + _, err = newApp.InitChain(&abci.RequestInitChain{ + AppStateBytes: exported.AppState, + ChainId: SimAppChainID, + }) + require.NoError(t, err) + + _, _, err = simulation.SimulateFromSeed( + t, + os.Stdout, + newApp.BaseApp, + simtestutil.AppStateFn(bApp.AppCodec(), bApp.SimulationManager(), bApp.DefaultGenesis()), + simulationtypes.RandomAccounts, + simtestutil.SimulationOperations(newApp, newApp.AppCodec(), config), + app.BlockedAddresses(), + config, + bApp.AppCodec(), + ) + require.NoError(t, err) } func TestAppStateDeterminism(t *testing.T) { @@ -111,59 +334,80 @@ func TestAppStateDeterminism(t *testing.T) { config := simcli.NewConfigFromFlags() config.InitialBlockHeight = 1 config.ExportParamsPath = "" - config.OnOperation = false - config.AllInvariants = false + config.OnOperation = true + config.AllInvariants = true config.ChainID = SimAppChainID numSeeds := 3 - numTimesToRunPerSeed := 5 + numTimesToRunPerSeed := 3 // This used to be set to 5, but we've temporarily reduced it to 3 for the sake of faster CI. appHashList := make([]json.RawMessage, numTimesToRunPerSeed) + // We will be overriding the random seed and just run a single simulation on the provided seed value + if config.Seed != simcli.DefaultSeedValue { + numSeeds = 1 + } + + appOptions := viper.New() + if FlagEnableStreamingValue { + m := make(map[string]interface{}) + m["streaming.abci.keys"] = []string{"*"} + m["streaming.abci.plugin"] = "abci_v1" + m["streaming.abci.stop-node-on-err"] = true + for key, value := range m { + appOptions.SetDefault(key, value) + } + } + appOptions.SetDefault(flags.FlagHome, app.DefaultNodeHome) + appOptions.SetDefault(server.FlagInvCheckPeriod, simcli.FlagPeriodValue) + if simcli.FlagVerboseValue { + appOptions.SetDefault(flags.FlagLogLevel, "debug") + } + for i := 0; i < numSeeds; i++ { - config.Seed = rand.Int63() + if config.Seed == simcli.DefaultSeedValue { + config.Seed = rand.Int63() + } + fmt.Println("config.Seed: ", config.Seed) for j := 0; j < numTimesToRunPerSeed; j++ { var logger log.Logger if simcli.FlagVerboseValue { - logger = log.TestingLogger() + logger = log.NewTestLogger(t) } else { logger = log.NewNopLogger() } db := dbm.NewMemDB() - sApp := app.NewSgeApp( + bApp, err := app.NewApp( logger, db, nil, true, - map[int64]bool{}, - app.DefaultNodeHome, - simcli.FlagPeriodValue, - app.MakeEncodingConfig(), - simtestutil.EmptyAppOptions{}, - []wasmkeeper.Option{}, + appOptions, interBlockCacheOpt(), + baseapp.SetChainID(SimAppChainID), ) + require.NoError(t, err) fmt.Printf( "running non-determinism simulation; seed %d: %d/%d, attempt: %d/%d\n", config.Seed, i+1, numSeeds, j+1, numTimesToRunPerSeed, ) - _, _, err := simulation.SimulateFromSeed( + _, _, err = simulation.SimulateFromSeed( t, os.Stdout, - sApp.BaseApp, + bApp.BaseApp, simtestutil.AppStateFn( - sApp.AppCodec(), - sApp.SimulationManager(), - app.NewDefaultGenesisState(), + bApp.AppCodec(), + bApp.SimulationManager(), + bApp.DefaultGenesis(), ), - simulation2.RandomAccounts, // Replace with own random account function if using keys other than secp256k1 - simtestutil.SimulationOperations(sApp, sApp.AppCodec(), config), - sApp.ModuleAccountAddrs(), + simulationtypes.RandomAccounts, + simtestutil.SimulationOperations(bApp, bApp.AppCodec(), config), + app.BlockedAddresses(), config, - sApp.AppCodec(), + bApp.AppCodec(), ) require.NoError(t, err) @@ -171,20 +415,13 @@ func TestAppStateDeterminism(t *testing.T) { simtestutil.PrintStats(db) } - appHash := sApp.LastCommitID().Hash + appHash := bApp.LastCommitID().Hash appHashList[j] = appHash if j != 0 { require.Equal( - t, - string(appHashList[0]), - string(appHashList[j]), - "non-determinism in seed %d: %d/%d, attempt: %d/%d\n", - config.Seed, - i+1, - numSeeds, - j+1, - numTimesToRunPerSeed, + t, string(appHashList[0]), string(appHashList[j]), + "non-determinism in seed %d: %d/%d, attempt: %d/%d\n", config.Seed, i+1, numSeeds, j+1, numTimesToRunPerSeed, ) } } diff --git a/app/upgrades/types.go b/app/upgrades/types.go index b6f579fc..78538c76 100644 --- a/app/upgrades/types.go +++ b/app/upgrades/types.go @@ -1,10 +1,10 @@ package upgrades import ( - store "github.com/cosmos/cosmos-sdk/store/types" + store "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/types/module" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" + upgradetypes "cosmossdk.io/x/upgrade/types" "github.com/sge-network/sge/app/keepers" ) diff --git a/app/upgrades/v10/consts.go b/app/upgrades/v10/consts.go index 9d34f899..ea0af6e8 100644 --- a/app/upgrades/v10/consts.go +++ b/app/upgrades/v10/consts.go @@ -1,19 +1,22 @@ package v10 import ( - store "github.com/cosmos/cosmos-sdk/store/types" + store "cosmossdk.io/store/types" + circuittypes "cosmossdk.io/x/circuit/types" "github.com/sge-network/sge/app/upgrades" ) -// UpgradeName defines the on-chain upgrade name for the v1.7.6 upgrade. -const UpgradeName = "v1.7.6" +// UpgradeName defines the on-chain upgrade name for the v1.8.0 upgrade. +const UpgradeName = "v1.8.0" var Upgrade = upgrades.Upgrade{ UpgradeName: UpgradeName, CreateUpgradeHandler: CreateUpgradeHandler, StoreUpgrades: store.StoreUpgrades{ - Added: []string{}, + Added: []string{ + circuittypes.ModuleName, + }, Deleted: []string{}, }, } diff --git a/app/upgrades/v10/upgrades.go b/app/upgrades/v10/upgrades.go index 640025b7..d05d84f1 100644 --- a/app/upgrades/v10/upgrades.go +++ b/app/upgrades/v10/upgrades.go @@ -1,18 +1,18 @@ package v10 import ( - "strings" + "context" + "time" sdkmath "cosmossdk.io/math" + upgradetypes "cosmossdk.io/x/upgrade/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" + paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" "github.com/sge-network/sge/app/keepers" "github.com/sge-network/sge/app/params" - housetypes "github.com/sge-network/sge/x/house/types" - orderbooktypes "github.com/sge-network/sge/x/orderbook/types" - rewardtypes "github.com/sge-network/sge/x/reward/types" + minttypes "github.com/sge-network/sge/x/mint/types" ) func CreateUpgradeHandler( @@ -20,64 +20,44 @@ func CreateUpgradeHandler( configurator module.Configurator, k *keepers.AppKeepers, ) upgradetypes.UpgradeHandler { - return func(ctx sdk.Context, _ upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { - var recAddress sdk.AccAddress - switch strings.ToLower(ctx.ChainID()) { - case "sgenet-1": - recAddress = sdk.MustAccAddressFromBech32("sge10gtzxh97gvgt6s58w5gagsacrwddhmgzn5ksk6") - case "sge-network-4": - recAddress = sdk.MustAccAddressFromBech32("sge19dkag3dkzcmjzhctz8ysfws443yq0nyyu0r8c0") - case "stage-sgenetwork": - recAddress = sdk.MustAccAddressFromBech32("sge1wkzh54s97m4cr70wfq9j7e4u42mkt2a7hak84c") - default: - return mm.RunMigrations(ctx, configurator, fromVM) - } + return func(ctx context.Context, _ upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { + // https://github.com/cosmos/cosmos-sdk/pull/12363/files + // Set param key table for params module migration + for _, subspace := range k.ParamsKeeper.GetSubspaces() { + var keyTable paramstypes.KeyTable + switch subspace.Name() { + // sdk + case minttypes.ModuleName: + keyTable = minttypes.ParamKeyTable() + default: + continue + } - orderBookBalance := k.BankKeeper.GetBalance( - ctx, - k.AccountKeeper.GetModuleAddress(orderbooktypes.OrderBookLiquidityFunder{}.GetModuleAcc()), - params.DefaultBondDenom, - ) - if orderBookBalance.Amount.GT(sdkmath.ZeroInt()) { - if err := k.BankKeeper.SendCoinsFromModuleToAccount( - ctx, - orderbooktypes.OrderBookLiquidityFunder{}.GetModuleAcc(), - recAddress, sdk.NewCoins(orderBookBalance), - ); err != nil { - return nil, err + if !subspace.HasKeyTable() { + subspace.WithKeyTable(keyTable) } } - houseFeeBalance := k.BankKeeper.GetBalance( - ctx, - k.AccountKeeper.GetModuleAddress(housetypes.HouseFeeCollectorFunder{}.GetModuleAcc()), - params.DefaultBondDenom, - ) - if houseFeeBalance.Amount.GT(sdkmath.ZeroInt()) { - if err := k.BankKeeper.SendCoinsFromModuleToAccount( - ctx, - housetypes.HouseFeeCollectorFunder{}.GetModuleAcc(), - recAddress, sdk.NewCoins(houseFeeBalance), - ); err != nil { - return nil, err - } + migrations, err := mm.RunMigrations(ctx, configurator, fromVM) + if err != nil { + return nil, err } - rewardPoolBalance := k.BankKeeper.GetBalance( - ctx, - k.AccountKeeper.GetModuleAddress(rewardtypes.RewardPoolFunder{}.GetModuleAcc()), - params.DefaultBondDenom, - ) - if rewardPoolBalance.Amount.GT(sdkmath.ZeroInt()) { - if err := k.BankKeeper.SendCoinsFromModuleToAccount( - ctx, - rewardtypes.RewardPoolFunder{}.GetModuleAcc(), - recAddress, sdk.NewCoins(rewardPoolBalance), - ); err != nil { - return nil, err - } + // Set expedited proposal param: + govParams, err := k.GovKeeper.Params.Get(ctx) + if err != nil { + return nil, err + } + govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(50000000000))) + govParams.MinInitialDepositRatio = "0.000000000000000000" + govParams.ExpeditedThreshold = "0.750000000000000000" + expediteVotingPeriod := 86400 * time.Second + govParams.ExpeditedVotingPeriod = &expediteVotingPeriod + err = k.GovKeeper.Params.Set(ctx, govParams) + if err != nil { + return nil, err } - return mm.RunMigrations(ctx, configurator, fromVM) + return migrations, nil } } diff --git a/app/upgrades/v9/consts.go b/app/upgrades/v9/consts.go deleted file mode 100644 index 915ed4f3..00000000 --- a/app/upgrades/v9/consts.go +++ /dev/null @@ -1,32 +0,0 @@ -package v9 - -import ( - store "github.com/cosmos/cosmos-sdk/store/types" - consensustypes "github.com/cosmos/cosmos-sdk/x/consensus/types" - crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" - - ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" - ibcwasmtypes "github.com/cosmos/ibc-go/modules/light-clients/08-wasm/types" - - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - - "github.com/sge-network/sge/app/upgrades" -) - -// UpgradeName defines the on-chain upgrade name for the v1.7.0 upgrade. -const UpgradeName = "v1.7.0" - -var Upgrade = upgrades.Upgrade{ - UpgradeName: UpgradeName, - CreateUpgradeHandler: CreateUpgradeHandler, - StoreUpgrades: store.StoreUpgrades{ - Added: []string{ - crisistypes.ModuleName, - consensustypes.ModuleName, - ibchookstypes.StoreKey, - wasmtypes.ModuleName, - ibcwasmtypes.ModuleName, - }, - Deleted: []string{}, - }, -} diff --git a/app/upgrades/v9/upgrades.go b/app/upgrades/v9/upgrades.go deleted file mode 100644 index 5665de7b..00000000 --- a/app/upgrades/v9/upgrades.go +++ /dev/null @@ -1,128 +0,0 @@ -package v9 - -import ( - "fmt" - - sdkmath "cosmossdk.io/math" - "github.com/cosmos/cosmos-sdk/baseapp" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/module" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" - distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" - paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - - ibcwasmtypes "github.com/cosmos/ibc-go/modules/light-clients/08-wasm/types" - icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" - icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" - ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" - exported "github.com/cosmos/ibc-go/v7/modules/core/exported" - - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - - "github.com/sge-network/sge/app/keepers" - betmoduletypes "github.com/sge-network/sge/x/bet/types" - housemoduletypes "github.com/sge-network/sge/x/house/types" - marketmoduletypes "github.com/sge-network/sge/x/market/types" - minttypes "github.com/sge-network/sge/x/mint/types" - orderbookmoduletypes "github.com/sge-network/sge/x/orderbook/types" - ovmmoduletypes "github.com/sge-network/sge/x/ovm/types" - rewardmoduletypes "github.com/sge-network/sge/x/reward/types" - subaccountmoduletypes "github.com/sge-network/sge/x/subaccount/types" -) - -//nolint:staticcheck -func CreateUpgradeHandler( - mm *module.Manager, - configurator module.Configurator, - k *keepers.AppKeepers, -) upgradetypes.UpgradeHandler { - return func(ctx sdk.Context, _ upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { - // https://github.com/cosmos/cosmos-sdk/pull/12363/files - // Set param key table for params module migration - for _, subspace := range k.ParamsKeeper.GetSubspaces() { - var keyTable paramstypes.KeyTable - switch subspace.Name() { - case authtypes.ModuleName: - keyTable = authtypes.ParamKeyTable() - case banktypes.ModuleName: - keyTable = banktypes.ParamKeyTable() - case stakingtypes.ModuleName: - keyTable = stakingtypes.ParamKeyTable() - - // case minttypes.ModuleName: - // keyTable = minttypes.ParamKeyTable() - case distrtypes.ModuleName: - keyTable = distrtypes.ParamKeyTable() - case slashingtypes.ModuleName: - keyTable = slashingtypes.ParamKeyTable() - case govtypes.ModuleName: - keyTable = govv1.ParamKeyTable() - case crisistypes.ModuleName: - keyTable = crisistypes.ParamKeyTable() - - // ibc types - case ibctransfertypes.ModuleName: - keyTable = ibctransfertypes.ParamKeyTable() - case icahosttypes.SubModuleName: - keyTable = icahosttypes.ParamKeyTable() - case icacontrollertypes.SubModuleName: - keyTable = icacontrollertypes.ParamKeyTable() - - // wasm - case wasmtypes.ModuleName: - keyTable = wasmtypes.ParamKeyTable() //nolint:staticcheck - - // sge modules - case betmoduletypes.ModuleName: - keyTable = betmoduletypes.ParamKeyTable() - case housemoduletypes.ModuleName: - keyTable = housemoduletypes.ParamKeyTable() - case marketmoduletypes.ModuleName: - keyTable = marketmoduletypes.ParamKeyTable() - case minttypes.ModuleName: - keyTable = minttypes.ParamKeyTable() - case orderbookmoduletypes.ModuleName: - keyTable = orderbookmoduletypes.ParamKeyTable() - case ovmmoduletypes.ModuleName: - keyTable = ovmmoduletypes.ParamKeyTable() - case subaccountmoduletypes.ModuleName: - keyTable = subaccountmoduletypes.ParamKeyTable() - case rewardmoduletypes.ModuleName: - keyTable = rewardmoduletypes.ParamKeyTable() - } - - if !subspace.HasKeyTable() { - fmt.Println(subspace.Name()) - subspace.WithKeyTable(keyTable) - } - } - - // Migrate Tendermint consensus parameters from x/params module to a - // dedicated x/consensus module. - baseAppLegacySS := k.ParamsKeeper.Subspace(baseapp.Paramspace).WithKeyTable(paramstypes.ConsensusParamsKeyTable()) - baseapp.MigrateParams(ctx, baseAppLegacySS, &k.ConsensusParamsKeeper) - - // https://github.com/cosmos/ibc-go/blob/v7.1.0/docs/migrations/v7-to-v7_1.md - // explicitly update the IBC 02-client params, adding the localhost client type - params := k.IBCKeeper.ClientKeeper.GetParams(ctx) - params.AllowedClients = append(params.AllowedClients, exported.Localhost) - params.AllowedClients = append(params.AllowedClients, ibcwasmtypes.Wasm) - k.IBCKeeper.ClientKeeper.SetParams(ctx, params) - - // update gov params to use a 20% initial deposit ratio, allowing us to remote the ante handler - govParams := k.GovKeeper.GetParams(ctx) - govParams.MinInitialDepositRatio = sdkmath.LegacyNewDec(20).Quo(sdkmath.LegacyNewDec(100)).String() - if err := k.GovKeeper.SetParams(ctx, govParams); err != nil { - return nil, err - } - - return mm.RunMigrations(ctx, configurator, fromVM) - } -} diff --git a/app/wasm.go b/app/wasm.go new file mode 100644 index 00000000..c1fcc8b7 --- /dev/null +++ b/app/wasm.go @@ -0,0 +1,155 @@ +package app + +import ( + "fmt" + "path/filepath" + + storetypes "cosmossdk.io/store/types" + "github.com/CosmWasm/wasmd/x/wasm" + wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" + wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" + "github.com/cosmos/cosmos-sdk/client" + "github.com/cosmos/cosmos-sdk/runtime" + servertypes "github.com/cosmos/cosmos-sdk/server/types" + "github.com/cosmos/cosmos-sdk/types/msgservice" + "github.com/cosmos/cosmos-sdk/x/auth/ante" + "github.com/cosmos/cosmos-sdk/x/auth/posthandler" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + distrkeeper "github.com/cosmos/cosmos-sdk/x/distribution/keeper" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/gogoproto/proto" + ibcfee "github.com/cosmos/ibc-go/v8/modules/apps/29-fee" + porttypes "github.com/cosmos/ibc-go/v8/modules/core/05-port/types" +) + +// registerWasmModules register CosmWasm keepers and non dependency inject modules. +func (app *App) registerWasmModules( + appOpts servertypes.AppOptions, + wasmOpts ...wasmkeeper.Option, +) (porttypes.IBCModule, error) { + // set up non depinject support modules store keys + if err := app.RegisterStores( + storetypes.NewKVStoreKey(wasmtypes.StoreKey), + ); err != nil { + panic(err) + } + + scopedWasmKeeper := app.CapabilityKeeper.ScopeToModule(wasmtypes.ModuleName) + + wasmDir := filepath.Join(DefaultNodeHome, "wasm") + + wasmConfig, err := wasm.ReadWasmConfig(appOpts) + if err != nil { + return nil, fmt.Errorf("error while reading wasm config: %s", err) + } + + // The last arguments can contain custom message handlers, and custom query handlers, + // if we want to allow any custom callbacks + app.WasmKeeper = wasmkeeper.NewKeeper( + app.AppCodec(), + runtime.NewKVStoreService(app.GetKey(wasmtypes.StoreKey)), + app.AccountKeeper, + app.BankKeeper, + app.StakingKeeper, + distrkeeper.NewQuerier(app.DistrKeeper), + app.IBCFeeKeeper, // ISC4 Wrapper: fee IBC middleware + app.IBCKeeper.ChannelKeeper, + app.IBCKeeper.PortKeeper, + scopedWasmKeeper, + app.TransferKeeper, + app.MsgServiceRouter(), + app.GRPCQueryRouter(), + wasmDir, + wasmConfig, + wasmkeeper.BuiltInCapabilities(), + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + wasmOpts..., + ) + + // register IBC modules + if err := app.RegisterModules( + wasm.NewAppModule( + app.AppCodec(), + &app.WasmKeeper, + app.StakingKeeper, + app.AccountKeeper, + app.BankKeeper, + app.MsgServiceRouter(), + app.GetSubspace(wasmtypes.ModuleName), + )); err != nil { + return nil, err + } + + if err := app.setAnteHandler(app.txConfig, wasmConfig, app.GetKey(wasmtypes.StoreKey)); err != nil { + return nil, err + } + + if manager := app.SnapshotManager(); manager != nil { + err := manager.RegisterExtensions( + wasmkeeper.NewWasmSnapshotter(app.CommitMultiStore(), &app.WasmKeeper), + ) + if err != nil { + return nil, fmt.Errorf("failed to register snapshot extension: %s", err) + } + } + app.ScopedWasmKeeper = scopedWasmKeeper + + if err := app.setPostHandler(); err != nil { + return nil, err + } + + // At startup, after all modules have been registered, check that all proto + // annotations are correct. + protoFiles, err := proto.MergedRegistry() + if err != nil { + return nil, err + } + err = msgservice.ValidateProtoAnnotations(protoFiles) + if err != nil { + return nil, err + } + + // Create fee enabled wasm ibc Stack + var wasmStack porttypes.IBCModule + wasmStack = wasm.NewIBCHandler(app.WasmKeeper, app.IBCKeeper.ChannelKeeper, app.IBCFeeKeeper) + wasmStack = ibcfee.NewIBCMiddleware(wasmStack, app.IBCFeeKeeper) + + return wasmStack, nil +} + +func (app *App) setPostHandler() error { + postHandler, err := posthandler.NewPostHandler( + posthandler.HandlerOptions{}, + ) + if err != nil { + return err + } + app.SetPostHandler(postHandler) + return nil +} + +func (app *App) setAnteHandler(txConfig client.TxConfig, wasmConfig wasmtypes.WasmConfig, txCounterStoreKey *storetypes.KVStoreKey) error { + anteHandler, err := NewAnteHandler( + HandlerOptions{ + HandlerOptions: ante.HandlerOptions{ + AccountKeeper: app.AccountKeeper, + BankKeeper: app.BankKeeper, + SignModeHandler: txConfig.SignModeHandler(), + FeegrantKeeper: app.FeeGrantKeeper, + SigGasConsumer: ante.DefaultSigVerificationGasConsumer, + }, + IBCKeeper: app.IBCKeeper, + WasmConfig: &wasmConfig, + WasmKeeper: &app.WasmKeeper, + TXCounterStoreService: runtime.NewKVStoreService(txCounterStoreKey), + CircuitKeeper: &app.CircuitBreakerKeeper, + }, + ) + if err != nil { + return fmt.Errorf("failed to create AnteHandler: %s", err) + } + + // Set the AnteHandler for the app + app.SetAnteHandler(anteHandler) + return nil +} diff --git a/cmd/sged/cmd/args.go b/cmd/sged/cmd/args.go deleted file mode 100644 index b4a2e33a..00000000 --- a/cmd/sged/cmd/args.go +++ /dev/null @@ -1,11 +0,0 @@ -package cmd - -const ( - EnvPrefix = "SGE" - - argAppHome = "The application home directory" - argKeyringBackend = "Select keyring backend (os|file|kwallet|pass|test)" - argVestingAccountCoins = "amount of coins for vesting accounts" - argVestingScheduleStart = "schedule start time (unix epoch) for vesting accounts" - argVestingScheduleEnd = "schedule end time (unix epoch) for vesting accounts" -) diff --git a/cmd/sged/cmd/commands.go b/cmd/sged/cmd/commands.go new file mode 100644 index 00000000..f075bcb4 --- /dev/null +++ b/cmd/sged/cmd/commands.go @@ -0,0 +1,195 @@ +package cmd + +import ( + "errors" + "io" + + "cosmossdk.io/log" + confixcmd "cosmossdk.io/tools/confix/cmd" + dbm "github.com/cosmos/cosmos-db" + "github.com/cosmos/cosmos-sdk/client" + "github.com/cosmos/cosmos-sdk/client/debug" + "github.com/cosmos/cosmos-sdk/client/flags" + "github.com/cosmos/cosmos-sdk/client/keys" + "github.com/cosmos/cosmos-sdk/client/pruning" + "github.com/cosmos/cosmos-sdk/client/rpc" + "github.com/cosmos/cosmos-sdk/client/snapshot" + "github.com/cosmos/cosmos-sdk/server" + servertypes "github.com/cosmos/cosmos-sdk/server/types" + "github.com/cosmos/cosmos-sdk/types/module" + authcmd "github.com/cosmos/cosmos-sdk/x/auth/client/cli" + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + "github.com/cosmos/cosmos-sdk/x/crisis" + genutilcli "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" + "github.com/spf13/cobra" + "github.com/spf13/viper" + + "github.com/sge-network/sge/app" + + "github.com/CosmWasm/wasmd/x/wasm" + wasmcli "github.com/CosmWasm/wasmd/x/wasm/client/cli" +) + +func initRootCmd( + rootCmd *cobra.Command, + txConfig client.TxConfig, + basicManager module.BasicManager, +) { + rootCmd.AddCommand( + genutilcli.InitCmd(basicManager, app.DefaultNodeHome), + NewInPlaceTestnetCmd(addModuleInitFlags), + NewTestnetMultiNodeCmd(basicManager, banktypes.GenesisBalancesIterator{}), + debug.Cmd(), + confixcmd.ConfigCommand(), + pruning.Cmd(newApp, app.DefaultNodeHome), + snapshot.Cmd(newApp), + ) + + server.AddCommands(rootCmd, app.DefaultNodeHome, newApp, appExport, addModuleInitFlags) + + // add keybase, auxiliary RPC, query, genesis, and tx child commands + rootCmd.AddCommand( + server.StatusCommand(), + genesisCommand(txConfig, basicManager), + queryCommand(), + txCommand(), + keys.Commands(), + ) + wasmcli.ExtendUnsafeResetAllCmd(rootCmd) +} + +func addModuleInitFlags(startCmd *cobra.Command) { + crisis.AddModuleInitFlags(startCmd) + wasm.AddModuleInitFlags(startCmd) +} + +// genesisCommand builds genesis-related `sged genesis` command. Users may provide application specific commands as a parameter +func genesisCommand(txConfig client.TxConfig, basicManager module.BasicManager, cmds ...*cobra.Command) *cobra.Command { + cmd := genutilcli.Commands(txConfig, basicManager, app.DefaultNodeHome) + + for _, subCmd := range cmds { + cmd.AddCommand(subCmd) + } + return cmd +} + +func queryCommand() *cobra.Command { + cmd := &cobra.Command{ + Use: "query", + Aliases: []string{"q"}, + Short: "Querying subcommands", + DisableFlagParsing: false, + SuggestionsMinimumDistance: 2, + RunE: client.ValidateCmd, + } + + cmd.AddCommand( + rpc.QueryEventForTxCmd(), + rpc.ValidatorCommand(), + server.QueryBlockCmd(), + authcmd.QueryTxsByEventsCmd(), + server.QueryBlocksCmd(), + authcmd.QueryTxCmd(), + server.QueryBlockResultsCmd(), + ) + cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") + + return cmd +} + +func txCommand() *cobra.Command { + cmd := &cobra.Command{ + Use: "tx", + Short: "Transactions subcommands", + DisableFlagParsing: false, + SuggestionsMinimumDistance: 2, + RunE: client.ValidateCmd, + } + + cmd.AddCommand( + authcmd.GetSignCommand(), + authcmd.GetSignBatchCommand(), + authcmd.GetMultiSignCommand(), + authcmd.GetMultiSignBatchCmd(), + authcmd.GetValidateSignaturesCommand(), + flags.LineBreak, + authcmd.GetBroadcastCommand(), + authcmd.GetEncodeCommand(), + authcmd.GetDecodeCommand(), + authcmd.GetSimulateCmd(), + ) + cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") + + return cmd +} + +// newApp creates the application +func newApp( + logger log.Logger, + db dbm.DB, + traceStore io.Writer, + appOpts servertypes.AppOptions, +) servertypes.Application { + baseappOptions := server.DefaultBaseappOptions(appOpts) + + app, err := app.NewApp( + logger, db, traceStore, true, + appOpts, + baseappOptions..., + ) + if err != nil { + panic(err) + } + return app +} + +// appExport creates a new app (optionally at a given height) and exports state. +func appExport( + logger log.Logger, + db dbm.DB, + traceStore io.Writer, + height int64, + forZeroHeight bool, + jailAllowedAddrs []string, + appOpts servertypes.AppOptions, + modulesToExport []string, +) (servertypes.ExportedApp, error) { + var ( + bApp *app.App + err error + ) + + // this check is necessary as we use the flag in x/upgrade. + // we can exit more gracefully by checking the flag here. + homePath, ok := appOpts.Get(flags.FlagHome).(string) + if !ok || homePath == "" { + return servertypes.ExportedApp{}, errors.New("application home not set") + } + + viperAppOpts, ok := appOpts.(*viper.Viper) + if !ok { + return servertypes.ExportedApp{}, errors.New("appOpts is not viper.Viper") + } + + // overwrite the FlagInvCheckPeriod + viperAppOpts.Set(server.FlagInvCheckPeriod, 1) + appOpts = viperAppOpts + + if height != -1 { + bApp, err = app.NewApp(logger, db, traceStore, false, appOpts) + if err != nil { + return servertypes.ExportedApp{}, err + } + + if err := bApp.LoadHeight(height); err != nil { + return servertypes.ExportedApp{}, err + } + } else { + bApp, err = app.NewApp(logger, db, traceStore, true, appOpts) + if err != nil { + return servertypes.ExportedApp{}, err + } + } + + return bApp.ExportAppStateAndValidators(forZeroHeight, jailAllowedAddrs, modulesToExport) +} diff --git a/cmd/sged/cmd/config.go b/cmd/sged/cmd/config.go new file mode 100644 index 00000000..a14ebc57 --- /dev/null +++ b/cmd/sged/cmd/config.go @@ -0,0 +1,62 @@ +package cmd + +import ( + cmtcfg "github.com/cometbft/cometbft/config" + serverconfig "github.com/cosmos/cosmos-sdk/server/config" +) + +// initCometBFTConfig helps to override default CometBFT Config values. +// return cmtcfg.DefaultConfig if no custom configuration is required for the application. +func initCometBFTConfig() *cmtcfg.Config { + cfg := cmtcfg.DefaultConfig() + + // these values put a higher strain on node memory + // cfg.P2P.MaxNumInboundPeers = 100 + // cfg.P2P.MaxNumOutboundPeers = 40 + + return cfg +} + +// initAppConfig helps to override default appConfig template and configs. +// return "", nil if no custom configuration is required for the application. +func initAppConfig() (string, interface{}) { + // The following code snippet is just for reference. + type CustomAppConfig struct { + serverconfig.Config `mapstructure:",squash"` + } + + // Optionally allow the chain developer to overwrite the SDK's default + // server config. + srvCfg := serverconfig.DefaultConfig() + // The SDK's default minimum gas price is set to "" (empty value) inside + // app.toml. If left empty by validators, the node will halt on startup. + // However, the chain developer can set a default app.toml value for their + // validators here. + // + // In summary: + // - if you leave srvCfg.MinGasPrices = "", all validators MUST tweak their + // own app.toml config, + // - if you set srvCfg.MinGasPrices non-empty, validators CAN tweak their + // own app.toml to override, or use this default value. + // + // In tests, we set the min gas prices to 0. + // srvCfg.MinGasPrices = "0stake" + // srvCfg.BaseConfig.IAVLDisableFastNode = true // disable fastnode by default + + customAppConfig := CustomAppConfig{ + Config: *srvCfg, + } + + customAppTemplate := serverconfig.DefaultConfigTemplate + // Edit the default template file + // + // customAppTemplate := serverconfig.DefaultConfigTemplate + ` + // [wasm] + // # This is the maximum sdk gas (wasm and storage) that we allow for any x/wasm "smart" queries + // query_gas_limit = 300000 + // # This is the number of wasm vm instances we keep cached in memory for speed-up + // # Warning: this is currently unstable and may lead to crashes, best to keep for 0 unless testing locally + // lru_size = 0` + + return customAppTemplate, customAppConfig +} diff --git a/cmd/sged/cmd/errors.go b/cmd/sged/cmd/errors.go deleted file mode 100644 index 4c50e241..00000000 --- a/cmd/sged/cmd/errors.go +++ /dev/null @@ -1,18 +0,0 @@ -package cmd - -const ( - errTextVestingAccountGreaterThanTotal = "vesting amount cannot be greater than total amount" - errTextInvalidVestingParams = "invalid vesting parameters; must supply start and end time or end time" - errTextGenesisUnmarshalFailed = "failed to unmarshal genesis state: %w" - errTextBlankGenesisUnmarshalFailed = "failed to marshal bank genesis state: %w" - errTextApplicationGenesisMarshalFailed = "failed to marshal application genesis state: %w" - errTextGettingAddressFromKeybaseFailed = "failed to get address from Keybase: %w" - errTextGettingAddressFromInfoFailed = "failed to get address from info: %w" - errTextCoinsParsingFailed = "failed to parse coins: %w" - errTextGetAccountFromAnyFailed = "failed to get accounts from any: %w" - errTextCannotAddExistingAddress = "cannot add account at existing address %s" - errTextConvertAccountToAnyFailed = "failed to convert accounts into any's: %w" - errTextGenesisAuthMarshalFailed = "failed to marshal auth genesis state: %w" - errTextParsingVestingAmountFailed = "failed to parse vesting amount: %w" - errTextGenesisAccValidationFailed = "failed to validate new genesis account: %w" -) diff --git a/cmd/sged/cmd/genaccounts.go b/cmd/sged/cmd/genaccounts.go deleted file mode 100644 index 3a06e359..00000000 --- a/cmd/sged/cmd/genaccounts.go +++ /dev/null @@ -1,265 +0,0 @@ -package cmd - -import ( - "bufio" - "encoding/json" - "errors" - "fmt" - - "github.com/spf13/cobra" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/cosmos/cosmos-sdk/codec" - "github.com/cosmos/cosmos-sdk/crypto/keyring" - "github.com/cosmos/cosmos-sdk/server" - sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - authvesting "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/cosmos-sdk/x/genutil" - genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" -) - -const ( - flagVestingStart = "vesting-start-time" - flagVestingEnd = "vesting-end-time" - flagVestingAmt = "vesting-amount" - genesisAccountNumber = 0 - genesisSequenceNumber = 0 - defaultVestingStart = 0 - defaultVestingEnd = 0 -) - -// AddGenesisAccountCmd returns add-genesis-account cobra Command. -func AddGenesisAccountCmd(defaultNodeHome string) *cobra.Command { - cmd := &cobra.Command{ - Use: "add-genesis-account [address_or_key_name] [coin][,[coin]]", - Short: "Add a genesis account to genesis.json", - Long: `Add a genesis account to genesis.json. The provided account must specify -the account address or key name and a list of initial coins. If a key name is given, -the address will be looked up in the local Keybase. The list of initial tokens must -contain valid denominations. Accounts may optionally be supplied with vesting parameters. -`, - Args: cobra.ExactArgs(2), - RunE: func(cmd *cobra.Command, args []string) error { - clientCtx := client.GetClientContextFromCmd(cmd) - - serverCtx := server.GetServerContextFromCmd(cmd) - config := serverCtx.Config - - config.SetRoot(clientCtx.HomeDir) - - addr, genAccount, balances, err := getAccountAddressAndBalances( - cmd, - args[0], - args[1], - clientCtx.HomeDir, - clientCtx, - ) - if err != nil { - return err - } - - genFile := config.GenesisFile() - appState, genDoc, err := genutiltypes.GenesisStateFromGenFile(genFile) - if err != nil { - return fmt.Errorf(errTextGenesisUnmarshalFailed, err) - } - - authGenStateBz, err := getAuthGenesisState(clientCtx.Codec, appState, addr, genAccount) - if err != nil { - return err - } - - appState[authtypes.ModuleName] = authGenStateBz - - bankGenState := banktypes.GetGenesisStateFromAppState(clientCtx.Codec, appState) - bankGenState.Balances = append(bankGenState.Balances, balances) - bankGenState.Balances = banktypes.SanitizeGenesisBalances(bankGenState.Balances) - bankGenState.Supply = bankGenState.Supply.Add(balances.Coins...) - - bankGenStateBz, err := clientCtx.Codec.MarshalJSON(bankGenState) - if err != nil { - return fmt.Errorf(errTextBlankGenesisUnmarshalFailed, err) - } - - appState[banktypes.ModuleName] = bankGenStateBz - - appStateJSON, err := json.Marshal(appState) - if err != nil { - return fmt.Errorf(errTextApplicationGenesisMarshalFailed, err) - } - - genDoc.AppState = appStateJSON - return genutil.ExportGenesisFile(genDoc, genFile) - }, - } - - cmd.Flags().String(flags.FlagHome, defaultNodeHome, argAppHome) - cmd.Flags().String(flags.FlagKeyringBackend, flags.DefaultKeyringBackend, argKeyringBackend) - cmd.Flags().String(flagVestingAmt, "", argVestingAccountCoins) - cmd.Flags().Int64(flagVestingStart, defaultVestingStart, argVestingScheduleStart) - cmd.Flags().Int64(flagVestingEnd, defaultVestingEnd, argVestingScheduleEnd) - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} - -func getAccountAddress(cmd *cobra.Command, address, homeDir string, clientCtx client.Context) (sdk.AccAddress, error) { - addr, err := sdk.AccAddressFromBech32(address) - if err != nil { - inBuf := bufio.NewReader(cmd.InOrStdin()) - keyringBackend, err := cmd.Flags().GetString(flags.FlagKeyringBackend) - if err != nil { - return sdk.AccAddress{}, err - } - - // attempt to lookup address from Keybase if no address was provided - kb, err := keyring.New(sdk.KeyringServiceName(), keyringBackend, homeDir, inBuf, clientCtx.Codec) - if err != nil { - return sdk.AccAddress{}, err - } - - info, err := kb.Key(address) - if err != nil { - return sdk.AccAddress{}, fmt.Errorf(errTextGettingAddressFromKeybaseFailed, err) - } - - addr, err = info.GetAddress() - if err != nil { - return sdk.AccAddress{}, fmt.Errorf(errTextGettingAddressFromInfoFailed, err) - } - } - return addr, nil -} - -func getAccountAddressAndBalances(cmd *cobra.Command, - addressOrKeyName, - coins, - homeDir string, - clientCtx client.Context, -) ( - sdk.AccAddress, - authtypes.GenesisAccount, - banktypes.Balance, - error, -) { - addr, err := getAccountAddress(cmd, addressOrKeyName, homeDir, clientCtx) - if err != nil { - return sdk.AccAddress{}, nil, banktypes.Balance{}, err - } - - cns, err := sdk.ParseCoinsNormalized(coins) - if err != nil { - return sdk.AccAddress{}, nil, banktypes.Balance{}, fmt.Errorf(errTextCoinsParsingFailed, err) - } - - balances := banktypes.Balance{Address: addr.String(), Coins: cns.Sort()} - genAccount, err := getAndValidateGenesisAccount(cmd, addr, balances) - if err != nil { - return sdk.AccAddress{}, nil, banktypes.Balance{}, err - } - return addr, genAccount, balances, err -} - -func getAuthGenesisState(cdc codec.Codec, - appState map[string]json.RawMessage, - addr sdk.Address, - genAccount authtypes.GenesisAccount, -) ([]byte, error) { - authGenState := authtypes.GetGenesisStateFromAppState(cdc, appState) - - accs, err := authtypes.UnpackAccounts(authGenState.Accounts) - if err != nil { - return nil, fmt.Errorf(errTextGetAccountFromAnyFailed, err) - } - - if accs.Contains(addr) { - return nil, fmt.Errorf(errTextCannotAddExistingAddress, addr) - } - - // Add the new account to the set of genesis accounts and sanitize the - // accounts afterwards. - accs = append(accs, genAccount) - accs = authtypes.SanitizeGenesisAccounts(accs) - - genAccs, err := authtypes.PackAccounts(accs) - if err != nil { - return nil, fmt.Errorf(errTextConvertAccountToAnyFailed, err) - } - authGenState.Accounts = genAccs - - authGenStateBz, err := cdc.MarshalJSON(&authGenState) - if err != nil { - return nil, fmt.Errorf(errTextGenesisAuthMarshalFailed, err) - } - return authGenStateBz, nil -} - -func getVestingParams(cmd *cobra.Command) (int64, int64, sdk.Coins, error) { - vestingStart, err := cmd.Flags().GetInt64(flagVestingStart) - if err != nil { - return 0, 0, sdk.Coins{}, err - } - vestingEnd, err := cmd.Flags().GetInt64(flagVestingEnd) - if err != nil { - return 0, 0, sdk.Coins{}, err - } - vestingAmtStr, err := cmd.Flags().GetString(flagVestingAmt) - if err != nil { - return 0, 0, sdk.Coins{}, err - } - - vestingAmt, err := sdk.ParseCoinsNormalized(vestingAmtStr) - if err != nil { - return 0, 0, sdk.Coins{}, fmt.Errorf(errTextParsingVestingAmountFailed, err) - } - return vestingStart, vestingEnd, vestingAmt, nil -} - -func getAndValidateGenesisAccount( - cmd *cobra.Command, - addr sdk.AccAddress, - balances banktypes.Balance, -) (authtypes.GenesisAccount, error) { - // create concrete account type based on input parameters - var genAccount authtypes.GenesisAccount - baseAccount := authtypes.NewBaseAccount(addr, nil, genesisAccountNumber, genesisSequenceNumber) - vestingStart, vestingEnd, vestingAmt, err := getVestingParams(cmd) - if err != nil { - return nil, err - } - - if !vestingAmt.IsZero() { - baseVestingAccount := authvesting.NewBaseVestingAccount( - baseAccount, - vestingAmt.Sort(), - vestingEnd, - ) - - if (balances.Coins.IsZero() && !baseVestingAccount.OriginalVesting.IsZero()) || - baseVestingAccount.OriginalVesting.IsAnyGT(balances.Coins) { - return nil, errors.New(errTextVestingAccountGreaterThanTotal) - } - - switch { - case vestingStart != defaultVestingStart && vestingEnd != defaultVestingEnd: - genAccount = authvesting.NewContinuousVestingAccountRaw(baseVestingAccount, vestingStart) - - case vestingEnd != defaultVestingEnd: - genAccount = authvesting.NewDelayedVestingAccountRaw(baseVestingAccount) - - default: - return nil, errors.New(errTextInvalidVestingParams) - } - } else { - genAccount = baseAccount - } - - if err := genAccount.Validate(); err != nil { - return nil, fmt.Errorf(errTextGenesisAccValidationFailed, err) - } - - return genAccount, nil -} diff --git a/cmd/sged/cmd/genaccounts_test.go b/cmd/sged/cmd/genaccounts_test.go deleted file mode 100644 index 299981b4..00000000 --- a/cmd/sged/cmd/genaccounts_test.go +++ /dev/null @@ -1,77 +0,0 @@ -package cmd_test - -import ( - "os" - "path/filepath" - "testing" - - "github.com/stretchr/testify/require" - - "github.com/cosmos/cosmos-sdk/crypto/hd" - "github.com/cosmos/cosmos-sdk/crypto/keyring" - clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" - sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/sge-network/sge/cmd/sged/cmd" - "github.com/sge-network/sge/testutil/network" -) - -func TestAddGenesisAccountCmdPanic(t *testing.T) { - userHomeDir, err := os.UserHomeDir() - require.NoError(t, err) - defaultNodeHome := filepath.Join(userHomeDir, ".sge") - panicFunc := func() { - cmd.AddGenesisAccountCmd(defaultNodeHome) - } - - require.NotPanics(t, panicFunc) -} - -func TestSampleCMD(t *testing.T) { - net := network.New(t) - val := net.Validators[0] - ctx := val.ClientCtx - sec := hd.Secp256k1 - - keyInfo, _, err := ctx.Keyring.NewMnemonic( - "genUser1", - keyring.English, - sdk.FullFundraiserPath, - "", - sec, - ) - require.NoError(t, err) - - userHomeDir, err := os.UserHomeDir() - require.NoError(t, err) - defaultNodeHome := filepath.Join(userHomeDir, ".sge") - - accAddr, err := keyInfo.GetAddress() - require.NoError(t, err) - - fields := []string{accAddr.String(), "10000000usge"} - for _, tc := range []struct { - desc string - args []string - err error - code uint32 - }{ - { - desc: "valid", - args: []string{}, - }, - } { - t.Run(tc.desc, func(t *testing.T) { - var args []string - - args = append(args, fields...) - args = append(args, tc.args...) - _, err := clitestutil.ExecTestCLICmd(ctx, cmd.AddGenesisAccountCmd(defaultNodeHome), args) - if tc.err != nil { - require.ErrorIs(t, err, tc.err) - } else { - require.NoError(t, err) - } - }) - } -} diff --git a/cmd/sged/cmd/root.go b/cmd/sged/cmd/root.go index 798db623..e23139aa 100644 --- a/cmd/sged/cmd/root.go +++ b/cmd/sged/cmd/root.go @@ -1,318 +1,147 @@ package cmd import ( - "io" "os" - "path/filepath" + "strings" - "github.com/prometheus/client_golang/prometheus" - "github.com/spf13/cast" - "github.com/spf13/cobra" - - dbm "github.com/cometbft/cometbft-db" - tmcfg "github.com/cometbft/cometbft/config" - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cometbft/cometbft/libs/log" - tmtypes "github.com/cometbft/cometbft/types" - - "github.com/cosmos/cosmos-sdk/baseapp" + "cosmossdk.io/client/v2/autocli" + "cosmossdk.io/depinject" + "cosmossdk.io/log" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/config" - "github.com/cosmos/cosmos-sdk/client/debug" "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/cosmos/cosmos-sdk/client/keys" - "github.com/cosmos/cosmos-sdk/client/rpc" "github.com/cosmos/cosmos-sdk/codec" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/server" - serverconfig "github.com/cosmos/cosmos-sdk/server/config" - servertypes "github.com/cosmos/cosmos-sdk/server/types" - "github.com/cosmos/cosmos-sdk/snapshots" - snapshottypes "github.com/cosmos/cosmos-sdk/snapshots/types" - "github.com/cosmos/cosmos-sdk/store" - sdk "github.com/cosmos/cosmos-sdk/types" - authcmd "github.com/cosmos/cosmos-sdk/x/auth/client/cli" + "github.com/cosmos/cosmos-sdk/types/module" + "github.com/cosmos/cosmos-sdk/x/auth/tx" + authtxconfig "github.com/cosmos/cosmos-sdk/x/auth/tx/config" "github.com/cosmos/cosmos-sdk/x/auth/types" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/cosmos-sdk/x/crisis" - "github.com/cosmos/cosmos-sdk/x/genutil" - genutilcli "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" - genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" - - wasm "github.com/CosmWasm/wasmd/x/wasm" - wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" + "github.com/spf13/cobra" + "github.com/spf13/pflag" "github.com/sge-network/sge/app" - "github.com/sge-network/sge/app/params" ) -// NewRootCmd creates a new root command for simd. It is called once in the -// main function. -func NewRootCmd() (*cobra.Command, params.EncodingConfig) { - // Set config for prefixes - app.SetConfig() +// NewRootCmd creates a new root command for sged. It is called once in the main function. +func NewRootCmd() *cobra.Command { + var ( + autoCliOpts autocli.AppOptions + moduleBasicManager module.BasicManager + clientCtx client.Context + ) - encodingConfig := app.MakeEncodingConfig() - initClientCtx := client.Context{}. - WithCodec(encodingConfig.Marshaler). - WithInterfaceRegistry(encodingConfig.InterfaceRegistry). - WithTxConfig(encodingConfig.TxConfig). - WithLegacyAmino(encodingConfig.Amino). - WithInput(os.Stdin). - WithAccountRetriever(types.AccountRetriever{}). - WithHomeDir(app.DefaultNodeHome). - WithViper("") + if err := depinject.Inject( + depinject.Configs(app.Config(), + depinject.Supply( + log.NewNopLogger(), + ), + depinject.Provide( + ProvideClientContext, + ), + ), + &autoCliOpts, + &moduleBasicManager, + &clientCtx, + ); err != nil { + panic(err) + } rootCmd := &cobra.Command{ - Use: "sged", - Short: "SGE-Network App", + Use: app.Name + "d", + Short: "Start sge node", + SilenceErrors: true, PersistentPreRunE: func(cmd *cobra.Command, _ []string) error { - initClientCtx, err := client.ReadPersistentCommandFlags(initClientCtx, cmd.Flags()) + // set the default command outputs + cmd.SetOut(cmd.OutOrStdout()) + cmd.SetErr(cmd.ErrOrStderr()) + + clientCtx = clientCtx.WithCmdContext(cmd.Context()) + clientCtx, err := client.ReadPersistentCommandFlags(clientCtx, cmd.Flags()) if err != nil { return err } - initClientCtx, err = config.ReadFromClientConfig(initClientCtx) + clientCtx, err = config.ReadFromClientConfig(clientCtx) if err != nil { return err } - if err = client.SetCmdClientContextHandler(initClientCtx, cmd); err != nil { + if err := client.SetCmdClientContextHandler(clientCtx, cmd); err != nil { return err } customAppTemplate, customAppConfig := initAppConfig() + customCMTConfig := initCometBFTConfig() - return server.InterceptConfigsPreRunHandler(cmd, customAppTemplate, customAppConfig, tmcfg.DefaultConfig()) + return server.InterceptConfigsPreRunHandler(cmd, customAppTemplate, customAppConfig, customCMTConfig) }, } - initRootCmd(rootCmd, encodingConfig) - - return rootCmd, encodingConfig -} - -// initAppConfig helps to override default appConfig template and configs. -// return "", nil if no custom configuration is required for the application. -func initAppConfig() (string, interface{}) { - type CustomAppConfig struct { - serverconfig.Config - - Wasm wasmtypes.WasmConfig `mapstructure:"wasm"` - } - - // Optionally allow the chain developer to overwrite the SDK's default - // server config. - srvCfg := serverconfig.DefaultConfig() - - customAppConfig := CustomAppConfig{ - Config: *srvCfg, - Wasm: wasmtypes.DefaultWasmConfig(), - } - - customAppTemplate := serverconfig.DefaultConfigTemplate + wasmtypes.DefaultConfigTemplate() - - return customAppTemplate, customAppConfig -} - -func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig) { - cfg := sdk.GetConfig() - cfg.Seal() - - gentxModule, ok := app.ModuleBasics[genutiltypes.ModuleName].(genutil.AppModuleBasic) - if !ok { - panic("genutil AppModuleBasic assertion failed") - } - - rootCmd.AddCommand( - genutilcli.InitCmd(app.ModuleBasics, app.DefaultNodeHome), - genutilcli.CollectGenTxsCmd(banktypes.GenesisBalancesIterator{}, app.DefaultNodeHome, gentxModule.GenTxValidator), - genutilcli.GenTxCmd( - app.ModuleBasics, - encodingConfig.TxConfig, - banktypes.GenesisBalancesIterator{}, - app.DefaultNodeHome, - ), - genutilcli.ValidateGenesisCmd(app.ModuleBasics), - AddGenesisAccountCmd(app.DefaultNodeHome), - tmcli.NewCompletionCmd(rootCmd, true), - debug.Cmd(), - config.Cmd(), - ) - - server.AddCommands(rootCmd, app.DefaultNodeHome, newApp, createSimappAndExport, addModuleInitFlags) - - // add keybase, auxiliary RPC, query, and tx child commands - rootCmd.AddCommand( - rpc.StatusCommand(), - queryCommand(), - txCommand(), - keys.Commands(app.DefaultNodeHome), - ) -} - -func addModuleInitFlags(startCmd *cobra.Command) { - crisis.AddModuleInitFlags(startCmd) - wasm.AddModuleInitFlags(startCmd) -} - -func queryCommand() *cobra.Command { - cmd := &cobra.Command{ - Use: "query", - Aliases: []string{"q"}, - Short: "Querying subcommands", - DisableFlagParsing: true, - SuggestionsMinimumDistance: 2, - RunE: client.ValidateCmd, + // Since the IBC modules don't support dependency injection, we need to + // manually register the modules on the client side. + // This needs to be removed after IBC supports App Wiring. + ibcModules := app.RegisterIBC(clientCtx.InterfaceRegistry) + for name, mod := range ibcModules { + moduleBasicManager[name] = module.CoreAppModuleBasicAdaptor(name, mod) + autoCliOpts.Modules[name] = mod } - cmd.AddCommand( - authcmd.GetAccountCmd(), - rpc.ValidatorCommand(), - rpc.BlockCommand(), - authcmd.QueryTxsByEventsCmd(), - authcmd.QueryTxCmd(), - ) + initRootCmd(rootCmd, clientCtx.TxConfig, moduleBasicManager) - app.ModuleBasics.AddQueryCommands(cmd) - cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") + overwriteFlagDefaults(rootCmd, map[string]string{ + flags.FlagChainID: strings.ReplaceAll(app.Name, "-", ""), + flags.FlagKeyringBackend: "test", + }) - return cmd -} - -func txCommand() *cobra.Command { - cmd := &cobra.Command{ - Use: "tx", - Short: "Transactions subcommands", - DisableFlagParsing: true, - SuggestionsMinimumDistance: 2, - RunE: client.ValidateCmd, + if err := autoCliOpts.EnhanceRootCommand(rootCmd); err != nil { + panic(err) } - cmd.AddCommand( - authcmd.GetSignCommand(), - authcmd.GetSignBatchCommand(), - authcmd.GetMultiSignCommand(), - authcmd.GetMultiSignBatchCmd(), - authcmd.GetValidateSignaturesCommand(), - flags.LineBreak, - authcmd.GetBroadcastCommand(), - authcmd.GetEncodeCommand(), - authcmd.GetDecodeCommand(), - ) - - app.ModuleBasics.AddTxCommands(cmd) - cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") - - return cmd + return rootCmd } -// newApp is an AppCreator -func newApp( - logger log.Logger, - db dbm.DB, - traceStore io.Writer, - appOpts servertypes.AppOptions, -) servertypes.Application { - var cache sdk.MultiStorePersistentCache - - if cast.ToBool(appOpts.Get(server.FlagInterBlockCache)) { - cache = store.NewCommitKVStoreCacheManager() +func overwriteFlagDefaults(c *cobra.Command, defaults map[string]string) { + set := func(s *pflag.FlagSet, key, val string) { + if f := s.Lookup(key); f != nil { + f.DefValue = val + _ = f.Value.Set(val) + } } - - skipUpgradeHeights := make(map[int64]bool) - for _, h := range cast.ToIntSlice(appOpts.Get(server.FlagUnsafeSkipUpgrades)) { - skipUpgradeHeights[int64(h)] = true + for key, val := range defaults { + set(c.Flags(), key, val) + set(c.PersistentFlags(), key, val) } - - pruningOpts, err := server.GetPruningOptionsFromFlags(appOpts) - if err != nil { - panic(err) + for _, c := range c.Commands() { + overwriteFlagDefaults(c, defaults) } +} - homeDir := cast.ToString(appOpts.Get(flags.FlagHome)) - chainID := cast.ToString(appOpts.Get(flags.FlagChainID)) - if chainID == "" { - // fallback to genesis chain-id - appGenesis, err := tmtypes.GenesisDocFromFile(filepath.Join(homeDir, "config", "genesis.json")) - if err != nil { - panic(err) - } +func ProvideClientContext( + appCodec codec.Codec, + interfaceRegistry codectypes.InterfaceRegistry, + txConfigOpts tx.ConfigOptions, + legacyAmino *codec.LegacyAmino, +) client.Context { + clientCtx := client.Context{}. + WithCodec(appCodec). + WithInterfaceRegistry(interfaceRegistry). + WithLegacyAmino(legacyAmino). + WithInput(os.Stdin). + WithAccountRetriever(types.AccountRetriever{}). + WithHomeDir(app.DefaultNodeHome). + WithViper(app.Name) // env variable prefix - chainID = appGenesis.ChainID - } + // Read the config again to overwrite the default values with the values from the config file + clientCtx, _ = config.ReadFromClientConfig(clientCtx) - snapshotDir := filepath.Join(cast.ToString(appOpts.Get(flags.FlagHome)), "data", "snapshots") - snapshotDB, err := dbm.NewGoLevelDB("metadata", snapshotDir) - if err != nil { - panic(err) - } - snapshotStore, err := snapshots.NewStore(snapshotDB, snapshotDir) + // textual is enabled by default, we need to re-create the tx config grpc instead of bank keeper. + txConfigOpts.TextualCoinMetadataQueryFn = authtxconfig.NewGRPCCoinMetadataQueryFn(clientCtx) + txConfig, err := tx.NewTxConfigWithOptions(clientCtx.Codec, txConfigOpts) if err != nil { panic(err) } + clientCtx = clientCtx.WithTxConfig(txConfig) - var wasmOpts []wasmkeeper.Option - if cast.ToBool(appOpts.Get("telemetry.enabled")) { - wasmOpts = append(wasmOpts, wasmkeeper.WithVMCacheMetrics(prometheus.DefaultRegisterer)) - } - - return app.NewSgeApp( - logger, - db, - traceStore, - true, - skipUpgradeHeights, - cast.ToString(appOpts.Get(flags.FlagHome)), - cast.ToUint(appOpts.Get(server.FlagInvCheckPeriod)), - app.MakeEncodingConfig(), // Ideally, we would reuse the one created by NewRootCmd. - appOpts, - wasmOpts, - baseapp.SetPruning(pruningOpts), - baseapp.SetMinGasPrices(cast.ToString(appOpts.Get(server.FlagMinGasPrices))), - baseapp.SetHaltHeight(cast.ToUint64(appOpts.Get(server.FlagHaltHeight))), - baseapp.SetHaltTime(cast.ToUint64(appOpts.Get(server.FlagHaltTime))), - baseapp.SetMinRetainBlocks(cast.ToUint64(appOpts.Get(server.FlagMinRetainBlocks))), - baseapp.SetInterBlockCache(cache), - baseapp.SetTrace(cast.ToBool(appOpts.Get(server.FlagTrace))), - baseapp.SetIndexEvents(cast.ToStringSlice(appOpts.Get(server.FlagIndexEvents))), - baseapp.SetSnapshot(snapshotStore, snapshottypes.SnapshotOptions{ - Interval: cast.ToUint64(appOpts.Get(server.FlagStateSyncSnapshotInterval)), - KeepRecent: cast.ToUint32(appOpts.Get(server.FlagStateSyncSnapshotKeepRecent)), - }), - baseapp.SetIAVLCacheSize(cast.ToInt(appOpts.Get(server.FlagIAVLCacheSize))), - baseapp.SetIAVLDisableFastNode(cast.ToBool(appOpts.Get(server.FlagDisableIAVLFastNode))), - baseapp.SetChainID(chainID), - ) -} - -func createSimappAndExport( - logger log.Logger, - db dbm.DB, - traceStore io.Writer, - height int64, - forZeroHeight bool, - jailAllowedAddrs []string, - appOpts servertypes.AppOptions, - modulesToExport []string, -) (servertypes.ExportedApp, error) { - encCfg := app.MakeEncodingConfig() // Ideally, we would reuse the one created by NewRootCmd. - encCfg.Marshaler = codec.NewProtoCodec(encCfg.InterfaceRegistry) - var sgeApp *app.SgeApp - var emptyWasmOpts []wasmkeeper.Option - loadLatest := height == -1 - sgeApp = app.NewSgeApp( - logger, - db, - traceStore, - loadLatest, - map[int64]bool{}, - cast.ToString(appOpts.Get(flags.FlagHome)), - cast.ToUint(appOpts.Get(server.FlagInvCheckPeriod)), - encCfg, - appOpts, - emptyWasmOpts, - ) - - return sgeApp.ExportAppStateAndValidators(forZeroHeight, jailAllowedAddrs, modulesToExport) + return clientCtx } diff --git a/cmd/sged/cmd/root_test.go b/cmd/sged/cmd/root_test.go deleted file mode 100644 index ac45813c..00000000 --- a/cmd/sged/cmd/root_test.go +++ /dev/null @@ -1,21 +0,0 @@ -package cmd_test - -import ( - "testing" - - svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" - "github.com/sge-network/sge/app" - "github.com/sge-network/sge/cmd/sged/cmd" - "github.com/stretchr/testify/require" -) - -func TestRootCmdConfig(t *testing.T) { - rootCmd, _ := cmd.NewRootCmd() - rootCmd.SetArgs([]string{ - "config", // Test the config cmd - "keyring-backend", // key - "test", // value - }) - - require.NoError(t, svrcmd.Execute(rootCmd, cmd.EnvPrefix, app.DefaultNodeHome)) -} diff --git a/cmd/sged/cmd/testnet.go b/cmd/sged/cmd/testnet.go new file mode 100644 index 00000000..ec963aff --- /dev/null +++ b/cmd/sged/cmd/testnet.go @@ -0,0 +1,285 @@ +package cmd + +import ( + "fmt" + "io" + "strings" + + "cosmossdk.io/log" + "cosmossdk.io/math" + storetypes "cosmossdk.io/store/types" + "github.com/cometbft/cometbft/crypto" + "github.com/cometbft/cometbft/libs/bytes" + tmos "github.com/cometbft/cometbft/libs/os" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + dbm "github.com/cosmos/cosmos-db" + "github.com/cosmos/cosmos-sdk/client/flags" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" + "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" + "github.com/cosmos/cosmos-sdk/server" + servertypes "github.com/cosmos/cosmos-sdk/server/types" + sdk "github.com/cosmos/cosmos-sdk/types" + distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" + slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" + stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + minttypes "github.com/sge-network/sge/x/mint/types" + "github.com/spf13/cast" + "github.com/spf13/cobra" + + "github.com/sge-network/sge/app" +) + +const ( + valVotingPower int64 = 900000000000000 +) + +var flagAccountsToFund = "accounts-to-fund" + +type valArgs struct { + newValAddr bytes.HexBytes + newOperatorAddress string + newValPubKey crypto.PubKey + accountsToFund []sdk.AccAddress + upgradeToTrigger string + homeDir string +} + +func NewInPlaceTestnetCmd(addStartFlags servertypes.ModuleInitFlags) *cobra.Command { + cmd := server.InPlaceTestnetCreator(newTestnetApp) + addStartFlags(cmd) + cmd.Short = "Updates chain's application and consensus state with provided validator info and starts the node" + cmd.Long = `The test command modifies both application and consensus stores within a local mainnet node and starts the node, +with the aim of facilitating testing procedures. This command replaces existing validator data with updated information, +thereby removing the old validator set and introducing a new set suitable for local testing purposes. By altering the state extracted from the mainnet node, +it enables developers to configure their local environments to reflect mainnet conditions more accurately.` + + cmd.Example = fmt.Sprintf(`%sd in-place-testnet testing-1 cosmosvaloper1w7f3xx7e75p4l7qdym5msqem9rd4dyc4mq79dm --home $HOME/.%sd/validator1 --validator-privkey=6dq+/KHNvyiw2TToCgOpUpQKIzrLs69Rb8Az39xvmxPHNoPxY1Cil8FY+4DhT9YwD6s0tFABMlLcpaylzKKBOg== --accounts-to-fund="cosmos1f7twgcq4ypzg7y24wuywy06xmdet8pc4473tnq,cosmos1qvuhm5m644660nd8377d6l7yz9e9hhm9evmx3x"`, "sge", "sge") + + cmd.Flags().String(flagAccountsToFund, "", "Comma-separated list of account addresses that will be funded for testing purposes") + return cmd +} + +// newTestnetApp starts by running the normal newApp method. From there, the app interface returned is modified in order +// for a testnet to be created from the provided app. +func newTestnetApp(logger log.Logger, db dbm.DB, traceStore io.Writer, appOpts servertypes.AppOptions) servertypes.Application { + // Create an app and type cast to an App + newApp := newApp(logger, db, traceStore, appOpts) + testApp, ok := newApp.(*app.App) + if !ok { + panic("app created from newApp is not of type App") + } + + // Get command args + args, err := getCommandArgs(appOpts) + if err != nil { + panic(err) + } + + return initAppForTestnet(testApp, args) +} + +func initAppForTestnet(app *app.App, args valArgs) *app.App { + // Required Changes: + // + ctx := app.BaseApp.NewUncachedContext(true, tmproto.Header{}) + + pubkey := &ed25519.PubKey{Key: args.newValPubKey.Bytes()} + pubkeyAny, err := codectypes.NewAnyWithValue(pubkey) + if err != nil { + tmos.Exit(err.Error()) + } + + // STAKING + // + + // Create Validator struct for our new validator. + newVal := stakingtypes.Validator{ + OperatorAddress: args.newOperatorAddress, + ConsensusPubkey: pubkeyAny, + Jailed: false, + Status: stakingtypes.Bonded, + Tokens: math.NewInt(valVotingPower), + DelegatorShares: math.LegacyMustNewDecFromStr("10000000"), + Description: stakingtypes.Description{ + Moniker: "Testnet Validator", + }, + Commission: stakingtypes.Commission{ + CommissionRates: stakingtypes.CommissionRates{ + Rate: math.LegacyMustNewDecFromStr("0.05"), + MaxRate: math.LegacyMustNewDecFromStr("0.1"), + MaxChangeRate: math.LegacyMustNewDecFromStr("0.05"), + }, + }, + MinSelfDelegation: math.OneInt(), + } + + validator, err := app.StakingKeeper.ValidatorAddressCodec().StringToBytes(newVal.GetOperator()) + if err != nil { + tmos.Exit(err.Error()) + } + + // Remove all validators from power store + stakingKey := app.GetKey(stakingtypes.ModuleName) + stakingStore := ctx.KVStore(stakingKey) + iterator, err := app.StakingKeeper.ValidatorsPowerStoreIterator(ctx) + if err != nil { + tmos.Exit(err.Error()) + } + for ; iterator.Valid(); iterator.Next() { + stakingStore.Delete(iterator.Key()) + } + iterator.Close() + + // Remove all valdiators from last validators store + iterator, err = app.StakingKeeper.LastValidatorsIterator(ctx) + if err != nil { + tmos.Exit(err.Error()) + } + for ; iterator.Valid(); iterator.Next() { + stakingStore.Delete(iterator.Key()) + } + iterator.Close() + + // Remove all validators from validators store + iterator = stakingStore.Iterator(stakingtypes.ValidatorsKey, storetypes.PrefixEndBytes(stakingtypes.ValidatorsKey)) + for ; iterator.Valid(); iterator.Next() { + stakingStore.Delete(iterator.Key()) + } + iterator.Close() + + // Remove all validators from unbonding queue + iterator = stakingStore.Iterator(stakingtypes.ValidatorQueueKey, storetypes.PrefixEndBytes(stakingtypes.ValidatorQueueKey)) + for ; iterator.Valid(); iterator.Next() { + stakingStore.Delete(iterator.Key()) + } + iterator.Close() + + // Add our validator to power and last validators store + err = app.StakingKeeper.SetValidator(ctx, newVal) + if err != nil { + tmos.Exit(err.Error()) + } + + err = app.StakingKeeper.SetValidatorByConsAddr(ctx, newVal) + if err != nil { + tmos.Exit(err.Error()) + } + err = app.StakingKeeper.SetValidatorByPowerIndex(ctx, newVal) + if err != nil { + tmos.Exit(err.Error()) + } + err = app.StakingKeeper.SetLastValidatorPower(ctx, validator, 0) + if err != nil { + tmos.Exit(err.Error()) + } + if err := app.StakingKeeper.Hooks().AfterValidatorCreated(ctx, validator); err != nil { + tmos.Exit(err.Error()) + } + + // DISTRIBUTION + // + + // Initialize records for this validator across all distribution stores + err = app.DistrKeeper.SetValidatorHistoricalRewards(ctx, validator, 0, distrtypes.NewValidatorHistoricalRewards(sdk.DecCoins{}, 1)) + if err != nil { + tmos.Exit(err.Error()) + } + err = app.DistrKeeper.SetValidatorCurrentRewards(ctx, validator, distrtypes.NewValidatorCurrentRewards(sdk.DecCoins{}, 1)) + if err != nil { + tmos.Exit(err.Error()) + } + err = app.DistrKeeper.SetValidatorAccumulatedCommission(ctx, validator, distrtypes.InitialValidatorAccumulatedCommission()) + if err != nil { + tmos.Exit(err.Error()) + } + err = app.DistrKeeper.SetValidatorOutstandingRewards(ctx, validator, distrtypes.ValidatorOutstandingRewards{Rewards: sdk.DecCoins{}}) + if err != nil { + tmos.Exit(err.Error()) + } + + // SLASHING + // + + // Set validator signing info for our new validator. + newConsAddr := sdk.ConsAddress(args.newValAddr.Bytes()) + newValidatorSigningInfo := slashingtypes.ValidatorSigningInfo{ + Address: newConsAddr.String(), + StartHeight: app.LastBlockHeight() - 1, + Tombstoned: false, + } + err = app.SlashingKeeper.SetValidatorSigningInfo(ctx, newConsAddr, newValidatorSigningInfo) + if err != nil { + tmos.Exit(err.Error()) + } + + // BANK + // + bondDenom, err := app.StakingKeeper.BondDenom(ctx) + if err != nil { + tmos.Exit(err.Error()) + } + + defaultCoins := sdk.NewCoins(sdk.NewInt64Coin(bondDenom, 1000000000)) + + // Fund local accounts + for _, account := range args.accountsToFund { + err := app.BankKeeper.MintCoins(ctx, minttypes.ModuleName, defaultCoins) + if err != nil { + tmos.Exit(err.Error()) + } + err = app.BankKeeper.SendCoinsFromModuleToAccount(ctx, minttypes.ModuleName, account, defaultCoins) + if err != nil { + tmos.Exit(err.Error()) + } + } + + return app +} + +// parse the input flags and returns valArgs +func getCommandArgs(appOpts servertypes.AppOptions) (valArgs, error) { + args := valArgs{} + + newValAddr, ok := appOpts.Get(server.KeyNewValAddr).(bytes.HexBytes) + if !ok { + panic("newValAddr is not of type bytes.HexBytes") + } + args.newValAddr = newValAddr + newValPubKey, ok := appOpts.Get(server.KeyUserPubKey).(crypto.PubKey) + if !ok { + panic("newValPubKey is not of type crypto.PubKey") + } + args.newValPubKey = newValPubKey + newOperatorAddress, ok := appOpts.Get(server.KeyNewOpAddr).(string) + if !ok { + panic("newOperatorAddress is not of type string") + } + args.newOperatorAddress = newOperatorAddress + upgradeToTrigger, ok := appOpts.Get(server.KeyTriggerTestnetUpgrade).(string) + if !ok { + panic("upgradeToTrigger is not of type string") + } + args.upgradeToTrigger = upgradeToTrigger + + // validate and set accounts to fund + accountsString := cast.ToString(appOpts.Get(flagAccountsToFund)) + + for _, account := range strings.Split(accountsString, ",") { + if account != "" { + addr, err := sdk.AccAddressFromBech32(account) + if err != nil { + return args, fmt.Errorf("invalid bech32 address format %w", err) + } + args.accountsToFund = append(args.accountsToFund, addr) + } + } + + // home dir + homeDir := cast.ToString(appOpts.Get(flags.FlagHome)) + if homeDir == "" { + return args, fmt.Errorf("invalid home dir") + } + args.homeDir = homeDir + + return args, nil +} diff --git a/cmd/sged/main.go b/cmd/sged/main.go index c3351621..f2c257e2 100644 --- a/cmd/sged/main.go +++ b/cmd/sged/main.go @@ -1,9 +1,10 @@ package main import ( + "fmt" "os" - "github.com/cosmos/cosmos-sdk/server" + clienthelpers "cosmossdk.io/client/v2/helpers" svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" "github.com/sge-network/sge/app" @@ -11,15 +12,9 @@ import ( ) func main() { - rootCmd, _ := cmd.NewRootCmd() - - if err := svrcmd.Execute(rootCmd, cmd.EnvPrefix, app.DefaultNodeHome); err != nil { - switch e := err.(type) { - case server.ErrorCode: - os.Exit(e.Code) - - default: - os.Exit(1) - } + rootCmd := cmd.NewRootCmd() + if err := svrcmd.Execute(rootCmd, clienthelpers.EnvPrefix, app.DefaultNodeHome); err != nil { + fmt.Fprintln(rootCmd.OutOrStderr(), err) + os.Exit(1) } } From 6d017a41c25d45d8d82a1e99e5f7ef20756b8736 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Tue, 11 Feb 2025 15:25:48 +0300 Subject: [PATCH 08/16] feat: set expedited params for upgrade ehandler v.8.0 --- app/upgrades/v10/upgrades.go | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) diff --git a/app/upgrades/v10/upgrades.go b/app/upgrades/v10/upgrades.go index d05d84f1..6eab0a14 100644 --- a/app/upgrades/v10/upgrades.go +++ b/app/upgrades/v10/upgrades.go @@ -2,6 +2,7 @@ package v10 import ( "context" + "strings" "time" sdkmath "cosmossdk.io/math" @@ -48,11 +49,32 @@ func CreateUpgradeHandler( if err != nil { return nil, err } - govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(50000000000))) - govParams.MinInitialDepositRatio = "0.000000000000000000" - govParams.ExpeditedThreshold = "0.750000000000000000" - expediteVotingPeriod := 86400 * time.Second - govParams.ExpeditedVotingPeriod = &expediteVotingPeriod + + sdkCtx := sdk.UnwrapSDKContext(ctx) + + switch strings.ToLower(sdkCtx.ChainID()) { + + case "stage-sgenetwork": + govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(20000000))) + govParams.MinInitialDepositRatio = "0.000000000000000000" + govParams.ExpeditedThreshold = "0.667000000000000000" + expediteVotingPeriod := 600 * time.Second + govParams.ExpeditedVotingPeriod = &expediteVotingPeriod + case "sge-network-4": + govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(6000000000))) + govParams.MinInitialDepositRatio = "0.000000000000000000" + govParams.ExpeditedThreshold = "0.667000000000000000" + expediteVotingPeriod := 86400 * time.Second + govParams.ExpeditedVotingPeriod = &expediteVotingPeriod + default: + // mainnet + govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(50000000000))) + govParams.MinInitialDepositRatio = "0.000000000000000000" + govParams.ExpeditedThreshold = "0.750000000000000000" + expediteVotingPeriod := 86400 * time.Second + govParams.ExpeditedVotingPeriod = &expediteVotingPeriod + } + err = k.GovKeeper.Params.Set(ctx, govParams) if err != nil { return nil, err From b2193c51efd0692d5ddc5b37807ef7bd8a80e9ea Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Tue, 11 Feb 2025 15:42:14 +0300 Subject: [PATCH 09/16] refactor: rename testnet command --- cmd/sged/cmd/testnet_multi.go | 541 ++++++++++++++++++++++++++++++++++ 1 file changed, 541 insertions(+) create mode 100644 cmd/sged/cmd/testnet_multi.go diff --git a/cmd/sged/cmd/testnet_multi.go b/cmd/sged/cmd/testnet_multi.go new file mode 100644 index 00000000..032c1823 --- /dev/null +++ b/cmd/sged/cmd/testnet_multi.go @@ -0,0 +1,541 @@ +package cmd + +import ( + "bufio" + "encoding/json" + "fmt" + "io" + "math/rand" + "os" + "path/filepath" + "strconv" + "strings" + "time" + + cmtconfig "github.com/cometbft/cometbft/config" + types "github.com/cometbft/cometbft/types" + tmtime "github.com/cometbft/cometbft/types/time" + "github.com/spf13/cobra" + "github.com/spf13/pflag" + + "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/client" + "github.com/cosmos/cosmos-sdk/client/flags" + "github.com/cosmos/cosmos-sdk/client/tx" + "github.com/cosmos/cosmos-sdk/crypto/hd" + "github.com/cosmos/cosmos-sdk/crypto/keyring" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" + "github.com/cosmos/cosmos-sdk/server" + srvconfig "github.com/cosmos/cosmos-sdk/server/config" + "github.com/cosmos/cosmos-sdk/testutil" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/module" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + "github.com/cosmos/cosmos-sdk/x/genutil" + genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" + stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + + runtime "github.com/cosmos/cosmos-sdk/runtime" +) + +var ( + flagNodeDirPrefix = "node-dir-prefix" + flagPorts = "list-ports" + flagNumValidators = "v" + flagOutputDir = "output-dir" + flagValidatorsStakeAmount = "validators-stake-amount" + flagStartingIPAddress = "starting-ip-address" +) + +const nodeDirPerm = 0o755 + +type initArgs struct { + algo string + chainID string + keyringBackend string + minGasPrices string + nodeDirPrefix string + numValidators int + outputDir string + startingIPAddress string + validatorsStakesAmount map[int]sdk.Coin + ports map[int]string +} + +// NewTestnetMultiNodeCmd returns a cmd to initialize all files for tendermint testnet and application +func NewTestnetMultiNodeCmd(mbm module.BasicManager, genBalIterator banktypes.GenesisBalancesIterator) *cobra.Command { + cmd := &cobra.Command{ + Use: "multi-node", + Short: "Initialize config directories & files for a multi-validator testnet running locally via separate processes (e.g. Docker Compose or similar)", + Long: `multi-node will setup "v" number of directories and populate each with +necessary files (private validator, genesis, config, etc.) for running "v" validator nodes. + +Booting up a network with these validator folders is intended to be used with Docker Compose, +or a similar setup where each node has a manually configurable IP address. + +Note, strict routability for addresses is turned off in the config file. + +Example: + wasmappd multi-node --v 4 --output-dir ./.testnets --validators-stake-amount 1000000,200000,300000,400000 --list-ports 47222,50434,52851,44210 + `, + RunE: func(cmd *cobra.Command, _ []string) error { + clientCtx, err := client.GetClientQueryContext(cmd) + if err != nil { + return err + } + + serverCtx := server.GetServerContextFromCmd(cmd) + config := serverCtx.Config + + args := initArgs{} + args.outputDir, _ = cmd.Flags().GetString(flagOutputDir) + args.keyringBackend, _ = cmd.Flags().GetString(flags.FlagKeyringBackend) + args.chainID, _ = cmd.Flags().GetString(flags.FlagChainID) + args.minGasPrices, _ = cmd.Flags().GetString(server.FlagMinGasPrices) + args.nodeDirPrefix, _ = cmd.Flags().GetString(flagNodeDirPrefix) + args.startingIPAddress, _ = cmd.Flags().GetString(flagStartingIPAddress) + args.numValidators, _ = cmd.Flags().GetInt(flagNumValidators) + args.algo, _ = cmd.Flags().GetString(flags.FlagKeyType) + + args.ports = map[int]string{} + args.validatorsStakesAmount = make(map[int]sdk.Coin) + top := 0 + // If the flag string is invalid, the amount will default to 100000000. + if s, err := cmd.Flags().GetString(flagValidatorsStakeAmount); err == nil { + for _, amount := range strings.Split(s, ",") { + a, ok := math.NewIntFromString(amount) + if !ok { + continue + } + args.validatorsStakesAmount[top] = sdk.NewCoin(sdk.DefaultBondDenom, a) + top++ + } + } + top = 0 + if s, err := cmd.Flags().GetString(flagPorts); err == nil { + if s == "" { + for i := 0; i < args.numValidators; i++ { + args.ports[top] = strconv.Itoa(26657 - 3*i) + top++ + } + } else { + for _, port := range strings.Split(s, ",") { + args.ports[top] = port + top++ + } + } + } + + return initTestnetFiles(clientCtx, cmd, config, mbm, genBalIterator, args) + }, + } + + addTestnetFlagsToCmd(cmd) + cmd.Flags().String(flagPorts, "", "Ports of nodes (default 26657,26654,26651,26648.. )") + cmd.Flags().String(flagNodeDirPrefix, "validator", "Prefix the directory name for each node with (node results in node0, node1, ...)") + cmd.Flags().String(flagValidatorsStakeAmount, "100000000,100000000,100000000,100000000", "Amount of stake for each validator") + cmd.Flags().String(flagStartingIPAddress, "localhost", "Starting IP address (192.168.0.1 results in persistent peers list ID0@192.168.0.1:46656, ID1@192.168.0.2:46656, ...)") + cmd.Flags().String(flags.FlagKeyringBackend, "test", "Select keyring's backend (os|file|test)") + + return cmd +} + +func addTestnetFlagsToCmd(cmd *cobra.Command) { + cmd.Flags().Int(flagNumValidators, 4, "Number of validators to initialize the testnet with") + cmd.Flags().StringP(flagOutputDir, "o", "./.testnets", "Directory to store initialization data for the testnet") + cmd.Flags().String(flags.FlagChainID, "", "genesis file chain-id, if left blank will be randomly created") + cmd.Flags().String(server.FlagMinGasPrices, fmt.Sprintf("0.0001%s", sdk.DefaultBondDenom), "Minimum gas prices to accept for transactions; All fees in a tx must meet this minimum (e.g. 0.01photino,0.001stake)") + cmd.Flags().String(flags.FlagKeyType, string(hd.Secp256k1Type), "Key signing algorithm to generate keys for") + + // support old flags name for backwards compatibility + cmd.Flags().SetNormalizeFunc(func(_ *pflag.FlagSet, name string) pflag.NormalizedName { + if name == "algo" { + name = flags.FlagKeyType + } + + return pflag.NormalizedName(name) + }) +} + +// initTestnetFiles initializes testnet files for a testnet to be run in a separate process +func initTestnetFiles( + clientCtx client.Context, + cmd *cobra.Command, + nodeConfig *cmtconfig.Config, + mbm module.BasicManager, + genBalIterator banktypes.GenesisBalancesIterator, + args initArgs, +) error { + if args.chainID == "" { + args.chainID = "chain-" + generateRandomString(6) + } + nodeIDs := make([]string, args.numValidators) + valPubKeys := make([]cryptotypes.PubKey, args.numValidators) + + appConfig := srvconfig.DefaultConfig() + appConfig.MinGasPrices = args.minGasPrices + appConfig.API.Enable = false + appConfig.BaseConfig.MinGasPrices = "0.0001" + sdk.DefaultBondDenom + appConfig.Telemetry.EnableHostnameLabel = false + appConfig.Telemetry.Enabled = false + appConfig.Telemetry.PrometheusRetentionTime = 0 + + var ( + genAccounts []authtypes.GenesisAccount + genBalances []banktypes.Balance + genFiles []string + persistentPeers string + gentxsFiles []string + ) + + inBuf := bufio.NewReader(cmd.InOrStdin()) + for i := 0; i < args.numValidators; i++ { + nodeDirName := fmt.Sprintf("%s%d", args.nodeDirPrefix, i) + nodeDir := filepath.Join(args.outputDir, nodeDirName) + gentxsDir := filepath.Join(args.outputDir, nodeDirName, "config", "gentx") + + nodeConfig.SetRoot(nodeDir) + nodeConfig.Moniker = nodeDirName + nodeConfig.RPC.ListenAddress = "tcp://0.0.0.0:" + args.ports[i] + + var err error + if err := os.MkdirAll(filepath.Join(nodeDir, "config"), nodeDirPerm); err != nil { + _ = os.RemoveAll(args.outputDir) + return err + } + + nodeIDs[i], valPubKeys[i], err = genutil.InitializeNodeValidatorFiles(nodeConfig) + if err != nil { + _ = os.RemoveAll(args.outputDir) + return err + } + + memo := fmt.Sprintf("%s@%s:"+strconv.Itoa(26656-3*i), nodeIDs[i], args.startingIPAddress) + + if persistentPeers == "" { + persistentPeers = memo + } else { + persistentPeers = persistentPeers + "," + memo + } + + genFiles = append(genFiles, nodeConfig.GenesisFile()) + + kb, err := keyring.New(sdk.KeyringServiceName(), args.keyringBackend, nodeDir, inBuf, clientCtx.Codec) + if err != nil { + return err + } + + keyringAlgos, _ := kb.SupportedAlgorithms() + algo, err := keyring.NewSigningAlgoFromString(args.algo, keyringAlgos) + if err != nil { + return err + } + + addr, secret, err := testutil.GenerateSaveCoinKey(kb, nodeDirName, "", true, algo) + if err != nil { + _ = os.RemoveAll(args.outputDir) + return err + } + + info := map[string]string{"secret": secret} + + cliPrint, err := json.Marshal(info) + if err != nil { + return err + } + + // save private key seed words + file := filepath.Join(nodeDir, fmt.Sprintf("%v.json", "key_seed")) + if err := writeFile(file, nodeDir, cliPrint); err != nil { + return err + } + + accTokens := sdk.TokensFromConsensusPower(1000, sdk.DefaultPowerReduction) + accStakingTokens := sdk.TokensFromConsensusPower(500, sdk.DefaultPowerReduction) + coins := sdk.Coins{ + sdk.NewCoin("testtoken", accTokens), + sdk.NewCoin(sdk.DefaultBondDenom, accStakingTokens), + } + + genBalances = append(genBalances, banktypes.Balance{Address: addr.String(), Coins: coins.Sort()}) + genAccounts = append(genAccounts, authtypes.NewBaseAccount(addr, nil, 0, 0)) + + var valTokens sdk.Coin + valTokens, ok := args.validatorsStakesAmount[i] + if !ok { + valTokens = sdk.NewCoin(sdk.DefaultBondDenom, sdk.TokensFromConsensusPower(100, sdk.DefaultPowerReduction)) + } + createValMsg, err := stakingtypes.NewMsgCreateValidator( + sdk.ValAddress(addr).String(), + valPubKeys[i], + valTokens, + stakingtypes.NewDescription(nodeDirName, "", "", "", ""), + stakingtypes.NewCommissionRates(math.LegacyOneDec(), math.LegacyOneDec(), math.LegacyOneDec()), + math.OneInt(), + ) + if err != nil { + return err + } + + txBuilder := clientCtx.TxConfig.NewTxBuilder() + if err := txBuilder.SetMsgs(createValMsg); err != nil { + return err + } + + txBuilder.SetMemo(memo) + + txFactory := tx.Factory{} + txFactory = txFactory. + WithChainID(args.chainID). + WithMemo(memo). + WithKeybase(kb). + WithTxConfig(clientCtx.TxConfig) + + if err := tx.Sign(cmd.Context(), txFactory, nodeDirName, txBuilder, true); err != nil { + return err + } + + txBz, err := clientCtx.TxConfig.TxJSONEncoder()(txBuilder.GetTx()) + if err != nil { + return err + } + file = filepath.Join(gentxsDir, fmt.Sprintf("%v.json", "gentx-"+nodeIDs[i])) + gentxsFiles = append(gentxsFiles, file) + if err := writeFile(file, gentxsDir, txBz); err != nil { + return err + } + + appConfig.GRPC.Address = args.startingIPAddress + ":" + strconv.Itoa(9090-2*i) + appConfig.API.Address = "tcp://localhost:" + strconv.Itoa(1317-i) + srvconfig.WriteConfigFile(filepath.Join(nodeDir, "config", "app.toml"), appConfig) + } + + if err := initGenFiles(clientCtx, mbm, args.chainID, genAccounts, genBalances, genFiles, args.numValidators); err != nil { + return err + } + // copy gentx file + for i := 0; i < args.numValidators; i++ { + for _, file := range gentxsFiles { + nodeDirName := fmt.Sprintf("%s%d", args.nodeDirPrefix, i) + nodeDir := filepath.Join(args.outputDir, nodeDirName) + gentxsDir := filepath.Join(nodeDir, "config", "gentx") + + yes, err := isSubDir(file, gentxsDir) + if err != nil || yes { + continue + } + _, err = copyFile(file, gentxsDir) + if err != nil { + return err + } + } + } + err := collectGenFiles( + clientCtx, nodeConfig, nodeIDs, valPubKeys, + genBalIterator, + clientCtx.TxConfig.SigningContext().ValidatorAddressCodec(), + persistentPeers, args, + ) + if err != nil { + return err + } + + cmd.PrintErrf("Successfully initialized %d node directories\n", args.numValidators) + return nil +} + +func writeFile(file, dir string, contents []byte) error { + if err := os.MkdirAll(dir, 0o755); err != nil { + return fmt.Errorf("could not create directory %q: %w", dir, err) + } + + //nolint:gosec + if err := os.WriteFile(file, contents, 0o644); err != nil { + return err + } + + return nil +} + +func initGenFiles( + clientCtx client.Context, mbm module.BasicManager, chainID string, + genAccounts []authtypes.GenesisAccount, genBalances []banktypes.Balance, + genFiles []string, numValidators int, +) error { + appGenState := mbm.DefaultGenesis(clientCtx.Codec) + + // set the accounts in the genesis state + var authGenState authtypes.GenesisState + clientCtx.Codec.MustUnmarshalJSON(appGenState[authtypes.ModuleName], &authGenState) + + accounts, err := authtypes.PackAccounts(genAccounts) + if err != nil { + return err + } + + authGenState.Accounts = accounts + appGenState[authtypes.ModuleName] = clientCtx.Codec.MustMarshalJSON(&authGenState) + + // set the balances in the genesis state + var bankGenState banktypes.GenesisState + clientCtx.Codec.MustUnmarshalJSON(appGenState[banktypes.ModuleName], &bankGenState) + + bankGenState.Balances = banktypes.SanitizeGenesisBalances(genBalances) + for _, bal := range bankGenState.Balances { + bankGenState.Supply = bankGenState.Supply.Add(bal.Coins...) + } + appGenState[banktypes.ModuleName] = clientCtx.Codec.MustMarshalJSON(&bankGenState) + + appGenStateJSON, err := json.MarshalIndent(appGenState, "", " ") + if err != nil { + return err + } + + genDoc := types.GenesisDoc{ + ChainID: chainID, + AppState: appGenStateJSON, + Validators: nil, + } + + // generate empty genesis files for each validator and save + for i := 0; i < numValidators; i++ { + if err := genDoc.SaveAs(genFiles[i]); err != nil { + return err + } + } + return nil +} + +func collectGenFiles( + clientCtx client.Context, nodeConfig *cmtconfig.Config, + nodeIDs []string, valPubKeys []cryptotypes.PubKey, + genBalIterator banktypes.GenesisBalancesIterator, + valAddrCodec runtime.ValidatorAddressCodec, persistentPeers string, + args initArgs, +) error { + chainID := args.chainID + numValidators := args.numValidators + outputDir := args.outputDir + nodeDirPrefix := args.nodeDirPrefix + + var appState json.RawMessage + genTime := tmtime.Now() + + for i := 0; i < numValidators; i++ { + nodeDirName := fmt.Sprintf("%s%d", nodeDirPrefix, i) + nodeDir := filepath.Join(outputDir, nodeDirName) + gentxsDir := filepath.Join(nodeDir, "config", "gentx") + nodeConfig.Moniker = nodeDirName + + nodeConfig.SetRoot(nodeDir) + + nodeID, valPubKey := nodeIDs[i], valPubKeys[i] + initCfg := genutiltypes.NewInitConfig(chainID, gentxsDir, nodeID, valPubKey) + + appGenesis, err := genutiltypes.AppGenesisFromFile(nodeConfig.GenesisFile()) + if err != nil { + return err + } + + nodeAppState, err := genutil.GenAppStateFromConfig(clientCtx.Codec, clientCtx.TxConfig, nodeConfig, initCfg, appGenesis, genBalIterator, genutiltypes.DefaultMessageValidator, + valAddrCodec) + if err != nil { + return err + } + + nodeConfig.P2P.PersistentPeers = persistentPeers + nodeConfig.P2P.AllowDuplicateIP = true + nodeConfig.P2P.ListenAddress = "tcp://0.0.0.0:" + strconv.Itoa(26656-3*i) + nodeConfig.RPC.ListenAddress = "tcp://127.0.0.1:" + args.ports[i] + nodeConfig.BaseConfig.ProxyApp = "tcp://127.0.0.1:" + strconv.Itoa(26658-3*i) + nodeConfig.Instrumentation.PrometheusListenAddr = ":" + strconv.Itoa(26660+i) + nodeConfig.Instrumentation.Prometheus = true + cmtconfig.WriteConfigFile(filepath.Join(nodeConfig.RootDir, "config", "config.toml"), nodeConfig) + if appState == nil { + // set the canonical application state (they should not differ) + appState = nodeAppState + } + + genFile := nodeConfig.GenesisFile() + + // overwrite each validator's genesis file to have a canonical genesis time + if err := genutil.ExportGenesisFileWithTime(genFile, chainID, nil, appState, genTime); err != nil { + return err + } + } + + return nil +} + +func copyFile(src, dstDir string) (int64, error) { + // Extract the file name from the source path + fileName := filepath.Base(src) + + // Create the full destination path (directory + file name) + dst := filepath.Join(dstDir, fileName) + + // Open the source file + sourceFile, err := os.Open(src) + if err != nil { + return 0, err + } + defer sourceFile.Close() + + // Create the destination file + destinationFile, err := os.Create(dst) + if err != nil { + return 0, err + } + defer destinationFile.Close() + + // Copy content from the source file to the destination file + bytesCopied, err := io.Copy(destinationFile, sourceFile) + if err != nil { + return 0, err + } + + // Ensure the content is written to the destination file + err = destinationFile.Sync() + if err != nil { + return 0, err + } + + return bytesCopied, nil +} + +// isSubDir checks if dstDir is a parent directory of src +func isSubDir(src, dstDir string) (bool, error) { + // Get the absolute path of src and dstDir + absSrc, err := filepath.Abs(src) + if err != nil { + return false, err + } + absDstDir, err := filepath.Abs(dstDir) + if err != nil { + return false, err + } + + // Check if absSrc is within absDstDir + relativePath, err := filepath.Rel(absDstDir, absSrc) + if err != nil { + return false, err + } + + // If the relative path doesn't go up the directory tree (doesn't contain ".."), it is inside dstDir + isInside := !strings.HasPrefix(relativePath, "..") && !filepath.IsAbs(relativePath) + return isInside, nil +} + +// generateRandomString generates a random string of the specified length. +func generateRandomString(length int) string { + const charset = "abcdefghijklmnopqrstuvwxyz0123456789" + //nolint:all + var seededRand *rand.Rand = rand.New(rand.NewSource(time.Now().UnixNano())) + + b := make([]byte, length) + for i := range b { + b[i] = charset[seededRand.Intn(len(charset))] + } + return string(b) +} From 6f772e9043d638bb396256e2c4a653631510ccfc Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Tue, 11 Feb 2025 15:59:39 +0300 Subject: [PATCH 10/16] lint: golangci fixes --- app/upgrades/v10/upgrades.go | 9 +++++---- x/legacy/bet/types/codec.go | 12 ++++-------- x/legacy/bet/types/messages_bet.go | 2 +- x/legacy/bet/types/messages_params.go | 2 +- x/legacy/house/types/codec.go | 12 ++++-------- x/legacy/house/types/message_deposit.go | 2 +- x/legacy/house/types/message_withdraw.go | 2 +- x/legacy/house/types/messages_params.go | 2 +- x/legacy/market/types/codec.go | 12 ++++-------- x/legacy/market/types/message_market.go | 4 ++-- x/legacy/market/types/message_market_resolve.go | 2 +- x/legacy/market/types/messages_params.go | 2 +- x/legacy/orderbook/types/codec.go | 12 ++++-------- x/legacy/orderbook/types/messages_params.go | 2 +- x/legacy/ovm/types/codec.go | 12 ++++-------- x/legacy/ovm/types/message_pubkeys_proposal.go | 2 +- x/legacy/ovm/types/message_pubkeys_vote.go | 2 +- x/legacy/ovm/types/messages_params.go | 2 +- x/legacy/reward/types/codec.go | 12 +++++------- x/legacy/reward/types/messages_campaign.go | 6 +++--- x/legacy/reward/types/messages_params.go | 2 +- x/legacy/reward/types/messages_promoter.go | 4 ++-- x/legacy/reward/types/messages_reward.go | 2 +- x/legacy/subaccount/types/codec.go | 14 +++++--------- x/legacy/subaccount/types/messages_bet.go | 2 +- x/legacy/subaccount/types/messages_house.go | 4 ++-- x/legacy/subaccount/types/messages_params.go | 2 +- x/legacy/subaccount/types/messages_subaccount.go | 2 +- 28 files changed, 60 insertions(+), 85 deletions(-) diff --git a/app/upgrades/v10/upgrades.go b/app/upgrades/v10/upgrades.go index 6eab0a14..2baeedd2 100644 --- a/app/upgrades/v10/upgrades.go +++ b/app/upgrades/v10/upgrades.go @@ -16,6 +16,8 @@ import ( minttypes "github.com/sge-network/sge/x/mint/types" ) +const minDepositRatio = "0.000000000000000000" + func CreateUpgradeHandler( mm *module.Manager, configurator module.Configurator, @@ -53,23 +55,22 @@ func CreateUpgradeHandler( sdkCtx := sdk.UnwrapSDKContext(ctx) switch strings.ToLower(sdkCtx.ChainID()) { - case "stage-sgenetwork": govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(20000000))) - govParams.MinInitialDepositRatio = "0.000000000000000000" + govParams.MinInitialDepositRatio = minDepositRatio govParams.ExpeditedThreshold = "0.667000000000000000" expediteVotingPeriod := 600 * time.Second govParams.ExpeditedVotingPeriod = &expediteVotingPeriod case "sge-network-4": govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(6000000000))) - govParams.MinInitialDepositRatio = "0.000000000000000000" + govParams.MinInitialDepositRatio = minDepositRatio govParams.ExpeditedThreshold = "0.667000000000000000" expediteVotingPeriod := 86400 * time.Second govParams.ExpeditedVotingPeriod = &expediteVotingPeriod default: // mainnet govParams.ExpeditedMinDeposit = sdk.NewCoins(sdk.NewCoin(params.DefaultBondDenom, sdkmath.NewInt(50000000000))) - govParams.MinInitialDepositRatio = "0.000000000000000000" + govParams.MinInitialDepositRatio = minDepositRatio govParams.ExpeditedThreshold = "0.750000000000000000" expediteVotingPeriod := 86400 * time.Second govParams.ExpeditedVotingPeriod = &expediteVotingPeriod diff --git a/x/legacy/bet/types/codec.go b/x/legacy/bet/types/codec.go index 16f7f480..fe855bec 100644 --- a/x/legacy/bet/types/codec.go +++ b/x/legacy/bet/types/codec.go @@ -25,15 +25,11 @@ func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } -var ( - // amino is the legacy amino codec - amino = codec.NewLegacyAmino() - // ModuleCdc is the codec of the module - ModuleCdc = codec.NewAminoCodec(amino) -) +// Amino is the legacy Amino codec +var Amino = codec.NewLegacyAmino() func init() { - RegisterLegacyAminoCodec(amino) + RegisterLegacyAminoCodec(Amino) // cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + sdk.RegisterLegacyAminoCodec(Amino) } diff --git a/x/legacy/bet/types/messages_bet.go b/x/legacy/bet/types/messages_bet.go index 0327a2e0..b9fbcc4c 100644 --- a/x/legacy/bet/types/messages_bet.go +++ b/x/legacy/bet/types/messages_bet.go @@ -45,7 +45,7 @@ func (msg *MsgWager) GetSigners() []sdk.AccAddress { // GetSignBytes returns sortJson form of its message func (msg *MsgWager) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/bet/types/messages_params.go b/x/legacy/bet/types/messages_params.go index aa88b732..369c103d 100644 --- a/x/legacy/bet/types/messages_params.go +++ b/x/legacy/bet/types/messages_params.go @@ -26,7 +26,7 @@ func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) + return sdk.MustSortJSON(Amino.MustMarshalJSON(&msg)) } // ValidateBasic does a sanity check on the provided data. diff --git a/x/legacy/house/types/codec.go b/x/legacy/house/types/codec.go index d428622f..ed8774f0 100644 --- a/x/legacy/house/types/codec.go +++ b/x/legacy/house/types/codec.go @@ -33,15 +33,11 @@ func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } -var ( - // amino is the legacy amino codec - amino = codec.NewLegacyAmino() - // ModuleCdc is the codec of the module - ModuleCdc = codec.NewAminoCodec(amino) -) +// Amino is the legacy Amino codec +var Amino = codec.NewLegacyAmino() func init() { - RegisterLegacyAminoCodec(amino) + RegisterLegacyAminoCodec(Amino) // cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + sdk.RegisterLegacyAminoCodec(Amino) } diff --git a/x/legacy/house/types/message_deposit.go b/x/legacy/house/types/message_deposit.go index 65dae2b3..115cf302 100644 --- a/x/legacy/house/types/message_deposit.go +++ b/x/legacy/house/types/message_deposit.go @@ -43,7 +43,7 @@ func (msg *MsgDeposit) GetSigners() []sdk.AccAddress { // GetSignBytes return the marshalled bytes of the msg func (msg *MsgDeposit) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/house/types/message_withdraw.go b/x/legacy/house/types/message_withdraw.go index b7b0c973..238711f3 100644 --- a/x/legacy/house/types/message_withdraw.go +++ b/x/legacy/house/types/message_withdraw.go @@ -47,7 +47,7 @@ func (msg *MsgWithdraw) GetSigners() []sdk.AccAddress { // GetSignBytes return the marshalled bytes of the msg func (msg *MsgWithdraw) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/house/types/messages_params.go b/x/legacy/house/types/messages_params.go index ba6bb187..e28b914f 100644 --- a/x/legacy/house/types/messages_params.go +++ b/x/legacy/house/types/messages_params.go @@ -26,7 +26,7 @@ func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) + return sdk.MustSortJSON(Amino.MustMarshalJSON(&msg)) } // ValidateBasic does a sanity check on the provided data. diff --git a/x/legacy/market/types/codec.go b/x/legacy/market/types/codec.go index 348363be..d259d782 100644 --- a/x/legacy/market/types/codec.go +++ b/x/legacy/market/types/codec.go @@ -30,15 +30,11 @@ func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } -var ( - // amino is the legacy amino codec - amino = codec.NewLegacyAmino() - // ModuleCdc is the codec of the module - ModuleCdc = codec.NewAminoCodec(amino) -) +// Amino is the legacy Amino codec +var Amino = codec.NewLegacyAmino() func init() { - RegisterLegacyAminoCodec(amino) + RegisterLegacyAminoCodec(Amino) // cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + sdk.RegisterLegacyAminoCodec(Amino) } diff --git a/x/legacy/market/types/message_market.go b/x/legacy/market/types/message_market.go index 56ceea55..3fb69c19 100644 --- a/x/legacy/market/types/message_market.go +++ b/x/legacy/market/types/message_market.go @@ -37,7 +37,7 @@ func (msg *MsgAdd) GetSigners() []sdk.AccAddress { // GetSignBytes return the marshalled bytes of the msg func (msg *MsgAdd) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } @@ -94,7 +94,7 @@ func (msg *MsgUpdate) GetSigners() []sdk.AccAddress { // GetSignBytes return the marshalled bytes of the msg func (msg *MsgUpdate) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/market/types/message_market_resolve.go b/x/legacy/market/types/message_market_resolve.go index f74d5172..02d3ed92 100644 --- a/x/legacy/market/types/message_market_resolve.go +++ b/x/legacy/market/types/message_market_resolve.go @@ -37,7 +37,7 @@ func (msg *MsgResolve) GetSigners() []sdk.AccAddress { // GetSignBytes return the marshalled bytes of the msg func (msg *MsgResolve) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/market/types/messages_params.go b/x/legacy/market/types/messages_params.go index e357ac1e..c5ae366a 100644 --- a/x/legacy/market/types/messages_params.go +++ b/x/legacy/market/types/messages_params.go @@ -26,7 +26,7 @@ func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) + return sdk.MustSortJSON(Amino.MustMarshalJSON(&msg)) } // ValidateBasic does a sanity check on the provided data. diff --git a/x/legacy/orderbook/types/codec.go b/x/legacy/orderbook/types/codec.go index 57a29568..db8620f7 100644 --- a/x/legacy/orderbook/types/codec.go +++ b/x/legacy/orderbook/types/codec.go @@ -23,15 +23,11 @@ func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } -var ( - // amino is the legacy amino codec - amino = codec.NewLegacyAmino() - // ModuleCdc is the codec of the module - ModuleCdc = codec.NewAminoCodec(amino) -) +// Amino is the legacy Amino codec +var Amino = codec.NewLegacyAmino() func init() { - RegisterLegacyAminoCodec(amino) + RegisterLegacyAminoCodec(Amino) // cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + sdk.RegisterLegacyAminoCodec(Amino) } diff --git a/x/legacy/orderbook/types/messages_params.go b/x/legacy/orderbook/types/messages_params.go index e357ac1e..c5ae366a 100644 --- a/x/legacy/orderbook/types/messages_params.go +++ b/x/legacy/orderbook/types/messages_params.go @@ -26,7 +26,7 @@ func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) + return sdk.MustSortJSON(Amino.MustMarshalJSON(&msg)) } // ValidateBasic does a sanity check on the provided data. diff --git a/x/legacy/ovm/types/codec.go b/x/legacy/ovm/types/codec.go index 0437708d..1ab5c5bb 100644 --- a/x/legacy/ovm/types/codec.go +++ b/x/legacy/ovm/types/codec.go @@ -26,15 +26,11 @@ func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } -var ( - // amino is the legacy amino codec - amino = codec.NewLegacyAmino() - // ModuleCdc is the codec of the module - ModuleCdc = codec.NewAminoCodec(amino) -) +// Amino is the legacy Amino codec +var Amino = codec.NewLegacyAmino() func init() { - RegisterLegacyAminoCodec(amino) + RegisterLegacyAminoCodec(Amino) // cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + sdk.RegisterLegacyAminoCodec(Amino) } diff --git a/x/legacy/ovm/types/message_pubkeys_proposal.go b/x/legacy/ovm/types/message_pubkeys_proposal.go index 1861d2d3..b5cd530d 100644 --- a/x/legacy/ovm/types/message_pubkeys_proposal.go +++ b/x/legacy/ovm/types/message_pubkeys_proposal.go @@ -42,7 +42,7 @@ func (msg *MsgSubmitPubkeysChangeProposalRequest) GetSigners() []sdk.AccAddress // GetSignBytes returns sortJson form of its message func (msg *MsgSubmitPubkeysChangeProposalRequest) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/ovm/types/message_pubkeys_vote.go b/x/legacy/ovm/types/message_pubkeys_vote.go index fae5c013..2a9b91fb 100644 --- a/x/legacy/ovm/types/message_pubkeys_vote.go +++ b/x/legacy/ovm/types/message_pubkeys_vote.go @@ -44,7 +44,7 @@ func (msg *MsgVotePubkeysChangeRequest) GetSigners() []sdk.AccAddress { // GetSignBytes returns sortJson form of its message func (msg *MsgVotePubkeysChangeRequest) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/ovm/types/messages_params.go b/x/legacy/ovm/types/messages_params.go index b847a267..ddc20ef6 100644 --- a/x/legacy/ovm/types/messages_params.go +++ b/x/legacy/ovm/types/messages_params.go @@ -26,7 +26,7 @@ func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) + return sdk.MustSortJSON(Amino.MustMarshalJSON(&msg)) } // ValidateBasic does a sanity check on the provided data. diff --git a/x/legacy/reward/types/codec.go b/x/legacy/reward/types/codec.go index f175932b..c0b8f1e7 100644 --- a/x/legacy/reward/types/codec.go +++ b/x/legacy/reward/types/codec.go @@ -36,13 +36,11 @@ func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } -var ( - amino = codec.NewLegacyAmino() - ModuleCdc = codec.NewAminoCodec(amino) -) +// Amino is the legacy Amino codec +var Amino = codec.NewLegacyAmino() func init() { - RegisterLegacyAminoCodec(amino) - cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + RegisterLegacyAminoCodec(Amino) + cryptocodec.RegisterCrypto(Amino) + sdk.RegisterLegacyAminoCodec(Amino) } diff --git a/x/legacy/reward/types/messages_campaign.go b/x/legacy/reward/types/messages_campaign.go index 58919c7d..becde6a1 100644 --- a/x/legacy/reward/types/messages_campaign.go +++ b/x/legacy/reward/types/messages_campaign.go @@ -47,7 +47,7 @@ func (msg *MsgCreateCampaign) GetSigners() []sdk.AccAddress { } func (msg *MsgCreateCampaign) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } @@ -114,7 +114,7 @@ func (msg *MsgUpdateCampaign) GetSigners() []sdk.AccAddress { } func (msg *MsgUpdateCampaign) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } @@ -177,7 +177,7 @@ func (msg *MsgWithdrawFunds) GetSigners() []sdk.AccAddress { } func (msg *MsgWithdrawFunds) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/reward/types/messages_params.go b/x/legacy/reward/types/messages_params.go index 6af6f1b5..c100f1a3 100644 --- a/x/legacy/reward/types/messages_params.go +++ b/x/legacy/reward/types/messages_params.go @@ -26,7 +26,7 @@ func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) + return sdk.MustSortJSON(Amino.MustMarshalJSON(&msg)) } // ValidateBasic does a sanity check on the provided data. diff --git a/x/legacy/reward/types/messages_promoter.go b/x/legacy/reward/types/messages_promoter.go index c83924b1..3cb58e23 100644 --- a/x/legacy/reward/types/messages_promoter.go +++ b/x/legacy/reward/types/messages_promoter.go @@ -47,7 +47,7 @@ func (msg *MsgSetPromoterConf) GetSigners() []sdk.AccAddress { } func (msg *MsgSetPromoterConf) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } @@ -105,7 +105,7 @@ func (msg *MsgCreatePromoter) GetSigners() []sdk.AccAddress { } func (msg *MsgCreatePromoter) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/reward/types/messages_reward.go b/x/legacy/reward/types/messages_reward.go index 58849780..84b1b77b 100644 --- a/x/legacy/reward/types/messages_reward.go +++ b/x/legacy/reward/types/messages_reward.go @@ -47,7 +47,7 @@ func (msg *MsgGrantReward) GetSigners() []sdk.AccAddress { } func (msg *MsgGrantReward) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/subaccount/types/codec.go b/x/legacy/subaccount/types/codec.go index 6257d243..c9be2daf 100644 --- a/x/legacy/subaccount/types/codec.go +++ b/x/legacy/subaccount/types/codec.go @@ -35,15 +35,11 @@ func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } -var ( - // amino is the legacy amino codec - amino = codec.NewLegacyAmino() - // ModuleCdc is the codec of the module - ModuleCdc = codec.NewAminoCodec(amino) -) +// Amino is the legacy Amino codec +var Amino = codec.NewLegacyAmino() func init() { - RegisterLegacyAminoCodec(amino) - cryptocodec.RegisterCrypto(amino) - sdk.RegisterLegacyAminoCodec(amino) + RegisterLegacyAminoCodec(Amino) + cryptocodec.RegisterCrypto(Amino) + sdk.RegisterLegacyAminoCodec(Amino) } diff --git a/x/legacy/subaccount/types/messages_bet.go b/x/legacy/subaccount/types/messages_bet.go index 9fc179b8..5f19ead5 100644 --- a/x/legacy/subaccount/types/messages_bet.go +++ b/x/legacy/subaccount/types/messages_bet.go @@ -39,7 +39,7 @@ func (msg *MsgWager) GetSigners() []sdk.AccAddress { // GetSignBytes returns sortJson form of its message func (msg *MsgWager) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/subaccount/types/messages_house.go b/x/legacy/subaccount/types/messages_house.go index 834dac37..16798a54 100644 --- a/x/legacy/subaccount/types/messages_house.go +++ b/x/legacy/subaccount/types/messages_house.go @@ -36,7 +36,7 @@ func (msg *MsgHouseDeposit) GetSigners() []sdk.AccAddress { // GetSignBytes returns sortJson form of its message func (msg *MsgHouseDeposit) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } @@ -73,7 +73,7 @@ func (msg *MsgHouseWithdraw) GetSigners() []sdk.AccAddress { // GetSignBytes returns sortJson form of its message func (msg *MsgHouseWithdraw) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } diff --git a/x/legacy/subaccount/types/messages_params.go b/x/legacy/subaccount/types/messages_params.go index fd6b2d65..ba09ffad 100644 --- a/x/legacy/subaccount/types/messages_params.go +++ b/x/legacy/subaccount/types/messages_params.go @@ -26,7 +26,7 @@ func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { - return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) + return sdk.MustSortJSON(Amino.MustMarshalJSON(&msg)) } // ValidateBasic does a sanity check on the provided data. diff --git a/x/legacy/subaccount/types/messages_subaccount.go b/x/legacy/subaccount/types/messages_subaccount.go index 84c21194..c81321ed 100644 --- a/x/legacy/subaccount/types/messages_subaccount.go +++ b/x/legacy/subaccount/types/messages_subaccount.go @@ -31,7 +31,7 @@ func (msg *MsgCreate) GetSigners() []sdk.AccAddress { // GetSignBytes returns sortJson form of its message func (msg *MsgCreate) GetSignBytes() []byte { - bz := ModuleCdc.MustMarshalJSON(msg) + bz := Amino.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } From 606712abd0eae35d98976ea8321cc4ec55c9a9fc Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Tue, 11 Feb 2025 16:25:16 +0300 Subject: [PATCH 11/16] fix(ci): whitelist api dir in gosec --- .github/workflows/gosec.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/gosec.yml b/.github/workflows/gosec.yml index 7c4bf21c..7ae80257 100644 --- a/.github/workflows/gosec.yml +++ b/.github/workflows/gosec.yml @@ -30,7 +30,7 @@ jobs: uses: securego/gosec@master with: # we let the report trigger content trigger a failure using the GitHub Security features. - args: "-no-fail -fmt sarif -out results.sarif ./..." + args: "-no-fail -fmt sarif -out results.sarif ./... -exclude=./api" - name: Upload SARIF file uses: github/codeql-action/upload-sarif@v2 From 6bc93aab81079b61db4df86ec3b898deee48814c Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Tue, 11 Feb 2025 18:32:38 +0300 Subject: [PATCH 12/16] fix: upgrade wasmvm --- Dockerfile | 10 +++++----- go.mod | 4 ++-- go.sum | 8 ++++---- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index 45eb7515..07104481 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,7 +8,7 @@ ARG BUILD_TAGS="netgo,ledger,muslc" # Builder # -------------------------------------------------------- -FROM golang:${GO_VERSION}-alpine3.20 as builder +FROM golang:${GO_VERSION}-alpine3.20 AS builder ARG GIT_VERSION ARG GIT_COMMIT @@ -27,12 +27,12 @@ RUN --mount=type=cache,target=/root/.cache/go-build \ go mod download # Cosmwasm - Download correct libwasmvm version -RUN ARCH=$(uname -m) && WASMVM_VERSION=$(go list -m github.com/CosmWasm/wasmvm | sed 's/.* //') && \ +RUN ARCH=$(uname -m) && WASMVM_VERSION=$(go list -m github.com/CosmWasm/wasmvm/v2 | sed 's/.* //') && \ wget https://github.com/CosmWasm/wasmvm/releases/download/$WASMVM_VERSION/libwasmvm_muslc.$ARCH.a \ - -O /lib/libwasmvm_muslc.a && \ + -O /lib/libwasmvm_muslc.$ARCH.a && \ # verify checksum wget https://github.com/CosmWasm/wasmvm/releases/download/$WASMVM_VERSION/checksums.txt -O /tmp/checksums.txt && \ - sha256sum /lib/libwasmvm_muslc.a | grep $(cat /tmp/checksums.txt | grep libwasmvm_muslc.$ARCH | cut -d ' ' -f 1) + sha256sum /lib/libwasmvm_muslc.$ARCH.a | grep $(cat /tmp/checksums.txt | grep libwasmvm_muslc.$ARCH | cut -d ' ' -f 1) # Copy the remaining files COPY . . @@ -62,7 +62,7 @@ FROM ${RUNNER_IMAGE} COPY --from=builder /sge/build/sged /bin/sged -ENV HOME /sge +ENV HOME=/sge WORKDIR $HOME EXPOSE 26656 diff --git a/go.mod b/go.mod index 3fec5595..ec580fd7 100644 --- a/go.mod +++ b/go.mod @@ -20,7 +20,7 @@ require ( cosmossdk.io/x/feegrant v0.1.1 cosmossdk.io/x/nft v0.1.1 cosmossdk.io/x/upgrade v0.1.4 - github.com/CosmWasm/wasmd v0.53.0 + github.com/CosmWasm/wasmd v0.53.2 github.com/bufbuild/buf v1.34.0 github.com/cometbft/cometbft v0.38.15 github.com/cosmos/cosmos-db v1.1.1 @@ -97,7 +97,7 @@ require ( github.com/Antonboom/testifylint v1.5.2 // indirect github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c // indirect github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c // indirect - github.com/CosmWasm/wasmvm/v2 v2.2.1 // indirect + github.com/CosmWasm/wasmvm/v2 v2.2.2 // indirect github.com/Crocmagnon/fatcontext v0.5.3 // indirect github.com/DataDog/datadog-go v4.8.3+incompatible // indirect github.com/DataDog/zstd v1.5.5 // indirect diff --git a/go.sum b/go.sum index c978caae..89385b45 100644 --- a/go.sum +++ b/go.sum @@ -259,10 +259,10 @@ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03 github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c h1:pxW6RcqyfI9/kWtOwnv/G+AzdKuy2ZrqINhenH4HyNs= github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/CosmWasm/wasmd v0.53.0 h1:kdaoAi20bIb4VCsxw9pRaT2g5PpIp82Wqrr9DRVN9ao= -github.com/CosmWasm/wasmd v0.53.0/go.mod h1:FJl/aWjdpGof3usAMFQpDe07Rkx77PUzp0cygFMOvtw= -github.com/CosmWasm/wasmvm/v2 v2.2.1 h1:cmOnM+TDfUl2VRugeo1eJBw4U/Lw0WLviuQHKSo9DVQ= -github.com/CosmWasm/wasmvm/v2 v2.2.1/go.mod h1:bMhLQL4Yp9CzJi9A83aR7VO9wockOsSlZbT4ztOl6bg= +github.com/CosmWasm/wasmd v0.53.2 h1:c3MQjeQq+r+Zj2rPeW+c9kJmTevuNnZOIkiiCP/3bg4= +github.com/CosmWasm/wasmd v0.53.2/go.mod h1:gP10E56tuToU5rsZR7vZLBL5ssW2mie6KN/WrQLG7/I= +github.com/CosmWasm/wasmvm/v2 v2.2.2 h1:MaQMtaZN8L08N0uAlBlOICP+GWolibJsajHGo3fQ03w= +github.com/CosmWasm/wasmvm/v2 v2.2.2/go.mod h1:bMhLQL4Yp9CzJi9A83aR7VO9wockOsSlZbT4ztOl6bg= github.com/Crocmagnon/fatcontext v0.5.3 h1:zCh/wjc9oyeF+Gmp+V60wetm8ph2tlsxocgg/J0hOps= github.com/Crocmagnon/fatcontext v0.5.3/go.mod h1:XoCQYY1J+XTfyv74qLXvNw4xFunr3L1wkopIIKG7wGM= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= From eed5acedc12ab6a57f5b253f4ec10d8e0969c0a0 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Wed, 12 Feb 2025 12:34:32 +0300 Subject: [PATCH 13/16] refactor: move max wasm size to wasm.go --- app/app.go | 14 -------------- app/wasm.go | 13 +++++++++++++ 2 files changed, 13 insertions(+), 14 deletions(-) diff --git a/app/app.go b/app/app.go index d1a318f9..82cbbe19 100644 --- a/app/app.go +++ b/app/app.go @@ -63,8 +63,6 @@ import ( _ "github.com/cosmos/ibc-go/v8/modules/apps/29-fee" // import for side-effects ibckeeper "github.com/cosmos/ibc-go/v8/modules/core/keeper" - wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" - "github.com/sge-network/sge/app/keepers" "github.com/sge-network/sge/app/upgrades" v10 "github.com/sge-network/sge/app/upgrades/v10" @@ -85,8 +83,6 @@ var ( Upgrades = []upgrades.Upgrade{ v10.Upgrade, } - // default wasmd binary maximum allowed size - defaultMaxWasmSize = 1500 * 1024 // 1.5 MB ) var ( @@ -164,8 +160,6 @@ func NewApp( appOpts servertypes.AppOptions, baseAppOptions ...func(*baseapp.BaseApp), ) (*App, error) { - overrideWasmVariables() - var ( app = &App{AppKeepers: &keepers.AppKeepers{ScopedKeepers: make(map[string]capabilitykeeper.ScopedKeeper)}} appBuilder *runtime.AppBuilder @@ -421,11 +415,3 @@ func (app *App) setupUpgradeHandlers() { ) } } - -// overrideWasmVariables overrides the wasm variables to: -// - allow for larger wasm files -func overrideWasmVariables() { - // Override Wasm size limitation from WASMD. - wasmtypes.MaxWasmSize = defaultMaxWasmSize - wasmtypes.MaxProposalWasmSize = wasmtypes.MaxWasmSize -} diff --git a/app/wasm.go b/app/wasm.go index c1fcc8b7..02151275 100644 --- a/app/wasm.go +++ b/app/wasm.go @@ -22,11 +22,16 @@ import ( porttypes "github.com/cosmos/ibc-go/v8/modules/core/05-port/types" ) +// default wasmd binary maximum allowed size +var defaultMaxWasmSize = 1500 * 1024 // 1.5 MB + // registerWasmModules register CosmWasm keepers and non dependency inject modules. func (app *App) registerWasmModules( appOpts servertypes.AppOptions, wasmOpts ...wasmkeeper.Option, ) (porttypes.IBCModule, error) { + overrideWasmVariables() + // set up non depinject support modules store keys if err := app.RegisterStores( storetypes.NewKVStoreKey(wasmtypes.StoreKey), @@ -153,3 +158,11 @@ func (app *App) setAnteHandler(txConfig client.TxConfig, wasmConfig wasmtypes.Wa app.SetAnteHandler(anteHandler) return nil } + +// overrideWasmVariables overrides the wasm variables to: +// - allow for larger wasm files +func overrideWasmVariables() { + // Override Wasm size limitation from WASMD. + wasmtypes.MaxWasmSize = defaultMaxWasmSize + wasmtypes.MaxProposalWasmSize = wasmtypes.MaxWasmSize +} From d4bba51fbd353355ec0d23ddf26eac0861e0f4a3 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Wed, 12 Feb 2025 18:32:20 +0300 Subject: [PATCH 14/16] fix: wasmvm path --- app/wasm.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/wasm.go b/app/wasm.go index 02151275..62db782d 100644 --- a/app/wasm.go +++ b/app/wasm.go @@ -41,7 +41,7 @@ func (app *App) registerWasmModules( scopedWasmKeeper := app.CapabilityKeeper.ScopeToModule(wasmtypes.ModuleName) - wasmDir := filepath.Join(DefaultNodeHome, "wasm") + wasmDir := filepath.Join(DefaultNodeHome, "cwvm") wasmConfig, err := wasm.ReadWasmConfig(appOpts) if err != nil { From 3cb7aa87f3f840e6838715e25a8856cf2c6aef96 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Wed, 19 Feb 2025 15:10:19 +0300 Subject: [PATCH 15/16] feat: re-enable mint module txs --- app/app_config.go | 1 + x/mint/module.go | 6 +----- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/app/app_config.go b/app/app_config.go index e7188caa..52975800 100644 --- a/app/app_config.go +++ b/app/app_config.go @@ -49,6 +49,7 @@ import ( ibctransfertypes "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types" ibcexported "github.com/cosmos/ibc-go/v8/modules/core/exported" mintmodulev1 "github.com/sge-network/sge/api/sge/mint/module/v1" + _ "github.com/sge-network/sge/x/mint" // import for side-effects minttypes "github.com/sge-network/sge/x/mint/types" "google.golang.org/protobuf/types/known/durationpb" ) diff --git a/x/mint/module.go b/x/mint/module.go index 7957e6d0..7b0d1051 100644 --- a/x/mint/module.go +++ b/x/mint/module.go @@ -4,7 +4,6 @@ import ( "context" "encoding/json" "fmt" - "testing" "cosmossdk.io/core/appmodule" "cosmossdk.io/core/store" @@ -129,10 +128,7 @@ func (am AppModule) IsAppModule() {} // RegisterServices registers a GRPC query service to respond to the // module-specific GRPC queries. func (am AppModule) RegisterServices(cfg module.Configurator) { - // transactions deprecated in favor of v2 - if testing.Testing() { - types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) - } + types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) types.RegisterQueryServer(cfg.QueryServer(), keeper.NewQueryServerImpl(am.keeper)) m := keeper.NewMigrator(am.keeper, am.legacySubspace) From a393153f3a512d81734e64a3a556871112514851 Mon Sep 17 00:00:00 2001 From: scorpioborn <97235353+scorpioborn@users.noreply.github.com> Date: Thu, 20 Feb 2025 17:44:57 +0300 Subject: [PATCH 16/16] feat: v1.8.1 upgrade handler --- app/app.go | 2 ++ app/upgrades/v11/consts.go | 19 +++++++++++++++++++ app/upgrades/v11/upgrades.go | 20 ++++++++++++++++++++ 3 files changed, 41 insertions(+) create mode 100644 app/upgrades/v11/consts.go create mode 100644 app/upgrades/v11/upgrades.go diff --git a/app/app.go b/app/app.go index 82cbbe19..4f57968d 100644 --- a/app/app.go +++ b/app/app.go @@ -66,6 +66,7 @@ import ( "github.com/sge-network/sge/app/keepers" "github.com/sge-network/sge/app/upgrades" v10 "github.com/sge-network/sge/app/upgrades/v10" + v11 "github.com/sge-network/sge/app/upgrades/v11" "github.com/sge-network/sge/docs" ) @@ -82,6 +83,7 @@ var ( Upgrades = []upgrades.Upgrade{ v10.Upgrade, + v11.Upgrade, } ) diff --git a/app/upgrades/v11/consts.go b/app/upgrades/v11/consts.go new file mode 100644 index 00000000..e9dd9268 --- /dev/null +++ b/app/upgrades/v11/consts.go @@ -0,0 +1,19 @@ +package v11 + +import ( + store "cosmossdk.io/store/types" + + "github.com/sge-network/sge/app/upgrades" +) + +// UpgradeName defines the on-chain upgrade name for the v1.8.1 upgrade. +const UpgradeName = "v1.8.1" + +var Upgrade = upgrades.Upgrade{ + UpgradeName: UpgradeName, + CreateUpgradeHandler: CreateUpgradeHandler, + StoreUpgrades: store.StoreUpgrades{ + Added: []string{}, + Deleted: []string{}, + }, +} diff --git a/app/upgrades/v11/upgrades.go b/app/upgrades/v11/upgrades.go new file mode 100644 index 00000000..4be778a6 --- /dev/null +++ b/app/upgrades/v11/upgrades.go @@ -0,0 +1,20 @@ +package v11 + +import ( + "context" + + upgradetypes "cosmossdk.io/x/upgrade/types" + "github.com/cosmos/cosmos-sdk/types/module" + + "github.com/sge-network/sge/app/keepers" +) + +func CreateUpgradeHandler( + mm *module.Manager, + configurator module.Configurator, + _ *keepers.AppKeepers, +) upgradetypes.UpgradeHandler { + return func(ctx context.Context, _ upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { + return mm.RunMigrations(ctx, configurator, fromVM) + } +}